GithubHelp home page GithubHelp logo

59naga / gbf-data Goto Github PK

View Code? Open in Web Editor NEW
3.0 3.0 1.0 118 KB

(no longer maintained)【キャラクター、レイドボス簡易情報】build gbf json files using yaml

JavaScript 100.00%
gbf granbluefantasy javascript

gbf-data's Introduction

gbf-data

Npm version Build Status

src/chars -> dist/chars.json

gbf-teamsimulatorで使用します。

src/raid -> dist/raid.json

gbf-raid-serverでtwitter検索に使用するボス名の一覧をjsonで出力しdistに保存しています。

用法

axiosを使用してunpkg.comから直接使用するか、jsonファイルをダウンロードしてrequire/importしてください。

import createIoClient from 'socket.io-client';
import bosses from './gbf-raid-bosses.json'

createIoClient('https://gbf-raid-server.herokuapp.com/')
  .emit('gbf-raid-server:cache', (error, tweets) => {
    console.log(tweets);
    // [{id: '451A60CE', name: 'Lv100 ティアマト・マグナ=エア', createdAt: '2018-07-06 10:26:56'}, {...}]
  })
  .on('gbf-raid-server:tweet', (tweet) => {
    console.log(tweet);
    // {"id":"685D3F6E","name":"Lvl 100 Tiamat Omega Ayr","memo":"","urlOrigin":"twitter.com/0chokdee0/status/1016741472874291200", /*...*/ ,"createdAt":"2018-07-11 02:50:31"}

    const boss = bosses.find(boss => tweet.name === boss.name || tweet.name === boss.name_en)
    console.log(boss)
    // {"alias":"lv100-tiamat-omega-ayr","category":"impossible1","id":"","name":"Lv100 ティアマト・マグナ=エア","name_en":"Lvl 100 Tiamat Omega Ayr","image":"https://pbs.twimg.com/media/CT6cNUBUAAETdz6.jpg","element":"Wind"}
  });

jsonは一次元配列でボスごとにオブジェクトで下記の情報を持ちます。

  • alias: stringidが定義できていないため、現状idの代わりに識別子として使用する文字列です
  • category: string共闘部屋を基準に見た共闘の種別。
  • id: string…実際のゲーム画像などで使用されている10桁の数値。ティアマトマグナHL…2040020000など。現在管理できていません。
  • name: string…twitterの救援ツイートで使用されるボスの正式名称(日本語版)。
  • name_en: string…twitterの救援ツイートで使用されるボスの正式名称(英語版)。
  • image: string…twitterで添付される画像。日本語のものを使用
  • element: "None" | "Fire" | "Water" | "Earth" | "Wind" | "Light" | "Dark"…ボスの属性。GBF-Raidersから転載しています

ライセンス

MIT

gbf-data's People

Contributors

59naga avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

recnaleerf

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.