from pgzero.actor import Actor
from ..actors.buttons import TextButton, ImageButton
from ..constants import WIDTH, HEIGHT
+from ..vehicles.base import Vehicle
from .base import Scene, ChangeSceneEvent
self._roaches = self.actors.add_layer("roaches", level=10)
self._pads = self.actors.add_layer("pads", level=5)
self._buttons = self.actors.add_layer("buttons", level=6)
- self._init_bg()
self._init_pads()
self._init_buttons()
+ def enter(self, world):
+ self._vehicle = Vehicle.by_type(world.vehicles.current)
+ self._init_bg()
+ self._init_seats()
+
def _init_bg(self):
self.actors.default.add(Actor("vehicles/walking/background"))
+ self.actors.default.add(self._vehicle.background)
+
+ def _init_seats(self):
+ print("Seats:")
+ print([seat.pos for seat in self._vehicle.seats])
def _init_pads(self):
self._roach_pad = self._pads.add(