Step 7: Creating Specific Enemies

The following events demonstrate how to define the Skin on creation.
Note, the order of these actions is very important. MMF2 executes all events and actions sequentially. Make sure the Create Object action is above the Set Skin action. Otherwise the Skin will be set for every existing object and not the newly created one. Read the Object Scope article for more information.


So there you have it, object skins stored in different animation directions. This method can be easily adapted to work with 4, 8 and 16 directional movements. Although, obviously the more movement directions, the less room there is for storing different skins.

You may also like to assign your objects other initial and fixed values depending on their skin value.
For example, a cop might have higher initial health due to body armour, while a woman might move faster because she is smaller etc.

Well done, you have completed the tutorial!
10