Mods
This commit is contained in:
parent
1fd742ea8a
commit
cf7c267bb2
|
@ -89,10 +89,6 @@ class Ants:
|
||||||
Ants.save()
|
Ants.save()
|
||||||
Game.update_info()
|
Game.update_info()
|
||||||
|
|
||||||
@staticmethod
|
|
||||||
def hatch_burst() -> None:
|
|
||||||
Ants.hatch(Config.hatch_burst)
|
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def terminate() -> None:
|
def terminate() -> None:
|
||||||
from .game import Game
|
from .game import Game
|
||||||
|
@ -230,9 +226,6 @@ class Ants:
|
||||||
for ant in Ants.ants:
|
for ant in Ants.ants:
|
||||||
score = ant.get_score()
|
score = ant.get_score()
|
||||||
|
|
||||||
if score <= 0:
|
|
||||||
continue
|
|
||||||
|
|
||||||
if (not top) or (score > top_score):
|
if (not top) or (score > top_score):
|
||||||
top = ant
|
top = ant
|
||||||
top_score = score
|
top_score = score
|
||||||
|
@ -244,8 +237,6 @@ class Ants:
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def merge() -> None:
|
def merge() -> None:
|
||||||
from .game import Game
|
|
||||||
|
|
||||||
if len(Ants.ants) < 2:
|
if len(Ants.ants) < 2:
|
||||||
return
|
return
|
||||||
|
|
||||||
|
@ -310,8 +301,7 @@ class Ants:
|
||||||
|
|
||||||
Ants.ants.append(ant)
|
Ants.ants.append(ant)
|
||||||
Ants.announce_hatch(ant)
|
Ants.announce_hatch(ant)
|
||||||
Game.update_info()
|
Ants.hatch()
|
||||||
Ants.save()
|
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def announce_hatch(ant: Ant) -> None:
|
def announce_hatch(ant: Ant) -> None:
|
||||||
|
|
|
@ -26,7 +26,6 @@ class Config:
|
||||||
loop_delay_fast: int = 1000 * 5
|
loop_delay_fast: int = 1000 * 5
|
||||||
loop_delay_normal: int = 1000 * 60 * 1
|
loop_delay_normal: int = 1000 * 60 * 1
|
||||||
loop_delay_slow: int = 1000 * 60 * 5
|
loop_delay_slow: int = 1000 * 60 * 5
|
||||||
hatch_burst: int = 3
|
|
||||||
font_size: int = 20
|
font_size: int = 20
|
||||||
info_separator: str = " - "
|
info_separator: str = " - "
|
||||||
font_path: Path
|
font_path: Path
|
||||||
|
|
Loading…
Reference in New Issue