mirror of
https://github.com/tobspr/shapez.io.git
synced 2025-12-13 10:11:50 +00:00
Game state register (#1341)
* Added a gamestate register helper Added a gamestate register helper * Update mod_interface.js
This commit is contained in:
parent
5c9cbcd8ad
commit
e16f13034a
@ -367,6 +367,14 @@ export class ModInterface {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Registers a new state class, should be a GameState derived class
|
||||||
|
* @param {typeof GameState} stateClass
|
||||||
|
*/
|
||||||
|
registerGameState(stateClass) {
|
||||||
|
this.modLoader.app.stateMgr.register(stateClass);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param {object} param0
|
* @param {object} param0
|
||||||
* @param {"regular"|"wires"} param0.toolbar
|
* @param {"regular"|"wires"} param0.toolbar
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user