Fix random story generator
This commit is contained in:
parent
af93c96c0f
commit
2b89bcb16e
|
@ -930,7 +930,7 @@ def settingschanged():
|
||||||
#==================================================================#
|
#==================================================================#
|
||||||
# Take input text from SocketIO and decide what to do with it
|
# Take input text from SocketIO and decide what to do with it
|
||||||
#==================================================================#
|
#==================================================================#
|
||||||
def actionsubmit(data, actionmode=0):
|
def actionsubmit(data, actionmode=0, force_submit=False):
|
||||||
# Ignore new submissions if the AI is currently busy
|
# Ignore new submissions if the AI is currently busy
|
||||||
if(vars.aibusy):
|
if(vars.aibusy):
|
||||||
return
|
return
|
||||||
|
@ -952,7 +952,7 @@ def actionsubmit(data, actionmode=0):
|
||||||
vars.lastact = data
|
vars.lastact = data
|
||||||
|
|
||||||
if(not vars.gamestarted):
|
if(not vars.gamestarted):
|
||||||
if(len(data.strip()) == 0):
|
if(not force_submit and len(data.strip()) == 0):
|
||||||
set_aibusy(0)
|
set_aibusy(0)
|
||||||
return
|
return
|
||||||
# Start the game
|
# Start the game
|
||||||
|
@ -2398,7 +2398,7 @@ def newGameRequest():
|
||||||
def randomGameRequest(topic):
|
def randomGameRequest(topic):
|
||||||
newGameRequest()
|
newGameRequest()
|
||||||
vars.memory = "You generate the following " + topic + " story concept :"
|
vars.memory = "You generate the following " + topic + " story concept :"
|
||||||
actionsubmit("")
|
actionsubmit("", force_submit=True)
|
||||||
vars.memory = ""
|
vars.memory = ""
|
||||||
|
|
||||||
#==================================================================#
|
#==================================================================#
|
||||||
|
|
Loading…
Reference in New Issue