summaryrefslogtreecommitdiffstats
path: root/src/game-server/testing.cpp
diff options
context:
space:
mode:
authorPhilipp Sehmisch <tmw@crushnet.org>2007-03-11 21:38:08 +0000
committerPhilipp Sehmisch <tmw@crushnet.org>2007-03-11 21:38:08 +0000
commit99f34a8a72f63b4bd9fc2f3c370c8cbe9b9127cf (patch)
treec075dcc834e0720e6de819c7514f4fdfa7cfe554 /src/game-server/testing.cpp
parent0a74cd8c92844e730cf6f56bdc3dd578c65a10d0 (diff)
Implemented stat handling infrastructure and basic damage calculation.
Diffstat (limited to 'src/game-server/testing.cpp')
-rw-r--r--src/game-server/testing.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/game-server/testing.cpp b/src/game-server/testing.cpp
index b48a7e7..7c3f87a 100644
--- a/src/game-server/testing.cpp
+++ b/src/game-server/testing.cpp
@@ -37,7 +37,15 @@ void testingMap(int id)
Being *being = new Controlled(OBJECT_MONSTER);
being->setSpeed(150);
being->setSize(8);
- being->setHitpoints(3);
+
+ // some bogus stats for testing
+ being->setBaseStat(Being::STAT_HP_MAXIMUM, 42);
+ being->setBaseStat(Being::STAT_PHYSICAL_ATTACK_MINIMUM, 1);
+ being->setBaseStat(Being::STAT_PHYSICAL_ATTACK_FLUCTUATION, 0);
+ being->setBaseStat(Being::STAT_PHYSICAL_DEFENCE, 5);
+
+ being->setHitpoints(being->getRealStat(Being::STAT_HP_MAXIMUM));
+
being->setMapId(1);
Point pos(720, 900);
being->setPosition(pos);