Skip to content

Commit

Permalink
commands is now list[str] instead of list[flat.ConsoleCommand]
Browse files Browse the repository at this point in the history
  • Loading branch information
VirxEC committed Jan 29, 2025
1 parent 711630b commit f6afeeb
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 9 deletions.
2 changes: 1 addition & 1 deletion rlbot/managers/bot.py
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,7 @@ def set_game_state(
balls: dict[int, flat.DesiredBallState] = {},
cars: dict[int, flat.DesiredCarState] = {},
match_info: Optional[flat.DesiredMatchInfo] = None,
commands: list[flat.ConsoleCommand] = [],
commands: list[str] = [],
):
"""
Sets the game to the desired state.
Expand Down
2 changes: 1 addition & 1 deletion rlbot/managers/hivemind.py
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ def set_game_state(
balls: dict[int, flat.DesiredBallState] = {},
cars: dict[int, flat.DesiredCarState] = {},
match_info: Optional[flat.DesiredMatchInfo] = None,
commands: list[flat.ConsoleCommand] = [],
commands: list[str] = [],
):
"""
Sets the game to the desired state.
Expand Down
2 changes: 1 addition & 1 deletion rlbot/managers/match.py
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ def set_game_state(
balls: dict[int, flat.DesiredBallState] = {},
cars: dict[int, flat.DesiredCarState] = {},
match_info: Optional[flat.DesiredMatchInfo] = None,
commands: list[flat.ConsoleCommand] = [],
commands: list[str] = [],
):
"""
Sets the game to the desired state.
Expand Down
2 changes: 1 addition & 1 deletion rlbot/managers/script.py
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ def set_game_state(
balls: dict[int, flat.DesiredBallState] = {},
cars: dict[int, flat.DesiredCarState] = {},
match_info: Optional[flat.DesiredMatchInfo] = None,
commands: list[flat.ConsoleCommand] = [],
commands: list[str] = [],
):
"""
Sets the game to the desired state.
Expand Down
11 changes: 7 additions & 4 deletions rlbot/utils/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,17 @@ def fill_desired_game_state(
balls: dict[int, flat.DesiredBallState] = {},
cars: dict[int, flat.DesiredCarState] = {},
match_info: Optional[flat.DesiredMatchInfo] = None,
commands: list[flat.ConsoleCommand] = [],
commands: list[str] = [],
) -> flat.DesiredGameState:
"""
# Converts the dictionaries to a DesiredGameState by
# filling in the blanks with empty states that do nothing.
Converts the dictionaries to a DesiredGameState by
filling in the blanks with empty states that do nothing.
"""

game_state = flat.DesiredGameState(match_info=match_info, console_commands=commands)
game_state = flat.DesiredGameState(
match_info=match_info,
console_commands=[flat.ConsoleCommand(cmd) for cmd in commands],
)

if balls:
max_entry = max(balls.keys())
Expand Down
2 changes: 1 addition & 1 deletion rlbot/version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "2.0.0-beta.22"
__version__ = "2.0.0-beta.23"

0 comments on commit f6afeeb

Please sign in to comment.