3.0.1 • Published 2 years ago

lol-esports-spectate v3.0.1

Weekly downloads
8
License
ISC
Repository
github
Last release
2 years ago

lol-esports-spectate

JS Api for creating a custom view for a tournament draft spectator with a example like the official one used in the competetive scene.

Example Application

For an example application using this module to create something like the official esports spectator go here The example client has been moved to a standalone repository, which can be found here

Download

LolEsportsSpectate is installable via:

  • GitHub git clone https://github.com/Litzuck/LoLEsportsSpectate.git
  • npm: npm install lol-esports-spectate

Usage example

const ChampSelectApi = require('lol-esports-spectate');
const api = new ChampSelectApi();
//start listening for events
api.start()

api.on('championSelectStarted', (data) => {
    console.log("champion select started")
    gameStarted = true
})

Available methods

constructor ()

Creates a new ChampSelectApi.

Parameters

  1. executablePath {string} A path to where the LeagueClient executable resides. If not passed it will be automatically figured out from the OS process list.

start()

Starts listening for events of from the LCU.

request(uri, callback)

Sends a request to the specified enpoint of the LCU and calls the given function with the result.

Events

championSelectStarted

Fired when the champion select started

newTurnBegin(timeLeftinPhase)

Fired when its a new players turn

banTurnBegin(playerTurn)

Fired when it a new players turn to ban a champion

playerTurnBegin(playerId)

Fired when it a new players turn to pick a champion

championHoverChanged(championId, playerId)

Fired when a player changed his hovered champion

championBanned(championId, playerTurn)

Fired when it a new players turn to ban a champion

championLocked(championId, playerId)

Fired when a champion is locked in.

phaseChanged(type)

Fired when the phase of the champion select changed

teamTurnChanged(isBlueTurn)

Fired when the team who's turn it is changed

summonerSpellChanged(playerId, slotId,summonerSpellId)

Fired when a player changed one of this summoner spells

3.0.1

2 years ago

3.0.0

2 years ago

2.0.2-beta.27

3 years ago

2.0.2-beta.24

3 years ago

2.0.2-beta.23

3 years ago

2.0.2-beta.26

3 years ago

2.0.2-beta.25

3 years ago

2.0.2-beta.9

4 years ago

2.0.2-beta.22

4 years ago

2.0.2-beta.21

4 years ago

2.0.2-beta.20

4 years ago

2.0.2-beta.6

4 years ago

2.0.2-beta.7

4 years ago

2.0.2-beta.8

4 years ago

2.0.2-beta.13

4 years ago

2.0.2-beta.12

4 years ago

2.0.2-beta.11

4 years ago

2.0.2-beta.10

4 years ago

2.0.2-beta.17

4 years ago

2.0.2-beta.16

4 years ago

2.0.2-beta.15

4 years ago

2.0.2-beta.14

4 years ago

2.0.2-beta.19

4 years ago

2.0.2-beta.18

4 years ago

2.0.2-beta.5

4 years ago

2.0.2-beta.2

4 years ago

2.0.2-beta.3

4 years ago

2.0.2-beta.4

4 years ago

2.0.2-beta.1

4 years ago

1.1.3

4 years ago

1.1.2

4 years ago

1.1.1

4 years ago

1.1.0

4 years ago

1.0.7

4 years ago

1.0.6

4 years ago

1.0.5

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago