Archived
1
0

Added fruit status

This commit is contained in:
2023-02-24 22:17:45 -08:00
parent dc8f0ace68
commit f40b58508e
2 changed files with 18 additions and 0 deletions

View File

@ -28,6 +28,9 @@ class CelesteState(NamedTuple):
# Number of deaths since game start
deaths: int
# If an index is true, we got a strawberry on that stage.
berries: list[bool]
# Distance to next point
dist: float
@ -223,6 +226,7 @@ class Celeste:
xvel = float(self._internal_state["vx"]),
yvel = float(self._internal_state["vy"]),
deaths = int(self._internal_state["dc"]),
berries = [x == "t" for x in self._internal_state["fr"][1:]],
dist = self._dist,
next_point = self._next_checkpoint_idx,