added support for instring variables and made character IDs

be always stored in lowercase
This commit is contained in:
2026-05-26 21:41:36 +01:00
parent cc3eca857d
commit 148fb73f7f
12 changed files with 69 additions and 70 deletions
+7 -5
View File
@@ -2,11 +2,11 @@ import requests
import os
import time
import sys
debug = False
debug = True
try:
if sys.argv[1] == "debug": debug = True
if sys.argv[1] == "silent": debug = False
except:
debug = False
debug = True
# Loop and get new api
def main():
@@ -22,7 +22,9 @@ def main():
output(character, response["content"])
case "choice":
user_choice = choice(response["choices"])
time.sleep(0.5)
continue
case "input":
get_input()
continue
case "end":
print("Exitting successfully")
@@ -46,7 +48,7 @@ def choice(choices):
def get_input():
api_url = "http://localhost:20264/input"
input_string = input()
input_string = input("Input: ")
requests.post(api_url, json=input_string);