From 0a7aeec3627ee2b9f57308c6df93ab58b11d9630 Mon Sep 17 00:00:00 2001 From: Rob Pearce Date: Sun, 11 Mar 2012 01:39:33 +0000 Subject: [PATCH] - [+] weakness spell should half melee damage. - [+] quaffed a potion of polymorph self... and nothing happened! - [+] only killing undead should please the god of life, not just killing anything evil - [+] klikirak shouldn't get angry when you take cold damage! - [+] fire sohuld convert flammable celltypes to another type: - [+] wood -> stone floor with pit - [+] carpet > stone - [+] increase flamepillar range - [+] warning before killing firebug on wood/carpet, if wisdom is at_high or above, and animal lore is high enough. - [+] make f_twohanded only apply up to a given lf size. - [+] implement - [+] then add "istwohandedfor(wep, lf)" - [+] then fix up ob defs in data.c - [+] unnatural growth/shrinkage spells should be temporary too (like potion) - [+] random polymorph code - [+] stay at the same TR, or one higher/lower! (same for player random polymorph) - [+] elephant - friendly to mammoans - [+] mammoth - [+] pixie (then pixie, dryad sprite = sylvan / fae) - [+] naiad / nixie - [+] blue 'n' - [+] low power charm to lure into water - [+] dagger/javelin - [+] throwing net - [+] resist magic 25% - [+] droid - zapper - [+] hoverscout (levitates, summons monsters) - [+] skellion - floating flaming skull, scream attack, flame melee - [+] fire primality should cast flame burst. - [+] don't modify monster hp based on fitness. - [+] storm primality / wind primality - [+] very fast - [+] 2 attacks - 1d5 each time. (pummel with debris / zapper) - [+] permenant windshield - [+] lesser: - [+] lightningbolt (lesser, 2d6) - [+] sleetstorm (lesser, 1-2 cold and slow movement) - [+] greater - [+] chain lightning (greater, 3d6) - [+] hailstorm (greater, 1d6 cold and 1d4-5d4 depending on power) - [+] naiad (water sprite) - 'n' -blue - [+] good - [+] aquatic - [+] water spirit - [+] charm spell - [+] ling parasite - green 'x' - [+] turns one corpse into a zombie (dies in the process) - [+] add onion object. - [+] roc - [+] "crystal cur" - canine. only bashing works - [+] gems for corpses. - [+] bug: monsters not using spells. fixed. - [+] test NOSPELLS bug with rapidivy - [+] test low IQ spells with storm primality - [+] make hitdice be d8 rather than d4 - [+] change F_HITDICE - [+] add constant HITDIESIDES - [+] redo all definitions in data.c --- ai.c | 2 +- attack.c | 22 + data.c | 975 ++++++++++++++++++++++++++--------- data/hiscores.db | Bin 14336 -> 14336 bytes data/vaults/antnest.vlt | 30 ++ data/vaults/cave_troll.vlt | 28 + data/vaults/playerstart4.vlt | 6 +- defs.h | 57 +- doc/add_eatconfer.txt | 6 + doc/glyphs.txt | 11 +- flag.c | 14 + flag.h | 1 + io.c | 29 +- lf.c | 173 +++++-- map.c | 22 +- nexus.c | 39 +- objects.c | 66 ++- objects.h | 3 +- spell.c | 90 ++-- 19 files changed, 1186 insertions(+), 388 deletions(-) create mode 100644 data/vaults/antnest.vlt create mode 100644 data/vaults/cave_troll.vlt create mode 100644 doc/add_eatconfer.txt diff --git a/ai.c b/ai.c index ca8c1c1..1dd9e8a 100644 --- a/ai.c +++ b/ai.c @@ -1292,7 +1292,7 @@ int ai_inventory_mgt(lifeform_t *lf, int *canattack) { // do we have a better firearm ? curgun = getfirearm(lf); - if (curwep && hasflag(curwep->flags, F_TWOHANDED)) { + if (curwep && istwohandedfor(curwep, lf)) { // we are using a two handed weapon. don't // check for guns. } else { diff --git a/attack.c b/attack.c index 959cdf2..83f6b48 100644 --- a/attack.c +++ b/attack.c @@ -257,6 +257,21 @@ int attackcell(lifeform_t *lf, cell_t *c, int force) { } } } + // high wisdom will prevent you from starting fires + if (getattrbracket(getattr(lf, A_WIS), A_WIS, NULL) >= AT_HIGH) { + if (hasflag(c->type->material->flags, F_FLAMMABLE)) { + if (getlorelevel(player, c->lf->race->raceclass->id) >= PR_BEGINNER) { + if (c->lf->race->id == R_FIREBUG) { + char victimname[BUFLEN],buf[BUFLEN]; + getlfname(c->lf, victimname); + snprintf(buf, BUFLEN, "Attacking %s might start a fire - proceed anyway?",victimname); + if (!warnabout(buf)) { + return B_TRUE; + } + } + } + } + } if (lfhasflag(lf, F_HASNEWLEVEL)) { if (!warnabout(TEXT_WARN_ATTACK_NOXP)) { @@ -2258,6 +2273,13 @@ int getdamroll(object_t *o, lifeform_t *victim, flag_t *damflag) { } } + if (o->pile->owner) { + int pct; + sumflags(o->pile->owner->flags, F_MELEEDAMPCT, &pct, NULL, NULL); + if (pct != 0) { + dam = pctof(f->val[0], dam); + } + } return dam; } diff --git a/data.c b/data.c index c10594e..1f2fe19 100644 --- a/data.c +++ b/data.c @@ -531,7 +531,7 @@ void initjobs(void) { addflag(lastjob->flags, F_ALIGNMENT, AL_NEUTRAL, NA, NA, NULL); // initial objects addflag(lastjob->flags, F_STARTOB, 100, NA, NA, "hatchet"); - addflag(lastjob->flags, F_STARTOB, 100, NA, NA, "bow"); + addflag(lastjob->flags, F_STARTOB, 100, NA, NA, "short bow"); addflag(lastjob->flags, F_STARTOB, 100, NA, NA, "50 arrows"); addflag(lastjob->flags, F_STARTOB, 100, NA, NA, "throwing net"); addflag(lastjob->flags, F_STARTOB, 100, NA, NA, "leather armour"); @@ -1297,11 +1297,19 @@ void initobjects(void) { addflag(lastmaterial->flags, F_DTIMMUNE, DT_FIRE, NA, NA, NULL); addflag(lastmaterial->flags, F_DTIMMUNE, DT_COLD, NA, NA, NULL); addmaterial(MT_RUBBER, "rubber", 4); + addflag(lastmaterial->flags, F_DTIMMUNE, DT_ELECTRIC, NA, NA, NULL); addmaterial(MT_LEATHER, "leather", 4); addflag(lastmaterial->flags, F_CANGETWET, B_TRUE, NA, NA, NULL); addflag(lastmaterial->flags, F_DTIMMUNE, DT_BASH, NA, NA, NULL); + addflag(lastmaterial->flags, F_DTIMMUNE, DT_ELECTRIC, NA, NA, NULL); addmaterial(MT_BONE, "bone", 5); addflag(lastmaterial->flags, F_HARDNESS, 3, NA, NA, NULL); + addmaterial(MT_CRYSTAL, "crystal", 5); + addflag(lastmaterial->flags, F_HARDNESS, 4, NA, NA, NULL); + addflag(lastmaterial->flags, F_DTVULN, DT_BASH, NA, NA, NULL); + addflag(lastmaterial->flags, F_DTIMMUNE, DT_COLD, NA, NA, NULL); + addflag(lastmaterial->flags, F_DTIMMUNE, DT_FIRE, NA, NA, NULL); + addflag(lastmaterial->flags, F_DTIMMUNE, DT_ELECTRIC, NA, NA, NULL); addmaterial(MT_OIL, "oil", 5); addmaterial(MT_ICE, "ice",6); addflag(lastmaterial->flags, F_HARDNESS, 3, NA, NA, NULL); @@ -2378,6 +2386,11 @@ void initobjects(void) { addflag(lastot->flags, F_RARITY, H_FOREST, 90, NA, NULL); addflag(lastot->flags, F_RARITY, H_DUNGEON, 90, NA, NULL); addflag(lastot->flags, F_NUMAPPEAR, 1, 12, NA, ""); + addot(OT_ONION, "onion", "An edible bulb, known for its irritant effects on the eyes.", MT_FOOD, 0.2, OC_FOOD, SZ_TINY); + addflag(lastot->flags, F_GLYPH, C_BROWN, '%', NA, NULL); + addflag(lastot->flags, F_EDIBLE, B_TRUE, 60, NA, ""); + addflag(lastot->flags, F_RARITY, H_DUNGEON, 100, RR_UNCOMMON, NULL); + addflag(lastot->flags, F_RARITY, H_FOREST, 100, RR_UNCOMMON, NULL); addot(OT_PASSIONFRUIT, "passionfruit", "A succulent passionfruit.", MT_FOOD, 0.5, OC_FOOD, SZ_TINY); addflag(lastot->flags, F_GLYPH, C_MAGENTA, '%', NA, NULL); addflag(lastot->flags, F_EDIBLE, B_TRUE, 100, NA, ""); @@ -2560,6 +2573,10 @@ void initobjects(void) { addflag(lastot->flags, F_RARITY, H_ALL, 100, NA, NULL); addflag(lastot->flags, F_VALUE, 160, NA, NA, NULL); + addot(OT_POT_FISHLUNG, "potion of fishy lungs", "Grants the imbiber the ability to temporarily breath water.", MT_GLASS, 1, OC_POTION, SZ_TINY); + addflag(lastot->flags, F_RARITY, H_ALL, 100, RR_UNCOMMON, NULL); + addflag(lastot->flags, F_VALUE, 75, NA, NA, NULL); + addot(OT_POT_FURY, "potion of fury", "Causes the drinker to enter a state of berzerk rage.", MT_GLASS, 1, OC_POTION, SZ_TINY); addflag(lastot->flags, F_AIBOOSTITEM, B_TRUE, NA, RR_UNCOMMON, NULL); addflag(lastot->flags, F_RARITY, H_ALL, 100, NA, NULL); @@ -2882,7 +2899,7 @@ void initobjects(void) { addflag(lastot->flags, F_AICASTTOATTACK, ST_SELF, NA, NA, NULL); addflag(lastot->flags, F_LOSLOF, B_FALSE, LOF_DONTNEED, NA, NULL); addflag(lastot->flags, F_ONGOING, B_TRUE, NA, NA, NULL); - addot(OT_S_WEAKEN, "weaken", "Temporarily lowers the target's muscle strength by ^bpower^n points.", MT_NOTHING, 0, OC_SPELL, SZ_TINY); + addot(OT_S_WEAKEN, "weaken", "Temporarily lowers the target's muscle strength by ^bpower^n points, and halves their melee damage.", MT_NOTHING, 0, OC_SPELL, SZ_TINY); addflag(lastot->flags, F_EXTRADESC, NA, NA, NA, "Spell power determines the duration of the weakness effect."); addflag(lastot->flags, F_SPELLSCHOOL, SS_DEATH, NA, NA, NULL); addflag(lastot->flags, F_SPELLLEVEL, 4, NA, NA, NULL); @@ -3157,6 +3174,11 @@ void initobjects(void) { addflag(lastot->flags, F_SPELLLEVEL, 5, NA, NA, NULL); addflag(lastot->flags, F_AICASTTOFLEE, ST_SELF, NA, NA, NULL); addflag(lastot->flags, F_LOSLOF, B_FALSE, LOF_DONTNEED, NA, NULL); + addot(OT_S_FLIGHT, "fly", "Allows the caster to fly.", MT_NOTHING, 0, OC_SPELL, SZ_TINY); + addflag(lastot->flags, F_SPELLSCHOOL, SS_AIR, NA, NA, NULL); + addflag(lastot->flags, F_SPELLLEVEL, 5, NA, NA, NULL); + addflag(lastot->flags, F_MAXPOWER, 1, NA, NA, NULL); + addflag(lastot->flags, F_ONGOING, B_TRUE, NA, NA, NULL); addot(OT_S_HASTE, "haste", "Increases the speed of the target.", MT_NOTHING, 0, OC_SPELL, SZ_TINY); addflag(lastot->flags, F_EXTRADESC, NA, NA, NA, "The spell's power determines how long its effects will last."); addflag(lastot->flags, F_SPELLSCHOOL, SS_AIR, NA, NA, NULL); @@ -3172,11 +3194,6 @@ void initobjects(void) { addflag(lastot->flags, F_MAXPOWER, 5, NA, NA, NULL); addflag(lastot->flags, F_AICASTTOATTACK, ST_VICTIM, NA, NA, NULL); // l6 - addot(OT_S_FLIGHT, "fly", "Allows the caster to fly.", MT_NOTHING, 0, OC_SPELL, SZ_TINY); - addflag(lastot->flags, F_SPELLSCHOOL, SS_AIR, NA, NA, NULL); - addflag(lastot->flags, F_SPELLLEVEL, 6, NA, NA, NULL); - addflag(lastot->flags, F_MAXPOWER, 1, NA, NA, NULL); - addflag(lastot->flags, F_ONGOING, B_TRUE, NA, NA, NULL); addot(OT_S_HURRICANE, "conjure hurricane", "Creates a devastating hurricane at a specified location. The hurricane will move about, obliterating all in its path.", MT_NOTHING, 0, OC_SPELL, SZ_TINY); addflag(lastot->flags, F_EXTRADESC, NA, NA, NA, "The spell's power determines how long the hurricane will last."); addflag(lastot->flags, F_SPELLSCHOOL, SS_AIR, NA, NA, NULL); @@ -3901,16 +3918,16 @@ void initobjects(void) { addflag(lastot->flags, F_LOSLOF, B_FALSE, LOF_DONTNEED, NA, NULL); // l2 addot(OT_S_SIZEUP, "unnatural growth", "Causes the target's body to grow in size. They will become easier to hit, but deal more damage.", MT_NOTHING, 0, OC_SPELL, SZ_TINY); + addflag(lastot->flags, F_EXTRADESC, NA, NA, NA, "Spell power determines how long the effect will last."); addflag(lastot->flags, F_SPELLSCHOOL, SS_MODIFICATION, NA, NA, NULL); addflag(lastot->flags, F_TARGETTEDSPELL, TT_MONSTER, NA, NA, NULL); addflag(lastot->flags, F_SPELLLEVEL, 2, NA, NA, NULL); - addflag(lastot->flags, F_MAXPOWER, 1, NA, NA, NULL); addflag(lastot->flags, F_AICASTTOATTACK, ST_SELF, NA, NA, NULL); addot(OT_S_SIZEDOWN, "unnatural shrinkage", "Causes the target's body to shrink in size. They will deal less damage, but become harder to hit.", MT_NOTHING, 0, OC_SPELL, SZ_TINY); + addflag(lastot->flags, F_EXTRADESC, NA, NA, NA, "Spell power determines how long the effect will last."); addflag(lastot->flags, F_SPELLSCHOOL, SS_MODIFICATION, NA, NA, NULL); addflag(lastot->flags, F_TARGETTEDSPELL, TT_MONSTER, NA, NA, NULL); addflag(lastot->flags, F_SPELLLEVEL, 2, NA, NA, NULL); - addflag(lastot->flags, F_MAXPOWER, 1, NA, NA, NULL); addflag(lastot->flags, F_AICASTTOATTACK, ST_VICTIM, NA, NA, NULL); addot(OT_S_MIRRORIMAGE, "mirror image", "Creates ^bpower^n illusionary clones of the caster to distract enemies. These clones cannot deal damage, and vanish when hit.", MT_NOTHING, 0, OC_SPELL, SZ_TINY); addflag(lastot->flags, F_EXTRADESC, NA, NA, NA, "Spell power determines how many clones are created, and how many hits they can sustain."); @@ -3978,7 +3995,7 @@ void initobjects(void) { addflag(lastot->flags, F_SPELLLEVEL, 5, NA, NA, NULL); addflag(lastot->flags, F_MAXPOWER, 1, NA, NA, NULL); addflag(lastot->flags, F_AICASTTOATTACK, ST_SELF, NA, NA, NULL); - addot(OT_S_QUICKENSTONE, "quicken stone", "Crafts nearby stone into powerful stone primalities.", MT_NOTHING, 0, OC_SPELL, SZ_TINY); + addot(OT_S_QUICKENSTONE, "quicken stone", "Crafts nearby stone into powerful rock primalities.", MT_NOTHING, 0, OC_SPELL, SZ_TINY); addflag(lastot->flags, F_EXTRADESC, NA, NA, NA, "Spell power determines how many creatures will be created."); addflag(lastot->flags, F_EXTRADESC, NA, NA, NA, "At power level VI, stronger creatures will be created."); addflag(lastot->flags, F_SPELLSCHOOL, SS_MODIFICATION, NA, NA, NULL); @@ -5619,7 +5636,7 @@ void initobjects(void) { addflag(lastot->flags, F_WALKDAM, DT_HEAT, NA, NA, "1d1+1"); addflag(lastot->flags, F_THEREISHERE, B_TRUE, NA, NA, "!"); - addot(OT_SLEETSTORM, "storm of sleet", "An intense storm of sleet. Hampers movement", MT_GAS, 0, OC_EFFECT, SZ_LARGE); + addot(OT_SLEETSTORM, "storm of sleet", "An intense storm of sleet. Hampers movement and deals minor cold damage.", MT_GAS, 0, OC_EFFECT, SZ_LARGE); addflag(lastot->flags, F_GLYPH, C_CYAN, UNI_SHADEMED, NA, NULL); addflag(lastot->flags, F_NODIECONVERTTEXT, NA, NA, NA, NULL); addflag(lastot->flags, F_OBHP, 10, 10, NA, NULL); @@ -5630,6 +5647,7 @@ void initobjects(void) { addflag(lastot->flags, F_DAMAGABLE, B_TRUE, NA, NA, NULL); addflag(lastot->flags, F_REDUCEMOVEMENT, 3, NA, NA, NULL); addflag(lastot->flags, F_THEREISHERE, B_TRUE, NA, NA, "!"); + addflag(lastot->flags, F_WALKDAM, DT_COLD, NA, NA, "1d2"); addflag(lastot->flags, F_WALKDAMBP, BP_HEAD, DT_WATER, NA, "1d2"); addflag(lastot->flags, F_WALKDAMBP, BP_SHOULDERS, DT_WATER, NA, "1d2"); addflag(lastot->flags, F_WALKDAMBP, BP_BODY, DT_WATER, NA, "1d2"); @@ -5713,7 +5731,8 @@ void initobjects(void) { addflag(lastot->flags, F_NOOBDIETEXT, B_TRUE, NA, NA, NULL); addflag(lastot->flags, F_DAMAGABLE, B_TRUE, NA, NA, NULL); addflag(lastot->flags, F_THEREISHERE, B_TRUE, NA, NA, "!"); - addflag(lastot->flags, F_WALKDAM, DT_COLD, NA, NA, "1d4"); + addflag(lastot->flags, F_WALKDAM, DT_COLD, NA, NA, "1d6"); + addflag(lastot->flags, F_WALKDAM, DT_PROJECTILE, NA, NA, "1d5"); addflag(lastot->flags, F_WALKDAMBP, BP_HEAD, DT_WATER, NA, "1d2"); addflag(lastot->flags, F_WALKDAMBP, BP_SHOULDERS, DT_WATER, NA, "1d2"); addflag(lastot->flags, F_WALKDAMBP, BP_BODY, DT_WATER, NA, "1d2"); @@ -6503,6 +6522,14 @@ void initobjects(void) { addflag(lastot->flags, F_UNARMEDWEP, B_TRUE, NA, NA, NULL); addflag(lastot->flags, F_CRITCHANCE, 1, NA, NA, NULL); + addot(OT_AIRFISTS, "air currents", "air currents object", MT_GAS, 0, OC_WEAPON, SZ_TINY); + addflag(lastot->flags, F_DAM, DT_BASH, 2, NA, NULL); + addflag(lastot->flags, F_ACCURACY, 100, NA, NA, NULL); + addflag(lastot->flags, F_USESSKILL, SK_UNARMED, NA, NA, NULL); + addflag(lastot->flags, F_ATTACKVERB, NA, NA, NA, "pummel"); + addflag(lastot->flags, F_UNARMEDWEP, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_CRITCHANCE, 1, NA, NA, NULL); + // this one is for the pirate addot(OT_HOOKHAND, "hook", "hook", MT_METAL, 0, OC_WEAPON, SZ_TINY); addflag(lastot->flags, F_DAM, DT_SLASH, 4, NA, NULL); @@ -6523,6 +6550,14 @@ void initobjects(void) { addflag(lastot->flags, F_UNARMEDWEP, B_TRUE, NA, NA, NULL); addflag(lastot->flags, F_CRITCHANCE, 3, NA, NA, NULL); + addot(OT_TRAMPLE, "trample", "trample object", MT_BONE, 0, OC_WEAPON, SZ_TINY); + addflag(lastot->flags, F_DAM, DT_CRUSH, 2, NA, NULL); + addflag(lastot->flags, F_ACCURACY, 100, NA, NA, NULL); + addflag(lastot->flags, F_ATTACKVERB, NA, NA, NA, "trample"); + addflag(lastot->flags, F_USESSKILL, SK_NONE, NA, NA, NULL); + addflag(lastot->flags, F_UNARMEDWEP, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_CRITCHANCE, 5, NA, NA, NULL); + addot(OT_BEAK, "beak", "beak object", MT_BONE, 0, OC_WEAPON, SZ_TINY); addflag(lastot->flags, F_DAM, DT_BITE, 2, NA, NULL); addflag(lastot->flags, F_ACCURACY, 100, NA, NA, NULL); @@ -6555,6 +6590,21 @@ void initobjects(void) { addflag(lastot->flags, F_UNARMEDWEP, B_TRUE, NA, NA, NULL); addflag(lastot->flags, F_CRITCHANCE, 5, NA, NA, NULL); + addot(OT_SAWBLADE, "sawblade", "sawblade object", MT_BONE, 0, OC_WEAPON, SZ_TINY); + addflag(lastot->flags, F_DAM, DT_SLASH, 2, NA, NULL); + addflag(lastot->flags, F_NOSTRDAMMOD, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_ATTACKVERB, NA, 2, NA, "scratch"); + addflag(lastot->flags, F_ATTACKVERB, 3, 6, NA, "slash"); + addflag(lastot->flags, F_ATTACKVERB, 7, 12, NA, "tear"); + addflag(lastot->flags, F_ATTACKVERB, 13, 18, NA, "rake"); + addflag(lastot->flags, F_ATTACKVERB, 19, 24, NA, "gouge"); + addflag(lastot->flags, F_ATTACKVERB, 25, NA, NA, "shred"); + addflag(lastot->flags, F_KILLVERB, 70, NA, NA, "disembowel"); + addflag(lastot->flags, F_ACCURACY, 100, NA, NA, NULL); + addflag(lastot->flags, F_USESSKILL, SK_NONE, NA, NA, NULL); + addflag(lastot->flags, F_UNARMEDWEP, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_CRITCHANCE, 5, NA, NA, NULL); + addot(OT_HOOF, "hooves", "hoof object", MT_BONE, 0, OC_WEAPON, SZ_TINY); addflag(lastot->flags, F_DAM, DT_BASH, 2, NA, NULL); addflag(lastot->flags, F_NOSTRDAMMOD, B_TRUE, NA, NA, NULL); @@ -6637,6 +6687,15 @@ void initobjects(void) { addflag(lastot->flags, F_NOSTRDAMMOD, B_TRUE, NA, NA, NULL); addflag(lastot->flags, F_USESSKILL, SK_NONE, NA, NA, NULL); addflag(lastot->flags, F_UNARMEDWEP, B_TRUE, NA, NA, NULL); + addot(OT_TOUCHCONFUSE, "confusing touch", "confusing touch object", MT_BONE, 0, OC_WEAPON, SZ_TINY); + addflag(lastot->flags, F_DAM, DT_BASH, 1, NA, NULL); + addflag(lastot->flags, F_ACCURACY, 100, NA, NA, NULL); + addflag(lastot->flags, F_ATTACKVERB, NA, NA, NA, "touch"); + addflag(lastot->flags, F_NOSTRDAMMOD, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_USESSKILL, SK_NONE, NA, NA, NULL); + addflag(lastot->flags, F_UNARMEDWEP, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_HITCONFER, F_CONFUSED, NA, NA, "3-4"); + addflag(lastot->flags, F_HITCONFERVALS, B_TRUE, NA, NA, NULL); addot(OT_TOUCHHOLY, "holy touch", "holy touch object", MT_BONE, 0, OC_WEAPON, SZ_TINY); addflag(lastot->flags, F_DAM, DT_HOLY, 1, NA, NULL); addflag(lastot->flags, F_ACCURACY, 100, NA, NA, NULL); @@ -6828,7 +6887,7 @@ void initobjects(void) { addflag(lastot->flags, F_DAM, DT_CHOP, 18, NA, NULL); addflag(lastot->flags, F_ALTDAM, DT_BASH, 6, NA, NULL); addflag(lastot->flags, F_NEEDSSPACE, B_TRUE, NA, NA, NULL); - addflag(lastot->flags, F_TWOHANDED, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_TWOHANDED, SZ_LARGE, NA, NA, NULL); addflag(lastot->flags, F_ACCURACY, 70, NA, NA, NULL); addflag(lastot->flags, F_USESSKILL, SK_AXES, NA, NA, NULL); addflag(lastot->flags, F_ATTREQ, A_STR, 75, 80, "15"); @@ -7008,7 +7067,7 @@ void initobjects(void) { addflag(lastot->flags, F_DAM, DT_SLASH, 12, NA, NULL); addflag(lastot->flags, F_ALTDAM, DT_PIERCE, 12, NA, NULL); addflag(lastot->flags, F_ACCURACY, 80, NA, NA, NULL); - addflag(lastot->flags, F_TWOHANDED, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_TWOHANDED, SZ_HUMAN, NA, NA, NULL); addflag(lastot->flags, F_USESSKILL, SK_LONGBLADES, NA, NA, NULL); addflag(lastot->flags, F_ATTREQ, A_STR, 65, 80, "10"); addflag(lastot->flags, F_CRITCHANCE, 5, NA, NA, NULL); @@ -7030,7 +7089,7 @@ void initobjects(void) { addflag(lastot->flags, F_DAM, DT_SLASH, 15, NA, NULL); addflag(lastot->flags, F_ALTDAM, DT_PIERCE, 15, NA, NULL); addflag(lastot->flags, F_ACCURACY, 80, NA, NA, NULL); - addflag(lastot->flags, F_TWOHANDED, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_TWOHANDED, SZ_LARGE, NA, NA, NULL); addflag(lastot->flags, F_NEEDSSPACE, B_TRUE, NA, NA, NULL); addflag(lastot->flags, F_USESSKILL, SK_LONGBLADES, NA, NA, NULL); addflag(lastot->flags, F_ATTREQ, A_STR, 75, 90, "3"); @@ -7066,6 +7125,21 @@ void initobjects(void) { addflag(lastot->flags, F_CRITCHANCE, 7, NA, NA, NULL); addflag(lastot->flags, F_CANBLOCK, DT_SLASH, NA, NA, NULL); + addot(OT_TUSK, "ivory tusk", "A large ivory tusk from a slain elephant. Could be used as weapon by very large creatures.", MT_BONE, 61, OC_WEAPON, SZ_HUMAN); + addflag(lastot->flags, F_NOBLESS, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_VALUE, 450, NA, NA, NULL); + addflag(lastot->flags, F_RARITY, H_DUNGEON, NA, RR_VERYRARE, NULL); + addflag(lastot->flags, F_RARITY, H_CAVE, NA, RR_VERYRARE, NULL); + addflag(lastot->flags, F_RARITY, H_FOREST, NA, RR_VERYRARE, NULL); + addflag(lastot->flags, F_OBATTACKDELAY, 120, NA, NA, NULL); + addflag(lastot->flags, F_DAM, DT_PIERCE, 12, NA, NULL); + addflag(lastot->flags, F_ACCURACY, 70, NA, NA, NULL); + addflag(lastot->flags, F_USESSKILL, SK_LONGBLADES, NA, NA, NULL); + addflag(lastot->flags, F_ATTREQ, A_STR, 80, NA, "3"); + addflag(lastot->flags, F_CRITCHANCE, 1, NA, NA, NULL); + addflag(lastot->flags, F_CANBLOCK, DT_SLASH, NA, NA, NULL); + + // polearms addot(OT_GLAIVE, "glaive", "A single-edged blade attached to a long pole.", MT_METAL, 10, OC_WEAPON, SZ_HUMAN); addflag(lastot->flags, F_RARITY, H_DUNGEON, 73, NA, NULL); @@ -7074,7 +7148,7 @@ void initobjects(void) { addflag(lastot->flags, F_DAM, DT_SLASH, 12, NA, NULL); addflag(lastot->flags, F_ALTDAM, DT_BASH, 6, NA, NULL); addflag(lastot->flags, F_ACCURACY, 80, NA, NA, NULL); - addflag(lastot->flags, F_TWOHANDED, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_TWOHANDED, SZ_LARGE, NA, NA, NULL); addflag(lastot->flags, F_NEEDSSPACE, B_TRUE, NA, NA, NULL); addflag(lastot->flags, F_USESSKILL, SK_POLEARMS, NA, NA, NULL); addflag(lastot->flags, F_ATTREQ, A_STR, 65, 85, "5"); @@ -7083,7 +7157,7 @@ void initobjects(void) { addflag(lastot->flags, F_RARITY, H_DUNGEON, 67, NA, NULL); addflag(lastot->flags, F_RARITY, H_CAVE, 67, NA, NULL); addflag(lastot->flags, F_EQUIPCONFER, F_CANWILL, OT_A_TRIPLF, NA, NULL); - addflag(lastot->flags, F_TWOHANDED, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_TWOHANDED, SZ_LARGE, NA, NA, NULL); addflag(lastot->flags, F_NEEDSSPACE, B_TRUE, NA, NA, NULL); addflag(lastot->flags, F_OBATTACKDELAY, 130, NA, NA, NULL); addflag(lastot->flags, F_DAM, DT_SLASH, 9, NA, NULL); @@ -7102,7 +7176,7 @@ void initobjects(void) { addflag(lastot->flags, F_DAM, DT_CHOP, 13, NA, NULL); addflag(lastot->flags, F_ALTDAM, DT_SLASH, 10, NA, NULL); addflag(lastot->flags, F_ACCURACY, 80, NA, NA, NULL); - addflag(lastot->flags, F_TWOHANDED, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_TWOHANDED, SZ_LARGE, NA, NA, NULL); addflag(lastot->flags, F_NEEDSSPACE, B_TRUE, NA, NA, NULL); addflag(lastot->flags, F_USESSKILL, SK_POLEARMS, NA, NA, NULL); addflag(lastot->flags, F_ATTREQ, A_STR, 35, 55, "10"); @@ -7111,7 +7185,7 @@ void initobjects(void) { addot(OT_LANCE, "lance", "A pole weapon designed for use while mounted.", MT_METAL, 12, OC_WEAPON, SZ_HUMAN); addflag(lastot->flags, F_RARITY, H_DUNGEON, 67, NA, NULL); addflag(lastot->flags, F_RARITY, H_CAVE, 67, NA, NULL); - addflag(lastot->flags, F_TWOHANDED, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_TWOHANDED, SZ_LARGE, NA, NA, NULL); addflag(lastot->flags, F_OBATTACKDELAY, 140, NA, NA, NULL); addflag(lastot->flags, F_DAM, DT_PIERCE, 11, NA, NULL); addflag(lastot->flags, F_ALTDAM, DT_BASH, 6, NA, NULL); @@ -7134,7 +7208,7 @@ void initobjects(void) { addflag(lastot->flags, F_RARITY, H_DUNGEON, 67, NA, NULL); addflag(lastot->flags, F_RARITY, H_CAVE, 67, NA, NULL); addflag(lastot->flags, F_EQUIPCONFER, F_CANWILL, OT_A_DISARMLF, NA, NULL); - addflag(lastot->flags, F_TWOHANDED, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_TWOHANDED, SZ_LARGE, NA, NA, NULL); addflag(lastot->flags, F_OBATTACKDELAY, 120, NA, NA, NULL); addflag(lastot->flags, F_DAM, DT_PIERCE, 11, NA, NULL); addflag(lastot->flags, F_ALTDAM, DT_BASH, 6, NA, NULL); @@ -7185,7 +7259,7 @@ void initobjects(void) { addflag(lastot->flags, F_DAM, DT_BASH, 8, NA, NULL); addflag(lastot->flags, F_ACCURACY, 80, NA, NA, NULL); addflag(lastot->flags, F_NEEDSSPACE, B_TRUE, NA, NA, NULL); - addflag(lastot->flags, F_TWOHANDED, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_TWOHANDED, NA, NA, NA, NULL); addflag(lastot->flags, F_USESSKILL, SK_STAVES, NA, NA, NULL); addflag(lastot->flags, F_ATTREQ, A_AGI, 50, 60, "15"); addflag(lastot->flags, F_RODSHAPED, B_TRUE, NA, NA, NULL); @@ -7198,7 +7272,7 @@ void initobjects(void) { addflag(lastot->flags, F_DAM, DT_BASH, 9, NA, NULL); addflag(lastot->flags, F_ACCURACY, 80, NA, NA, NULL); addflag(lastot->flags, F_NEEDSSPACE, B_TRUE, NA, NA, NULL); - addflag(lastot->flags, F_TWOHANDED, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_TWOHANDED, NA, NA, NA, NULL); addflag(lastot->flags, F_USESSKILL, SK_STAVES, NA, NA, NULL); addflag(lastot->flags, F_ATTREQ, A_AGI, 60, 70, "15"); addflag(lastot->flags, F_RODSHAPED, B_TRUE, NA, NA, NULL); @@ -7212,7 +7286,7 @@ void initobjects(void) { addflag(lastot->flags, F_ALTDAM, DT_BASH, 8, NA, NULL); addflag(lastot->flags, F_NEEDSSPACE, B_TRUE, NA, NA, NULL); addflag(lastot->flags, F_ACCURACY, 75, NA, NA, NULL); - addflag(lastot->flags, F_TWOHANDED, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_TWOHANDED, NA, NA, NA, NULL); addflag(lastot->flags, F_USESSKILL, SK_STAVES, NA, NA, NULL); addflag(lastot->flags, F_ATTREQ, A_AGI, 75, 85, "15"); addflag(lastot->flags, F_RODSHAPED, B_TRUE, NA, NA, NULL); @@ -7226,7 +7300,7 @@ void initobjects(void) { addflag(lastot->flags, F_DAM, DT_BASH, 10, NA, NULL); addflag(lastot->flags, F_NEEDSSPACE, B_TRUE, NA, NA, NULL); addflag(lastot->flags, F_ACCURACY, 80, NA, NA, NULL); - addflag(lastot->flags, F_TWOHANDED, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_TWOHANDED, SZ_LARGE, NA, NA, NULL); addflag(lastot->flags, F_USESSKILL, SK_STAVES, NA, NA, NULL); addflag(lastot->flags, F_ATTREQ, A_STR, 60, 70, "10"); addflag(lastot->flags, F_ATTREQ, A_AGI, 60, 70, "10"); @@ -7354,7 +7428,7 @@ void initobjects(void) { addflag(lastot->flags, F_OBATTACKDELAY, 200, NA, NA, NULL); addflag(lastot->flags, F_DAM, DT_BASH, 15, NA, NULL); addflag(lastot->flags, F_ACCURACY, 80, NA, NA, NULL); - addflag(lastot->flags, F_TWOHANDED, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_TWOHANDED, SZ_LARGE, NA, NA, NULL); addflag(lastot->flags, F_USESSKILL, SK_CLUBS, NA, NA, NULL); addflag(lastot->flags, F_ATTREQ, A_STR, 75, 85, "10"); addot(OT_MACE, "mace", "A weapon with a heavy head on a solid shaft used to bludgeon opponents.", MT_METAL, 10, OC_WEAPON, SZ_MEDIUM); @@ -7374,7 +7448,7 @@ void initobjects(void) { addflag(lastot->flags, F_DAM, DT_BASH, 12, NA, NULL); addflag(lastot->flags, F_ARMOURPIERCE, 6, NA, NA, ""); addflag(lastot->flags, F_ACCURACY, 80, NA, NA, NULL); - addflag(lastot->flags, F_TWOHANDED, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_TWOHANDED, SZ_HUMAN, NA, NA, NULL); addflag(lastot->flags, F_USESSKILL, SK_CLUBS, NA, NA, NULL); addflag(lastot->flags, F_ATTREQ, A_STR, 65, 75, "10"); addflag(lastot->flags, F_CRITCHANCE, 8, NA, NA, NULL); @@ -7529,7 +7603,7 @@ void initobjects(void) { addflag(lastot->flags, F_RARITY, H_CAVE, 100, RR_RARE, NULL); addflag(lastot->flags, F_FIREARM, B_TRUE, NA, NA, NULL); addflag(lastot->flags, F_OPERABLE, B_TRUE, NA, NA, NULL); - addflag(lastot->flags, F_TWOHANDED, B_TRUE, NA, NA, NULL); + addflag(lastot->flags, F_TWOHANDED, SZ_HUMAN, NA, NA, NULL); addflag(lastot->flags, F_FIRESPEED, 20, NA, NA, NULL); addflag(lastot->flags, F_ACCURACY, 80, NA, NA, NULL); addflag(lastot->flags, F_RANGE, 3, NA, NA, NULL); @@ -7710,7 +7784,7 @@ void initrace(void) { addflag(lastrace->flags, F_UNIQUE, NA, NA, NA, NULL); addflag(lastrace->flags, F_HOSTILE, NA, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4+20"); + addflag(lastrace->flags, F_HITDICE, 7, NA, NA, NULL); addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); //addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); //addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, NULL); @@ -7755,7 +7829,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_RARE, NULL); addflag(lastrace->flags, F_VARLEVEL, NA, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d3+4"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, NULL); @@ -7792,7 +7866,7 @@ void initrace(void) { addbonustext(lastrace->flags, F_PENDESC, "Low hit points."); addflag(lastrace->flags, F_DTVULN, DT_FIRE, NA, NA, NULL); addflag(lastrace->flags, F_DTVULN, DT_ELECTRIC, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+3"); + addflag(lastrace->flags, F_HITDICE, 1, 3, 4, NULL); // other special stuff addflag(lastrace->flags, F_NOISETEXT, N_GETANGRY, 3, NA, "screechs^a screech"); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); @@ -7809,7 +7883,7 @@ void initrace(void) { addflag(lastrace->flags, F_AVIAN, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_ALIGNMENT, AL_NONE, NA, NA, "gne"); - addrace(R_CYBORG, "cyborg", 150, 'R', C_GREY, MT_FLESH, RC_HUMANOID, "A cyborg is a human with cybernetic implants grafted throughout their body. In most cases their body has been partially reconstructed from metal, with a thin later of skin outside to maintain a human appearance. Cyborgs are exceptionaly good with technology due to their computer-enhanced brain, but completely unable to use magic (for much the same reason)."); + addrace(R_CYBORG, "cyborg", 150, '@', C_GREY, MT_FLESH, RC_HUMANOID, "A cyborg is a human with cybernetic implants grafted throughout their body. In most cases their body has been partially reconstructed from metal, with a thin later of skin outside to maintain a human appearance. Cyborgs are exceptionaly good with technology due to their computer-enhanced brain, but completely unable to use magic (for much the same reason)."); setbodytype(lastrace, BT_HUMANOID); setbodypartname(lastrace, BP_EARS, "audio inputs"); setbodypartname(lastrace, BP_EYES, "video inputs"); @@ -7855,7 +7929,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_VERYRARE, NULL); addflag(lastrace->flags, F_VARLEVEL, NA, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4+3"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, NULL); @@ -7880,7 +7954,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_VARLEVEL, NA, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d3+2"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, NULL); @@ -7929,7 +8003,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_RARE, NULL); addflag(lastrace->flags, F_VARLEVEL, NA, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d3+4"); + addflag(lastrace->flags, F_HITDICE, 1, 2, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, NULL); @@ -7966,7 +8040,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_VARLEVEL, NA, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d2+4"); + addflag(lastrace->flags, F_HITDICE, 1, NA, 5, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, NULL); @@ -8009,7 +8083,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_VARLEVEL, NA, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_LARGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d3+4"); + addflag(lastrace->flags, F_HITDICE, 1, 4, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_VERYSLOW, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_SLOW, NA, NA, NULL); @@ -8025,6 +8099,7 @@ void initrace(void) { addflag(lastrace->flags, F_FLEEONHPPCT, 50, NA, NA, NULL); // bonuses addbonustext(lastrace->flags, F_BONDESC, "Leather skin reduces damage."); + addflag(lastrace->flags, F_ARMOURRATING, 6, NA, NA, NULL); addflag(lastrace->flags, F_PHOTOMEM, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_ENHANCESMELL, 3, NA, NA, NULL); addflag(lastrace->flags, F_STARTSKILL, SK_LISTEN, PR_NOVICE, NA, NULL); @@ -8037,11 +8112,13 @@ void initrace(void) { addflag(lastrace->flags, F_TAMABLE, 25, NA, NA, NULL); addflag(lastrace->flags, F_ALIGNMENT, AL_NONE, NA, NA, "gne"); + + // robots addrace(R_ANDROID, "android", 150, 'R', C_GREEN, MT_METAL, RC_ROBOT, "Androids are robots contructed in the likeness of a human. Unlike cyborgs they contain no living tissue at all outside the brain."); setbodytype(lastrace, BT_HUMANOID); - setbodypartname(lastrace, BP_EARS, "audio inputs"); - setbodypartname(lastrace, BP_EYES, "video inputs"); + setbodypartname(lastrace, BP_EARS, "audio sensors"); + setbodypartname(lastrace, BP_EYES, "video sensors"); setbodypartname(lastrace, BP_BODY, "central frame"); setbodypartname(lastrace, BP_LEGS, "stabilisers"); setbodypartname(lastrace, BP_HANDS, "manipulators"); @@ -8060,7 +8137,7 @@ void initrace(void) { addflag(lastrace->flags, F_STARTSKILL, SK_TECHUSAGE, PR_MASTER, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, NULL); @@ -8073,8 +8150,10 @@ void initrace(void) { addflag(lastrace->flags, F_STARTOBCLASS, 50, OC_TECH, NA, NULL); addflag(lastrace->flags, F_HUMANOID, B_TRUE, NA, NA, NULL); - addrace(R_BOTRIOT, "riot bot", 90, 'R', C_BOLDBLUE, MT_METAL, RC_ROBOT, "Riot bots were created as unmanned crowd-control devices. They use water cannons, gas and electricity to repel violent protestors, and can protect themselves."); + addrace(R_BOTRIOT, "riot bot", 90, 'b', C_BOLDBLUE, MT_METAL, RC_ROBOT, "Riot bots were created as unmanned crowd-control devices. They use water cannons, gas and electricity to repel violent protestors, and can protect themselves."); addbodypart(lastrace, BP_BODY, "central core"); + addbodypart(lastrace, BP_EARS, "aural sensors"); + addbodypart(lastrace, BP_EYES, "video sensors"); addbodypart(lastrace, BP_FEET, "wheels"); addflag(lastrace->flags, F_ALIGNMENT, AL_NONE, NA, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); @@ -8082,7 +8161,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_VERYRARE, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 1, NA, 4, NULL); addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); addflag(lastrace->flags, F_HEAVENARM, 25, NA, NA, "force field"); addflag(lastrace->flags, F_CANWILL, OT_S_WATERJET, 3, 3, "pw:6;"); @@ -8092,11 +8171,14 @@ void initrace(void) { addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, B_APPENDYOU, "aims its turret"); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); + addflag(lastrace->flags, F_STARTOBCLASS, 50, OC_TECH, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_IQ, IQ_MINDLESS, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_ZAPPER, 6, NA, NULL); - addrace(R_BOTSECURITY, "security bot", 90, 'R', C_BROWN, MT_METAL, RC_ROBOT, "Security bots are basic robotic constructs that generate short (but powerful) electrical charges to deter trespassers."); + addrace(R_BOTSECURITY, "security bot", 90, 'b', C_BROWN, MT_METAL, RC_ROBOT, "One step up from droids, security bots are basic robotic constructs equipped with razor-sharp sawblades, and a protective force field."); addbodypart(lastrace, BP_BODY, "central core"); + addbodypart(lastrace, BP_EARS, "aural sensors"); + addbodypart(lastrace, BP_EYES, "video sensors"); addbodypart(lastrace, BP_FEET, "wheels"); addflag(lastrace->flags, F_ALIGNMENT, AL_NONE, NA, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); @@ -8104,24 +8186,48 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4"); + addflag(lastrace->flags, F_HITDICE, 1, NA, 4, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_HEAVENARM, 6, NA, NA, "force field"); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); addflag(lastrace->flags, F_STARTATT, A_IQ, IQ_MINDLESS, NA, NULL); + addflag(lastrace->flags, F_MAXATTACKS, 1, 1, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_ZAPPER, 3, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_SAWBLADE, 4, NA, NULL); + addflag(lastrace->flags, F_STARTOBCLASS, 50, OC_TECH, NA, NULL); addflag(lastrace->flags, F_AWARENESS, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, B_APPENDYOU, "swivels its sensors"); + addrace(R_DROID, "droid", 90, 'b', C_GREY, MT_METAL, RC_ROBOT, "Droids are very basic robots designed for one simple function. Generally this function is \"kill\". They can generate short (but powerful) electrical charges to deter trespassers."); + addbodypart(lastrace, BP_BODY, "central core"); + addbodypart(lastrace, BP_EARS, "aural sensors"); + addbodypart(lastrace, BP_EYES, "video sensors"); + addbodypart(lastrace, BP_FEET, "wheels"); + addflag(lastrace->flags, F_ALIGNMENT, AL_NONE, NA, NA, NULL); + addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); + addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, NA, NULL); + addflag(lastrace->flags, F_RARITY, H_CAVE, NA, NA, NULL); + addflag(lastrace->flags, F_RARITY, H_FOREST, NA, NA, NULL); + addflag(lastrace->flags, F_HITDICE, 1, NA, 4, NULL); + addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); + addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); + addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); + addflag(lastrace->flags, F_STARTATT, A_IQ, IQ_MINDLESS, NA, NULL); + addflag(lastrace->flags, F_STARTOBCLASS, 50, OC_TECH, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_ZAPPER, 3, NA, NULL); + addflag(lastrace->flags, F_AWARENESS, B_TRUE, NA, NA, NULL); + addrace(R_FLAMETURRET, "flame turret", 100, 'R', C_RED, MT_METAL, RC_ROBOT, "A motorised flamethrower mounted on an automated turntable."); addbodypart(lastrace, BP_BODY, "central core"); + addbodypart(lastrace, BP_EYES, "sensors"); addbodypart(lastrace, BP_FEET, "turntable"); addflag(lastrace->flags, F_ALIGNMENT, AL_NONE, NA, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 0, 1, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_DOESNTMOVE, B_TRUE, NA, B_TRUE, NULL); addflag(lastrace->flags, F_NOPRINTS, B_TRUE, NA, NA, NULL); @@ -8131,9 +8237,33 @@ void initrace(void) { addflag(lastrace->flags, F_CANWILL, OT_S_BURNINGWAVE, NA, NA, "pw:10;"); addflag(lastrace->flags, F_CASTCHANCE, 100, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, NA, NULL); + addflag(lastrace->flags, F_STARTOBCLASS, 50, OC_TECH, NA, NULL); addflag(lastrace->flags, F_AUTOROTATE, 1, NA, NA, NULL); addflag(lastrace->flags, F_FOLLOWTIME, 3, NA, NA, NULL); + addrace(R_HOVERSCOUT, "hoverscout", 100, 'b', C_CYAN, MT_METAL, RC_ROBOT, "An airborne drone constantly on the lookout for intruders. Hoverscouts are equipped with technology allowing them to teleport in backup units."); + addbodypart(lastrace, BP_BODY, "central core"); + addbodypart(lastrace, BP_EARS, "aural sensors"); + addbodypart(lastrace, BP_EYES, "video sensors"); + addflag(lastrace->flags, F_ALIGNMENT, AL_NONE, NA, NA, NULL); + addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); + addflag(lastrace->flags, F_RARITY, H_ALL, NA, RR_UNCOMMON, NULL); + addflag(lastrace->flags, F_HITDICE, 0, 1, NA, NULL); + addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); + addflag(lastrace->flags, F_NOPRINTS, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_LEVITATING, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); + addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); + addflag(lastrace->flags, F_STARTATT, A_IQ, IQ_MINDLESS, NA, NULL); + addflag(lastrace->flags, F_CANWILL, OT_S_CREATEMONSTER, 15, 15, "pw:3;"); + addflag(lastrace->flags, F_CASTCHANCE, 100, NA, NA, NULL); + addflag(lastrace->flags, F_NOISETEXT, N_FLY, 2, NA, "^whirring"); + addflag(lastrace->flags, F_NOISETEXT, N_GETANGRY, 5, NA, "blares its siren^a loud siren"); + addflag(lastrace->flags, F_SPELLCASTTIME, 5, OT_S_CREATEMONSTER, NA, NULL); + addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, NA, "emits a beam of coloured light"); + addflag(lastrace->flags, F_SPELLCASTCONTTEXT, OT_NONE, NA, NA, "intensifies its beam of light"); + addflag(lastrace->flags, F_STARTOBCLASS, 50, OC_TECH, NA, NULL); // human monsters... addrace(R_BANDITLDR, "bandit leader", 75, '@', C_GREY, MT_FLESH, RC_HUMANOID, "Like a regular bandit, but bigger and stronger. Enough so to bully their followers into submission anyway."); @@ -8145,7 +8275,7 @@ void initrace(void) { addflag(lastrace->flags, F_DEMANDSBRIBE, NA, NA, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+2"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, NULL); @@ -8172,7 +8302,7 @@ void initrace(void) { addflag(lastrace->flags, F_DEMANDSBRIBE, NA, NA, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_NUMAPPEAR, 1, 3, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -8198,7 +8328,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_VILLAGE, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+2"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 0, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_FISTS, 2, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_AGI, AT_AVERAGE, NA, NULL); @@ -8215,7 +8345,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_VARLEVEL, NA, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+2"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 0, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_FISTS, 2, NA, NULL); addflag(lastrace->flags, F_STARTOB, 80, NA, NA, "1-50 gold coins"); @@ -8238,7 +8368,7 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_STR, AT_LTAVERAGE, NA, NULL); addflag(lastrace->flags, F_VARLEVEL, NA, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 0, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_FISTS, 2, NA, NULL); addflag(lastrace->flags, F_STARTOB, 50, NA, NA, "1-2 stones"); @@ -8262,7 +8392,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_VILLAGE, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_VARLEVEL, NA, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+4"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_NUMAPPEAR, 1, 3, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -8273,7 +8403,7 @@ void initrace(void) { addflag(lastrace->flags, F_STARTOB, 100, NA, NA, "good armour"); addflag(lastrace->flags, F_STARTOB, 100, NA, NA, "good armour"); addflag(lastrace->flags, F_STARTOB, 100, NA, NA, "good armour"); - addflag(lastrace->flags, F_STARTOB, 50, NA, NA, "bow"); + addflag(lastrace->flags, F_STARTOB, 50, NA, NA, "short bow"); addflag(lastrace->flags, F_STARTOB, 50, NA, NA, "1-10 arrows"); addflag(lastrace->flags, F_WANTSBETTERWEP, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_WANTSBETTERARM, B_TRUE, NA, NA, NULL); @@ -8293,7 +8423,7 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_CHA, NA, NA, "80"); addflag(lastrace->flags, F_STARTASLEEPPCT, 0, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "50d4"); + addflag(lastrace->flags, F_HITDICE, 50, NA, NA, NULL); addflag(lastrace->flags, F_TR, 50, NA, NA, NULL); addflag(lastrace->flags, F_UNIQUE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_FISTS, 2, NA, NULL); @@ -8345,7 +8475,7 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_CHA, NA, NA, "70"); addflag(lastrace->flags, F_STARTASLEEPPCT, 0, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "50d4"); + addflag(lastrace->flags, F_HITDICE, 50, NA, NA, NULL); addflag(lastrace->flags, F_TR, 50, NA, NA, NULL); addflag(lastrace->flags, F_UNIQUE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_FISTS, 8, NA, NULL); @@ -8399,7 +8529,7 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_CHA, NA, NA, "60"); addflag(lastrace->flags, F_STARTASLEEPPCT, 0, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "50d4"); + addflag(lastrace->flags, F_HITDICE, 50, NA, NA, NULL); addflag(lastrace->flags, F_TR, 50, NA, NA, NULL); addflag(lastrace->flags, F_UNIQUE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_FISTS, 6, NA, NULL); @@ -8454,7 +8584,7 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_CHA, NA, NA, "30"); addflag(lastrace->flags, F_STARTASLEEPPCT, 0, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "30d4"); + addflag(lastrace->flags, F_HITDICE, 30, NA, NA, NULL); addflag(lastrace->flags, F_TR, 50, NA, NA, NULL); addflag(lastrace->flags, F_UNIQUE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_FISTS, 2, NA, NULL); @@ -8504,7 +8634,7 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_CHA, NA, NA, "50"); addflag(lastrace->flags, F_STARTASLEEPPCT, 0, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "50d4"); + addflag(lastrace->flags, F_HITDICE, 50, NA, NA, NULL); addflag(lastrace->flags, F_TR, 50, NA, NA, NULL); addflag(lastrace->flags, F_UNIQUE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TOUCHHOLY, 10, NA, NULL); @@ -8550,7 +8680,7 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_CHA, NA, NA, "30"); addflag(lastrace->flags, F_STARTASLEEPPCT, 0, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "30d4"); + addflag(lastrace->flags, F_HITDICE, 30, NA, NA, NULL); addflag(lastrace->flags, F_TR, 50, NA, NA, NULL); addflag(lastrace->flags, F_UNIQUE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 12, NA, NULL); @@ -8599,7 +8729,7 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_CHA, NA, NA, "60"); addflag(lastrace->flags, F_STARTASLEEPPCT, 0, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "50d4"); + addflag(lastrace->flags, F_HITDICE, 50, NA, NA, NULL); addflag(lastrace->flags, F_TR, 50, NA, NA, NULL); addflag(lastrace->flags, F_UNIQUE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TOUCHBURN, 16, NA, NULL); @@ -8639,7 +8769,7 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_CHA, NA, NA, "60"); addflag(lastrace->flags, F_STARTASLEEPPCT, 0, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "25d4"); + addflag(lastrace->flags, F_HITDICE, 25, NA, NA, NULL); addflag(lastrace->flags, F_TR, 50, NA, NA, NULL); addflag(lastrace->flags, F_UNIQUE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_FISTS, 4, NA, NULL); @@ -8685,7 +8815,7 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_CHA, NA, NA, "85"); addflag(lastrace->flags, F_STARTASLEEPPCT, 0, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "50d4"); + addflag(lastrace->flags, F_HITDICE, 50, NA, NA, NULL); addflag(lastrace->flags, F_TR, 50, NA, NA, NULL); addflag(lastrace->flags, F_UNIQUE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_FISTS, 2, NA, NULL); @@ -8730,7 +8860,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_VERYRARE, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_VERYRARE, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "8d4"); + addflag(lastrace->flags, F_HITDICE, 8, NA, NA, NULL); addflag(lastrace->flags, F_TR, 9, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 8, NA, NA, NULL); addflag(lastrace->flags, F_LEVITATING, B_TRUE, NA, NA, NULL); @@ -8763,7 +8893,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_LARGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4+12"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_ENHANCESMELL, 5, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -8796,7 +8926,7 @@ void initrace(void) { addflag(lastrace->flags, F_COLDBLOOD, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_BLOODOB, NA, NA, NA, "splash of cockatrice blood"); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 8, NA, NA, NULL); @@ -8819,7 +8949,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_TINY, NA, NA, NULL); addflag(lastrace->flags, F_NUMAPPEAR, 1, 3, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4"); + addflag(lastrace->flags, F_HITDICE, 1, NA, 4, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -8845,7 +8975,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_LARGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "7d4"); + addflag(lastrace->flags, F_HITDICE, 7, NA, NA, NULL); addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 10, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 15, NA, NA, NULL); @@ -8855,6 +8985,7 @@ void initrace(void) { addflag(lastrace->flags, F_ACTIONSPEED, SP_VERYSLOW, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); + addflag(lastrace->flags, F_CASTWITHOUTIQ, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_CANCAST, OT_S_DARKNESS, 7, 7, "pw:3;"); addflag(lastrace->flags, F_CANWILL, OT_A_GRAB, NA, NA, NULL); addflag(lastrace->flags, F_CANWILL, OT_A_CRUSH, NA, NA, "dam:0d0+5;"); @@ -8874,11 +9005,9 @@ void initrace(void) { addflag(lastrace->flags, F_ALIGNMENT, AL_GOOD, NA, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_RARITY, H_DUNGEON, RR_RARE, NA, NULL); - addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); + addflag(lastrace->flags, F_RARITY, H_DUNGEON, RR_VERYRARE, NA, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_RARE, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -8897,6 +9026,7 @@ void initrace(void) { addflag(lastrace->flags, F_STARTOB, 100, NA, NA, "knife"); addflag(lastrace->flags, F_CANCAST, OT_S_PLANTWALK, NA, NA, NULL); addflag(lastrace->flags, F_CANCAST, OT_S_CHARM, NA, NA, "pw:1;"); + addflag(lastrace->flags, F_CASTCHANCE, 70, NA, NA, NULL); //addflag(lastrace->flags, F_CANCAST, OT_S_SLEEP, 10, 10, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_PLANTWALK, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_CHARM, NA, B_APPENDYOU, "beckons"); @@ -8918,7 +9048,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_RARE, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_RARE, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_RARE, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "7d4+3"); + addflag(lastrace->flags, F_HITDICE, 7, NA, NA, NULL); addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -8954,7 +9084,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_RARE, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_RARE, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_RARE, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4+3"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -8988,7 +9118,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+3"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 20, NA, NA, NULL); addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); @@ -9016,7 +9146,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_RARE, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "6d4+5"); + addflag(lastrace->flags, F_HITDICE, 6, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, -20, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -9046,7 +9176,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_RARE, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "13d4"); + addflag(lastrace->flags, F_HITDICE, 13, NA, NA, NULL); addflag(lastrace->flags, F_TR, 11, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 12, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, -20, NA, NA, NULL); @@ -9082,7 +9212,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "15d4"); + addflag(lastrace->flags, F_HITDICE, 15, NA, NA, NULL); addflag(lastrace->flags, F_TR, 12, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 13, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, -20, NA, NA, NULL); @@ -9122,7 +9252,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_RARE, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "15d4"); + addflag(lastrace->flags, F_HITDICE, 15, NA, NA, NULL); addflag(lastrace->flags, F_TR, 13, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 12, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, -20, NA, NA, NULL); @@ -9159,7 +9289,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_VERYRARE, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_ENORMOUS, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "17d4"); + addflag(lastrace->flags, F_HITDICE, 17, NA, NA, NULL); addflag(lastrace->flags, F_TR, 14, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 20, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, -30, NA, NA, NULL); @@ -9208,7 +9338,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_ENHANCESMELL, 4, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 9, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); @@ -9245,7 +9375,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, 87, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, 87, RR_COMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4+3"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -9268,6 +9398,7 @@ void initrace(void) { addflag(lastrace->flags, F_NOCTURNAL, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_MORALE, 0, NA, NA, NULL); addflag(lastrace->flags, F_STARTJOB, 10, J_ROGUE, NA, NULL); + addflag(lastrace->flags, F_STARTJOB, 5, SJ_NECROMANCER, NA, NULL); addflag(lastrace->flags, F_STARTJOB, 5, J_DEMONOLOGIST, NA, NULL); addrace(R_GOBLINR, "froglin", 25, 'g', C_BLUE, MT_FLESH, RC_HUMANOID, "River goblins (more commonly known as 'froglins') are blueish goblins with sleek, leathery skin. They seems constantly wet, and can leap like a frog."); @@ -9281,7 +9412,7 @@ void initrace(void) { addflag(lastrace->flags, F_BREATHWATER, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_AQUATIC, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4+3"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 5, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); @@ -9320,7 +9451,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, 100, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, 80, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+3"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -9363,7 +9494,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, 75, NA, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, 75, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+5"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -9396,7 +9527,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, 70, NA, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, 70, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4+7"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -9431,7 +9562,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, 63, NA, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, 63, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4+6"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_SLOW, NA, NA, NULL); @@ -9465,7 +9596,7 @@ void initrace(void) { addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, 50, RR_VERYRARE, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+10"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -9496,7 +9627,7 @@ void initrace(void) { addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_ALL, NA, RR_RARE, NULL); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_BREATHWATER, B_TRUE, NA, NA, NULL); @@ -9527,7 +9658,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, 73, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, 73, RR_COMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4+3"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 8, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); @@ -9566,7 +9697,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, 60, NA, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, 60, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "7d4+3"); + addflag(lastrace->flags, F_HITDICE, 7, NA, NA, NULL); addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 10, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); @@ -9605,7 +9736,7 @@ void initrace(void) { addflag(lastrace->flags, F_POISONCORPSE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_NUMAPPEAR, 1, 3, NA, ""); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4"); + addflag(lastrace->flags, F_HITDICE, 1, NA, 4, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 5, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -9640,7 +9771,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, 78, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, 78, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SEWER, NA, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 10, NA, NA, NULL); @@ -9663,13 +9794,13 @@ void initrace(void) { addflag(lastrace->flags, F_MORALE, 2, NA, NA, NULL); addflag(lastrace->flags, F_CANEATRAW, B_TRUE, NA, NA, NULL); - addrace(R_LEPRECHAUN, "leprechaun", 35, 'n', C_GREEN, MT_FLESH, RC_HUMANOID, "Leprechauns are tiny Irish humans, with a love for gold and practical jokes. Known for their supernatural luck."); + addrace(R_LEPRECHAUN, "leprechaun", 35, 'n', C_BOLDGREEN, MT_FLESH, RC_HUMANOID, "Leprechauns are tiny Irish humans, with a love for gold and practical jokes. Known for their supernatural luck."); setbodytype(lastrace, BT_HUMANOID); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_RARE, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_STR, AT_AVERAGE, NA, NULL); @@ -9700,7 +9831,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, 72, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, 72, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "6d4"); + addflag(lastrace->flags, F_HITDICE, 6, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_STR, AT_HIGH, NA, NULL); @@ -9736,7 +9867,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_RARE, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_RARE, NULL); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 15, NA, NA, NULL); addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); @@ -9767,8 +9898,8 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_RARE, NULL); addflag(lastrace->flags, F_ENHANCESMELL, 5, NA, NA, NULL); addflag(lastrace->flags, F_HATESRACE, R_GNOLL, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "6d4+6"); - addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); + addflag(lastrace->flags, F_HITDICE, 6, NA, NA, NULL); + addflag(lastrace->flags, F_TR, 8, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 12, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_STAYINROOM, NA, NA, NA, NULL); // stay in our maze @@ -9801,7 +9932,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, 60, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, 66, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, 66, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+0"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, -5, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 11, NA, NA, NULL); @@ -9827,6 +9958,44 @@ void initrace(void) { addflag(lastrace->flags, F_CANEATRAW, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_STARTJOB, 20, J_WIZARD, SJ_RANDOM, NULL); + addrace(R_NAIAD, "naiad", 5, 'n', C_BLUE, MT_FLESH, RC_MAGIC, "A small, beautiful water spirit with webbed hands and feet."); + setbodytype(lastrace, BT_HUMANOID); + addflag(lastrace->flags, F_ALIGNMENT, AL_GOOD, NA, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_STR, AT_LOW, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_IQ, AT_GTAVERAGE, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_CHA, AT_HIGH, NA, NULL); + addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); + addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); + addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_FREQUENT, NULL); + addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); + addflag(lastrace->flags, F_AQUATIC, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_BREATHWATER, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_NEEDSWATER, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); + addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); + addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); + addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); + addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); + addflag(lastrace->flags, F_CANCAST, OT_S_CHARM, NA, NA, "pw:1;"); + addflag(lastrace->flags, F_CASTCHANCE, 60, NA, NA, NULL); + addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, B_APPENDYOU, "smiles sweetly"); + addflag(lastrace->flags, F_HASATTACK, OT_FISTS, 2, NA, NULL); + addflag(lastrace->flags, F_STARTOB, 50, NA, NA, "javelin"); + addflag(lastrace->flags, F_STARTOB, 50, NA, NA, "trident"); + addflag(lastrace->flags, F_STARTOB, 50, NA, NA, "throwing net"); + addflag(lastrace->flags, F_STARTOB, 25, NA, NA, "1-3 pearl"); + addflag(lastrace->flags, F_STARTOB, 25, NA, NA, "1-2 opal"); + addflag(lastrace->flags, F_STARTOB, 25, NA, NA, "potion of fishy lungs"); + addflag(lastrace->flags, F_STARTSKILL, SK_THROWING, PR_ADEPT, NA, NULL); + addflag(lastrace->flags, F_STARTSKILL, SK_PERCEPTION, PR_BEGINNER, NA, NULL); + addflag(lastrace->flags, F_HUMANOID, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_MORALE, 5, NA, NA, NULL); + addflag(lastrace->flags, F_CASTCHANCE, 30, NA, NA, NULL); + addflag(lastrace->flags, F_VEGETARIAN, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_RESISTMAG, 25, NA, NA, NULL); + addflag(lastrace->flags, F_DTVULN, DT_FIRE, NA, NA, NULL); + addrace(R_OGRA, "ogra", 160, 'O', C_BROWN, MT_FLESH, RC_HUMANOID, "Female ogres (known as 'ogras' are no less angry of hungry than the males of the species. They are however slightly faster and weaker."); setbodytype(lastrace, BT_HUMANOID); addflag(lastrace->flags, F_ALIGNMENT, AL_EVIL, NA, NA, NULL); @@ -9836,7 +10005,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, 60, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, 66, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, 66, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+0"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 8, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -9871,9 +10040,9 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, 45, NA, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, 50, NA, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, 50, RR_VERYRARE, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "12d4+0"); + addflag(lastrace->flags, F_HITDICE, 10, NA, NA, NULL); addflag(lastrace->flags, F_TR, 10, NA, NA, NULL); - addflag(lastrace->flags, F_ARMOURRATING, 11, NA, NA, NULL); + addflag(lastrace->flags, F_ARMOURRATING, 10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); addflag(lastrace->flags, F_HASATTACK, OT_FISTS, 16, NA, NULL); @@ -9906,7 +10075,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, 78, NA, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, 80, NA, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, 80, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4+3"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 5, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 5, NA, NA, NULL); @@ -9944,7 +10113,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, 100, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, 80, RR_RARE, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, 80, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+3"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 5, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 5, NA, NA, NULL); @@ -9979,7 +10148,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, 80, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, 100, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, 80, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+3"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 5, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 5, NA, NA, NULL); @@ -10004,7 +10173,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, 81, NA, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, 81, NA, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, 81, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4+3"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -10035,7 +10204,7 @@ void initrace(void) { addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_ALL, 80, RR_RARE, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "6d4+3"); + addflag(lastrace->flags, F_HITDICE, 6, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 5, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 5, NA, NA, NULL); @@ -10060,7 +10229,7 @@ void initrace(void) { addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_ALL, 80, RR_VERYRARE, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "7d4+3"); + addflag(lastrace->flags, F_HITDICE, 7, NA, NA, NULL); addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 5, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 8, NA, NA, NULL); @@ -10087,7 +10256,7 @@ void initrace(void) { addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_LEVITATING, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_CANCAST, OT_S_LEVITATION, NA, NA, NULL); @@ -10110,7 +10279,7 @@ void initrace(void) { addflag(lastrace->flags, F_NOSLEEP, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_EATCONFER, F_DTRESIST, DT_COLD, NA, "80"); - addrace(R_PEGASUS, "pegasus", 130, 'Q', C_GREY, MT_FLESH, RC_MAGIC, "A legendary white, winged horse."); + addrace(R_PEGASUS, "pegasus", 130, 'Q', C_WHITE, MT_FLESH, RC_MAGIC, "A legendary white, winged horse."); setbodytype(lastrace, BT_QUADRAPED); addflag(lastrace->flags, F_ALIGNMENT, AL_GOOD, NA, NA, NULL); addflag(lastrace->flags, F_CANTALK, B_TRUE, NA, NA, NULL); @@ -10126,7 +10295,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "6d4"); + addflag(lastrace->flags, F_HITDICE, 6, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_HOOF, 8, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_HOOF, 8, NA, NULL); @@ -10141,6 +10310,41 @@ void initrace(void) { addflag(lastrace->flags, F_ENHANCESMELL, 3, NA, NA, NULL); addflag(lastrace->flags, F_STARTSKILL, SK_PERCEPTION, PR_SKILLED, NA, NULL); + addrace(R_PIXIE, "pixie", 5, 'n', C_GREEN, MT_FLESH, RC_MAGIC, "A small magical woodland creature, flying around on moth-like wings."); + setbodytype(lastrace, BT_HUMANOID); + addbodypart(lastrace, BP_WINGS, NULL); + addflag(lastrace->flags, F_EXTRACORPSE, 15, NA, NA, "pile of prankster's dust"); + addflag(lastrace->flags, F_ALIGNMENT, AL_GOOD, NA, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_STR, AT_LOW, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_IQ, AT_GTAVERAGE, NA, NULL); + addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); + addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_FREQUENT, NULL); + addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); + addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); + addflag(lastrace->flags, F_EVASION, 20, NA, NA, NULL); + addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); + addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); + addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); + addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); + addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); + addflag(lastrace->flags, F_RNDSPELLCOUNT, 2, NA, NA, NULL); + addflag(lastrace->flags, F_RNDSPELLSCHOOL, SS_NATURE, 1, 2, "pw:2;"); + addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, B_APPENDYOU, "gestures"); + addflag(lastrace->flags, F_HASATTACK, OT_FISTS, 3, NA, NULL); + addflag(lastrace->flags, F_STARTOB, 100, NA, NA, "short bow"); + addflag(lastrace->flags, F_STARTOB, 100, NA, NA, "2-6 arrows"); + addflag(lastrace->flags, F_STARTOB, 60, NA, NA, "cap"); + addflag(lastrace->flags, F_STARTOB, 60, NA, NA, "leather shoes"); + addflag(lastrace->flags, F_STARTSKILL, SK_RANGED, PR_BEGINNER, NA, NULL); + addflag(lastrace->flags, F_STARTSKILL, SK_PERCEPTION, PR_ADEPT, NA, NULL); + addflag(lastrace->flags, F_HUMANOID, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_MORALE, 5, NA, NA, NULL); + addflag(lastrace->flags, F_CASTCHANCE, 30, NA, NA, NULL); + addflag(lastrace->flags, F_VEGETARIAN, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_RESISTMAG, 25, NA, NA, NULL); + addrace(R_POLTERGEIST, "poltergeist", 50, 'p', C_GREEN, MT_FLESH, RC_UNDEAD, "An evil ghostly spirit who telekinetically throws objects at its enemies."); // sPirit addbodypart(lastrace, BP_BODY, NULL); addflag(lastrace->flags, F_ALIGNMENT, AL_EVIL, NA, NA, NULL); @@ -10149,7 +10353,7 @@ void initrace(void) { addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, 75, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); @@ -10171,7 +10375,7 @@ void initrace(void) { addflag(lastrace->flags, F_INVISIBLE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_STAYINROOM, NA, NA, NA, NULL); - addrace(R_PRIMALFIRE, "fire primality", 50, 'E', C_RED, MT_FIRE, RC_HUMANOID, "A living mass of fire, animated by powerful magic."); + addrace(R_PRIMALFIRE, "fire primality", 50, 'E', C_RED, MT_FIRE, RC_MAGIC, "A living mass of fire, animated by powerful magic."); setbodytype(lastrace, BT_HUMANOID); addflag(lastrace->flags, F_ALIGNMENT, AL_NONE, NA, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_STR, AT_AVERAGE, NA, NULL); @@ -10182,7 +10386,7 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_CHA, AT_AVERAGE, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "6d4"); + addflag(lastrace->flags, F_HITDICE, 6, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_DTIMMUNE, DT_FIRE, NA, NA, NULL); addflag(lastrace->flags, F_DTVULN, DT_COLD, NA, NA, NULL); @@ -10191,17 +10395,18 @@ void initrace(void) { addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_AUTOCREATEOB, 0, NA, NA, "small fire"); addflag(lastrace->flags, F_FLAMESTRIKE, B_TRUE, NA, NA, NULL); - addflag(lastrace->flags, F_HASATTACK, OT_TOUCHBURN, 4, NA, NULL); - addflag(lastrace->flags, F_HUMANOID, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_TOUCHBURN, 6, NA, NULL); addflag(lastrace->flags, F_MORALE, 50, NA, NA, NULL); + addflag(lastrace->flags, F_CASTWITHOUTIQ, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_CANCAST, OT_S_PYROMANIA, NA, NA, "pw:1;"); + addflag(lastrace->flags, F_CANCAST, OT_S_FLAMEBURST, NA, NA, "pw:10;"); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, NA, "burns brightly"); addflag(lastrace->flags, F_CORPSETYPE, NA, NA, NA, "large fire"); addflag(lastrace->flags, F_UNSUMMONOB, NA, NA, NA, "large fire"); addflag(lastrace->flags, F_NOSLEEP, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_AWARENESS, B_TRUE, NA, NA, NULL); - addrace(R_PRIMALFIREL, "lesser fire primality", 30, 'E', C_RED, MT_FIRE, RC_HUMANOID, "A living mass of fire, animated by powerful magic."); + addrace(R_PRIMALFIREL, "lesser fire primality", 30, 'E', C_RED, MT_FIRE, RC_MAGIC, "A living mass of fire, animated by powerful magic."); setbodytype(lastrace, BT_HUMANOID); addflag(lastrace->flags, F_ALIGNMENT, AL_NONE, NA, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_STR, AT_AVERAGE, NA, NULL); @@ -10211,8 +10416,8 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_CON, AT_AVERAGE, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_CHA, AT_AVERAGE, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); - addflag(lastrace->flags, F_SIZE, SZ_LARGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4"); + addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_DTIMMUNE, DT_FIRE, NA, NA, NULL); addflag(lastrace->flags, F_DTVULN, DT_COLD, NA, NA, NULL); @@ -10222,8 +10427,8 @@ void initrace(void) { addflag(lastrace->flags, F_AUTOCREATEOB, 0, NA, NA, "small fire"); addflag(lastrace->flags, F_FLAMESTRIKE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TOUCHBURN, 2, NA, NULL); - addflag(lastrace->flags, F_HUMANOID, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_MORALE, 50, NA, NA, NULL); + addflag(lastrace->flags, F_CASTWITHOUTIQ, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_CANCAST, OT_S_PYROMANIA, NA, NA, "pw:1;"); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, NA, "burns brightly"); addflag(lastrace->flags, F_CORPSETYPE, NA, NA, NA, "medium fire"); @@ -10231,7 +10436,7 @@ void initrace(void) { addflag(lastrace->flags, F_NOSLEEP, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_AWARENESS, B_TRUE, NA, NA, NULL); - addrace(R_PRIMALSTONE, "stone primality", 200, 'E', C_GREY, MT_STONE, RC_HUMANOID, "A living mass of stone, animated by powerful magic."); + addrace(R_PRIMALSTONE, "rock primality", 200, 'E', C_GREY, MT_STONE, RC_MAGIC, "A living mass of stone, animated by powerful magic."); setbodytype(lastrace, BT_HUMANOID); addflag(lastrace->flags, F_ALIGNMENT, AL_NONE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, 72, RR_RARE, NULL); @@ -10243,7 +10448,7 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_CHA, AT_EXLOW, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "10d4"); + addflag(lastrace->flags, F_HITDICE, 10, NA, NA, NULL); addflag(lastrace->flags, F_TR, 10, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 14, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, -50, NA, NA, NULL); @@ -10257,7 +10462,7 @@ void initrace(void) { addflag(lastrace->flags, F_UNSUMMONOB, NA, NA, NA, "boulder"); addflag(lastrace->flags, F_NOSLEEP, B_TRUE, NA, NA, NULL); - addrace(R_PRIMALSTONEL, "lesser stone primality", 120, 'E', C_GREY, MT_STONE, RC_HUMANOID, "A living mass of stone, animated by powerful magic."); + addrace(R_PRIMALSTONEL, "lesser rock primality", 120, 'E', C_GREY, MT_STONE, RC_MAGIC, "A living mass of stone, animated by powerful magic."); setbodytype(lastrace, BT_HUMANOID); addflag(lastrace->flags, F_ALIGNMENT, AL_NONE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, 72, RR_RARE, NULL); @@ -10268,8 +10473,8 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_CON, AT_EXHIGH, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_CHA, AT_EXLOW, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); - addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4"); + addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 12, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, -50, NA, NA, NULL); @@ -10283,6 +10488,78 @@ void initrace(void) { addflag(lastrace->flags, F_UNSUMMONOB, NA, NA, NA, "boulder"); addflag(lastrace->flags, F_NOSLEEP, B_TRUE, NA, NA, NULL); + + + + addrace(R_PRIMALSTORM, "storm primality", 50, 'E', C_CYAN, MT_GAS, RC_MAGIC, "A living storm of seething winds and electricity, animated by powerful magic."); + setbodytype(lastrace, BT_HUMANOID); + addflag(lastrace->flags, F_ALIGNMENT, AL_NONE, NA, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_STR, AT_AVERAGE, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_AGI, AT_EXHIGH, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_WIS, AT_EXLOW, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_IQ, AT_EXLOW, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_CON, AT_AVERAGE, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_CHA, AT_AVERAGE, NA, NULL); + addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); + addflag(lastrace->flags, F_HITDICE, 6, NA, NA, NULL); + addflag(lastrace->flags, F_TR, 8, NA, NA, NULL); + addflag(lastrace->flags, F_DTIMMUNE, DT_ELECTRIC, NA, NA, NULL); + addflag(lastrace->flags, F_DTIMMUNE, DT_COLD, NA, NA, NULL); + addflag(lastrace->flags, F_DTIMMUNE, DT_PROJECTILE, NA, NA, NULL); + addflag(lastrace->flags, F_DTIMMUNE, DT_WATER, NA, NA, NULL); + addflag(lastrace->flags, F_MOVESPEED, SP_VERYFAST, NA, NA, NULL); + addflag(lastrace->flags, F_ACTIONSPEED, SP_VERYFAST, NA, NA, NULL); + addflag(lastrace->flags, F_SPELLSPEED, SP_NORMAL, NA, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_AIRFISTS, 5, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_ZAPPER, 5, NA, NULL); + addflag(lastrace->flags, F_MORALE, 50, NA, NA, NULL); + addflag(lastrace->flags, F_WINDSHIELD, 20, NA, NA, NULL); + addflag(lastrace->flags, F_CASTWITHOUTIQ, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_CANCAST, OT_S_CHAINLIGHTNING, NA, NA, "pw:2;"); + addflag(lastrace->flags, F_CANCAST, OT_S_HAILSTORM, 15, 15, "pw:4;"); + addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, NA, "whirls violently"); + addflag(lastrace->flags, F_CASTCHANCE, 40, NA, NA, NULL); + addflag(lastrace->flags, F_CORPSETYPE, NA, NA, NA, NULL); + addflag(lastrace->flags, F_UNSUMMONOB, NA, NA, NA, NULL); + addflag(lastrace->flags, F_NOSLEEP, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_AWARENESS, B_TRUE, NA, NA, NULL); + + addrace(R_PRIMALSTORML, "lesser storm primality", 50, 'E', C_CYAN, MT_GAS, RC_MAGIC, "A living storm of seething winds and electricity, animated by powerful magic."); + setbodytype(lastrace, BT_HUMANOID); + addflag(lastrace->flags, F_ALIGNMENT, AL_NONE, NA, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_STR, AT_AVERAGE, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_AGI, AT_EXHIGH, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_WIS, AT_EXLOW, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_IQ, AT_EXLOW, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_CON, AT_AVERAGE, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_CHA, AT_AVERAGE, NA, NULL); + addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); + addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); + addflag(lastrace->flags, F_DTIMMUNE, DT_ELECTRIC, NA, NA, NULL); + addflag(lastrace->flags, F_DTIMMUNE, DT_COLD, NA, NA, NULL); + addflag(lastrace->flags, F_DTIMMUNE, DT_PROJECTILE, NA, NA, NULL); + addflag(lastrace->flags, F_DTIMMUNE, DT_WATER, NA, NA, NULL); + addflag(lastrace->flags, F_MOVESPEED, SP_VERYFAST, NA, NA, NULL); + addflag(lastrace->flags, F_ACTIONSPEED, SP_VERYFAST, NA, NA, NULL); + addflag(lastrace->flags, F_SPELLSPEED, SP_NORMAL, NA, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_AIRFISTS, 2, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_ZAPPER, 2, NA, NULL); + addflag(lastrace->flags, F_MORALE, 50, NA, NA, NULL); + addflag(lastrace->flags, F_WINDSHIELD, 20, NA, NA, NULL); + addflag(lastrace->flags, F_CANCAST, OT_S_LIGHTNINGBOLT, NA, NA, "pw:2;"); + addflag(lastrace->flags, F_CANCAST, OT_S_SLEETSTORM, 15, 15, "pw:4;"); + addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, NA, "whirls violently"); + addflag(lastrace->flags, F_CASTWITHOUTIQ, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_CASTCHANCE, 40, NA, NA, NULL); + addflag(lastrace->flags, F_CORPSETYPE, NA, NA, NA, NULL); + addflag(lastrace->flags, F_UNSUMMONOB, NA, NA, NA, NULL); + addflag(lastrace->flags, F_NOSLEEP, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_AWARENESS, B_TRUE, NA, NA, NULL); + + addrace(R_SANDMAN, "sandman", 10, 'y', C_BROWN, MT_DIRT, RC_OTHER, "A whirling tornado of sand, with a humanoid figure dimly visible within."); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_BLOODOB, NA, NA, NA, "small dust cloud"); @@ -10293,7 +10570,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 10, NA, NA, NULL); addflag(lastrace->flags, F_NOPACK, B_TRUE, NA, NA, NULL); @@ -10315,7 +10592,7 @@ void initrace(void) { addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 6, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -10336,7 +10613,7 @@ void initrace(void) { addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "6d4"); + addflag(lastrace->flags, F_HITDICE, 6, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_STR, AT_GTAVERAGE, NA, NULL); @@ -10358,14 +10635,14 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, 72, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, 75, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, 72, RR_RARE, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_IQ, AT_HIGH, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_BUTT, 8, NA, NULL); addflag(lastrace->flags, F_STARTOBWEPSK, 50, SK_SHORTBLADES, NA, NULL); addflag(lastrace->flags, F_STARTOB, 100, NA, NA, "panpipes"); - addflag(lastrace->flags, F_STARTOB, 50, NA, NA, "bow"); + addflag(lastrace->flags, F_STARTOB, 50, NA, NA, "short bow"); addflag(lastrace->flags, F_STARTOB, 75, NA, NA, "1-10 arrows"); addflag(lastrace->flags, F_STARTOB, 50, NA, NA, "1-30 gold coins"); addflag(lastrace->flags, F_WANTSBETTERWEP, B_TRUE, NA, NA, NULL); @@ -10393,7 +10670,7 @@ void initrace(void) { addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, 65, NA, NULL); addflag(lastrace->flags, F_ENHANCESMELL, 5, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4+3"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 40, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -10419,7 +10696,7 @@ void initrace(void) { addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_SLOW, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -10446,7 +10723,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_FREQUENT, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_RARE, NULL); addflag(lastrace->flags, F_RARITY, H_SEWER, NA, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+0"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_VERYSLOW, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -10469,7 +10746,7 @@ void initrace(void) { addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_DTIMMUNE, DT_PROJECTILE, NA, NA, NULL); addflag(lastrace->flags, F_DTIMMUNE, DT_FALL, NA, NA, NULL); @@ -10490,8 +10767,9 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_IQ, AT_AVERAGE, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); + addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_FREQUENT, NULL); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 15, NA, NA, NULL); addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); @@ -10525,8 +10803,9 @@ void initrace(void) { addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); + addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_FREQUENT, NULL); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 15, NA, NA, NULL); addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); @@ -10557,8 +10836,9 @@ void initrace(void) { addflag(lastrace->flags, F_STARTATT, A_IQ, AT_AVERAGE, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); + addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_FREQUENT, NULL); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 15, NA, NA, NULL); addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); @@ -10595,7 +10875,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -10625,7 +10905,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4+0"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -10657,7 +10937,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "6d4+0"); + addflag(lastrace->flags, F_HITDICE, 6, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -10692,7 +10972,7 @@ void initrace(void) { addflag(lastrace->flags, F_SIZE, SZ_LARGE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4+0"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -10721,7 +11001,7 @@ void initrace(void) { addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+0"); + addflag(lastrace->flags, F_HITDICE, 1, NA, 4, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -10742,7 +11022,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_SEWER, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_LARGE, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 20, NA, NA, NULL); // very high armour - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4+4"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_VERYSLOW, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_VERYSLOW, NA, NA, ""); @@ -10759,7 +11039,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_RARE, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d3+4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, NULL); @@ -10789,7 +11069,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_SEWER, NA, RR_RARE, NULL); addflag(lastrace->flags, F_SIZE, SZ_LARGE, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 15, NA, NA, NULL); // high armour - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4+4"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_SLOW, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_SLOW, NA, NA, ""); @@ -10817,7 +11097,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_FREQUENT, NULL); addflag(lastrace->flags, F_RARITY, H_SEWER, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4"); + addflag(lastrace->flags, F_HITDICE, 1, NA, 2, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_FAST, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -10836,7 +11116,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SEWER, NA, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4+2"); + addflag(lastrace->flags, F_HITDICE, 1, NA, 6, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_FAST, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -10855,7 +11135,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_FREQUENT, NULL); addflag(lastrace->flags, F_RARITY, H_SEWER, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4+0"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -10875,7 +11155,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_FREQUENT, NULL); addflag(lastrace->flags, F_RARITY, H_SEWER, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4+0"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -10897,7 +11177,7 @@ void initrace(void) { addflag(lastrace->flags, F_DOESNTMOVE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_NOPRINTS, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_NOSPELLS, B_TRUE, NA, NA, NULL); @@ -10915,7 +11195,7 @@ void initrace(void) { addflag(lastrace->flags, F_DOESNTMOVE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_NOPRINTS, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_NOSPELLS, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_DTIMMUNE, DT_BASH, NA, NA, NULL); @@ -10933,7 +11213,7 @@ void initrace(void) { addflag(lastrace->flags, F_DOESNTMOVE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_NOPRINTS, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_NOSPELLS, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_DTIMMUNE, DT_BASH, NA, NA, NULL); @@ -10950,7 +11230,7 @@ void initrace(void) { addflag(lastrace->flags, F_DOESNTMOVE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_NOPRINTS, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_STARTOB, 50, NA, NA, "passionfruit"); addflag(lastrace->flags, F_RETALIATE, 1, 1, DT_PIERCE, "sharp spines"); @@ -10958,8 +11238,8 @@ void initrace(void) { addflag(lastrace->flags, F_NOSPELLS, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_TREMORSENSE, 10, NA, NA, NULL); addflag(lastrace->flags, F_DTIMMUNE, DT_BASH, NA, NA, NULL); - addflag(lastrace->flags, F_CANCAST, OT_S_CLONE, 0, 100, "pw:1;"); - addflag(lastrace->flags, F_CANCAST, OT_S_ENTANGLE, 50, 50, "pw:2; range:1;"); + addflag(lastrace->flags, F_CANWILL, OT_S_CLONE, 0, 100, "pw:1;"); + addflag(lastrace->flags, F_CANWILL, OT_S_ENTANGLE, 50, 50, "pw:2; range:1;"); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_CLONE, NA, NA, "expands"); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_ENTANGLE, NA, NA, "writhes"); @@ -10983,7 +11263,7 @@ void initrace(void) { addflag(lastrace->flags, F_DOESNTMOVE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_NOPRINTS, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_NOSPELLS, B_TRUE, NA, NA, NULL); @@ -10999,7 +11279,7 @@ void initrace(void) { addflag(lastrace->flags, F_DOESNTMOVE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_NOPRINTS, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 6, NA, NULL); addflag(lastrace->flags, F_MAXATTACKS, 1, 1, NA, NULL); @@ -11021,7 +11301,7 @@ void initrace(void) { addflag(lastrace->flags, F_DOESNTMOVE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_NOPRINTS, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_NOSPELLS, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_DTIMMUNE, DT_BASH, NA, NA, NULL); @@ -11041,7 +11321,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "0d4+2"); + addflag(lastrace->flags, F_HITDICE, 1, NA, 4, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 1, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 1, NA, NULL); @@ -11066,7 +11346,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+2"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 1, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 2, NA, NULL); @@ -11091,7 +11371,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4+4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 2, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 2, NA, NULL); @@ -11113,7 +11393,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); addflag(lastrace->flags, F_STARTASLEEPPCT, 80, NA, NA, NULL); // hibernating - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "6d4+3"); + addflag(lastrace->flags, F_HITDICE, 6, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -11142,7 +11422,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_LARGE, NA, NA, NULL); addflag(lastrace->flags, F_STARTASLEEPPCT, 80, NA, NA, NULL); // hibernating - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "7d4+12"); + addflag(lastrace->flags, F_HITDICE, 7, NA, NA, NULL); addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -11171,7 +11451,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4+4"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -11199,7 +11479,7 @@ void initrace(void) { addflag(lastrace->flags, F_NUMAPPEAR, 3, 4, NA, ""); addflag(lastrace->flags, F_ARMOURRATING, 4, NA, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_IQ, IQ_ANIMAL, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+3"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -11222,7 +11502,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_ARMOURRATING, 9, NA, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_IQ, IQ_ANIMAL, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4+4"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -11250,7 +11530,7 @@ void initrace(void) { addflag(lastrace->flags, F_ARMOURRATING, 4, NA, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_IQ, IQ_ANIMAL, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_AGI, AT_AVERAGE, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "6d4+6"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -11279,7 +11559,7 @@ void initrace(void) { addflag(lastrace->flags, F_ARMOURRATING, 6, NA, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_IQ, IQ_ANIMAL, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_AGI, AT_AVERAGE, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "10d4"); + addflag(lastrace->flags, F_HITDICE, 10, NA, NA, NULL); addflag(lastrace->flags, F_TR, 10, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -11306,7 +11586,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_RARE, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SEWER, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TONGUE, 3, NA, NULL); addflag(lastrace->flags, F_NOPACK, B_TRUE, NA, NA, NULL); @@ -11318,8 +11598,8 @@ void initrace(void) { addflag(lastrace->flags, F_NOISETEXT, N_FRUSTRATED, SV_SHOUT, NA, "croaks^croaking"); addflag(lastrace->flags, F_NOISETEXT, N_SPELLCAST, SV_SHOUT, NA, "gurgles loudly^a loud gurgling"); addflag(lastrace->flags, F_CANWILL, OT_A_JUMP, NA, NA, "stamcost:0;"); - addflag(lastrace->flags, F_CANCAST, OT_S_FLOOD, 20, 20, "pw:6;"); - addflag(lastrace->flags, F_CANCAST, OT_S_WATERJET, NA, NA, "pw:4;"); + addflag(lastrace->flags, F_CANWILL, OT_S_FLOOD, 20, 20, "pw:6;"); + addflag(lastrace->flags, F_CANWILL, OT_S_WATERJET, NA, NA, "pw:4;"); addflag(lastrace->flags, F_STARTSKILL, SK_SWIMMING, PR_MASTER, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, NA, NULL); addflag(lastrace->flags, F_AISPELLTARGETOVERRIDE, OT_S_FLOOD, ST_SELF, NA, NULL); @@ -11335,7 +11615,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_VILLAGE, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "0d4+1"); + addflag(lastrace->flags, F_HITDICE, 0, NA, 1, NULL); addflag(lastrace->flags, F_TR, 0, NA, NA, NULL); addflag(lastrace->flags, F_NOSPELLS, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_NOPACK, B_TRUE, NA, NA, NULL); @@ -11359,7 +11639,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_ENHANCESMELL, 6, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 3, NA, NULL); addflag(lastrace->flags, F_MAXATTACKS, 1, 2, NA, NULL); @@ -11389,7 +11669,7 @@ void initrace(void) { addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_ENHANCESMELL, 6, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4+3"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 6, NA, NULL); addflag(lastrace->flags, F_MAXATTACKS, 1, 1, NA, NULL); @@ -11418,7 +11698,7 @@ void initrace(void) { addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_FAST, NA, NA, ""); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4+1"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 10, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 10, NA, NULL); @@ -11449,7 +11729,7 @@ void initrace(void) { addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_FAST, NA, NA, ""); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+2"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 8, NA, NULL); addflag(lastrace->flags, F_MAXATTACKS, 1, 1, NA, NULL); @@ -11479,7 +11759,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SEWER, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4+4"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TONGUE, 6, NA, NULL); addflag(lastrace->flags, F_NOPACK, B_TRUE, NA, NA, NULL); @@ -11508,7 +11788,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+2"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 2, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 2, NA, NULL); @@ -11540,7 +11820,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4+3"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 3, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 3, NA, NULL); @@ -11570,7 +11850,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4+3"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 6, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 7, NA, NULL); @@ -11584,7 +11864,7 @@ void initrace(void) { addflag(lastrace->flags, F_MORALE, 8, NA, NA, NULL); addflag(lastrace->flags, F_AVIAN, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_CANEATRAW, B_TRUE, NA, NA, NULL); - addrace(R_HAWKFROST, "frost hawk", 1, 'A', C_CYAN, MT_FLESH, RC_ANIMAL, "A hark imbued with the power of ice. Frost hawks can release a powerufl blast of freezing air when threatened."); // 'A' for Avian + addrace(R_HAWKFROST, "frost hawk", 1, 'A', C_CYAN, MT_FLESH, RC_ANIMAL, "A hawk imbued with the power of ice. Frost hawks can release a powerufl blast of freezing air when threatened."); // 'A' for Avian setbodytype(lastrace, BT_BIRD); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); @@ -11596,7 +11876,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "8d4"); + addflag(lastrace->flags, F_HITDICE, 7, NA, NA, NULL); addflag(lastrace->flags, F_TR, 8, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 11, NA, NULL); addflag(lastrace->flags, F_EXTRADAM, DT_COLD, NA, NA, "1d6"); @@ -11605,7 +11885,7 @@ void initrace(void) { addflag(lastrace->flags, F_NOSPELLS, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_CANWILL, OT_A_SWOOP, NA, NA, NULL); addflag(lastrace->flags, F_SWOOPRANGE, 5, NA, NA, NULL); - addflag(lastrace->flags, F_CANCAST, OT_S_COLDBURST, 2, 2, "pw:2;"); + addflag(lastrace->flags, F_CANWILL, OT_S_COLDBURST, 2, 2, "pw:2;"); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, NA, "screeches"); addflag(lastrace->flags, F_MORALE, 10, NA, NA, NULL); addflag(lastrace->flags, F_SEEINDARK, B_TRUE, NA, NA, NULL); @@ -11614,7 +11894,37 @@ void initrace(void) { addflag(lastrace->flags, F_CANEATRAW, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_DTIMMUNE, DT_COLD, B_TRUE, NA, NULL); addflag(lastrace->flags, F_EATCONFER, F_DTRESIST, DT_COLD, NA, "20"); - addrace(R_GYRFALCON, "gyrfalcon", 1, 'A', C_WHITE, MT_FLESH, RC_ANIMAL, "An anormous falcon, commonly found in arctic climates."); // 'A' for Avian + + addrace(R_ELEPHANT, "elephant", 4000, 'Q', C_GREY, MT_LEATHER, RC_ANIMAL, "A massive grey mammal with a long trunk and sharp tusks."); + setbodytype(lastrace, BT_QUADRAPED); + addbodypart(lastrace, BP_TAIL, NULL); + addflag(lastrace->flags, F_EXTRACORPSE, 50, NA, NA, "ivory tusk"); + addflag(lastrace->flags, F_EXTRACORPSE, 50, NA, NA, "ivory tusk"); + addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_RARE, NULL); + addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_COMMON, NULL); + addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); + addflag(lastrace->flags, F_DIURNAL, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_HITDICE, 11, NA, NA, NULL); + addflag(lastrace->flags, F_TR, 11, NA, NA, NULL); + addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); + addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); + addflag(lastrace->flags, F_ENHANCESMELL, 5, NA, NA, NULL); + addflag(lastrace->flags, F_ARMOURRATING, 8, NA, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_BUTT, 12, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_TRAMPLE, 16, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_STR, AT_VHIGH, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_IQ, IQ_ANIMAL, NA, NULL); + addflag(lastrace->flags, F_VEGETARIAN, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_WANTSOBFLAG, F_EDIBLE, B_COVETS, NA, NULL); + addflag(lastrace->flags, F_NOISETEXT, N_GETANGRY, 4, NA, "trumpets loudly^a loud trumpeting"); + addflag(lastrace->flags, F_SEEINDARK, 3, NA, NA, NULL); + addflag(lastrace->flags, F_VISRANGEMOD, -2, NA, NA, NULL); + addflag(lastrace->flags, F_DTVULN, DT_SONIC, NA, NA, NULL); + addflag(lastrace->flags, F_MORALE, 5, NA, NA, NULL); + + + addrace(R_GYRFALCON, "gyrfalcon", 1, 'A', C_WHITE, MT_FLESH, RC_ANIMAL, "An enormous falcon, commonly found in arctic climates."); // 'A' for Avian setbodytype(lastrace, BT_BIRD); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); @@ -11626,7 +11936,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "10d4"); + addflag(lastrace->flags, F_HITDICE, 10, NA, NA, NULL); addflag(lastrace->flags, F_TR, 9, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 14, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); @@ -11654,7 +11964,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SEWER, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4+1"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 3, NA, NULL); addflag(lastrace->flags, F_NOPACK, B_TRUE, NA, NA, NULL); @@ -11672,6 +11982,36 @@ void initrace(void) { addflag(lastrace->flags, F_ENHANCESMELL, 5, NA, NA, NULL); addflag(lastrace->flags, F_WALKVERB, NA, NA, NA, "slither"); addflag(lastrace->flags, F_MORALE, 20, NA, NA, NULL); + + addrace(R_MAMMOTH, "mammoth", 6000, 'Q', C_BROWN, MT_LEATHER, RC_ANIMAL, "A massive ancenstor of the elephant, mammoths are covered with fur, slightly larger and more dangerous."); + setbodytype(lastrace, BT_QUADRAPED); + addbodypart(lastrace, BP_TAIL, NULL); + addflag(lastrace->flags, F_EXTRACORPSE, 50, NA, NA, "ivory tusk"); + addflag(lastrace->flags, F_EXTRACORPSE, 50, NA, NA, "ivory tusk"); + addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_VERYRARE, NULL); + addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_COMMON, NULL); + addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); + addflag(lastrace->flags, F_DIURNAL, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_HITDICE, 13, NA, NA, NULL); + addflag(lastrace->flags, F_TR, 12, NA, NA, NULL); + addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); + addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); + addflag(lastrace->flags, F_ENHANCESMELL, 5, NA, NA, NULL); + addflag(lastrace->flags, F_ARMOURRATING, 10, NA, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_BUTT, 14, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_TRAMPLE, 18, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_STR, AT_VHIGH, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_IQ, IQ_ANIMAL, NA, NULL); + addflag(lastrace->flags, F_VEGETARIAN, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_WANTSOBFLAG, F_EDIBLE, B_COVETS, NA, NULL); + addflag(lastrace->flags, F_NOISETEXT, N_GETANGRY, 4, NA, "trumpets loudly^a loud trumpeting"); + addflag(lastrace->flags, F_SEEINDARK, 3, NA, NA, NULL); + addflag(lastrace->flags, F_VISRANGEMOD, -2, NA, NA, NULL); + addflag(lastrace->flags, F_DTVULN, DT_SONIC, NA, NA, NULL); + addflag(lastrace->flags, F_DTVULN, DT_FIRE, NA, NA, NULL); + addflag(lastrace->flags, F_MORALE, 5, NA, NA, NULL); + addrace(R_NEWT, "giant newt", 4, ':', C_BROWN, MT_FLESH, RC_ANIMAL, "An abnormally large example of the lizard family."); setbodytype(lastrace, BT_QUADRAPED); addbodypart(lastrace, BP_TAIL, NULL); @@ -11679,7 +12019,7 @@ void initrace(void) { addflag(lastrace->flags, F_COLDBLOOD, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_IQ, IQ_ANIMAL, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+0"); + addflag(lastrace->flags, F_HITDICE, 1, NA, 4, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -11704,7 +12044,7 @@ void initrace(void) { addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4+1"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 4, NA, NULL); addflag(lastrace->flags, F_MAXATTACKS, 1, 1, NA, NULL); @@ -11725,7 +12065,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SEWER, NA, RR_FREQUENT, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "0d4+1"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 2, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 3, NA, NULL); @@ -11736,6 +12076,39 @@ void initrace(void) { addflag(lastrace->flags, F_DTVULN, DT_POISONGAS, NA, NA, NULL); addflag(lastrace->flags, F_MORALE, 5, NA, NA, NULL); addflag(lastrace->flags, F_CANEATRAW, B_TRUE, NA, NA, NULL); + + addrace(R_ROC, "roc", 1, 'A', C_MAGENTA, MT_FLESH, RC_ANIMAL, "Rocs are unbelievably gargantuan birds or prey, large enough to carry a fully-grown elephant. They are generally peaceful, but deadly once provoked."); // 'A' for Avian + setbodytype(lastrace, BT_BIRD); + addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_VERYRARE, NULL); + addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_VERYRARE, NULL); + addflag(lastrace->flags, F_STARTATT, A_IQ, IQ_ANIMAL, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_STR, AT_EXHIGH, NA, NULL); + addflag(lastrace->flags, F_SIZE, SZ_ENORMOUS, NA, NA, NULL); + addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); + addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); + addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); + addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); + addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); + addflag(lastrace->flags, F_HITDICE, 18, NA, NA, NULL); + addflag(lastrace->flags, F_TR, 15, NA, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 18, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 18, NA, NULL); + addflag(lastrace->flags, F_EVASION, 15, NA, NA, NULL); + addflag(lastrace->flags, F_NOPACK, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_NOSPELLS, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_CANWILL, OT_A_SWOOP, NA, NA, NULL); + addflag(lastrace->flags, F_SWOOPRANGE, 8, NA, NA, NULL); + addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, NA, "screeches"); + addflag(lastrace->flags, F_MORALE, 10, NA, NA, NULL); + addflag(lastrace->flags, F_SEEINDARK, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_NOISETEXT, N_LOWHP, 5, NA, "screeches in pain^screeches of pain"); + addflag(lastrace->flags, F_AVIAN, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_CANEATRAW, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_EATCONFER, F_CANWILL, OT_S_FLIGHT, NA, "90"); + addflag(lastrace->flags, F_WANTSOBFLAG, F_EDIBLE, NA, NA, NULL); + addflag(lastrace->flags, F_CARNIVORE, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_HATESRACE, R_DWARF, NA, NA, NULL); + addrace(R_SLUG, "acid slug", 150, 'P', C_GREY, MT_FLESH, RC_ANIMAL, "While acid slugs lack the protective shell of their snail cousings, their rubbery flesh is extremely resilient. Their acid-based attacks also make them much more dangerous."); addbodypart(lastrace, BP_BODY, NULL); addbodypart(lastrace, BP_HEAD, NULL); @@ -11750,7 +12123,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_FREQUENT, NULL); addflag(lastrace->flags, F_RARITY, H_SEWER, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "7d4+1"); + addflag(lastrace->flags, F_HITDICE, 7, NA, NA, NULL); addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 18, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_ACIDATTACK, 11, NA, NULL); @@ -11780,7 +12153,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_FREQUENT, NULL); addflag(lastrace->flags, F_RARITY, H_SEWER, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+1"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 18, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 8, NA, NULL); @@ -11804,7 +12177,7 @@ void initrace(void) { addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 4, NA, NULL); addflag(lastrace->flags, F_HITCONFER, F_POISONED, SC_POISON, 20, "5-10"); @@ -11831,7 +12204,7 @@ void initrace(void) { addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 4, NA, NULL); addflag(lastrace->flags, F_NOPACK, B_TRUE, NA, NA, NULL); @@ -11854,7 +12227,7 @@ void initrace(void) { addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 5, NA, NULL); addflag(lastrace->flags, F_NOPACK, B_TRUE, NA, NA, NULL); @@ -11879,7 +12252,7 @@ void initrace(void) { addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 4, NA, NULL); addflag(lastrace->flags, F_NOPACK, B_TRUE, NA, NA, NULL); @@ -11888,7 +12261,7 @@ void initrace(void) { addflag(lastrace->flags, F_WALKVERB, NA, NA, NA, "slither"); addflag(lastrace->flags, F_NOISETEXT, N_WALK, 1, NA, "^slithering"); addflag(lastrace->flags, F_NOISETEXT, N_GETANGRY, 2, NA, "hisses^hissing"); - addflag(lastrace->flags, F_CANCAST, OT_S_POISONBOLT, 4, 4, "pw:3;"); + addflag(lastrace->flags, F_CANWILL, OT_S_POISONBOLT, 4, 4, "pw:3;"); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, B_APPENDYOU, "spits"); addflag(lastrace->flags, F_DEAF, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_DTIMMUNE, DT_POISON, NA, NA, NULL); @@ -11906,7 +12279,7 @@ void initrace(void) { addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4+2"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 4, NA, NULL); addflag(lastrace->flags, F_NOPACK, B_TRUE, NA, NA, NULL); @@ -11919,7 +12292,7 @@ void initrace(void) { addflag(lastrace->flags, F_CASTTYPE, CT_EYESPIT, NA, NA, NULL); addflag(lastrace->flags, F_DEAF, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_DTIMMUNE, DT_POISON, NA, NA, NULL); - addflag(lastrace->flags, F_CANCAST, OT_S_BLINDNESS, 4, 4, "pw:3;range:2;"); + addflag(lastrace->flags, F_CANWILL, OT_S_BLINDNESS, 4, 4, "pw:3;range:2;"); addflag(lastrace->flags, F_TREMORSENSE, 10, NA, NA, NULL); addflag(lastrace->flags, F_DIURNAL, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_NOFLEE, B_TRUE, NA, NA, NULL); @@ -11935,7 +12308,7 @@ void initrace(void) { addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+3"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 1, NA, NULL); addflag(lastrace->flags, F_NOPACK, B_TRUE, NA, NA, NULL); @@ -11965,7 +12338,7 @@ void initrace(void) { addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 5, NA, NULL); addflag(lastrace->flags, F_NOPACK, B_TRUE, NA, NA, NULL); @@ -11988,7 +12361,7 @@ void initrace(void) { addflag(lastrace->flags, F_NOSMELL, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+1"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 4, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, NA, NULL); // don't announce spellcasting @@ -12017,7 +12390,7 @@ void initrace(void) { addflag(lastrace->flags, F_NOSMELL, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SPIDERCLIMB, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4+1"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 4, NA, NULL); addflag(lastrace->flags, F_HITCONFER, F_POISONED, SC_POISON, 26, "10-20"); @@ -12048,7 +12421,7 @@ void initrace(void) { addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); addflag(lastrace->flags, F_SPIDERCLIMB, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4+1"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 4, NA, NULL); addflag(lastrace->flags, F_HITCONFER, F_PAIN, SC_POISON, 26, "5-15"); @@ -12077,7 +12450,7 @@ void initrace(void) { addflag(lastrace->flags, F_NOSMELL, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "6d4+2"); + addflag(lastrace->flags, F_HITDICE, 6, NA, NA, NULL); addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 7, NA, NULL); addflag(lastrace->flags, F_VAMPIRIC, B_TRUE, NA, NA, NULL); @@ -12107,7 +12480,7 @@ void initrace(void) { addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_RARE, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+2"); + addflag(lastrace->flags, F_HITDICE, 1, NA, 6, NULL); addflag(lastrace->flags, F_TR, 0, NA, NA, NULL); addflag(lastrace->flags, F_NOSPELLS, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_NOPACK, B_TRUE, NA, NA, NULL); @@ -12131,7 +12504,7 @@ void initrace(void) { addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); addflag(lastrace->flags, F_ENHANCESMELL, 5, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4+2"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 3, NA, NULL); addflag(lastrace->flags, F_MAXATTACKS, 1, 1, NA, NULL); @@ -12159,7 +12532,7 @@ void initrace(void) { addflag(lastrace->flags, F_MOVESPEED, SP_FAST, NA, NA, ""); addflag(lastrace->flags, F_ENHANCESMELL, 6, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+4"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 5, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 5, NA, NULL); @@ -12188,7 +12561,7 @@ void initrace(void) { addflag(lastrace->flags, F_MOVESPEED, SP_FAST, NA, NA, ""); addflag(lastrace->flags, F_ENHANCESMELL, 6, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4+2"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 3, NA, NULL); addflag(lastrace->flags, F_EXTRADAM, DT_COLD, NA, NA, "1d6"); @@ -12206,13 +12579,47 @@ void initrace(void) { addflag(lastrace->flags, F_FLEEONHPPCT, 50, NA, NA, ""); addflag(lastrace->flags, F_HASSKILL, SK_SWIMMING, PR_BEGINNER, NA, NULL); addflag(lastrace->flags, F_MORALE, 11, NA, NA, NULL); - addflag(lastrace->flags, F_CANCAST, OT_S_COLDRAY, 10, 10, "pw:2;"); + addflag(lastrace->flags, F_CANWILL, OT_S_COLDRAY, 10, 10, "pw:2;"); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, NA, "unleashes its icy breath"); addflag(lastrace->flags, F_CANINE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_CANEATRAW, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_FATALFOOD, OT_CHOCOLATE, NA, NA, NULL); addflag(lastrace->flags, F_EATCONFER, F_DTRESIST, DT_COLD, NA, "25"); + addrace(R_CRYSTALCUR, "crystal cur", 60, 'd', C_WHITE, MT_CRYSTAL, RC_ANIMAL, "Crystal Curs are magical hounds, imbued with magical defenses by over-protective owners."); + setbodytype(lastrace, BT_QUADRAPED); + addbodypart(lastrace, BP_TAIL, NULL); + addflag(lastrace->flags, F_ALIGNMENT, AL_GOOD, NA, NA, NULL); + addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_CORPSETYPE, NA, NA, NA, "random gem"); + addflag(lastrace->flags, F_EXTRACORPSE, 80, NA, NA, "random gem"); + addflag(lastrace->flags, F_EXTRACORPSE, 50, NA, NA, "random gem"); + addflag(lastrace->flags, F_EXTRACORPSE, 25, NA, NA, "random gem"); + addflag(lastrace->flags, F_STARTATT, A_CON, AT_VHIGH, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_IQ, IQ_ANIMAL, NA, NULL); + addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); + addflag(lastrace->flags, F_MOVESPEED, SP_FAST, NA, NA, ""); + addflag(lastrace->flags, F_ENHANCESMELL, 6, NA, NA, NULL); + addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_RARE, NULL); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); + addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); + addflag(lastrace->flags, F_MAXATTACKS, 1, 1, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_CLAWS, 6, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 6, NA, NULL); + addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); + addflag(lastrace->flags, F_NOSPELLS, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_CARNIVORE, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_WANTSOBFLAG, F_EDIBLE, B_COVETS, NA, NULL); + addflag(lastrace->flags, F_SEEINDARK, 5, NA, NA, NULL); + addflag(lastrace->flags, F_CANWILL, OT_A_SPRINT, NA, NA, NULL); + addflag(lastrace->flags, F_NOISETEXT, N_LOWHP, 2, NA, "whines in pain^whining"); + addflag(lastrace->flags, F_NOISETEXT, N_FRUSTRATED, 3, NA, "growls^growling"); + addflag(lastrace->flags, F_FLEEONHPPCT, 50, NA, NA, ""); + addflag(lastrace->flags, F_HASSKILL, SK_SWIMMING, PR_BEGINNER, NA, NULL); + addflag(lastrace->flags, F_MORALE, 11, NA, NA, NULL); + addflag(lastrace->flags, F_CANINE, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_CANEATRAW, B_TRUE, NA, NA, NULL); + addrace(R_WORMGLUT, "glutwyrm", 25, 'W', C_MAGENTA, MT_FLESH, RC_DRAGON, "Gigantic wyrms who have become so obese over the centuries that they have evolved without wings. They swallow their prey whole, slowly digesting their still living bodies."); addbodypart(lastrace, BP_HEAD, NULL); addbodypart(lastrace, BP_TAIL, NULL); @@ -12226,7 +12633,7 @@ void initrace(void) { addflag(lastrace->flags, F_TREMORSENSE, 2, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_VERYRARE, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_RARE, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "10d4"); + addflag(lastrace->flags, F_HITDICE, 10, NA, NA, NULL); addflag(lastrace->flags, F_TR, 9, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); //addflag(lastrace->flags, F_WANTSOBFLAG, F_RARITY, NA, NA, NULL); // ie. everything @@ -12252,7 +12659,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "10d5"); + addflag(lastrace->flags, F_HITDICE, 10, NA, NA, NULL); addflag(lastrace->flags, F_TR, 10, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 12, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -12285,7 +12692,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "28d4"); + addflag(lastrace->flags, F_HITDICE, 28, NA, NA, NULL); addflag(lastrace->flags, F_TR, 16, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 18, NA, NA, NULL); addflag(lastrace->flags, F_AQUATIC, B_TRUE, NA, NA, NULL); @@ -12336,7 +12743,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "13d4"); + addflag(lastrace->flags, F_HITDICE, 13, NA, NA, NULL); addflag(lastrace->flags, F_TR, 10, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 12, NA, NA, NULL); addflag(lastrace->flags, F_AQUATIC, B_TRUE, NA, NA, NULL); @@ -12387,7 +12794,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "40d4"); + addflag(lastrace->flags, F_HITDICE, 40, NA, NA, NULL); addflag(lastrace->flags, F_TR, 19, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 24, NA, NA, NULL); addflag(lastrace->flags, F_AQUATIC, B_TRUE, NA, NA, NULL); @@ -12446,7 +12853,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "30d4"); + addflag(lastrace->flags, F_HITDICE, 30, NA, NA, NULL); addflag(lastrace->flags, F_TR, 17, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 18, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -12497,7 +12904,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "15d4"); + addflag(lastrace->flags, F_HITDICE, 15, NA, NA, NULL); addflag(lastrace->flags, F_TR, 10, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 12, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -12544,7 +12951,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "45d4"); + addflag(lastrace->flags, F_HITDICE, 45, NA, NA, NULL); addflag(lastrace->flags, F_TR, 20, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 24, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -12598,7 +13005,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "22d4"); + addflag(lastrace->flags, F_HITDICE, 22, NA, NA, NULL); addflag(lastrace->flags, F_TR, 15, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -12648,7 +13055,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "10d4+5"); + addflag(lastrace->flags, F_HITDICE, 10, NA, NA, NULL); addflag(lastrace->flags, F_TR, 10, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 7, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -12693,7 +13100,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "32d4"); + addflag(lastrace->flags, F_HITDICE, 32, NA, NA, NULL); addflag(lastrace->flags, F_TR, 18, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 16, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -12745,7 +13152,7 @@ void initrace(void) { addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_RARE, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4+0"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -12756,7 +13163,7 @@ void initrace(void) { addflag(lastrace->flags, F_CORPSEFLAG, F_EXPLODEONDEATH, NA, 2, "32d2"); addflag(lastrace->flags, F_MORALE, 5, NA, NA, NULL); addflag(lastrace->flags, F_WANTS, OT_STONE, B_COVETS, NA, NULL); - addflag(lastrace->flags, F_CANCAST, OT_S_DETONATEDELAY, 20, 20, "pw:1;range:3;"); + addflag(lastrace->flags, F_CANWILL, OT_S_DETONATEDELAY, 20, 20, "pw:1;range:3;"); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, NA, "vibrates"); addrace(R_BUTTERFLY, "butterfly", 0.01, 'i', C_YELLOW, MT_FLESH, RC_INSECT, "A harmless, colourful butterfly."); @@ -12770,7 +13177,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "0d4+1"); + addflag(lastrace->flags, F_HITDICE, 0, NA, 1, NULL); addflag(lastrace->flags, F_TR, 0, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 60, NA, NA, NULL); addflag(lastrace->flags, F_NOPACK, B_TRUE, NA, NA, NULL); @@ -12795,7 +13202,7 @@ void initrace(void) { addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d1+0"); + addflag(lastrace->flags, F_HITDICE, 0, NA, 1, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 10, NA, NA, NULL); addflag(lastrace->flags, F_ENHANCESMELL, 5, NA, NA, NULL); @@ -12826,7 +13233,7 @@ void initrace(void) { addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+3"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 5, NA, NA, NULL); addflag(lastrace->flags, F_ENHANCESMELL, 5, NA, NA, NULL); @@ -12854,7 +13261,7 @@ void initrace(void) { addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+1"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_ENHANCESMELL, 2, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 1, NA, NULL); @@ -12885,7 +13292,7 @@ void initrace(void) { addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 6, NA, NULL); addflag(lastrace->flags, F_HITCONFER, F_POISONED, SC_POISON, 25, "10-15"); @@ -12903,7 +13310,7 @@ void initrace(void) { addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -12929,11 +13336,11 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+0"); + addflag(lastrace->flags, F_HITDICE, 1, NA, 4, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 60, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_ZAPPER, 1, NA, NULL); - addflag(lastrace->flags, F_CANCAST, OT_S_FLASH, 15, 15, "pw:4;"); + addflag(lastrace->flags, F_CANWILL, OT_S_FLASH, 15, 15, "pw:4;"); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_NONE, NA, NA, "pulses"); addflag(lastrace->flags, F_NOPACK, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_NOSPELLS, B_TRUE, NA, NA, NULL); @@ -12956,7 +13363,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+0"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 10, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 1, NA, NULL); @@ -12978,9 +13385,10 @@ void initrace(void) { addbodypart(lastrace, BP_WINGS, NULL); addflag(lastrace->flags, F_ALIGNMENT, AL_EVIL, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_HEAVEN, NA, RR_COMMON, NULL); + addflag(lastrace->flags, F_RARITY, H_ALL, NA, RR_RARE, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+9"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 18, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -13006,9 +13414,10 @@ void initrace(void) { addbodypart(lastrace, BP_WINGS, NULL); addflag(lastrace->flags, F_ALIGNMENT, AL_EVIL, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_HEAVEN, NA, RR_COMMON, NULL); + addflag(lastrace->flags, F_RARITY, H_ALL, NA, RR_RARE, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 8, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -13032,9 +13441,10 @@ void initrace(void) { addbodypart(lastrace, BP_WINGS, NULL); addflag(lastrace->flags, F_ALIGNMENT, AL_EVIL, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_HEAVEN, NA, RR_COMMON, NULL); + addflag(lastrace->flags, F_RARITY, H_ALL, NA, RR_RARE, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "6d4"); + addflag(lastrace->flags, F_HITDICE, 6, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 12, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -13058,9 +13468,8 @@ void initrace(void) { addflag(lastrace->flags, F_NOCORPSE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_LARGE, NA, NA, NULL); - addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_RARE, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4+0"); + addflag(lastrace->flags, F_RARITY, H_ALL, NA, RR_VERYRARE, NULL); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_SLOW, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -13072,15 +13481,33 @@ void initrace(void) { addflag(lastrace->flags, F_MORALE, 30, NA, NA, NULL); addflag(lastrace->flags, F_DEAF, B_TRUE, NA, NA, NULL); - addrace(R_NECRONREAPER, "necron reaper", 65, 'N', C_RED, MT_FLESH, RC_DEMON, "An evil demonic creature, covered in spikes and the bright red blood of its victims."); + addrace(R_LINGPARASITE, "ling parasite", 2, 'x', C_GREEN, MT_FLESH, RC_DEMON, "A tiny demonic parasite resembling a centipede. Harmless in their normal form, they can become much more dangerous by crawling inside a corpse and re-animating it."); + setbodytype(lastrace, BT_QUADRAPED); + addbodypart(lastrace, BP_TAIL, NULL); + addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_SIZE, SZ_TINY, NA, NA, NULL); + addflag(lastrace->flags, F_RARITY, H_ALL, NA, RR_RARE, NULL); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); + addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); + addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); + addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); + addflag(lastrace->flags, F_STARTATT, A_IQ, AT_GTAVERAGE, NA, NULL); + addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 2, NA, NULL); + addflag(lastrace->flags, F_NOISETEXT, N_GETANGRY, 3, NA, "screeches^a screech"); + addflag(lastrace->flags, F_MORALE, 5, NA, NA, NULL); + addflag(lastrace->flags, F_CANEATRAW, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_WANTSOBFLAG, F_EDIBLE, B_COVETS, NA, NULL); + + addrace(R_LINGREAPER, "ling reaper", 65, 'N', C_RED, MT_FLESH, RC_DEMON, "An evil demonic creature, covered in spikes and the bright red blood of its victims."); setbodytype(lastrace, BT_HUMANOID); addbodypart(lastrace, BP_TAIL, NULL); addbodypart(lastrace, BP_WINGS, NULL); + addflag(lastrace->flags, F_RARITY, H_ALL, NA, RR_VERYRARE, NULL); addflag(lastrace->flags, F_ALIGNMENT, AL_EVIL, NA, NA, NULL); addflag(lastrace->flags, F_RETALIATE, 1, 4, DT_PIERCE, "razor-sharp spikes"); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "6d4"); + addflag(lastrace->flags, F_HITDICE, 6, NA, NA, NULL); addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); addflag(lastrace->flags, F_REGENERATES, 1, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 4, NA, NA, NULL); @@ -13099,15 +13526,16 @@ void initrace(void) { addflag(lastrace->flags, F_STARTOB, 100, NA, NA, "scythe"); addflag(lastrace->flags, F_NOISETEXT, N_GETANGRY, 2, NA, "screechs^an other-wordly screech"); - addrace(R_NECRONTRAPPER, "necron trapper", 65, 'N', C_BLUE, MT_FLESH, RC_DEMON, "A wiry, muscled humanoid whose blue-black flesh seems to writhe and pulse. Its elongatd jaw holds razor-sharp fangs which drip with saliva."); + addrace(R_LINGTRAPPER, "ling trapper", 65, 'N', C_BLUE, MT_FLESH, RC_DEMON, "A wiry, muscled humanoid whose blue-black flesh seems to writhe and pulse. Its elongatd jaw holds razor-sharp fangs which drip with saliva."); setbodytype(lastrace, BT_HUMANOID); addbodypart(lastrace, BP_TAIL, NULL); addbodypart(lastrace, BP_WINGS, NULL); + addflag(lastrace->flags, F_RARITY, H_ALL, NA, RR_VERYRARE, NULL); addflag(lastrace->flags, F_ALIGNMENT, AL_EVIL, NA, NA, NULL); addflag(lastrace->flags, F_STARTHIDDENPCT, 70, NA, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_REGENERATES, 1, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 6, NA, NA, NULL); @@ -13131,10 +13559,11 @@ void initrace(void) { addbodypart(lastrace, BP_TAIL, NULL); addbodypart(lastrace, BP_WINGS, NULL); addflag(lastrace->flags, F_RARITY, H_HEAVEN, NA, RR_COMMON, NULL); + addflag(lastrace->flags, F_RARITY, H_ALL, NA, RR_RARE, NULL); addflag(lastrace->flags, F_ALIGNMENT, AL_EVIL, NA, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d8"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); addflag(lastrace->flags, F_REGENERATES, 2, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 18, NA, NA, NULL); @@ -13170,7 +13599,7 @@ void initrace(void) { addflag(lastrace->flags, F_NUMAPPEAR, 1, 3, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+3"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 5, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, -10, NA, NA, NULL); @@ -13213,7 +13642,7 @@ void initrace(void) { addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 3, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, -10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_SLOW, NA, NA, NULL); @@ -13249,7 +13678,7 @@ void initrace(void) { addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "3d4"); + addflag(lastrace->flags, F_HITDICE, 3, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, -10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_SLOW, NA, NA, NULL); @@ -13263,6 +13692,31 @@ void initrace(void) { addflag(lastrace->flags, F_DEAF, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_MORALE, 30, NA, NA, NULL); + addrace(R_SKELLION, "skellion", 10, 'r', C_RED, MT_BONE, RC_UNDEAD, "A floating skull, immersed in flames. Skellions are often created when attempting to animate a beheaded corpse."); + addbodypart(lastrace, BP_HEAD, NULL); + addflag(lastrace->flags, F_CORPSETYPE, NA, NA, NA, "skull"); + addflag(lastrace->flags, F_BLOODOB, NA, NA, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_STR, AT_AVERAGE, NA, NULL); + addflag(lastrace->flags, F_STARTATT, A_IQ, AT_AVERAGE, NA, NULL); + addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); + addflag(lastrace->flags, F_SIZE, SZ_SMALL, NA, NA, NULL); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); + addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); + addflag(lastrace->flags, F_LEVITATING, B_TRUE, NA, NA, NULL); + addflag(lastrace->flags, F_CANCAST, OT_S_LEVITATION, NA, NA, NULL); + addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_LEVITATION, NA, NA, NULL); + addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); + addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); + addflag(lastrace->flags, F_NOISETEXT, N_SONICBOLT, 4, NA, "screams!^an otherworld scream!"); + addflag(lastrace->flags, F_CANWILL, OT_A_SONICBOLT, 3, 3, "pw:4;dam:1d7;"); + addflag(lastrace->flags, F_HASATTACK, OT_TEETH, 2, NA, NULL); + addflag(lastrace->flags, F_EXTRADAM, DT_FIRE, NA, NA, "1d4"); + addflag(lastrace->flags, F_DTRESIST, DT_SLASH, NA, NA, NULL); + addflag(lastrace->flags, F_MORALE, 20, NA, NA, NULL); + addflag(lastrace->flags, F_CASTCHANCE, 30, NA, NA, NULL); + addflag(lastrace->flags, F_NOSLEEP, B_TRUE, NA, NA, NULL); + addrace(R_WRAITHICE, "ice wraith", 20, 'Z', C_CYAN, MT_ICE, RC_UNDEAD, "Ice wraiths look like frozen humanoid forms, often garbed in threadbare clothing."); setbodytype(lastrace, BT_HUMANOID); addflag(lastrace->flags, F_ALIGNMENT, AL_EVIL, NA, NA, NULL); @@ -13272,7 +13726,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_FOREST, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_UNCOMMON, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+4"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 4, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -13302,7 +13756,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_RARITY, H_CAVE, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "6d4+2"); + addflag(lastrace->flags, F_HITDICE, 6, NA, NA, NULL); addflag(lastrace->flags, F_TR, 6, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_SLOW, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -13331,7 +13785,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_RARE, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); addflag(lastrace->flags, F_HASATTACK, OT_TOUCHCHILL, 4, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "5d4+2"); + addflag(lastrace->flags, F_HITDICE, 5, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_SLOW, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -13363,7 +13817,7 @@ void initrace(void) { addflag(lastrace->flags, F_RARITY, H_SWAMP, NA, RR_COMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); addflag(lastrace->flags, F_STENCH, 3, 1, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "4d4+2"); + addflag(lastrace->flags, F_HITDICE, 4, NA, NA, NULL); addflag(lastrace->flags, F_TR, 5, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, -10, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_SLOW, NA, NA, NULL); @@ -13388,7 +13842,7 @@ void initrace(void) { addflag(lastrace->flags, F_BLOODOB, NA, NA, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "11d4"); + addflag(lastrace->flags, F_HITDICE, 11, NA, NA, NULL); addflag(lastrace->flags, F_TR, 11, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, NULL); @@ -13419,7 +13873,7 @@ void initrace(void) { addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "6d4+3"); + addflag(lastrace->flags, F_HITDICE, 6, NA, NA, NULL); addflag(lastrace->flags, F_TR, 7, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_SLOW, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, ""); @@ -13446,7 +13900,7 @@ void initrace(void) { addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_RARITY, H_DUNGEON, NA, RR_UNCOMMON, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "8d4+7"); + addflag(lastrace->flags, F_HITDICE, 8, NA, NA, NULL); addflag(lastrace->flags, F_TR, 9, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_SLOW, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, "pw:8;"); @@ -13480,7 +13934,7 @@ void initrace(void) { addflag(lastrace->flags, F_BLOODOB, NA, NA, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUMAN, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "8d4"); + addflag(lastrace->flags, F_HITDICE, 8, NA, NA, NULL); addflag(lastrace->flags, F_TR, 8, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 5, NA, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_NORMAL, NA, NA, NULL); @@ -13521,7 +13975,7 @@ void initrace(void) { addflag(lastrace->flags, F_AVOIDOBTYPE, OT_GARLIC, B_TRUE, NA, NULL); addflag(lastrace->flags, F_MOVESPEED, SP_FAST, NA, NA, NULL); addflag(lastrace->flags, F_ACTIONSPEED, SP_NORMAL, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "8d4+3"); + addflag(lastrace->flags, F_HITDICE, 8, NA, NA, NULL); addflag(lastrace->flags, F_TR, 9, NA, NA, NULL); addflag(lastrace->flags, F_ARMOURRATING, 5, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, -10, NA, NA, NULL); @@ -13555,7 +14009,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4+1"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 300, NA, NA, NULL); addflag(lastrace->flags, F_NOATTACK, B_TRUE, NA, NA, NULL); @@ -13582,7 +14036,7 @@ void initrace(void) { addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_HATESALL, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_HUGE, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "10d4"); + addflag(lastrace->flags, F_HITDICE, 10, NA, NA, NULL); addflag(lastrace->flags, F_TR, 10, NA, NA, NULL); addflag(lastrace->flags, F_DOESNTMOVE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_NOPRINTS, B_TRUE, NA, NA, NULL); @@ -13602,7 +14056,7 @@ void initrace(void) { addflag(lastrace->flags, F_NATURALFLIGHT, B_TRUE, NA, NA, ""); addflag(lastrace->flags, F_CANWILL, OT_S_FLIGHT, NA, NA, NULL); addflag(lastrace->flags, F_SPELLCASTTEXT, OT_S_FLIGHT, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 8, NA, NA, NULL); addflag(lastrace->flags, F_EVASION, 50, NA, NA, NULL); addflag(lastrace->flags, F_BLOODOB, NA, NA, NA, NULL); @@ -13620,7 +14074,7 @@ void initrace(void) { addflag(lastrace->flags, F_SIZE, SZ_MEDIUM, NA, NA, NULL); addflag(lastrace->flags, F_STARTATT, A_IQ, IQ_MINDLESS, NA, NULL); addflag(lastrace->flags, F_LEVITATING, B_TRUE, NA, NA, ""); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "1d4"); + addflag(lastrace->flags, F_HITDICE, 1, NA, NA, NULL); addflag(lastrace->flags, F_TR, 1, NA, NA, NULL); addflag(lastrace->flags, F_BLOODOB, NA, NA, NA, NULL); addflag(lastrace->flags, F_FOLLOWRANGE, 1, 1, NA, NULL); // stay right next to master @@ -13645,7 +14099,7 @@ void initrace(void) { addflag(lastrace->flags, F_BLOODOB, NA, NA, NA, NULL); addflag(lastrace->flags, F_HOSTILE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_SIZE, SZ_ENORMOUS, NA, NA, NULL); - addflag(lastrace->flags, F_HITDICE, NA, NA, NA, "2d4"); + addflag(lastrace->flags, F_HITDICE, 2, NA, NA, NULL); addflag(lastrace->flags, F_TR, 2, NA, NA, NULL); addflag(lastrace->flags, F_DOESNTMOVE, B_TRUE, NA, NA, NULL); addflag(lastrace->flags, F_NOPRINTS, B_TRUE, NA, NA, NULL); @@ -13711,10 +14165,15 @@ void initrace(void) { addflag(r->flags, F_BREATHWATER, B_TRUE, NA, NA, NULL); addflag(r->flags, F_DTVULN, DT_ELECTRIC, NA, NA, NULL); addflag(r->flags, F_DTVULN, DT_WATER, NA, NA, NULL); - addflag(r->flags, F_NOISETEXT, N_GETANGRY, 3, NA, "beeps^a beep"); addflag(r->flags, F_CORPSETYPE, NA, NA, NA, "unstable power core"); addflag(r->flags, F_MORALE, 40, NA, NA, NULL); addflag(r->flags, F_SEEINDARK, B_TRUE, NA, NA, NULL); + if (!hasflagval(r->flags, F_NOISETEXT, N_WALK, NA, NA, NULL)) { + addflag(r->flags, F_NOISETEXT, N_WALK, 2, NA, "^whirring"); + } + if (!hasflagval(r->flags, F_NOISETEXT, N_GETANGRY, NA, NA, NULL)) { + addflag(r->flags, F_NOISETEXT, N_GETANGRY, 3, NA, "beeps^a beep"); + } // will probably also be immune to fire/cold because they are metal diff --git a/data/hiscores.db b/data/hiscores.db index 1888a7113ec61dbe84ca4208d04228c037344b07..a689b20eea682cfcab83a7cbfd68d9d3fea2df50 100644 GIT binary patch delta 579 zcmX9)OK4L;6rH&@X+AICHa|_&XR}dElbT|1BZwG9Y*ldKDq@?25)5sUMrpe!d0A)# zLECE;LKl8ew>8ghq_(0W^+PLyU5H?niU@*s5f{zIdC$4bxo6I~+&eRsLZxs$X#c|g zuQrkRqg|gc^qE<30madQU-3Qu!5_GaoA?G_;)1%}Fo%6crAOG3avuLOqavt5u?aLO zDaM?FSd^ohD7ICZu;LKQ@ETxCH2Q|GMVm#O!&#ict2mBj>NJnijCpG(jG_bY^BOkA zyb8R7XSfUrJOy`Q0tZAaPZl3j&C&{Y8Ib{7)sTaZUS0X12(%=qpKO4_8p69pt65oWqkb^p`pczl&C48#Nwq8yF`yN`fr)l1Co2HyY zbj5v~4z%~sulDhfU3(#4XM7!e&X86W+m01kpOx@VkVwuJk4j}4BUg?n8cf^ue-^$qF&V* zZ}NbZZ7_(z7`#9?rm(@+_zixDZA=zFN++t(HU=HBq9I7dpvRxgXVc}CZn;AyhZZ3xq%?4%2)@jlJq7CMB3G}G5SCc=hgrzMUUvbm@N#xyNP zUc~end04!-W1L8)eijcIF?cDeLNhtzbg^i_RKFf}u>{CqkO7mhfD`zQ3aFnRt&| z{w2Bj8MV>l7njY7j!v)vF=TTYv742mwYUOP#ofYOqvTuATCo+J;%Bl`T+17@)#}9tN19Dj6y6eaHz+P_ zVr6K}tAtr`(`*-$&SY^ksl-IntdpU&UP`lj*peVn&=Htv{tXv+#Z+skWy-rF3RO$(KZN+ zp{(^Hah*|bhV#q-=@Gqcd5wcHGaF@ceS~~C24R?h&*(rOj^QubCwSpQ(NmZmF% 1. val[0] = min, val[1] = max F_MINIONS, // val0 % chance of appearing with v1-v2 lf of type text - F_HITDICE, // text = xdy+z to roll for maxhp per level. - // if v0 is set, this overrides text as maxhp. + F_HITDICE, // v0 = number of hitdice to roll per level + // v1 = +xxx + // v2 = hitdie sides, if NA, use HITDIESIDES F_TR, // v0 = threat rating of this race. F_MAXHPMOD, // maxhp = pctof(v0, maxhp) F_MPDICE, // val0: # d4 to roll for maxmp per level. val1: +xx @@ -3115,7 +3148,8 @@ enum FLAG { F_NOINJURIES, // this race cannot sustain injuries. F_NOATTACK, // this lf can't attack F_NOPACK, // this race cannot hold objects - F_NOSPELLS, // this race cannot cast spells + F_NOSPELLS, // this race cannot cast spells (except for ones + // with FROMRACE) F_NOPRINTS, // this race doesn't leave footprints F_INDUCEFEAR, // causes fear when you attack it F_POISONCORPSE, // lf's corpse will be poisonous @@ -3164,6 +3198,7 @@ enum FLAG { F_CAFFEINATED, // can't sleep. F_CANEATRAW, // lf can eat raw food with no issues F_CANCAST, // can cast the spell val0 (need MP) + F_CASTWITHOUTIQ, // can cast spells even eith low iq. F_CANHEARLF, // you can hear lifeform id v0 (show their glyph) // this flag does not get announced. F_LOWHPABIL, // will automatically use the ability v0 when diff --git a/doc/add_eatconfer.txt b/doc/add_eatconfer.txt new file mode 100644 index 0000000..ab18e6a --- /dev/null +++ b/doc/add_eatconfer.txt @@ -0,0 +1,6 @@ +data.c: + add the f_eatconfer flag to the race. + +lf.c: + in eat(), specify what happens when you eat the corpse but + already have this flag. diff --git a/doc/glyphs.txt b/doc/glyphs.txt index 0a71517..99bc9c2 100644 --- a/doc/glyphs.txt +++ b/doc/glyphs.txt @@ -6,11 +6,12 @@ UNI_SOLID = deep water ^ = trap / dangerous thing ) = weapon ------------------------------------------------ -A = avian / bird a = ant +A = avian / bird +b = small roBot B = bat c = cockatrice / chicken / small bird - C = celestial / divine ? +C = celestial / divine ? d = canine/dog D = ? e = eye or floating thing @@ -29,7 +30,7 @@ L = lich, or other powerful undead ? m = mutant / magic creature M = mummy n = small humanoid / nymph / sprite -N = necron +N = ling / alieN creature o = orc O = monstrous humanoid (ie. ogre) P = gastropod @@ -40,7 +41,9 @@ r = rodent R = robot s = snake S = spider +t = troll T = walkingtree-like monster (dryad, treant) +u = ? make this be horse? if so, change pegasus. U = unearthly/horrific creature v = ? V = vampire @@ -48,7 +51,7 @@ w = small wyrm W = large wyrm x = small creature/monster X = unknown thing! -y/Y = air related creatures like clouds of gas, air elemental +y/Y = air/dust related creatures like clouds of gas, air elemental, sandman z = lizard-like creature Z = undead ; = fish diff --git a/flag.c b/flag.c index 2515d3a..e7b4947 100644 --- a/flag.c +++ b/flag.c @@ -1383,6 +1383,20 @@ void timeeffectsflag(flag_t *f, int howlong) { } } +int flagtomaxhp(flag_t *f) { + int hp; + int nsides = HITDIESIDES; + if (f->val[2] > 0) { + nsides = f->val[2]; + } + hp = f->val[0] * nsides; + + if (f->val[1] > 0) { + hp += f->val[1]; + } + return hp; +} + cell_t *getflagpilelocation(flagpile_t *fp) { cell_t *where = NULL; // everyone who can see this cell recalcs their los diff --git a/flag.h b/flag.h index f7ce40a..9ef5edb 100644 --- a/flag.h +++ b/flag.h @@ -23,6 +23,7 @@ int flagcausesloscalc(enum FLAG fid); int flagcausesredraw(lifeform_t *lf, enum FLAG fid); int flagcausesstatredraw(lifeform_t *lf, enum FLAG fid); int flagstacks(enum FLAG fid); +int flagtomaxhp(flag_t *f); cell_t *getflagpilelocation(flagpile_t *fp); int getflags(flagpile_t *fp, flag_t **retflag, int *nretflags, ... ); flag_t *hasflag(flagpile_t *fp, int id); diff --git a/io.c b/io.c index ab936de..efac290 100644 --- a/io.c +++ b/io.c @@ -5589,9 +5589,20 @@ char *makedesc_ob(object_t *o, char *retbuf) { if (isknown(o)) { // weapons? if (isfirearm(o)) { - flag_t *ff, *ff2; - sprintf(buf, "It is a %s firearm.\n", hasflag(o->flags, F_TWOHANDED) ? "two-handed" : "single handed"); + flag_t *ff, *ff2,*twohandf; + twohandf = hasflag(o->flags, F_TWOHANDED); + + sprintf(buf, "It is a %s firearm.\n", twohandf ? "two-handed" : "single handed"); strncat(retbuf, buf, HUGEBUFLEN); + + if ((twohandf->val[0] > 0) && (twohandf->val[0] < SZ_ENORMOUS)) { + char sizebuf[BUFLEN]; + sprintf(sizebuf, "%s", getsizetext(twohandf->val[0] + 1)); + capitalise(sizebuf); + sprintf(buf2, "@%s creatures can weild it in one hand.\n", sizebuf); + strncat(retbuf, buf2, HUGEBUFLEN); + } + f = hasflag(o->flags, F_ACCURACY); if (f) { int acc,accnum; @@ -5645,12 +5656,15 @@ char *makedesc_ob(object_t *o, char *retbuf) { sprintf(buf, "@It takes %d turn%s to reload.\n", ff2->val[0], (ff2->val[0] == 1) ? "" : "s"); strncat(retbuf, buf, HUGEBUFLEN); } else if (isweapon(o) && isknown(o)) { - flag_t *damflag; + flag_t *damflag,*twohandf; int delay; int critchance; + + twohandf = hasflag(o->flags, F_TWOHANDED); + snprintf(buf, BUFLEN, "%s %s weapon", (o->type->obclass->id == OC_WEAPON) ? "It is a" : "It can be used as a", - hasflag(o->flags, F_TWOHANDED) ? "two-handed" : "single handed"); + twohandf ? "two-handed" : "single handed"); damflag = hasflag(o->flags, F_DAM); if (damflag) { //int bonus = 0; @@ -5688,6 +5702,13 @@ char *makedesc_ob(object_t *o, char *retbuf) { strcat(buf, buf2); //dicetotext(f->val[0], f->val[1], f->val[2], NULL, NULL, dicebuf, NULL); + if ((twohandf->val[0] > 0) && (twohandf->val[0] < SZ_ENORMOUS)) { + char sizebuf[BUFLEN]; + sprintf(sizebuf, "%s", getsizetext(twohandf->val[0] + 1)); + capitalise(sizebuf); + sprintf(buf2, "@%s creatures can weild it in one hand.\n", sizebuf); + strcat(buf, buf2 ); + } sprintf(buf2, "@It has a base Damage Rating of %d",dr); strcat(buf, buf2); diff --git a/lf.c b/lf.c index a52d4ff..3f9ac03 100644 --- a/lf.c +++ b/lf.c @@ -358,7 +358,7 @@ int calcxp(lifeform_t *lf) { // -- hitdice f = lfhasflag(lf, F_HITDICE); if (f) { - maxhdroll = roll(f->text); + maxhdroll = flagtomaxhp(f); } else { maxhdroll = 4; } @@ -634,17 +634,21 @@ int cancast(lifeform_t *lf, enum OBTYPE oid, int *mpcost) { } else if ((f = lfhasflagval(lf, F_CANCAST, oid, NA, NA, NULL)) != NULL) { int cost,power; - // override! + // can only cast innate racial spels? if ((ot->obclass->id == OC_SPELL) && lfhasflag(lf, F_NOSPELLS)) { - reason = E_NOSPELLS; - return B_FALSE; + if (f->lifetime != FROMRACE) { + reason = E_NOSPELLS; + return B_FALSE; + } } // need >animal intelligence to cast spells if (ot->obclass->id == OC_SPELL) { if (getattrbracket(getattr(lf, A_IQ), A_IQ, NULL) <= IQ_ANIMAL) { - reason = E_LOWIQ; - return B_FALSE; + if (!lfhasflag(lf, F_CASTWITHOUTIQ)) { + reason = E_LOWIQ; + return B_FALSE; + } } } @@ -1441,7 +1445,7 @@ int canweild(lifeform_t *lf, object_t *o) { flag_t *retflag[MAXCANDIDATES]; int nretflags; - weildloc = getweildloc(o, &otherloc, NULL); + weildloc = getweildloc(o, lf, &otherloc, NULL); // already weilding it? if (o && isequipped(o)) { @@ -1501,7 +1505,7 @@ int canweild(lifeform_t *lf, object_t *o) { if (o) { int i; - getflags(o->flags, retflag, &nretflags, F_ATTREQ, F_TWOHANDED, F_NONE); + getflags(o->flags, retflag, &nretflags, F_ATTREQ, F_NONE); for (i = 0; i < nretflags; i++) { f = retflag[i]; if (f->id == F_ATTREQ) { @@ -1509,18 +1513,20 @@ int canweild(lifeform_t *lf, object_t *o) { if (!meetsattreq(lf, f, o, NULL)) { return B_FALSE; } - } else if (f->id == F_TWOHANDED) { + } + + } + if (istwohandedfor(o, lf)) { + if (getlfsize(lf) <= f->val[0]) { // need both hands free... if (!hasbp(lf, otherloc)) { reason = E_NOHANDS; return B_FALSE; } } - } } - reason = E_OK; // trying to fight unarmed, but no unarmed attack? @@ -1881,7 +1887,10 @@ int castspell(lifeform_t *lf, enum OBTYPE sid, lifeform_t *targlf, object_t *tar } // cast the spell. does it take time? - f = hasflag(sp->flags, F_CASTINGTIME); + f = hasflag(sp->flags, F_CASTINGTIME) ; + if (!f) { + f = lfhasflagval(lf, F_SPELLCASTTIME, NA, sp->id, NA, NULL); + } if (f && !fromob) { int castingtime; char tempbuf[BUFLEN]; @@ -2250,6 +2259,7 @@ int checkfordrowning(lifeform_t *lf, object_t *o) { addflag(lf->flags, F_NODEATHANNOUNCE, B_TRUE, NA, NA, NULL); lf->hp = 0; getobnametruebase(o, obname, o->amt); + lf->lastdamtype = DT_DIRECT; setlastdam(lf, obname); setkillverb(lf, "Drowned"); } else { @@ -2943,7 +2953,7 @@ void die(lifeform_t *lf) { awardxpfor(lf,100); if ((getalignment(lf) == AL_EVIL) || isundead(lf)) { pleasegodmaybe(R_GODPURITY, 5); - pleasegodmaybe(R_GODLIFE, 10); + if (isundead(lf)) pleasegodmaybe(R_GODLIFE, 10); } else if (getalignment(lf) == AL_GOOD) { pleasegodmaybe(R_GODDEATH, 5); } else { // ie. neutral @@ -3415,12 +3425,9 @@ void dumpmonsters(void) { int thishd; thishd = gettrrace(r); if (thishd == wanthd) { - int ndice,nsides,bonus,min,max; + int max; f = hasflag(r->flags, F_HITDICE); - texttodice(f->text ? f->text : DEF_HITDICE, &ndice,&nsides,&bonus); - - min = ndice + bonus; - max = (ndice*nsides) + bonus; + max = flagtomaxhp(f); dblog("\t%s (%d hp)",r->name, max); } } @@ -3940,13 +3947,29 @@ int eat(lifeform_t *lf, object_t *o) { getobname(o, obname, 1); getlfname(lf, lfname); - // is this a corpse? cf = hasflag(o->flags, F_CORPSEOF); if (cf) { corpserace = findrace(cf->val[0]); + // special case + if (lf->race->id == R_LINGPARASITE) { + if (isplayer(lf)) { + msg("You crawl inside %s.", obname); + } else if (cansee(player, lf)) { + msg("%s crawls inside %s.", lfname, obname); + } + // die, but animate the zombie! + addflag(lf->flags, F_NOCORPSE, B_TRUE, NA, NA, NULL); + addflag(lf->flags, F_NODEATHANNOUNCE, B_TRUE, NA, NA, NULL); + setlastdam(lf, "merging with a corpse"); + lf->lastdamtype = DT_DIRECT; + lf->hp = 0; + makezombie(o); + return B_FALSE; + } } + // get total nutrition nutrition = getnutrition(o); @@ -5854,6 +5877,7 @@ void gainxp(lifeform_t *lf, long amt) { amtneeded = getspforpoint(lf); assert(amtneeded > 0); + // would you gain more than 5 levels? probably a bug! if (((lf->skillxp + amt) / amtneeded) >= 3) { raise(SIGINT); } @@ -7068,11 +7092,6 @@ int gethearingrange(lifeform_t *lf) { int gettrrace(race_t *r) { flag_t *f; f = hasflag(r->flags, F_TR); - /* - int ndice,nsides,bonus; - texttodice(f->text ? f->text : DEF_HITDICE, &ndice,&nsides,&bonus); - return ((ndice*nsides)+bonus) / 4; - */ return f->val[0]; } @@ -7727,7 +7746,6 @@ int getnoisedetails(lifeform_t *lf, enum NOISETYPE nid, flag_t *noiseflag, return B_FALSE; } } else if (nid == N_SONICBOLT) { - if (volume) *volume = 5; if (heartext) strcpy(heartext, "a ear-splitting burst of sound!"); if (seetext) strcpy(seetext, "emits an ear-splitting burst of sound!"); @@ -10597,6 +10615,11 @@ void givestartobs(lifeform_t *lf, object_t *targob, flagpile_t *fp) { // give one extra rank of skill in this weapon sk = getobskill(o->flags); giveskill(lf, sk->id); + + // warriors get another rank + if (hasjob(lf, J_WARRIOR)) { + giveskill(lf, sk->id); + } } } } // end if lf && selectweapon @@ -11095,7 +11118,9 @@ int injure(lifeform_t *lf, enum BODYPART where, enum DAMTYPE damtype) { } else if (cansee(player, lf)) { msg("^%c%s%s heart is pierced!", getlfcol(lf, CC_VBAD), lfname, getpossessive(lfname)); } - if (lf->hp > 0) lf->hp = 0; + if (lf->hp > 0) { + lf->hp = 0; + } } else { inj = IJ_CHESTBLEED; desc = strdup("chest is bleeding^damage from enemies is increased"); break; } @@ -12171,11 +12196,12 @@ int isfreebp(lifeform_t *lf, enum BODYPART bp) { // check for 2handed weapons in other hand too if (bp == BP_WEAPON) otherbp = BP_SECWEAPON; else otherbp = BP_WEAPON; - o = hasobwithflagval(lf->pack, F_EQUIPPED, otherbp, NA, NA, NULL); - if (o && hasflag(o->flags, F_TWOHANDED)) { - return B_FALSE; + if (o) { + if (istwohandedfor(o, lf)) { + return B_FALSE; + } } } return B_TRUE; @@ -12910,6 +12936,9 @@ object_t *addtrail(lifeform_t *lf, cell_t *where, int dir, int doprints, int dos if (lfhasflag(lf, F_NOPRINTS)) { doprints = B_FALSE; } + if (getraceclass(lf) == RC_ROBOT) { + doscents = B_FALSE; + } // footprints first if (doprints) { @@ -13132,9 +13161,15 @@ lifeform_t *makezombie(object_t *o) { lf = addlf(where, r->id, 1); addflag(lf->flags, F_LFSUFFIX, B_TRUE, NA, NA, "zombie"); - addflag(lf->flags, F_GLYPH, C_GREY, 'Z', NA, NULL); + killflagsofid(lf->flags, F_GLYPH); + addflag(lf->flags, F_GLYPH, C_BLUE, 'Z', NA, NULL); addflag(lf->flags, F_UNDEAD, B_TRUE, NA, NA, NULL); + killflagsofid(lf->flags, F_CORPSETYPE); + killflagsofid(lf->flags, F_EXTRACORPSE); addflag(lf->flags, F_NOCORPSE, B_TRUE, NA, NA, NULL); + killflagsofid(lf->flags, F_DTIMMUNE); + killflagsofid(lf->flags, F_DTVULN); + killflagsofid(lf->flags, F_DTRESIST); addflag(lf->flags, F_DTIMMUNE, DT_COLD, NA, NA, NULL); addflag(lf->flags, F_DTIMMUNE, DT_POISONGAS, NA, NA, NULL); addflag(lf->flags, F_DTIMMUNE, DT_DECAY, NA, NA, NULL); @@ -13152,6 +13187,9 @@ lifeform_t *makezombie(object_t *o) { addflag(lf->flags, F_HEADLESS, B_TRUE, NA, NA, NULL); } + killflagsofid(lf->flags, F_XPVAL); + addflag(lf->flags, F_XPVAL, 0, NA, NA, NULL); + killflagsofid(lf->flags, F_WANTSBETTERWEP); killflagsofid(lf->flags, F_WANTSBETTERARM); killflagsofid(lf->flags, F_WANTSOBFLAG); @@ -13166,6 +13204,9 @@ lifeform_t *makezombie(object_t *o) { addflag(lf->flags, F_ACTIONSPEED, SP_SLOW, NA, NA, NULL); lf->baseatt[A_IQ] = rollattr(IQ_MINDLESS); lf->att[A_IQ] = lf->baseatt[A_IQ]; + + + killflagsofid(lf->flags, F_REVIVETIMER); // no magic lf->maxmp = 0; @@ -14297,6 +14338,8 @@ int losehp_real(lifeform_t *lf, int amt, enum DAMTYPE damtype, lifeform_t *froml f->val[0] -= amt; // they die when their FAKE hp drops below 0 if (f->val[0] <= 0) { + setlastdam(lf, "disappation"); + lf->lastdamtype = DT_DIRECT; lf->hp = 0; } } else { @@ -14415,7 +14458,7 @@ void losehpeffects(lifeform_t *lf, int dam, enum DAMTYPE damtype, lifeform_t *fr } } } - if (fromlf) { + if (fromlf && isplayer(fromlf)) { angergodmaybe(R_GODFIRE, 25, GA_HERESY); } } else if (damtype == DT_FIRE) { @@ -18258,6 +18301,7 @@ void startlfturn(lifeform_t *lf) { killflagsofid(lf->flags, F_JUSTENTERED); killflagsofid(lf->flags, F_UNSEENATTACKER); killflagsofid(lf->flags, F_DONELISTEN); + killflagsofid(lf->flags, F_DONEBURNMSG); killflagsofid(lf->flags, F_NOSWAP); movedlastturn = 0; movedlastturn += killflagsofid(lf->flags, F_HASBEENMOVED); @@ -19296,7 +19340,6 @@ void startlfturn(lifeform_t *lf) { f->val[1]--; if (f->val[1] <= 0) { resizelf(lf, f->val[0]); - killflag(f); continue; } } @@ -20401,7 +20444,7 @@ void unsummon(lifeform_t *lf, int vanishobs) { addflag(lf->flags, F_NOCORPSE, B_TRUE, NA, NA, NULL); f = lfhasflag(lf, F_UNSUMMONOB); - if (f) { + if (f && strlen(f->text)) { strcpy(unsummonob, f->text); } else { strcpy(unsummonob, "puff of smoke"); @@ -20940,6 +20983,14 @@ int validateraces(void) { goterror = B_TRUE; } + + if (hasflag(r->flags, F_CANCAST) && !hasflag(r->flags, F_CASTWITHOUTIQ)) { + if (getattr(lf, A_IQ) <= IQ_ANIMAL) { + printf("ERROR in race '%s' - has F_CANCAST but iq is too low. might need f_castwithoutiq?\n", r->name); + goterror = B_TRUE; + } + } + for (f = r->flags->first ; f ; f = f->next) { if (f->id == F_RNDSPELLCOUNT) { if (!hasflag(r->flags, F_RNDSPELLSCHOOL) && !hasflag(r->flags, F_RNDSPELLPOSS)) { @@ -21094,11 +21145,14 @@ int resizelf(lifeform_t *lf, enum LFSIZE newsize) { object_t *o,*nexto; getlfname(lf, lfname); + killflagsofid(lf->flags, F_SIZETIMER); + f = hasflag(lf->race->flags, F_SIZE); if (f) { racesize = f->val[0]; } + origsize = getlfsize(lf); if (origsize == newsize) { @@ -21136,9 +21190,9 @@ int resizelf(lifeform_t *lf, enum LFSIZE newsize) { for (o = lf->pack->first ; o ; o = nexto) { nexto = o->next; - // object is now the wrong size? - if (isequipped(o) && isarmour(o)) { - if (!armourfits(lf, o, NULL)) { + if (isequipped(o)) { + // object is now the wrong size? + if (isarmour(o) && !armourfits(lf, o, NULL)) { char obname[BUFLEN]; getobname(o, obname, o->amt); if (isplayer(lf)) { @@ -21150,12 +21204,47 @@ int resizelf(lifeform_t *lf, enum LFSIZE newsize) { unequipeffects(lf, o); if (isplayer(lf)) statdirty = B_TRUE; // might have impacted AR } + + if (isweapon(o)) { + flag_t *f; + // wasn't twohanded before, but is now? + if (istwohandedfor(o, lf)) { + f = hasflag(o->flags, F_TWOHANDED); + if ((f->val[0] > 0) && (origsize > f->val[0])) { + if (isplayer(lf)) { + char obname[BUFLEN]; + getobname(o, obname, o->amt); + msg("Your %s %s now too heavy to weild in one hand!", noprefix(obname), + (o->amt == 1) ? "is" : "are"); + } + // just drop it - this avoids complication if you have something in your + // other hand. + drop(o, o->amt); + continue; + } + } else { + // was twohanded before, but isn't now? + f = hasflag(o->flags, F_TWOHANDED); + if ((f->val[0] < 0) || (origsize <= f->val[0])) { + flag_t *f2; + if (isplayer(lf)) { + char obname[BUFLEN]; + getobname(o, obname, o->amt); + msg("You can now weild your %s in one hand!", noprefix(obname)); + } + f2 = hasflagval(o->flags, F_EQUIPPED, BP_SECWEAPON, NA, NA, NULL); + if (f2) killflag(f2); + } + } + } } // object is now too big to hold? - if (canpickup(lf, o, o->amt) == E_TOOBIG) { - drop(o, o->amt); - continue; + if (!canpickup(lf, o, o->amt)) { + if (reason == E_TOOBIG) { + drop(o, o->amt); + continue; + } } } @@ -21877,7 +21966,7 @@ int weild(lifeform_t *lf, object_t *o) { } // anything else weilded? - weildloc = getweildloc(o, &otherloc, &twohanded); + weildloc = getweildloc(o, lf, &otherloc, &twohanded); // firearm in regular hand? // note: this is the same logic as in canweild() @@ -21903,7 +21992,7 @@ int weild(lifeform_t *lf, object_t *o) { // ask if we want to use our other hand. if (!twohanded && hasbp(lf, otherloc)) { oo = getequippedob(lf->pack, weildloc); - if (getskill(lf, SK_TWOWEAPON) && oo && !hasflag(oo->flags, F_TWOHANDED)) { + if (getskill(lf, SK_TWOWEAPON) && oo && !istwohandedfor(oo, lf)) { char ch; if (isplayer(lf)) { char buf2[BUFLEN]; @@ -22047,7 +22136,7 @@ int weild(lifeform_t *lf, object_t *o) { // now weild this addflag(o->flags, F_EQUIPPED, weildloc, -1, -1, NULL); - if (hasflag(o->flags, F_TWOHANDED)) { + if (istwohandedfor(o, lf)) { addflag(o->flags, F_EQUIPPED, otherloc, -1, -1, NULL); } diff --git a/map.c b/map.c index 445ea5b..72c1356 100644 --- a/map.c +++ b/map.c @@ -48,6 +48,8 @@ extern enum GAMEMODE gamemode; extern int needredraw; extern int noredraw; +extern int notime; + extern long curtime; cell_t *addcell(map_t *m, int x, int y) { @@ -218,7 +220,7 @@ lifeform_t *addmonster(cell_t *c, enum RACE rid, char *racename, int randomjobok if (nadded) *nadded = 0; - //if (gamemode == GM_GAMESTARTED) checkallflags(player->cell->map); // debugging + /*if gamemode == GM_GAMESTARTED checkallflags(player->cell->map); */ // ie. don't create mosnters on closed doors! if (!cellwalkable(NULL, c, NULL)) { @@ -279,10 +281,10 @@ lifeform_t *addmonster(cell_t *c, enum RACE rid, char *racename, int randomjobok } } - //if (gamemode == GM_GAMESTARTED) checkallflags(player->cell->map); // debugging + //if gamemode == GM_GAMESTARTED checkallflags(player->cell->map); // debugging lf = addlf(c, r->id, getrandommonlevel(r, c->map)); if (db) dbtime("finished lf addition"); - //if (gamemode == GM_GAMESTARTED) checkallflags(player->cell->map); // debugging + //if gamemode == GM_GAMESTARTED checkallflags(player->cell->map); // debugging if (lf) { flag_t *f; @@ -348,7 +350,7 @@ lifeform_t *addmonster(cell_t *c, enum RACE rid, char *racename, int randomjobok } generatealignment(lf); - //if (gamemode == GM_GAMESTARTED) checkallflags(player->cell->map); // debugging + //if gamemode == GM_GAMESTARTED checkallflags(player->cell->map); // debugging if (autogen) { // sometimes start off hiding/asleep in new maps @@ -398,6 +400,8 @@ lifeform_t *addmonster(cell_t *c, enum RACE rid, char *racename, int randomjobok // adjust hostility based on player's race if ((player->race->id == R_AVIAD) && hasflag(lf->flags, F_AVIAN)) { killflagsofid(lf->flags, F_HOSTILE); + } else if ((player->race->id == R_MAMMOAN) && (lf->race->id == R_ELEPHANT)) { + killflagsofid(lf->flags, F_HOSTILE); } else { // adjust hostility based on player's alignment switch (getalignment(player)) { @@ -423,7 +427,7 @@ lifeform_t *addmonster(cell_t *c, enum RACE rid, char *racename, int randomjobok } lf->born = B_TRUE; - //if (gamemode == GM_GAMESTARTED) checkallflags(player->cell->map); // debugging + //if gamemode == GM_GAMESTARTED checkallflags(player->cell->map); // debugging // appears in groups? if (db) dbtime("handling groups"); @@ -5473,6 +5477,14 @@ void finalisemonster(lifeform_t *lf, lifeform_t *leader, flagpile_t *wantflags, if (lfhasflag(lf, F_ASLEEP)) { killflagsofid(lf->flags, F_FLYING); killflagsofid(lf->flags, F_HIDING); + } else { + if (hasflag(lf->race->flags, F_NATURALFLIGHT) && !lfhasflag(lf, F_FLYING)) { + if (cancast(lf, OT_S_FLIGHT, NULL)) { + notime = B_TRUE; + castspell(lf, OT_S_FLIGHT, lf, NULL, lf->cell, NULL, NULL); + notime = B_FALSE; + } + } } // automatic spells diff --git a/nexus.c b/nexus.c index 07073de..b4aa88e 100644 --- a/nexus.c +++ b/nexus.c @@ -748,6 +748,7 @@ void donextturn(map_t *map) { f->val[2]--; if (f->val[2] <= 0) { + // spell triggers! char *p; char buf[BUFLEN]; int lfid,mapid,x,y,power; @@ -801,7 +802,10 @@ void donextturn(map_t *map) { char lfname[BUFLEN]; // still going... getlfname(who, lfname); - f2 = lfhasflag(who,F_SPELLCASTTEXT); + f2 = lfhasflagval(who,F_SPELLCASTCONTTEXT, f->val[0], NA, NA, NULL); + if (!f2) { + f2 = lfhasflagval(who,F_SPELLCASTCONTTEXT, OT_NONE, NA, NA, NULL); + } if (f2 && strlen(f2->text)) { msg("%s %s.", lfname, f2->text); } else { @@ -1436,35 +1440,46 @@ int rolldie(int ndice, int sides) { int rollhitdice(lifeform_t *lf, int wantmax) { flag_t *f; - int ndice, nsides = 4, plus = 0; + int ndice, nsides = HITDIESIDES, plus = 0; int myroll = 0; - float mod; + int maxroll; + float pctofmax; int db = B_FALSE; + int myfitness; f = hasflag(lf->flags, F_HITDICE); if (f) { - texttodice(f->text, &ndice, &nsides, &plus); + ndice = f->val[0]; + if (f->val[1] > 0) { + plus = f->val[1]; + } + if (f->val[2] > 0) { + nsides = f->val[2]; + } } else { ndice = 1; - nsides = 4; plus = 0; } + maxroll = (ndice * nsides) + plus; + if (wantmax) { - myroll = (ndice * nsides) + plus; + myroll = maxroll; } else { myroll = rolldie(ndice, nsides) + plus; } - mod = 100 + getstatmod(lf, A_CON); - if (db) dblog("rollhitdice() - mod is +%0.0f%%",mod); - - if (db) dblog("TOTAL: %d",myroll); // modify for fitness/con - myroll = pctof(mod, myroll); - if (db) dblog(" -> modified to: %d",myroll); + if (isplayer(lf)) { + pctofmax = ((float)myroll / (float) maxroll) * 100.0; + myfitness = getattr(lf, A_CON); + if (pctofmax < myfitness) { + myroll = pctof(myfitness, maxroll); + if (db) dblog(" -> modified by fitness to: %d",myroll); + } + } limit(&myroll, 1, NA); return myroll; diff --git a/objects.c b/objects.c index 3f6c3a3..1a0fbe9 100644 --- a/objects.c +++ b/objects.c @@ -1722,11 +1722,13 @@ object_t *addobject(obpile_t *where, char *name, int canstack, int dolinks, enum rf = hasflag(corpserace->flags, F_HITDICE); if (rf) { int maxhp; - maxhp = roll(rf->text); + maxhp = flagtomaxhp(f); f->val[0] = maxhp; f->val[1] = maxhp; } } + + } else if (o->type->id == OT_HEAD) { flag_t *rf, *cf; @@ -4465,6 +4467,7 @@ int getmaterialvalue(enum MATERIAL mat) { case MT_METAL: return 5; case MT_SILVER: + case MT_CRYSTAL: return 6; case MT_GOLD: case MT_DRAGONWOOD: @@ -4731,7 +4734,7 @@ char *getobequipinfo(object_t *o, char *buf) { f = hasflag(o->flags,F_EQUIPPED); if (f) { if (f->val[0] == BP_WEAPON) { - if (hasflag(o->flags, F_TWOHANDED)) { + if (istwohandedfor(o, o->pile->owner)) { strcat(buf, " (two-handed weapon)"); } else if (ismeleeweapon(o)) { strcat(buf, " (weapon)"); @@ -4739,7 +4742,7 @@ char *getobequipinfo(object_t *o, char *buf) { strcat(buf, " (makeshift weapon)"); } } else if (f->val[0] == BP_SECWEAPON) { - if (hasflag(o->flags, F_TWOHANDED)) { + if (istwohandedfor(o, o->pile->owner)) { strcat(buf, " (two-handed weapon)"); } else if (isshield(o)) { strcat(buf, " (shield)"); @@ -6416,7 +6419,7 @@ char *gettopobname(cell_t *c, char *retbuf) { return retbuf; } -enum BODYPART getweildloc(object_t *o, enum BODYPART *otherloc, int *twohanded) { +enum BODYPART getweildloc(object_t *o, lifeform_t *lf, enum BODYPART *otherloc, int *twohanded) { enum BODYPART weildloc; if (o) { if (hasflag(o->flags, F_FIREARM)) { @@ -6425,7 +6428,7 @@ enum BODYPART getweildloc(object_t *o, enum BODYPART *otherloc, int *twohanded) weildloc = BP_WEAPON; } if (twohanded) { - if (hasflag(o->flags, F_TWOHANDED)) { + if (istwohandedfor(o, lf)) { *twohanded = B_TRUE; } else { *twohanded = B_FALSE; @@ -7250,6 +7253,18 @@ int issmellableob(object_t *o) { return B_FALSE; } +int istwohandedfor(object_t *o, lifeform_t *lf) { + flag_t *f; + f = hasflag(o->flags, F_TWOHANDED); + if (f) { + // twohanded for everyone + if (f->val[0] <= 0) return B_TRUE; + if (!lf) return B_TRUE; + if (getlfsize(lf) <= f->val[0]) return B_TRUE; + } + return B_FALSE; +} + int isweapon(object_t *o) { if (o->type->obclass->id == OC_WEAPON) { return B_TRUE; @@ -10364,6 +10379,20 @@ void potioneffects(lifeform_t *lf, enum OBTYPE oid, object_t *o, enum BLESSTYPE } gainlevel(lf, B_TRUE); + break; + case OT_POT_FISHLUNG: + if (getmr(lf) && skillcheck(lf, SC_RESISTMAG, 30, 0)) { + if (isplayer(lf)) { + msg("You lungs feel momentarily watery."); + } + break; + } + // how long for? + i = geteffecttime(50,100,potblessed); + + if (!lfhasflag(lf, F_BREATHWATER)) { + addtempflag(lf->flags, F_BREATHWATER, B_TRUE, NA, NA, NULL, i); + } break; case OT_POT_FURY: lf->stamina = getmaxstamina(lf); @@ -11641,6 +11670,7 @@ int shatter(object_t *o, int hitlf, char *damstring, lifeform_t *fromlf) { break; case OT_POT_ELEMENTIMMUNE: case OT_POT_ETHEREALNESS: + case OT_POT_FISHLUNG: case OT_POT_GASEOUSFORM: case OT_POT_GROWTH: case OT_POT_LEVITATION: @@ -12541,7 +12571,7 @@ int real_fireat(lifeform_t *thrower, object_t *o, int amt, cell_t *where, int sp glyph_t *gl; gl = getglyph(o); anim(where, srcloc, gl->ch, gl->colour); - msg("%s %s reflected away from %s!", obname, (o->amt == 1) ? "is" : "are", targetname); + msg("%s %s reflected away from %s!", obname, (amt == 1) ? "is" : "are", targetname); } // adjust target where = srcloc; @@ -13145,21 +13175,34 @@ void timeeffectsob(object_t *o) { // does object's material change cell type? if (o->material->id == MT_FIRE) { if (hasflag(location->type->material->flags, F_FLAMMABLE)) { - int changed = B_FALSE; + enum OBTYPE burnoid = OT_NONE; + if (haslos(player, location)) { + if (!lfhasflag(player, F_DONEBURNMSG)) { + msg("The %s burns!", location->type->name); + addflag(player->flags, F_DONEBURNMSG, B_TRUE, NA, NA, NULL); + needredraw = B_TRUE; + } + } // burn by changing celltype... switch (location->type->id) { case CT_GRASS: setcelltype(location, CT_DIRT); + burnoid = OT_ASH; + break; + case CT_FLOORWOOD: + setcelltype(location, CT_CORRIDOR); + burnoid = OT_HOLEINGROUND; break; default: + // stone floor + setcelltype(location, CT_CORRIDOR); + burnoid = OT_ASH; break; } - if (changed && haslos(player, location)) { - msg("The %s burns!", location->type->name); - needredraw = B_TRUE; + if (burnoid != OT_NONE) { + addobfast(location->obpile, burnoid); } //setcelltype(location, CT_CORRIDOR); - addob(location->obpile, "pile of ash"); } } @@ -14316,6 +14359,7 @@ int willshatter(enum MATERIAL mat) { switch (mat) { case MT_GLASS: case MT_ICE: + case MT_CRYSTAL: return B_TRUE; default: break; } diff --git a/objects.h b/objects.h index 5532696..35a7383 100644 --- a/objects.h +++ b/objects.h @@ -151,7 +151,7 @@ int getstairdirection(object_t *o); enum SKILLLEVEL gettechlevel(enum OBTYPE oid); int getthrowdam(object_t *o); char *gettopobname(cell_t *c, char *retbuf); -enum BODYPART getweildloc(object_t *o, enum BODYPART *otherloc, int *twohanded); +enum BODYPART getweildloc(object_t *o, lifeform_t *lf, enum BODYPART *otherloc, int *twohanded); int hasedibleob(obpile_t *op); object_t *hasequippedobid(obpile_t *op, enum OBTYPE oid); object_t *hasknownob(obpile_t *op, enum OBTYPE oid); @@ -212,6 +212,7 @@ int issmellableob(object_t *o); int isthrownmissile(object_t *o); knowledge_t *istried(object_t *o); knowledge_t *istriedot(objecttype_t *ot); +int istwohandedfor(object_t *o, lifeform_t *lf); int isweapon(object_t *o); int iswearable(object_t *o); void killallobs(obpile_t *op); diff --git a/spell.c b/spell.c index 8dbd4e4..1853eea 100644 --- a/spell.c +++ b/spell.c @@ -615,7 +615,7 @@ int abilityeffects(lifeform_t *user, enum OBTYPE abilid, cell_t *targcell, lifef if (corpse) { getobname(corpse, obname, o->amt); if (isimmuneto(corpse->flags, DT_FIRE, B_FALSE)) { - msg("You attempt to cook %s, but it won't heat up.", obname); + msg("^wYou attempt to cook %s, but it won't heat up.^n", obname); cooktime += getactspeed(user); ncooked++; } else { @@ -1715,6 +1715,7 @@ int abilityeffects(lifeform_t *user, enum OBTYPE abilid, cell_t *targcell, lifef takedamage(shield, roll("1d3"), DT_DIRECT); } else if (abilid == OT_A_SNATCH) { object_t *o = NULL; + flag_t *f; if (!targcell) { int dirch; @@ -1747,7 +1748,11 @@ int abilityeffects(lifeform_t *user, enum OBTYPE abilid, cell_t *targcell, lifef return B_TRUE; } + // setting v0 to spellid just in case pickup() changes flags + addflag(user->flags, F_NOTIME, OT_A_SNATCH, NA, NA, NULL); pickup(user, o, 1, B_TRUE, B_TRUE); + f = lfhasflagval(user, F_NOTIME, OT_A_SNATCH, NA, NA, NULL); + if (f) killflag(f); } else if (abilid == OT_A_SONICBOLT) { int volume; @@ -6600,7 +6605,7 @@ int dospelleffects(lifeform_t *caster, enum OBTYPE spellid, int power, lifeform_ for (o = c->obpile->first ; o ; o = o->next) { if (o->type->id == OT_HAILSTORM) { flag_t *f; - f = hasflag(o->flags, F_WALKDAM); + f = hasflagval(o->flags, F_WALKDAM, DT_PROJECTILE, NA, NA, NULL); if (f) { changeflagtext(f, dambuf); } @@ -8974,7 +8979,7 @@ int dospelleffects(lifeform_t *caster, enum OBTYPE spellid, int power, lifeform_ } else if ((spellid == OT_S_POLYMORPH) || (spellid == OT_S_SHAPESHIFT)) { race_t *r = NULL; - if (frompot || (spellid == OT_S_SHAPESHIFT)) { + if (caster && (frompot || (spellid == OT_S_SHAPESHIFT))) { target = caster; } else { target = targcell->lf; @@ -9000,27 +9005,33 @@ int dospelleffects(lifeform_t *caster, enum OBTYPE spellid, int power, lifeform_ } //if ((caster == target) && getforcedspellrace(caster, spellid, buf)) { - if (caster && getforcedspellrace(caster, spellid, buf)) { + if (getforcedspellrace(target, spellid, buf)) { r = findracebyname(buf); } else { if (spellid == OT_S_POLYMORPH) { - if (lfhasflag(caster, F_CONTROL)) { + int dorandom = B_FALSE; + if (caster && lfhasflag(caster, F_CONTROL)) { if (power < 5) { power = 5; } } - if (isplayer(caster) && (power >= 5)) { - if (isplayer(target)) { // ie. polymorphing yourself - askstring("What will you become", '?', buf, BUFLEN, NULL); + if (power >= 5) { // controlled + if (isplayer(caster)) { + if (isplayer(target)) { // ie. polymorphing yourself + askstring("What will you become", '?', buf, BUFLEN, NULL); + } else { + char buf2[BUFLEN]; + char targname[BUFLEN]; + getlfname(target, targname); + snprintf(buf2, BUFLEN, "What will you transform %s into", targname); + askstring(buf2, '?', buf, BUFLEN, NULL); + } + r = findracebyname(buf); } else { - char buf2[BUFLEN]; - char targname[BUFLEN]; - getlfname(target, targname); - snprintf(buf2, BUFLEN, "What will you transform %s into", targname); - askstring(buf2, '?', buf, BUFLEN, NULL); + // TODO: select based on player damage, etc + dorandom = B_TRUE; } - r = findracebyname(buf); } else { // random if (isplayer(target) && lfhasflag(target, F_CONTROL)) { askstring("What will you become", '?', buf, BUFLEN, NULL); @@ -9028,14 +9039,25 @@ int dospelleffects(lifeform_t *caster, enum OBTYPE spellid, int power, lifeform_ // make sure race is valid: if (r && !canpolymorphto(r->id)) r = NULL; - } + } else { + dorandom = B_TRUE; + } + } - if (!r) { - // random race, but not the same! - r = target->race; - while ((r == target->race) || !canpolymorphto(r->id)) { - r = getrandomrace(NULL, NA); - } + if (!r || dorandom) { + int forcedepth; + // want a random race with similar Threat Rating to the + // target's current one. + // + // normally tr range is (depth/2) +/- RARITYVARIANCELF + // + // so for a given tr, ask for: + // + // depth = tr*2 + forcedepth = gettr(target)*2; + r = target->race; + while ((r == target->race) || !canpolymorphto(r->id)) { + r = getrandomrace(NULL, forcedepth); } } } else if (spellid == OT_S_SHAPESHIFT) { @@ -9749,6 +9771,10 @@ int dospelleffects(lifeform_t *caster, enum OBTYPE spellid, int power, lifeform_ fizzle(caster); return B_TRUE; } + + // revert in a little while... + addflag(target->flags, F_SIZETIMER, origsize, power*10, NA, NULL); + if (isplayer(target) || cansee(player, target)) { if (seenbyplayer) *seenbyplayer = B_TRUE; } @@ -10159,23 +10185,13 @@ int dospelleffects(lifeform_t *caster, enum OBTYPE spellid, int power, lifeform_ // get list of possible snakes for (r = firstrace ; r ; r = r->next) { if (strstr(r->name, " snake")) { - flag_t *f; - f = hasflag(r->flags, F_HITDICE); - if (f) { - int ndice,nsides,bonus,maxroll; - texttodice(f->text, &ndice,&nsides,&bonus); - maxroll = ndice * nsides + bonus; - // ie. 1hd needs power 2 - // ie. 2hd needs power 4 - // ie. 3hd needs power 6 - // ie. 4hd needs power 8 - if (power >= (maxroll/4)) { - raceposs[nraceposs++] = r; - } + int tr; + tr = gettrrace(r); + if (power >= tr*2) { + raceposs[nraceposs++] = r; } } } - /* poss[0] = caster->cell; @@ -11320,6 +11336,8 @@ int dospelleffects(lifeform_t *caster, enum OBTYPE spellid, int power, lifeform_ howlong = getspellduration(5,10,blessed) + power; f = addtempflag(target->flags, F_ATTRMOD, A_STR, power*-15, NA, NULL, howlong); f->obfrom = OT_S_WEAKEN; + f = addtempflag(target->flags, F_MELEEDAMPCT, 50, NA, NA, NULL, howlong); + f->obfrom = OT_S_WEAKEN; if (seenbyplayer) *seenbyplayer = B_TRUE; } else { @@ -12444,7 +12462,7 @@ int getspellrange(lifeform_t *lf, enum OBTYPE spellid, int power) { range = power; break; case OT_S_FLAMEPILLAR: - range = power; + range = 3+(power/2); break; case OT_S_LIGHTNINGBOLT: range = (power*3);