nqp.world package¶
Subpackages¶
- nqp.world.controllers package
- Submodules
- nqp.world.controllers.choose_room_controller module
- nqp.world.controllers.combat_controller module
- nqp.world.controllers.event_controller module
- nqp.world.controllers.inn_controller module
- nqp.world.controllers.post_combat_controller module
- nqp.world.controllers.training_controller module
- Module contents
Submodules¶
nqp.world.model module¶
nqp.world.view module¶
- class WorldView(game: Game, model: WorldModel)[source]¶
Bases:
object
Render Terrain and game entities
- camera¶
Used to show portions of the game world
Do not modify the state of the game, entities, terrain, etc.
Only draw the state of the game, nothing else
The view should query the model or controller and make changes based on that info. The view should not collect input from the user.
- draw(surface: pygame.Surface)[source]¶
- get_team_center(team) Optional[pygame.math.Vector2] [source]¶
Get centre coordinates for the team
- view_to_point(point: pygame.math.Vector2)[source]¶
Return map pixel coords under the point
Point must be relative to the topleft corner of the view