S2ENGINE HD 2023
User guide
×
Menu
Index

Zombies

 
Zombie is the most simple type of enemy.
Its locomotion is basic and its logic is a sort of "seek and destroy" behaviour.
Otherwise if many zombies are placed in the level, with effective hit and death reactions, they can guarantee a decent fun.
 
In EasyGamePack installation there are male and female zombie prefabs.
Male zombie prefabs are located into EasyGamePack\Characters\Zombi\Male
Female zombie prefabs are located into  EasyGamePack\Characters\Zombi\Female
 
Zombie behaviour is built up with 2 gamemachines, they are located into EasyGamePack\Characters\Zombi folder:
 
Following are the parameters of the locomotion gameMachine:
6.3.9.1. Zombies
1

IdleMaxSpeed

1. IdleMaxSpeed
<TODO>: Insert description text here...
2

walkMaxSpeed

2. walkMaxSpeed
<TODO>: Insert description text here...
3

walkMinSpeed

3. walkMinSpeed
<TODO>: Insert description text here...
4

runMinSpeed

4. runMinSpeed
<TODO>: Insert description text here...
5

runMul

5. runMul
<TODO>: Insert description text here...
 
Following are the parameters of the zombie3 gameMachine:
6.3.9.1. Zombies
1

IdleSound

1. IdleSound
<TODO>: Insert description text here...
2

navmesh

2. navmesh
<TODO>: Insert description text here...
3

runSpeed

3. runSpeed
<TODO>: Insert description text here...
4

walkSpeed

4. walkSpeed
<TODO>: Insert description text here...
5

seekRangeMax

5. seekRangeMax
<TODO>: Insert description text here...
6

seekRangeMin

6. seekRangeMin
<TODO>: Insert description text here...
7

attackRange

7. attackRange
<TODO>: Insert description text here...
8

attack_anim

8. attack_anim
<TODO>: Insert description text here...
9

patrolID

9. patrolID
<TODO>: Insert description text here...
 
 

ANIMATIONS
 
Zombie animations are based on the animation blending system.
This means that every zombie has a modelscript containing the list of animations that he can perform in the gameMachine.
The modelscript contains walking, running, idles, attacks, death and hit animations. Every animation slot in the modelscript list can be a single animation or a blend1d / blend2d animation.
The animation slots in the modelscript are simply references to real source animation files, this means that changing these references you can change the animation set maintaining, at high level, the same animation names. This is why there is more than 1 modelscript containing different set of animations for a zombie.
Changing the modelscript in the zombie class changes the way in wihich zombie performs some anmations (like chasing for example).
 
In this version of EasyGamePack there are the following modelscripts you can use for the zombies, all of them are located in EasyGamePack\Characters\zombi\Female folder  :
 
They can be used also for male zombies because the source animations are the same (thanks to retargeting)
 
 

PATROLING
 
If no player is nearby, a zombie simply patrols a given zone.
A patrol zone is defined by Patrol points. Each patrol point has an ID that defines which zone it belongs to.
A zombie can patrol only one zone. You can set the ID of the zone to patrol (patrolID) in the "logic" GameMachine of the zombie.
If a zombie doesn't find any patrol point of specified ID, in order to avoid stucking, it starts to find a patrol point regardless of its ID.
 
To add a patrol point in the level:
 

ATTACKING
 
When zombie attacks player he randomly performs 2 alternative actions:
 
 
 

CREATING A NEW ZOMBIE
If you alreay have a "static" character 3d model, the simplest way to integrate a new character for EasyGamePack is to use MIXAMO service.
MIXAMO is an online service that takes in input a static single mesh character and convert it into a skinned, animatable, model.
You can find MIXAMO service at https://www.mixamo.com/.
 
Once you convert your model into a skinned MIXAMO model, you can import it into your s2engine project by drag and drop the model file in the project browser folder you want to locate the character files.
Take care about some s2 importer settings:
6.3.9.1. Zombies
1

Import Geometry

1. Import Geometry
<TODO>: Insert description text here...
2

Collapse FBX

2. Collapse FBX
<TODO>: Insert description text here...
 
Once you have successfully imported the model you have to do some changes in order to make it compliant with EasyGamePack system: