mirror of
https://github.com/KoboldAI/KoboldAI-Client.git
synced 2025-02-17 12:10:49 +01:00
Merge branch 'KoboldAI:main' into united
This commit is contained in:
commit
21ae45e9ab
22
aiserver.py
22
aiserver.py
@ -735,31 +735,31 @@ def do_connect():
|
|||||||
sendsettings()
|
sendsettings()
|
||||||
refresh_settings()
|
refresh_settings()
|
||||||
vars.laststory = None
|
vars.laststory = None
|
||||||
emit('from_server', {'cmd': 'setstoryname', 'data': vars.laststory}, broadcast=True)
|
emit('from_server', {'cmd': 'setstoryname', 'data': vars.laststory})
|
||||||
sendwi()
|
sendwi()
|
||||||
emit('from_server', {'cmd': 'setmemory', 'data': vars.memory}, broadcast=True)
|
emit('from_server', {'cmd': 'setmemory', 'data': vars.memory})
|
||||||
emit('from_server', {'cmd': 'setanote', 'data': vars.authornote}, broadcast=True)
|
emit('from_server', {'cmd': 'setanote', 'data': vars.authornote})
|
||||||
vars.mode = "play"
|
vars.mode = "play"
|
||||||
else:
|
else:
|
||||||
# Game in session, send current game data and ready state to browser
|
# Game in session, send current game data and ready state to browser
|
||||||
refresh_story()
|
refresh_story()
|
||||||
sendsettings()
|
sendsettings()
|
||||||
refresh_settings()
|
refresh_settings()
|
||||||
emit('from_server', {'cmd': 'setstoryname', 'data': vars.laststory}, broadcast=True)
|
emit('from_server', {'cmd': 'setstoryname', 'data': vars.laststory})
|
||||||
sendwi()
|
sendwi()
|
||||||
emit('from_server', {'cmd': 'setmemory', 'data': vars.memory}, broadcast=True)
|
emit('from_server', {'cmd': 'setmemory', 'data': vars.memory})
|
||||||
emit('from_server', {'cmd': 'setanote', 'data': vars.authornote}, broadcast=True)
|
emit('from_server', {'cmd': 'setanote', 'data': vars.authornote})
|
||||||
if(vars.mode == "play"):
|
if(vars.mode == "play"):
|
||||||
if(not vars.aibusy):
|
if(not vars.aibusy):
|
||||||
emit('from_server', {'cmd': 'setgamestate', 'data': 'ready'}, broadcast=True)
|
emit('from_server', {'cmd': 'setgamestate', 'data': 'ready'})
|
||||||
else:
|
else:
|
||||||
emit('from_server', {'cmd': 'setgamestate', 'data': 'wait'}, broadcast=True)
|
emit('from_server', {'cmd': 'setgamestate', 'data': 'wait'})
|
||||||
elif(vars.mode == "edit"):
|
elif(vars.mode == "edit"):
|
||||||
emit('from_server', {'cmd': 'editmode', 'data': 'true'}, broadcast=True)
|
emit('from_server', {'cmd': 'editmode', 'data': 'true'})
|
||||||
elif(vars.mode == "memory"):
|
elif(vars.mode == "memory"):
|
||||||
emit('from_server', {'cmd': 'memmode', 'data': 'true'}, broadcast=True)
|
emit('from_server', {'cmd': 'memmode', 'data': 'true'})
|
||||||
elif(vars.mode == "wi"):
|
elif(vars.mode == "wi"):
|
||||||
emit('from_server', {'cmd': 'wimode', 'data': 'true'}, broadcast=True)
|
emit('from_server', {'cmd': 'wimode', 'data': 'true'})
|
||||||
|
|
||||||
#==================================================================#
|
#==================================================================#
|
||||||
# Event triggered when browser SocketIO sends data to the server
|
# Event triggered when browser SocketIO sends data to the server
|
||||||
|
Loading…
x
Reference in New Issue
Block a user