version 1.1 | | version 1.2 |
---|
| | |
* Autonomous Individual movement. | | * Autonomous Individual movement. |
* | | * |
* $Log$ | | * $Log$ |
* Revision 1.1 1999/06/14 22:05:03 donut | | * Revision 1.2 2003/03/09 06:34:09 donut |
* Initial revision | | * change byte typedef to sbyte to avoid conflict with win32 byte which is unsigned |
| | * |
| | * Revision 1.1.1.1 1999/06/14 22:05:03 donut |
| | * Import of d1x 1.37 source. |
* | | * |
* Revision 2.11 1995/07/09 11:15:48 john | | * Revision 2.11 1995/07/09 11:15:48 john |
* Put in Mike's code to fix bug where bosses don't gate in bots after | | * Put in Mike's code to fix bug where bosses don't gate in bots after |
| | |
#define ANIM_RATE (F1_0/16) | | #define ANIM_RATE (F1_0/16) |
#define DELTA_ANG_SCALE 16 | | #define DELTA_ANG_SCALE 16 |
| | |
byte Mike_to_matt_xlate[] = {AS_REST, AS_REST, AS_ALERT, AS_ALERT, AS_FLINCH, AS_FIRE, AS_RECOIL, AS_REST}; | | sbyte Mike_to_matt_xlate[] = {AS_REST, AS_REST, AS_ALERT, AS_ALERT, AS_FLINCH, AS_FIRE, AS_RECOIL, AS_REST}; |
int john_cheats_index_2; // PORGYS high speed weapon firing | | int john_cheats_index_2; // PORGYS high speed weapon firing |
| | |
// int No_ai_flag=0; | | // int No_ai_flag=0; |
| | |
// 22 quad-laser | | // 22 quad-laser |
// 23 super boss | | // 23 super boss |
| | |
// byte Super_boss_gate_list[] = {0, 1, 2, 9, 11, 16, 18, 19, 21, 22, 0, 9, 9, 16, 16, 18, 19, 19, 22, 22}; | | // sbyte Super_boss_gate_list[] = {0, 1, 2, 9, 11, 16, 18, 19, 21, 22, 0, 9, 9, 16, 16, 18, 19, 19, 22, 22}; |
byte Super_boss_gate_list[] = {0, 1, 8, 9, 10, 11, 12, 15, 16, 18, 19, 20, 22, 0, 8, 11, 19, 20, 8, 20, 8}; | | sbyte Super_boss_gate_list[] = {0, 1, 8, 9, 10, 11, 12, 15, 16, 18, 19, 20, 22, 0, 8, 11, 19, 20, 8, 20, 8}; |
#define MAX_GATE_INDEX ( sizeof(Super_boss_gate_list) / sizeof(Super_boss_gate_list[0]) ) | | #define MAX_GATE_INDEX ( sizeof(Super_boss_gate_list) / sizeof(Super_boss_gate_list[0]) ) |
#endif | | #endif |
| | |
| | |
int Robot_firing_enabled = 1; | | int Robot_firing_enabled = 1; |
| | |
extern int Ugly_robot_cheat, Ugly_robot_texture, Laser_rapid_fire; | | extern int Ugly_robot_cheat, Ugly_robot_texture, Laser_rapid_fire; |
extern byte Enable_john_cheat_1, Enable_john_cheat_2, Enable_john_cheat_3, Enable_john_cheat_4; | | extern sbyte Enable_john_cheat_1, Enable_john_cheat_2, Enable_john_cheat_3, Enable_john_cheat_4; |
| | |
ubyte john_cheats_3[2*JOHN_CHEATS_SIZE_3+1] = { KEY_Y ^ 0x67, | | ubyte john_cheats_3[2*JOHN_CHEATS_SIZE_3+1] = { KEY_Y ^ 0x67, |
KEY_E ^ 0x66, | | KEY_E ^ 0x66, |
| | |
// Third dimension is goal state. | | // Third dimension is goal state. |
// Result is new goal state. | | // Result is new goal state. |
// ERR_ means something impossible has happened. | | // ERR_ means something impossible has happened. |
byte Ai_transition_table[AI_MAX_EVENT][AI_MAX_STATE][AI_MAX_STATE] = { | | sbyte Ai_transition_table[AI_MAX_EVENT][AI_MAX_STATE][AI_MAX_STATE] = { |
{ | | { |
// Event = AIE_FIRE, a nearby object fired | | // Event = AIE_FIRE, a nearby object fired |
// none rest srch lock flin fire reco // CURRENT is rows, GOAL is columns | | // none rest srch lock flin fire reco // CURRENT is rows, GOAL is columns |
| | |
int Diff_save = 1; | | int Diff_save = 1; |
| | |
fix Firing_wait_copy[MAX_ROBOT_TYPES]; | | fix Firing_wait_copy[MAX_ROBOT_TYPES]; |
byte Rapidfire_count_copy[MAX_ROBOT_TYPES]; | | sbyte Rapidfire_count_copy[MAX_ROBOT_TYPES]; |
| | |
void do_lunacy_on(void) | | void do_lunacy_on(void) |
{ | | { |
| | |
object *boss_objp = &Objects[boss_objnum]; | | object *boss_objp = &Objects[boss_objnum]; |
int head, tail; | | int head, tail; |
int seg_queue[QUEUE_SIZE]; | | int seg_queue[QUEUE_SIZE]; |
//ALREADY IN RENDER.H byte visited[MAX_SEGMENTS]; | | //ALREADY IN RENDER.H sbyte visited[MAX_SEGMENTS]; |
fix boss_size_save; | | fix boss_size_save; |
| | |
boss_size_save = boss_objp->size; | | boss_size_save = boss_objp->size; |
| | |
} | | } |
} | | } |
| | |
byte New_awareness[MAX_SEGMENTS]; | | sbyte New_awareness[MAX_SEGMENTS]; |
| | |
// ---------------------------------------------------------------------------------- | | // ---------------------------------------------------------------------------------- |
void pae_aux(int segnum, int type, int level) | | void pae_aux(int segnum, int type, int level) |