Fix #17 Too much game info data sent thru plugin framework
This commit is contained in:
parent
1fbfb8a743
commit
c1d80a32fa
2 changed files with 4 additions and 3 deletions
|
@ -133,8 +133,8 @@ async def start(version):
|
|||
http_server = Server(version)
|
||||
http_runner = web.AppRunner(http_server)
|
||||
await http_runner.setup()
|
||||
site = web.TCPSite(http_runner, '127.0.0.1', 5030)
|
||||
await site.start()
|
||||
http_site = web.TCPSite(http_runner, '127.0.0.1', 5030)
|
||||
await http_site.start()
|
||||
|
||||
async def shutdown(): # never really called
|
||||
global http_runner, http_server, http_site
|
||||
|
|
|
@ -125,7 +125,8 @@ export function getCurrentGame(): Promise<any> {
|
|||
}
|
||||
|
||||
export function onGameStart(gameId: number, data: any): Promise<any> {
|
||||
return server!.callPluginMethod("on_game_start", {"game_id": gameId, "data":data});
|
||||
const data2 = {appid: data.appid, display_name: data.display_name, gameid: gameId}; // Issue #17
|
||||
return server!.callPluginMethod("on_game_start", {"game_id": gameId, "data":data2});
|
||||
}
|
||||
|
||||
export function onGameStop(gameId: number | null): Promise<any> {
|
||||
|
|
Loading…
Reference in a new issue