Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions src/sim/simulation/sim.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
from src.sim.input.input import Input
from src.sim.output.output import Output

SCREEN_WIDTH = 1000
SCREEN_HEIGHT = 1000
SCREEN_WIDTH = 800
SCREEN_HEIGHT = 800
SCREEN_TITLE = "ARORA"

if TYPE_CHECKING:
Expand Down Expand Up @@ -299,12 +299,11 @@ def update_viewport_position(self) -> None:
Updates the position of the viewport.
"""
self.set_viewport(
0,
SCREEN_WIDTH,
self.root_tip_y - 2,
SCREEN_HEIGHT + self.root_tip_y - 2,
self.root_midpointx - SCREEN_WIDTH / 2,
self.root_midpointx + SCREEN_WIDTH / 2,
self.root_tip_y - SCREEN_HEIGHT / 8,
self.root_tip_y - SCREEN_HEIGHT / 3 + SCREEN_HEIGHT,
)
self.window_offset = self.root_tip_y - 2

def on_update(self, delta_time: float) -> None:
"""
Expand Down Expand Up @@ -373,6 +372,7 @@ def main(
geometry,
)
print("Running Simulation")
simulation.update_viewport_position()
simulation.run_sim()

return simulation.get_tick()