Skip to content

RanggaGultom/ic-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ic-api

ic-api is a wrapper to connect you trough Intersection Controller game datas. You can get/search for users, trending maps and other things from the game.

Example

Before you get into these example, remember this package is using much asynchronomous function

Search a user

const ic = require("ic-api")
ic.user.search("ShadowTree").then(x => console.log(x)) //will return array of Users named ShadowTree

Search a map

const ic = require("ic-api")
ic.map.search(1, "Diverging Diamond").then(x => console.log(x)) //will return array of Maps named Diverging Diamond in simulation mode

Show map's comments

So you have to search a map, or anything from Map class. I recommend to use asynchronomous function than spamming ".then" callbacks.

const ic = require("ic-api")
async function getComment() {
    const map = await ic.map.search(1, "Diverging Diamond") //search map
    const comments = await map.comments(5) //list a comment, they will come out in array
    return console.log(coments[4]) //choose one of the array, or do map or whatever you want
}

External links

NPM

Github

Python version (Made by Feeeeddmmmeee)

Discord server

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published