--- deliantra/server/common/item.C 2010/04/30 21:13:41 1.87 +++ deliantra/server/common/item.C 2010/10/11 18:40:43 1.90 @@ -51,21 +51,9 @@ */ // see include/object.h Body_Locations body_locations[NUM_BODY_LOCATIONS] = { - {KW_body_skill , "You can use it as your skill" , "It is used as a skill"}, - {KW_body_combat , "You can wield it as your weapon" , "It is used as a combat weapon"}, - {KW_body_range , "You can use it as your range weapon" , "It is used as a range weapon"}, - {KW_body_shield , "You can wield it as a shield" , "It is used as a shield"}, - {KW_body_arm , "You can put it on your arm" , "It goes on a human's arm"}, - {KW_body_torso , "You can wear it on your body" , "It goes on a human's torso"}, - {KW_body_head , "You can wear it on your head" , "It goes on a human's head"}, - {KW_body_neck , "You can wear it around your neck" , "It goes around a human's neck"}, - {KW_body_finger , "You can wear it on your finger" , "It goes on a human's finger"} , - {KW_body_shoulder, "You can wear it around your shoulders", "It goes around a human's shoulders"}, - {KW_body_foot , "You can put it on your foot" , "It goes on a human's foot"}, - {KW_body_hand , "You can put it on your hand" , "It goes on a human's hand"}, - {KW_body_wrist , "You can wear it around your wrist" , "It goes around a human's wrist"}, - {KW_body_waist , "You can wear it around your waist" , "It goes around a human's waist"}, -/*{"body_dragon_torso", "your body", "a dragon's body"} */ +# define def(name, use, nonuse) { # name, KW_body_ ## name, use, nonuse }, +# include "slotinc.h" +# undef def }; static char numbers_10[10][20] = { @@ -497,7 +485,7 @@ if ((val = op->stats.stat (attr))) buf.printf ("(%s%+d)", short_stat_name[attr], val); - if (op->stats.exp) buf.printf ("(speed %+lld)", (long long)op->stats.exp); + if (op->stats.exp) buf.printf ("(speed %+d)", (int)op->stats.exp); if (op->stats.wc) buf.printf ("(wc%+d)", op->stats.wc); if (op->stats.dam) buf.printf ("(dam%+d)", op->stats.dam); if (op->stats.ac) buf.printf ("(ac%+d)", op->stats.ac); @@ -688,12 +676,11 @@ { switch (op->type) { + case RANGED: case BOW: case WAND: case ROD: case HORN: - buf << " (applied)"; - break; case WEAPON: buf << " (applied)"; break; @@ -993,6 +980,7 @@ switch (op->type) { + case RANGED: case BOW: case ARROW: case WAND: @@ -1107,10 +1095,8 @@ */ if (identified || op->flag [FLAG_BEEN_APPLIED]) { - int attr, val; - - for (attr = 0; attr < NUM_STATS; attr++) - if ((val = op->stats.stat (attr))) + for (int attr = 0; attr < NUM_STATS; attr++) + if (int val = op->stats.stat (attr)) buf.printf ("(%s%+d)", short_stat_name[attr], val); if (op->stats.exp) @@ -1118,6 +1104,7 @@ switch (op->type) { + case RANGED: case BOW: case ARROW: case GIRDLE: @@ -1170,6 +1157,7 @@ switch (op->type) { + case RANGED: case ROD: /* These use stats.sp for spell selection and stats.food */ case HORN: /* and stats.hp for spell-point regeneration... */ case BOW: