Enemy
Last updated
Last updated
Enemy comprises things that will spawn and "killed" by the Player.
Each enemy is a prefab that typically consist of these components:
Enemy
: as a manager for all other components
BaseEnemyView
or its derivatives : to handle spine animation
DefaultEnemyView,
or its derivatives : to handle enemy states
ConvoyMovement
: adjust Movement's speed based on Player's speed
other supporting components, e.g. PoolableObject
Enemy have a config (EnemyConfig
) that determines how many points, coins, etc.
Some enemies will have a Vehicle
type config. If this enemies collide with Player, player will try to switch to the new Vehicle
if the condition is allowed.