-Person::Person() :
- whichpatchx(0),
- whichpatchz(0),
- animCurrent(bounceidleanim),
- animTarget(bounceidleanim),
- frameCurrent(0),
- frameTarget(1),
- oldanimCurrent(0),
- oldanimTarget(0),
- oldframeCurrent(0),
- oldframeTarget(0),
- howactive(typeactive),
- parriedrecently(0),
- superruntoggle(false),
- lastattack(0), lastattack2(0), lastattack3(0),
- currentoffset(), targetoffset(), offset(),
- target(0),
- transspeed(0),
-
- realoldcoords(),
- oldcoords(),
- coords(),
- velocity(),
-
- proportionhead(),
- proportionlegs(),
- proportionarms(),
- proportionbody(),
-
- unconscioustime(0),
-
- immobile(false),
-
- velspeed(0),
- targetyaw(0),
- targetrot(0),
- rot(0),
- oldrot(0),
- lookyaw(0),
- lookpitch(0),
- yaw(0),
- pitch(0),
- lowyaw(0),
- tilt(0),
- targettilt(0),
- tilt2(0),
- targettilt2(0),
- rabbitkickenabled(false),
-
- bloodloss(0),
- bleeddelay(0),
- skiddelay(0),
- skiddingdelay(0),
- deathbleeding(0),
- tempdeltav(0),
-
- damagetolerance(200),
- damage(0),
- permanentdamage(0),
- superpermanentdamage(0),
- lastcollide(0),
- dead(0),
-
- jumppower(5),
- onground(false),
-
- wentforweapon(0),
-
- calcrot(false),
-
- facing(),
-
- bleeding(0),
- bleedx(0), bleedy(0),
- direction(0),
- texupdatedelay(0),
-
- headyaw(0), headpitch(0),
- targetheadyaw(0), targetheadpitch(0),
-
- onterrain(false),
- pause(false),
-
- grabdelay(0),
-
- victim(nullptr),
- hasvictim(false),
-
- updatedelay(0),
- normalsupdatedelay(0),
-
- jumpstart(false),
- forwardkeydown(false),
- forwardstogglekeydown(false),
- rightkeydown(false),
- leftkeydown(false),
- backkeydown(false),
- jumpkeydown(false),
- jumptogglekeydown(false),
- crouchkeydown(false),
- crouchtogglekeydown(false),
- drawkeydown(false),
- drawtogglekeydown(false),
- throwkeydown(false),
- throwtogglekeydown(false),
- attackkeydown(false),
- feint(false),
- lastfeint(false),
- headless(false),
-
- crouchkeydowntime(0),
- jumpkeydowntime(0),
- freefall(false),
-
- turnspeed(0),
-
- aitype(passivetype),
- aiupdatedelay(0),
- losupdatedelay(0),
- ally(0),
- collide(0),
- collided(-10),
- avoidcollided(0),
- loaded(false),
- whichdirection(false),
- whichdirectiondelay(0),
- avoidsomething(false),
- avoidwhere(),
- blooddimamount(0),
-
- staggerdelay(0),
- blinkdelay(0),
- twitchdelay(0),
- twitchdelay2(0),
- twitchdelay3(0),
- lefthandmorphness(0),
- righthandmorphness(0),
- headmorphness(0),
- chestmorphness(0),
- tailmorphness(0),
- targetlefthandmorphness(0),
- targetrighthandmorphness(0),
- targetheadmorphness(1),
- targetchestmorphness(0),
- targettailmorphness(0),
- lefthandmorphstart(0), lefthandmorphend(0),
- righthandmorphstart(0), righthandmorphend(0),
- headmorphstart(0), headmorphend(0),
- chestmorphstart(0), chestmorphend(0),
- tailmorphstart(0), tailmorphend(0),
-
- weaponmissdelay(0),
- highreversaldelay(0),
- lowreversaldelay(0),
-
- creature(rabbittype),
-
- id(0),
-
- skeleton(),
-
- speed(0),
- scale(-1),
- power(0),
- speedmult(0),
-
- protectionhead(0),
- protectionhigh(0),
- protectionlow(0),
- armorhead(0),
- armorhigh(0),
- armorlow(0),
- metalhead(false),
- metalhigh(false),
- metallow(false),
-
- numclothes(0),
-
- landhard(false),
- bled(false),
- spurt(false),
- onfire(false),
- onfiredelay(0),
- burnt(0),
-
- flamedelay(0),
-
- playerdetail(0),
-
- num_weapons(0),
- weaponactive(-1),
- weaponstuck(-1),
- weaponstuckwhere(0),
-
- numwaypoints(0),
- pausetime(0),
-
- headtarget(),
- interestdelay(0),
-
- finalfinaltarget(),
- finaltarget(),
- finalpathfindpoint(0),
- targetpathfindpoint(0),
- lastpathfindpoint(0),
- lastpathfindpoint2(0),
- lastpathfindpoint3(0),
- lastpathfindpoint4(0),
-
- waypoint(0),
-
- lastseen(),
- lastseentime(0),
- lastchecktime(0),
- stunned(0),
- surprised(0),
- runninghowlong(0),
- occluded(0),
- lastoccluded(0),
- laststanding(0),
- escapednum(0),
-
- speechdelay(0),
- neckspurtdelay(0),
- neckspurtparticledelay(0),
- neckspurtamount(0),
-
- whichskin(0),
- rabbitkickragdoll(false),
-
- tempanimation(),
+void PersonType::Load()
+{
+ types.resize(2);
+
+ /* Wolf */
+ types[wolftype].proportions[0] = 1.1;
+ types[wolftype].proportions[1] = 1.1;
+ types[wolftype].proportions[2] = 1.1;
+ types[wolftype].proportions[3] = 1.1;
+
+ types[wolftype].animRun = wolfrunanim;
+ types[wolftype].animRunning = wolfrunninganim;
+ types[wolftype].animCrouch = wolfcrouchanim;
+ types[wolftype].animStop = wolfstopanim;
+ types[wolftype].animLanding = wolflandanim;
+ types[wolftype].animLandingHard = wolflandhardanim;
+
+ types[wolftype].soundsAttack[0] = barksound;
+ types[wolftype].soundsAttack[1] = bark2sound;
+ types[wolftype].soundsAttack[2] = bark3sound;
+ types[wolftype].soundsAttack[3] = barkgrowlsound;
+ types[wolftype].soundsTalk[0] = growlsound;
+ types[wolftype].soundsTalk[1] = growl2sound;
+
+ types[wolftype].figureFileName = "Skeleton/BasicFigureWolf";
+ types[wolftype].lowFigureFileName = "Skeleton/BasicFigureWolfLow";
+ types[wolftype].clothesFileName = "Skeleton/RabbitBelt";
+ types[wolftype].modelFileNames[0] = "Models/Wolf.solid";
+ types[wolftype].modelFileNames[1] = "Models/Wolf2.solid";
+ types[wolftype].modelFileNames[2] = "Models/Wolf3.solid";
+ types[wolftype].modelFileNames[3] = "Models/Wolf4.solid";
+ types[wolftype].modelFileNames[4] = "Models/Wolf5.solid";
+ types[wolftype].modelFileNames[5] = "Models/Wolf6.solid";
+ types[wolftype].modelFileNames[6] = "Models/Wolf7.solid";
+ types[wolftype].lowModelFileName = "Models/WolfLow.solid";
+ types[wolftype].modelClothesFileName = "Models/Belt.solid";
+
+ /* Rabbit */
+ types[rabbittype].proportions[0] = 1.2;
+ types[rabbittype].proportions[1] = 1.05;
+ types[rabbittype].proportions[2] = 1;
+ types[rabbittype].proportions[3] = 1.1;
+ types[rabbittype].proportions[3].y = 1.05;
+
+ types[rabbittype].animRun = runanim;
+ types[rabbittype].animRunning = rabbitrunninganim;
+ types[rabbittype].animCrouch = crouchanim;
+ types[rabbittype].animStop = stopanim;
+ types[rabbittype].animLanding = landanim;
+ types[rabbittype].animLandingHard = landhardanim;
+
+ types[rabbittype].soundsAttack[0] = rabbitattacksound;
+ types[rabbittype].soundsAttack[1] = rabbitattack2sound;
+ types[rabbittype].soundsAttack[2] = rabbitattack3sound;
+ types[rabbittype].soundsAttack[3] = rabbitattack4sound;
+ types[rabbittype].soundsTalk[0] = rabbitchitter;
+ types[rabbittype].soundsTalk[1] = rabbitchitter2;
+
+ types[rabbittype].figureFileName = "Skeleton/BasicFigure";
+ types[rabbittype].lowFigureFileName = "Skeleton/BasicFigureLow";
+ types[rabbittype].clothesFileName = "Skeleton/RabbitBelt";
+ types[rabbittype].modelFileNames[0] = "Models/Body.solid";
+ types[rabbittype].modelFileNames[1] = "Models/Body2.solid";
+ types[rabbittype].modelFileNames[2] = "Models/Body3.solid";
+ types[rabbittype].modelFileNames[3] = "Models/Body4.solid";
+ types[rabbittype].modelFileNames[4] = "Models/Body5.solid";
+ types[rabbittype].modelFileNames[5] = "Models/Body6.solid";
+ types[rabbittype].modelFileNames[6] = "Models/Body7.solid";
+ types[rabbittype].lowModelFileName = "Models/BodyLow.solid";
+ types[rabbittype].modelClothesFileName = "Models/Belt.solid";
+}
+
+Person::Person()
+ : whichpatchx(0)
+ , whichpatchz(0)
+ , animCurrent(bounceidleanim)
+ , animTarget(bounceidleanim)
+ , frameCurrent(0)
+ , frameTarget(1)
+ , oldanimCurrent(0)
+ , oldanimTarget(0)
+ , oldframeCurrent(0)
+ , oldframeTarget(0)
+ , howactive(typeactive)
+ , parriedrecently(0)
+ , superruntoggle(false)
+ , lastattack(0)
+ , lastattack2(0)
+ , lastattack3(0)
+ , currentoffset()
+ , targetoffset()
+ , offset()
+ , target(0)
+ , transspeed(0)
+ ,
+
+ realoldcoords()
+ , oldcoords()
+ , coords()
+ , velocity()
+
+ , unconscioustime(0)
+
+ , immobile(false)
+
+ , velspeed(0)
+ , targetyaw(0)
+ , targetrot(0)
+ , rot(0)
+ , oldrot(0)
+ , lookyaw(0)
+ , lookpitch(0)
+ , yaw(0)
+ , pitch(0)
+ , lowyaw(0)
+ , tilt(0)
+ , targettilt(0)
+ , tilt2(0)
+ , targettilt2(0)
+ , rabbitkickenabled(false)
+ ,
+
+ bloodloss(0)
+ , bleeddelay(0)
+ , skiddelay(0)
+ , skiddingdelay(0)
+ , deathbleeding(0)
+ , tempdeltav(0)
+ ,
+
+ damagetolerance(200)
+ , damage(0)
+ , permanentdamage(0)
+ , superpermanentdamage(0)
+ , lastcollide(0)
+ , dead(0)
+ ,
+
+ jumppower(5)
+ , onground(false)
+ ,
+
+ wentforweapon(0)
+ ,
+
+ calcrot(false)
+ ,
+
+ facing()
+ ,
+
+ bleeding(0)
+ , bleedx(0)
+ , bleedy(0)
+ , direction(0)
+ , texupdatedelay(0)
+ ,
+
+ headyaw(0)
+ , headpitch(0)
+ , targetheadyaw(0)
+ , targetheadpitch(0)
+ ,
+
+ onterrain(false)
+ , pause(false)
+ ,
+
+ grabdelay(0)
+ ,
+
+ victim(nullptr)
+ , hasvictim(false)
+ ,
+
+ updatedelay(0)
+ , normalsupdatedelay(0)
+ ,
+
+ jumpstart(false)
+ , forwardkeydown(false)
+ , forwardstogglekeydown(false)
+ , rightkeydown(false)
+ , leftkeydown(false)
+ , backkeydown(false)
+ , jumpkeydown(false)
+ , jumptogglekeydown(false)
+ , crouchkeydown(false)
+ , crouchtogglekeydown(false)
+ , drawkeydown(false)
+ , drawtogglekeydown(false)
+ , throwkeydown(false)
+ , throwtogglekeydown(false)
+ , attackkeydown(false)
+ , feint(false)
+ , lastfeint(false)
+ , headless(false)
+ ,
+
+ crouchkeydowntime(0)
+ , jumpkeydowntime(0)
+ , freefall(false)
+ ,
+
+ turnspeed(0)
+ ,
+
+ aitype(passivetype)
+ , aiupdatedelay(0)
+ , losupdatedelay(0)
+ , ally(0)
+ , collide(0)
+ , collided(-10)
+ , avoidcollided(0)
+ , loaded(false)
+ , whichdirection(false)
+ , whichdirectiondelay(0)
+ , avoidsomething(false)
+ , avoidwhere()
+ , blooddimamount(0)
+ ,
+
+ staggerdelay(0)
+ , blinkdelay(0)
+ , twitchdelay(0)
+ , twitchdelay2(0)
+ , twitchdelay3(0)
+ , lefthandmorphness(0)
+ , righthandmorphness(0)
+ , headmorphness(0)
+ , chestmorphness(0)
+ , tailmorphness(0)
+ , targetlefthandmorphness(0)
+ , targetrighthandmorphness(0)
+ , targetheadmorphness(1)
+ , targetchestmorphness(0)
+ , targettailmorphness(0)
+ , lefthandmorphstart(0)
+ , lefthandmorphend(0)
+ , righthandmorphstart(0)
+ , righthandmorphend(0)
+ , headmorphstart(0)
+ , headmorphend(0)
+ , chestmorphstart(0)
+ , chestmorphend(0)
+ , tailmorphstart(0)
+ , tailmorphend(0)
+ ,
+
+ weaponmissdelay(0)
+ , highreversaldelay(0)
+ , lowreversaldelay(0)
+ ,
+
+ creature(rabbittype)
+ ,
+
+ id(0)
+ ,
+
+ skeleton()
+ ,
+
+ speed(0)
+ , scale(-1)
+ , power(0)
+ , speedmult(0)
+ ,
+
+ protectionhead(0)
+ , protectionhigh(0)
+ , protectionlow(0)
+ , armorhead(0)
+ , armorhigh(0)
+ , armorlow(0)
+ , metalhead(false)
+ , metalhigh(false)
+ , metallow(false)
+ ,
+
+ numclothes(0)
+ ,
+
+ landhard(false)
+ , bled(false)
+ , spurt(false)
+ , onfire(false)
+ , onfiredelay(0)
+ , burnt(0)
+ ,
+
+ flamedelay(0)
+ ,
+
+ playerdetail(0)
+ ,
+
+ num_weapons(0)
+ , weaponactive(-1)
+ , weaponstuck(-1)
+ , weaponstuckwhere(0)
+ ,
+
+ numwaypoints(0)
+ , pausetime(0)
+ ,
+
+ headtarget()
+ , interestdelay(0)
+ ,
+
+ finalfinaltarget()
+ , finaltarget()
+ , finalpathfindpoint(0)
+ , targetpathfindpoint(0)
+ , lastpathfindpoint(0)
+ , lastpathfindpoint2(0)
+ , lastpathfindpoint3(0)
+ , lastpathfindpoint4(0)
+ ,
+
+ waypoint(0)
+ ,
+
+ lastseen()
+ , lastseentime(0)
+ , lastchecktime(0)
+ , stunned(0)
+ , surprised(0)
+ , runninghowlong(0)
+ , occluded(0)
+ , lastoccluded(0)
+ , laststanding(0)
+ , escapednum(0)
+ ,
+
+ speechdelay(0)
+ , neckspurtdelay(0)
+ , neckspurtparticledelay(0)
+ , neckspurtamount(0)
+ ,
+
+ whichskin(0)
+ , rabbitkickragdoll(false)
+ ,
+
+ tempanimation()
+ ,