]> git.jsancho.org Git - lugaru.git/blobdiff - Source/Objects/PersonType.cpp
Moved hurtidle anim to PersonType to avoid hardcoded wolftype test
[lugaru.git] / Source / Objects / PersonType.cpp
index 2cddb3201e5fe583e41e977d0c0adc48e04da193..41d07c2483749444ba3f227c1ad8ac58c656bead 100644 (file)
@@ -24,6 +24,7 @@ std::vector<PersonType> PersonType::types;
 PersonType::PersonType()
 {
     animTalkIdle = tempanim;
+    animHurtIdle = tempanim;
 }
 
 bool PersonType::hasAnimTalkIdle()
@@ -31,6 +32,11 @@ bool PersonType::hasAnimTalkIdle()
     return (animTalkIdle != tempanim);
 }
 
+bool PersonType::hasAnimHurtIdle()
+{
+    return (animHurtIdle != tempanim);
+}
+
 void PersonType::Load()
 {
     types.resize(2);
@@ -76,6 +82,12 @@ void PersonType::Load()
     types[wolftype].skins[2] = "Textures/FurWolfSnow.jpg";
 
     types[wolftype].power = 2.5;
+    types[wolftype].defaultDamageTolerance = 300;
+    types[wolftype].defaultScale = .23;
+    types[wolftype].hasClaws = true;
+    types[wolftype].clothes = false;
+    types[wolftype].maxRunSpeed = 75;
+    types[wolftype].knifeCatchingType = 1;
 
     /* Rabbit */
     types[rabbittype].proportions[0] = 1.2;
@@ -93,6 +105,7 @@ void PersonType::Load()
     types[rabbittype].animFightIdle = fightidleanim;
     types[rabbittype].animBounceIdle = bounceidleanim;
     types[rabbittype].animTalkIdle = talkidleanim;
+    types[rabbittype].animHurtIdle = hurtidleanim;
 
     types[rabbittype].soundsAttack[0] = rabbitattacksound;
     types[rabbittype].soundsAttack[1] = rabbitattack2sound;
@@ -127,4 +140,10 @@ void PersonType::Load()
     types[rabbittype].skins[9] = "Textures/FurBrownWhite.jpg";
 
     types[rabbittype].power = 1;
+    types[rabbittype].defaultDamageTolerance = 200;
+    types[rabbittype].defaultScale = .2;
+    types[rabbittype].hasClaws = false;
+    types[rabbittype].clothes = true;
+    types[rabbittype].maxRunSpeed = 55;
+    types[rabbittype].knifeCatchingType = 0;
 }