haive.games.monopoly.simple_demo¶

Simple demo for testing the Monopoly game without LangGraph integration.

This script demonstrates the core functionality of the Monopoly game: - Board setup - Player movement - Property purchasing - Rent payments - Game events

Usage:

python simple_demo.py

Functions¶

handle_property_landing(state, position)

Handle a player landing on a property.

print_divider()

Print a divider line.

print_player_status(state)

Print current status of all players.

print_property(property_obj)

Print property details.

print_recent_events(events[, count])

Print recent game events.

run_demo([turns])

Run a simple Monopoly game demo.

Module Contents¶

haive.games.monopoly.simple_demo.handle_property_landing(state, position)[source]¶

Handle a player landing on a property.

Parameters:
  • state (haive.games.monopoly.state.MonopolyState)

  • position (int)

Return type:

list[haive.games.monopoly.models.GameEvent]

haive.games.monopoly.simple_demo.print_divider()[source]¶

Print a divider line.

haive.games.monopoly.simple_demo.print_player_status(state)[source]¶

Print current status of all players.

Parameters:

state (haive.games.monopoly.state.MonopolyState)

haive.games.monopoly.simple_demo.print_property(property_obj)[source]¶

Print property details.

Parameters:

property_obj (haive.games.monopoly.models.Property)

haive.games.monopoly.simple_demo.print_recent_events(events, count=5)[source]¶

Print recent game events.

Parameters:
  • events (list[haive.games.monopoly.models.GameEvent])

  • count (int)

haive.games.monopoly.simple_demo.run_demo(turns=20)[source]¶

Run a simple Monopoly game demo.

Parameters:

turns (int)