aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBendegúz Nagy2016-06-18 12:44:41 +0200
committerBendegúz Nagy2016-08-26 23:02:22 +0200
commitef95c50fbb7acfa97b10a009c1f65e060ba26815 (patch)
treee67dbe43b48277ce020a84b1528158dce026fcc2
parent793ebd32a394bac738c27ac448431ef2c9faed38 (diff)
downloadscummvm-rg350-ef95c50fbb7acfa97b10a009c1f65e060ba26815.tar.gz
scummvm-rg350-ef95c50fbb7acfa97b10a009c1f65e060ba26815.tar.bz2
scummvm-rg350-ef95c50fbb7acfa97b10a009c1f65e060ba26815.zip
DM: Add gWeaponInfo
-rw-r--r--engines/dm/dungeonman.cpp48
-rw-r--r--engines/dm/dungeonman.h16
2 files changed, 57 insertions, 7 deletions
diff --git a/engines/dm/dungeonman.cpp b/engines/dm/dungeonman.cpp
index 4e09ce4896..3fd2e06a37 100644
--- a/engines/dm/dungeonman.cpp
+++ b/engines/dm/dungeonman.cpp
@@ -6,6 +6,54 @@
using namespace DM;
+WeaponInfo gWeaponInfo[46] = { // @ G0238_as_Graphic559_WeaponInfo
+ /* { Weight, Class, Strength, KineticEnergy, Attributes } */
+ WeaponInfo(1, (WeaponClass)130, 2, 0, 0x2000), /* EYE OF TIME */
+ WeaponInfo(1, (WeaponClass)131, 2, 0, 0x2000), /* STORMRING */
+ WeaponInfo(11, (WeaponClass)0, 8, 2, 0x2000), /* TORCH */
+ WeaponInfo(12, (WeaponClass)112, 10, 80, 0x2028), /* FLAMITT */
+ WeaponInfo(9, (WeaponClass)129, 16, 7, 0x2000), /* STAFF OF CLAWS */
+ WeaponInfo(30, (WeaponClass)113, 49, 110, 0x0942), /* BOLT BLADE */
+ WeaponInfo(47, (WeaponClass)0, 55, 20, 0x0900), /* FURY */
+ WeaponInfo(24, (WeaponClass)255, 25, 10, 0x20FF), /* THE FIRESTAFF */
+ WeaponInfo(5, (WeaponClass)2, 10, 19, 0x0200), /* DAGGER */
+ WeaponInfo(33, (WeaponClass)0, 30, 8, 0x0900), /* FALCHION */
+ WeaponInfo(32, (WeaponClass)0, 34, 10, 0x0900), /* SWORD */
+ WeaponInfo(26, (WeaponClass)0, 38, 10, 0x0900), /* RAPIER */
+ WeaponInfo(35, (WeaponClass)0, 42, 11, 0x0900), /* SABRE */
+ WeaponInfo(36, (WeaponClass)0, 46, 12, 0x0900), /* SAMURAI SWORD */
+ WeaponInfo(33, (WeaponClass)0, 50, 14, 0x0900), /* DELTA */
+ WeaponInfo(37, (WeaponClass)0, 62, 14, 0x0900), /* DIAMOND EDGE */
+ WeaponInfo(30, (WeaponClass)0, 48, 13, 0x0000), /* VORPAL BLADE */
+ WeaponInfo(39, (WeaponClass)0, 58, 15, 0x0900), /* THE INQUISITOR */
+ WeaponInfo(43, (WeaponClass)2, 49, 33, 0x0300), /* AXE */
+ WeaponInfo(65, (WeaponClass)2, 70, 44, 0x0300), /* HARDCLEAVE */
+ WeaponInfo(31, (WeaponClass)0, 32, 10, 0x2000), /* MACE */
+ WeaponInfo(41, (WeaponClass)0, 42, 13, 0x2000), /* MACE OF ORDER */
+ WeaponInfo(50, (WeaponClass)0, 60, 15, 0x2000), /* MORNINGSTAR */
+ WeaponInfo(36, (WeaponClass)0, 19, 10, 0x2700), /* CLUB */
+ WeaponInfo(110, (WeaponClass)0, 44, 22, 0x2600), /* STONE CLUB */
+ WeaponInfo(10, (WeaponClass)20, 1, 50, 0x2032), /* BOW */
+ WeaponInfo(28, (WeaponClass)30, 1, 180, 0x2078), /* CROSSBOW */
+ WeaponInfo(2, (WeaponClass)10, 2, 10, 0x0100), /* ARROW */
+ WeaponInfo(2, (WeaponClass)10, 2, 28, 0x0500), /* SLAYER */
+ WeaponInfo(19, (WeaponClass)39, 5, 20, 0x2032), /* SLING */
+ WeaponInfo(10, (WeaponClass)11, 6, 18, 0x2000), /* ROCK */
+ WeaponInfo(3, (WeaponClass)12, 7, 23, 0x0800), /* POISON DART */
+ WeaponInfo(1, (WeaponClass)1, 3, 19, 0x0A00), /* THROWING STAR */
+ WeaponInfo(8, (WeaponClass)0, 4, 4, 0x2000), /* STICK */
+ WeaponInfo(26, (WeaponClass)129, 12, 4, 0x2000), /* STAFF */
+ WeaponInfo(1, (WeaponClass)130, 0, 0, 0x2000), /* WAND */
+ WeaponInfo(2, (WeaponClass)140, 1, 20, 0x2000), /* TEOWAND */
+ WeaponInfo(35, (WeaponClass)128, 18, 6, 0x2000), /* YEW STAFF */
+ WeaponInfo(29, (WeaponClass)159, 0, 4, 0x2000), /* STAFF OF MANAR */
+ WeaponInfo(21, (WeaponClass)131, 0, 3, 0x2000), /* SNAKE STAFF */
+ WeaponInfo(33, (WeaponClass)136, 0, 7, 0x2000), /* THE CONDUIT */
+ WeaponInfo(8, (WeaponClass)132, 3, 1, 0x2000), /* DRAGON SPIT */
+ WeaponInfo(18, (WeaponClass)131, 9, 4, 0x2000), /* SCEPTRE OF LYF */
+ WeaponInfo(8, (WeaponClass)192, 1, 1, 0x2000), /* HORN OF FEAR */
+ WeaponInfo(30, (WeaponClass)26, 1, 220, 0x207D), /* SPEEDBOW */
+ WeaponInfo(36, (WeaponClass)255, 100, 50, 0x20FF)}; /* THE FIRESTAFF */
CreatureInfo gCreatureInfo[kCreatureTypeCount] = { // @ G0243_as_Graphic559_CreatureInfo
/* { CreatureAspectIndex, AttackSoundOrdinal, Attributes, GraphicInfo,
diff --git a/engines/dm/dungeonman.h b/engines/dm/dungeonman.h
index 6d4653e5b3..93705721f6 100644
--- a/engines/dm/dungeonman.h
+++ b/engines/dm/dungeonman.h
@@ -27,15 +27,17 @@ enum WeaponClass {
};
class WeaponInfo {
- uint16 _attributes; /* Bits 15-13 Unreferenced */
+
public:
- byte _weight;
+ uint16 _weight;
WeaponClass _class;
- byte _strength;
- byte _kineticEnergy;
-
- WeaponInfo(byte weight, WeaponClass wClass, byte strength, byte kineticEnergy, uint16 attributes)
- : _attributes(attributes), _weight(weight), _class(wClass), _strength(strength), _kineticEnergy(kineticEnergy) {}
+ uint16 _strength;
+ uint16 _kineticEnergy;
+private:
+ uint16 _attributes; /* Bits 15-13 Unreferenced */
+public:
+ WeaponInfo(uint16 weight, WeaponClass wClass, uint16 strength, uint16 kineticEnergy, uint16 attributes)
+ : _weight(weight), _class(wClass), _strength(strength), _kineticEnergy(kineticEnergy), _attributes(attributes) {}
uint16 getShootAttack() {return _attributes & 0xFF;} // @ M65_SHOOT_ATTACK
uint16 getProjectileAspectOrdinal() {return (_attributes >> 8) & 0x1F;} // @ M66_PROJECTILE_ASPECT_ORDINAL