1.3.1 • Published 1 year ago

bloons-js v1.3.1

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

bloons-js

A wrapper to work with the StatsNite Bloons TD 6 API

Install

$ npm install bloons-js --save

Use

Module

import Bloonsjs from 'bloons-js';

CommonJS

const Bloonsjs = require('bloons-js');

Examples

Module

import Bloonsjs from 'bloons-js';

async function getTowersId() {
    console.log(await BloonsJS.getAllTowers(true));
}
getTowersId();

CommonJS

const Bloonsjs = require('bloons-js');

async function getTowersId() {
    console.log(await BloonsJS.getAllTowers(true));
}
getTowersId();

API

getAllTowers(onlyId)

Returns information from all towers

Params:

  • onlyId: boolean optional - displays only the id of the towers

getTower(id)

Returns information from a specific tower

Params:

  • id: string - tower id

getAllHeroes(onlyId)

Returns information from all heroes

Params:

  • onlyId: boolean optional - displays only the id of the heroes

getHero(id)

Returns information from a specific hero

Params:

  • id: string - hero id

getAllBloons(onlyId)

Returns information from all bloons

Params:

  • onlyId: boolean optional - displays only the id of the bloons

getBloon(id)

Returns information from a specific bloon

Params:

  • id: string - bloon id

getTowerImage(towerId, level)

Returns tower image

Params:

  • towerId: string - tower id
  • level: string - tower level, for the default sprite use 'base', for path evolutions use '001', '002', '020', etc. for paragons forms use 'paragon'

getHeroImage(heroId, level, skinId)

Returns hero image

Params:

  • heroId: string - hero id
  • level: string - hero level, use numbers from 1 to 20, but only those where there are changes in the sprite
  • skinId: string - hero skin id

getBloonImage(bloonId, type)

Returns bloon image

Params:

  • bloonId: string - bloon id
  • type: string - bloon type (camo, regrow, camoregrow, fort, fortcamo, fortcamoregrow, fortregrow)
1.3.1

1 year ago

1.3.0

1 year ago

1.2.0

1 year ago

1.1.2

1 year ago

1.1.1

1 year ago

1.1.0

1 year ago

1.0.0

1 year ago