]> git.jsancho.org Git - lugaru.git/blobdiff - Source/Person.h
Moved clothes loop to Person, got rid of globals tintr,tintg,tintb
[lugaru.git] / Source / Person.h
index dea9c3ad6202c510cf070127b79a06f0503fe80c..2f0a6ca982b5482f973f192956ab036f064f62b6 100644 (file)
@@ -1,5 +1,6 @@
 /*
 Copyright (C) 2003, 2010 - Wolfire Games
+Copyright (C) 2010-2016 - Lugaru contributors (see AUTHORS file)
 
 This file is part of Lugaru.
 
@@ -127,6 +128,7 @@ public:
     float permanentdamage;
     float superpermanentdamage;
     float lastcollide;
+    /* Seems to be 0 = alive, 1 = unconscious, 2 = dead */
     int dead;
 
     float jumppower;
@@ -270,10 +272,12 @@ public:
 
     int num_weapons;
     int weaponids[4];
+    /* Key of weaponids which is the weapon in hand, if any. -1 otherwise.
+     * Always 0 or -1 as activeweapon is moved to position 0 when taken */
     int weaponactive;
     int weaponstuck;
+    /* 0 or 1 to say if weapon is stuck in the front or the back  */
     int weaponstuckwhere;
-    int weaponwhere;
 
     int numwaypoints;
     XYZ waypoints[90];
@@ -392,6 +396,11 @@ public:
     void setAnimation(int);
     void DoAnimations();
     void RagDoll(bool checkcollision);
+
+    void takeWeapon (int weaponId);
+
+    bool addClothes(const int& clothesId);
+    void addClothes();
 };
 
 const int maxplayers = 10;