User Tools

Site Tools


jill:algo:hive

Hive

Hive is ennemy that create Bees.
Width and Height is always set to 16.

iXD and iYD is set 0 at start time. When Hive is updated, iXD and iYD (1 or -1) is set to know relative position of player.
By example : iXD set to 1 if player is on right of hive. iXD is set to 1 if player is bellow to hive.

iCounter is use to know state of Hive.

Animation

Algorithme may be wrong ! It's very hard, without source code to understand how hive works.

iCounteriXDTilesetTileComment
0 1 37 0 genrerate random number between 0 and 20. If value is 0 then iCounter set to 1
1 1 37 1 Increase iCounter
2 1 37 3 Create Bees. iCounter set to 0.
2 -1 37 2 Create Bees. iCounter set to 0.

iCounter is incremented by 3 cycle !!!

jill/algo/hive.txt · Last modified: 2014/09/04 14:39 by emeric