Overview of the Gameplay Elements.
- This is from an excelent tutorial
- He introduces the "Gameplay Framework"
- This is intended for multiplayer, on line games.
- However, you really should watch this.
- The framework is a set of actors that allows programmers to
- Define and manage the rules of a game
- Spawn appropriate actors
- Track the state.
- The pawn system works with this to provide easily configurable player and ai characters.
-
- Elements
- The Game Instance
- The Game mode
- Pawn controllers
- Game and player states.
- The game instance
- This is persistant
- Created on engine launch
- Remains until engine shuts down.
- It is a manager designed to contain data and code, but no physical presence.
- It is not replecated on server and clients.
- This is the place for everything to persist between levels.
- "A repository of information that needs to exist beyonds the bounds of a single level of game play"
- A good place for the savegame system.
-
- The game mode
- A server based manager actor.
- Created on level load, not persistant.
- It is the first actor to instatiate on level load.
- It is set on a map by map basis.
- This manages the rules and structure of a play session
- Creates the other framework actors.
- This includes the game state and the player state.
- The game state/ player state
- This manages the state of the game/players.
- This is replactes the data across the server and all clients.
- The game state holds logic and data relvelant to all players
- The player state tracks info relative to a single player
- Health or inventory.
- One per player.
- Created when the player is loaded into a level.
-
- The player character
- Created by game mode
- Consists of
- a physical pawn
- A controller
- The pawn is the thing we have been building
- The controller provides the brain.
- It is responsible for providing the "brains" to the pawn.
- It can be a player inteface (ie keybord, mouse, ...)
- Or it can be an AI.
-
- More detail on the game instance:
- Reference
- called a manager actor.
- No physical presence.
- MANY tools for multi player games.
- He suggests having a player state update the game instance for save information
- And the game instance provide data to a fresh player state for a new level load.
- Game mode
- This spawns players and controllers.
- Special instances of this exist for multiplayer games.