This commit is contained in:
Auric Vente 2024-07-25 21:45:59 -06:00
parent b853eade5d
commit 962f59d794
1 changed files with 14 additions and 25 deletions

View File

@ -54,10 +54,7 @@ class Opts:
hit = Opt(2, Method.hit) hit = Opt(2, Method.hit)
travel = Opt(2, Method.travel) travel = Opt(2, Method.travel)
think = Opt(2, Method.think) think = Opt(2, Method.think)
words_1 = Opt(3, Method.words) words = Opt(3, Method.words)
words_2 = Opt(3, Method.words)
words_3 = Opt(3, Method.words)
words_4 = Opt(3, Method.words)
@staticmethod @staticmethod
def opts_score() -> list[Opt]: def opts_score() -> list[Opt]:
@ -73,12 +70,7 @@ class Opts:
@staticmethod @staticmethod
def opts_words() -> list[Opt]: def opts_words() -> list[Opt]:
return [ return [Opts.words]
Opts.words_1,
Opts.words_2,
Opts.words_3,
Opts.words_4,
]
class Game: class Game:
@ -291,7 +283,7 @@ class Game:
Game.merge_charge = 0 Game.merge_charge = 0
return return
value = Opts.words_4.value value = Opts.words.value
status = "" status = ""
method = "" method = ""
@ -319,21 +311,18 @@ class Game:
elif n == 3: elif n == 3:
status = Utils.random_words(1)[0].capitalize() status = Utils.random_words(1)[0].capitalize()
elif value == Opts.words_1.value: elif value == Opts.words.value:
n = random.randint(1, 4)
method = Opts.words.method
if n == 1:
status = Utils.words_1() status = Utils.words_1()
method = Opts.words_1.method elif n == 2:
elif value == Opts.words_2.value:
status = Utils.words_2() status = Utils.words_2()
method = Opts.words_2.method elif n == 3:
elif value == Opts.words_3.value:
status = Utils.words_3() status = Utils.words_3()
method = Opts.words_3.method elif n == 4:
elif value >= Opts.words_4.value:
status = Utils.words_4() status = Utils.words_4()
method = Opts.words_4.method
else: else:
status = "???" status = "???"