1 2void() monster_ogre = {remove(self);}; 3void() monster_demon1 = {remove(self);}; 4void() monster_shambler = {remove(self);}; 5void() monster_knight = {remove(self);}; 6void() monster_army = {remove(self);}; 7void() monster_wizard = {remove(self);}; 8void() monster_dog = {remove(self);}; 9void() monster_zombie = {remove(self);}; 10void() monster_boss = {remove(self);}; 11void() monster_tarbaby = {remove(self);}; 12void() monster_hell_knight = {remove(self);}; 13void() monster_fish = {remove(self);}; 14void() monster_shalrath = {remove(self);}; 15void() monster_enforcer = {remove(self);}; 16void() monster_oldone = {remove(self);}; 17void() event_lightning = {remove(self);}; 18 19/* 20============================================================================== 21 22MOVETARGET CODE 23 24The angle of the movetarget effects standing and bowing direction, but has no effect on movement, which allways heads to the next target. 25 26targetname 27must be present. The name of this movetarget. 28 29target 30the next spot to move to. If not present, stop here for good. 31 32pausetime 33The number of seconds to spend standing or bowing for path_stand or path_bow 34 35============================================================================== 36*/ 37 38/* 39============= 40t_movetarget 41 42Something has bumped into a movetarget. If it is a monster 43moving towards it, change the next destination and continue. 44============== 45*/ 46void() t_movetarget = 47{ 48local entity temp; 49 50 if (other.movetarget != self) 51 return; 52 53 if (other.enemy) 54 return; // fighting, not following a path 55 56 temp = self; 57 self = other; 58 other = temp; 59 60 if (self.classname == "monster_ogre") 61 sound (self, CHAN_VOICE, "ogre/ogdrag.wav", 1, ATTN_IDLE);// play chainsaw drag sound 62 63//dprint ("t_movetarget\n"); 64 self.goalentity = self.movetarget = find (world, targetname, other.target); 65 self.ideal_yaw = vectoyaw(self.goalentity.origin - self.origin); 66 if (!self.movetarget) 67 { 68 self.pausetime = time + 999999; 69 self.th_stand (); 70 return; 71 } 72}; 73 74 75 76void() movetarget_f = 77{ 78 if (!self.targetname) 79 objerror ("monster_movetarget: no targetname"); 80 81 self.solid = SOLID_TRIGGER; 82 self.touch = t_movetarget; 83 setsize (self, '-8 -8 -8', '8 8 8'); 84 85}; 86 87/*QUAKED path_corner (0.5 0.3 0) (-8 -8 -8) (8 8 8) 88Monsters will continue walking towards the next target corner. 89*/ 90void() path_corner = 91{ 92 movetarget_f (); 93}; 94 95 96 97//============================================================================ 98