GithubHelp home page GithubHelp logo

anant-k-singh / the-if-experiment Goto Github PK

View Code? Open in Web Editor NEW

This project forked from sanketpandia/the-if-experiment

1.0 1.0 0.0 4.84 MB

A bot for discord, which connects airtable and the infinite flight live API

JavaScript 24.22% HTML 75.77% Procfile 0.01%

the-if-experiment's Introduction

The IF Experiment

Table of contents

Commands

pilot_stats:

  • Fetches the stats of the pilot from the airtable database. Needs to be configured properly. Check docs for configuration
  • Pilot needs to have the callsign in their discord display name and pattern should be conigured in the bot configs
  • Usage syntax: >pilot_stats

cm_stats:

  • Fetches the career mode stats of the pilot from the airtable. Needs to be configured properly. Check docs for configuration
  • Usage syntax: >cm_stats
  • Pilot needs to have the callsign in their discord display name and pattern should be conigured in the bot configs

live:

  • Fetches the live flights of the VA. The callsign pattern needs to be configured in the configurations
  • live_small command not updated yet. To be done
  • Usage syntax: >live
  • Usage syntax: >live_small

aircraft:

  • Fetches the aircraft performances of different aircrafts. The repository can be updated. Images can also be added to the repository later to fetch the flight data.
  • Usage syntax: >aircraft A318-100

ifatc:

  • Fetches the active IFATC regions in the expert server.
  • Usage syntax: >ifatc

link and learn:

  • Fetches the relevant docs as marked by the server admin
  • Usage syntax: >learn keyword
  • Usage syntax: >link keyword

if_stats

  • Usage syntax >if_stats Cameron
  • Fetches the in game stats of the user

atis

  • Usage syntax >atis EGLL
  • Fetches the ATIS information of Active Airports in the Expert Server

prep_my_flight

  • Usage syntax >prep_my_flight
  • Fetches the checklists of the aircraft you are currently flying.
  • Need to be in VA discord with the callsign patterns configured.

Installation

  • Click here to install the bot in your server

Configure

Do not change the left side text (i.e. text before the colon).

  • In callsign patterns replace the following:

    • Switch the value in if_callsign to the format of your VA. For example, if you are BAVA, switch it to "if_callsign": "Speedbird ^^^VA" If you are from AFKLM, switch it to: "if_callsign": ^^^AK" When searching for pilots from your VA, the ^^^ will be substituted to their corresponding callsign numbers. So let them be

    • Switch the value in discord_callsign to the format you use in your server. For example if the display name format in your discord server is Cameron (MHVA010), then the value should look like "discord_callsign" : "MHVA^^^" . When you have done this, it will know what your current flight callsign looks like and will be able to facilitate the use of multiple commands

  • There are two more fields called "link" and "learn": Inside these you can place multiple keywords and texts to correspond them. For example if you cc link is https://community.infiniteflight.com/, your data would look like this, { "link": { "cc" : "https://community.infiniteflight.com/" } }. You can add any number of links and document links. So after you are done, your text should look like this now:

    {
    "callsign_patterns": {
        "if_callsign": "Speedbird ^^^VA",
        "discord_callsign": "BAVA^^^"
    },
    "learn": {
        "ifc": "https://community.infiniteflight.com",
        "if": "https://infiniteflight.com"
    },
    "link": {
        "ifatc": "https://ifatc.org",
        "cc": "https://infiniteflight.com"
    }
    }
    
  • Validate your text in https://jsonlint.com/. Copy the text and paste it in the text box there and click on 'Validate JSON'.

  • If it says 'VALID JSON' in the results, then copy the text to the newly created channel (#the-aircraft-experiment) and paste it there

  • go to a public channel now and run the command '>update'. You should get a reply 'Configs updated successfully'.

Now you may try out all the commands in the list. You won't be able to use cm_stats and pilot_stats. You should be good to go.

Airtable_Configs

  • Contact @sanketpandia on your IFC to setup your airtable if you don't have a developer in your VA who understands JSON. You will be able to fetch the pilot stats like rank, flight time, etc from your airtable.

the-if-experiment's People

Contributors

anant-k-singh avatar sam-neale avatar sanketpandia avatar sanketpandia-mt avatar

Stargazers

 avatar

Watchers

 avatar

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.