|
From: <dsh...@us...> - 2007-04-02 16:30:31
|
Revision: 1192
http://svn.sourceforge.net/crawl-ref/?rev=1192&view=rev
Author: dshaligram
Date: 2007-04-02 09:30:26 -0700 (Mon, 02 Apr 2007)
Log Message:
-----------
Merge trunk into 0.2 branch for 0.2.1.
Modified Paths:
--------------
branches/stone_soup-0.2/crawl-ref/CREDITS
branches/stone_soup-0.2/crawl-ref/docs/changes.stone_soup
branches/stone_soup-0.2/crawl-ref/source/AppHdr.h
branches/stone_soup-0.2/crawl-ref/source/describe.cc
branches/stone_soup-0.2/crawl-ref/source/dungeon.cc
branches/stone_soup-0.2/crawl-ref/source/enum.h
branches/stone_soup-0.2/crawl-ref/source/fight.cc
branches/stone_soup-0.2/crawl-ref/source/insult.cc
branches/stone_soup-0.2/crawl-ref/source/insult.h
branches/stone_soup-0.2/crawl-ref/source/macro.cc
branches/stone_soup-0.2/crawl-ref/source/message.cc
branches/stone_soup-0.2/crawl-ref/source/mon-data.h
branches/stone_soup-0.2/crawl-ref/source/mon-util.cc
branches/stone_soup-0.2/crawl-ref/source/monspeak.cc
branches/stone_soup-0.2/crawl-ref/source/monspeak.h
branches/stone_soup-0.2/crawl-ref/source/monstuff.cc
branches/stone_soup-0.2/crawl-ref/source/monstuff.h
branches/stone_soup-0.2/crawl-ref/source/player.cc
branches/stone_soup-0.2/crawl-ref/source/religion.cc
branches/stone_soup-0.2/crawl-ref/source/spells2.cc
branches/stone_soup-0.2/crawl-ref/source/spells2.h
branches/stone_soup-0.2/crawl-ref/source/spells4.cc
branches/stone_soup-0.2/crawl-ref/source/spl-cast.cc
branches/stone_soup-0.2/crawl-ref/source/tags.cc
branches/stone_soup-0.2/crawl-ref/source/util/levcomp.lpp
Modified: branches/stone_soup-0.2/crawl-ref/CREDITS
===================================================================
--- branches/stone_soup-0.2/crawl-ref/CREDITS 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/CREDITS 2007-04-02 16:30:26 UTC (rev 1192)
@@ -34,6 +34,7 @@
Jarmo Kielosto
Ryan Kusnery
Jukka Kuusisto
+Jordan Lewis
Icy Lich
Arien Malec
Shawn M Moore
Modified: branches/stone_soup-0.2/crawl-ref/docs/changes.stone_soup
===================================================================
--- branches/stone_soup-0.2/crawl-ref/docs/changes.stone_soup 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/docs/changes.stone_soup 2007-04-02 16:30:26 UTC (rev 1192)
@@ -1,3 +1,18 @@
+Stone Soup 0.2.1 (20070402)
+---------------------------
+* Fixed electric golems getting too much damage against shock-resistant
+ characters.
+* Fixed vampiric draining targeting.
+* Fixed monster dialogue grammar.
+* Fixed EV penalty for nagas and centaurs.
+* Fixed tutorial reporting corpse availability for corpses not in view.
+* Fixed a possible buffer overflow when reading saves.
+* Fixed sporadic crash when a poisoned monster with other enchantments dies
+ from poison.
+* Fixed description for staff of wizardry.
+* Reinstated old behaviour of -macro option for Crawl compiled with
+ -DDGAMELAUNCH (DGL_MACRO_ABSOLUTE_PATH).
+
Stone Soup 0.2 (20070401)
-------------------------
* Save and bones files formats changed, incompatible with 0.1.x.
Modified: branches/stone_soup-0.2/crawl-ref/source/AppHdr.h
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/AppHdr.h 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/AppHdr.h 2007-04-02 16:30:26 UTC (rev 1192)
@@ -225,6 +225,10 @@
// Record where players are currently.
#define DGL_WHEREIS
+
+ // Uses Options.macro_dir as the full path to the macro file. Mutually
+ // exclusive with DGL_NAMED_MACRO_FILE.
+ #define DGL_MACRO_ABSOLUTE_PATH
#endif
// =========================================================================
Modified: branches/stone_soup-0.2/crawl-ref/source/describe.cc
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/describe.cc 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/describe.cc 2007-04-02 16:30:26 UTC (rev 1192)
@@ -207,11 +207,11 @@
}
if (proprt[ RAP_FIRE ] < -2)
- description += "$It makes you highly vulnerable to fire. ";
+ description += "$It makes you extremely vulnerable to fire. ";
else if (proprt[ RAP_FIRE ] == -2)
- description += "$It makes you greatly susceptible to fire. ";
+ description += "$It makes you very vulnerable to fire. ";
else if (proprt[ RAP_FIRE ] == -1)
- description += "$It makes you susceptible to fire. ";
+ description += "$It makes you vulnerable to fire. ";
else if (proprt[ RAP_FIRE ] == 1)
description += "$It protects you from fire. ";
else if (proprt[ RAP_FIRE ] == 2)
@@ -220,11 +220,11 @@
description += "$It renders you almost immune to fire. ";
if (proprt[ RAP_COLD ] < -2)
- description += "$It makes you highly susceptible to cold. ";
+ description += "$It makes you extremely vulnerable to cold. ";
else if (proprt[ RAP_COLD ] == -2)
- description += "$It makes you greatly susceptible to cold. ";
+ description += "$It makes you very vulnerable to cold. ";
else if (proprt[ RAP_COLD ] == -1)
- description += "$It makes you susceptible to cold. ";
+ description += "$It makes you vulnerable to cold. ";
else if (proprt[ RAP_COLD ] == 1)
description += "$It protects you from cold. ";
else if (proprt[ RAP_COLD ] == 2)
@@ -2861,8 +2861,8 @@
{
case STAFF_WIZARDRY:
description +=
- "increases the magical proficiency of its wielder by "
- "a considerable degree, increasing the power of their spells. ";
+ "significantly increases the ability of its wielder to use "
+ "magical spells. ";
break;
case STAFF_POWER:
Modified: branches/stone_soup-0.2/crawl-ref/source/dungeon.cc
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/dungeon.cc 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/dungeon.cc 2007-04-02 16:30:26 UTC (rev 1192)
@@ -6542,9 +6542,26 @@
while (pools < no_pools);
} // end many_pools()
+static int exciting_colour()
+{
+ switch(random2(4))
+ {
+ case 0: return YELLOW;
+ case 1: return LIGHTGREEN;
+ case 2: return LIGHTRED;
+ case 3: return LIGHTMAGENTA;
+ default: return MAGENTA;
+ }
+}
+
+
static int newwave_weapon_colour(const item_def &item)
{
int item_colour = BLACK;
+ // unrandom artefacts get predefined colours
+ if ( is_random_artefact(item) )
+ return exciting_colour();
+
if (is_range_weapon( item ))
{
switch (range_skill(item))
@@ -6553,7 +6570,7 @@
item_colour = BLUE;
break;
case SK_CROSSBOWS:
- item_colour = RED;
+ item_colour = LIGHTBLUE;
break;
case SK_DARTS:
item_colour = WHITE;
@@ -6584,7 +6601,7 @@
item_colour = LIGHTGREY;
break;
case SK_POLEARMS:
- item_colour = LIGHTGREEN;
+ item_colour = RED;
break;
case SK_STAVES:
item_colour = GREEN;
@@ -6655,10 +6672,10 @@
item_colour = WHITE;
break;
case MI_BOLT:
- item_colour = RED;
+ item_colour = LIGHTBLUE;
break;
case MI_DART:
- item_colour = LIGHTRED;
+ item_colour = CYAN;
break;
default:
// huh?
Modified: branches/stone_soup-0.2/crawl-ref/source/enum.h
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/enum.h 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/enum.h 2007-04-02 16:30:26 UTC (rev 1192)
@@ -3004,8 +3004,8 @@
SIZE_LITTLE, // spriggan
SIZE_SMALL, // halfling/kobold/gnome
SIZE_MEDIUM, // human/elf/dwarf
- SIZE_LARGE, // troll/ogre
- SIZE_BIG, // centaur/naga/large quadrupeds
+ SIZE_LARGE, // troll/ogre/centaur/naga
+ SIZE_BIG, // large quadrupeds
SIZE_GIANT, // giant
SIZE_HUGE, // dragon
NUM_SIZE_LEVELS,
Modified: branches/stone_soup-0.2/crawl-ref/source/fight.cc
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/fight.cc 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/fight.cc 2007-04-02 16:30:26 UTC (rev 1192)
@@ -2760,8 +2760,10 @@
case AF_ELEC:
special_damage =
- resist_adjust_damage(defender->res_elec(),
- atk->hit_dice + random2( 2 * atk->hit_dice ));
+ resist_adjust_damage(
+ defender->res_elec(),
+ atk->hit_dice + random2( atk->hit_dice / 2 ));
+
if (defender->levitates())
special_damage = special_damage * 2 / 3;
@@ -2770,6 +2772,10 @@
attacker->name(DESC_CAP_THE).c_str(),
attacker->conj_verb("shock").c_str(),
defender->name(DESC_NOCAP_THE).c_str());
+
+#ifdef DEBUG_DIAGNOSTICS
+ mprf(MSGCH_DIAGNOSTICS, "Shock damage: %d", special_damage);
+#endif
break;
case AF_VAMPIRIC:
Modified: branches/stone_soup-0.2/crawl-ref/source/insult.cc
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/insult.cc 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/insult.cc 2007-04-02 16:30:26 UTC (rev 1192)
@@ -38,7 +38,7 @@
str[0] = toupper( str[0] );
}
-void imp_taunt( struct monsters *mons )
+void imp_taunt( const monsters *mons )
{
char buff[80];
const char *mon_name = ptr_monam( mons, DESC_CAP_THE );
@@ -65,7 +65,7 @@
}
}
-void demon_taunt( struct monsters *mons )
+void demon_taunt( const monsters *mons )
{
static const char * sound_list[] =
{
Modified: branches/stone_soup-0.2/crawl-ref/source/insult.h
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/insult.h 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/insult.h 2007-04-02 16:30:26 UTC (rev 1192)
@@ -3,8 +3,8 @@
#include "externs.h"
-void imp_taunt( struct monsters *mons );
-void demon_taunt( struct monsters *mons );
+void imp_taunt( const monsters *mons );
+void demon_taunt( const monsters *mons );
const char * generic_insult(void);
const char * racial_insult(void);
Modified: branches/stone_soup-0.2/crawl-ref/source/macro.cc
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/macro.cc 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/macro.cc 2007-04-02 16:30:26 UTC (rev 1192)
@@ -175,11 +175,19 @@
if (!dir.empty())
{
+#ifndef DGL_MACRO_ABSOLUTE_PATH
if (dir[dir.length() - 1] != FILE_SEPARATOR)
dir += FILE_SEPARATOR;
+#endif
}
-
+
+#if defined(DGL_MACRO_ABSOLUTE_PATH)
+ return (dir.empty()? "macro.txt" : dir);
+#elif defined(DGL_NAMED_MACRO_FILE)
+ return (dir + strip_filename_unsafe_chars(you.your_name) + "-macro.txt");
+#else
return (dir + "macro.txt");
+#endif
}
static void buf2keyseq(const char *buff, keyseq &k)
Modified: branches/stone_soup-0.2/crawl-ref/source/message.cc
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/message.cc 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/message.cc 2007-04-02 16:30:26 UTC (rev 1192)
@@ -572,6 +572,13 @@
Message_Line >= get_message_window_height() - 1 );
} // end more()
+static bool is_channel_dumpworthy(int channel)
+{
+ return (channel != MSGCH_EQUIPMENT
+ && channel != MSGCH_DIAGNOSTICS
+ && channel != MSGCH_TUTORIAL);
+}
+
std::string get_last_messages(int mcount)
{
if (mcount <= 0) return std::string();
@@ -586,9 +593,11 @@
int count = 0;
for (int i = initial; i != Next_Message; )
{
- if (Store_Message[i].text.length())
+ const message_item &msg = Store_Message[i];
+
+ if (msg.text.length() && is_channel_dumpworthy(msg.channel))
{
- text += Store_Message[i].text;
+ text += msg.text;
text += EOL;
count++;
}
Modified: branches/stone_soup-0.2/crawl-ref/source/mon-data.h
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/mon-data.h 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/mon-data.h 2007-04-02 16:30:26 UTC (rev 1192)
@@ -3833,7 +3833,7 @@
M_SPELLCASTER | M_SEE_INVIS,
MR_RES_ELEC | MR_RES_POISON | MR_RES_FIRE | MR_RES_COLD,
0, 10, MONS_CLAY_GOLEM, MONS_ELECTRIC_GOLEM, MH_NONLIVING, -8,
- { {AT_HIT, AF_ELEC, 12}, {AT_HIT, AF_ELEC, 12}, {AT_HIT, AF_ELEC, 12}, {AT_HIT, AF_PLAIN, 12} },
+ { {AT_HIT, AF_ELEC, 15}, {AT_HIT, AF_ELEC, 15}, {AT_HIT, AF_PLAIN, 15}, {AT_HIT, AF_PLAIN, 15} },
{ 15, 7, 4, 0 },
5, 20, 20, 7, MST_ELECTRIC_GOLEM, CE_NOCORPSE, Z_NOZOMBIE, S_SILENT, I_PLANT,
MONUSE_OPEN_DOORS, SIZE_LARGE
@@ -4393,7 +4393,7 @@
{
MONS_MURRAY, 'z', LIGHTRED, "Murray",
- M_SPELLCASTER | M_SEE_INVIS | M_EVIL | M_UNIQUE,
+ M_SPELLCASTER | M_SEE_INVIS | M_EVIL | M_SPEAKS | M_UNIQUE,
MR_RES_ELEC | MR_RES_POISON | MR_RES_HELLFIRE | MR_RES_COLD,
0, 50, MONS_LICH, MONS_CURSE_SKULL, MH_UNDEAD, MAG_IMMUNE,
{ {AT_BITE, AF_PLAIN, 20}, {AT_BITE, AF_PLAIN, 20}, {AT_NONE, AF_PLAIN, 0}, {AT_NONE, AF_PLAIN, 0} },
Modified: branches/stone_soup-0.2/crawl-ref/source/mon-util.cc
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/mon-util.cc 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/mon-util.cc 2007-04-02 16:30:26 UTC (rev 1192)
@@ -3573,6 +3573,10 @@
{
mon_enchant_list::iterator cur = i++;
apply_enchantment(*cur, spd);
+
+ // If the monster died, the iterator will be invalid!
+ if (!alive())
+ break;
}
}
Modified: branches/stone_soup-0.2/crawl-ref/source/monspeak.cc
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/monspeak.cc 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/monspeak.cc 2007-04-02 16:30:26 UTC (rev 1192)
@@ -38,11 +38,117 @@
#include "stuff.h"
#include "view.h"
+struct mon_dialogue
+{
+ monster_type speaker;
+ const char **silenced;
+ const char **confused;
+ const char **confused_friend;
+ const char **fleeing;
+ const char **fleeing_friend;
+ const char **friendly;
+ const char **hostile; // Most common.
+};
+
+static const char *murray_silenced[] =
+{
+ "%s rolls in a circle.",
+ "%s rolls around.",
+ "%s spins like a top.",
+ "%s grins evilly.",
+ "%s seems to say something.",
+ "%s says something you can't hear. It was probably not a compliment.",
+ NULL
+};
+
+static const char *murray_hostile[] =
+{
+ "%s rolls in a circle.",
+ "%s rolls around.",
+ "%s spins like a top.",
+ "%s grins evilly.",
+ "%s laughs evilly.",
+ "%s cackles, \"I will rule the world!\"",
+ "%s shouts, \"Give me your head, so I can impale it on a pike!\"",
+ "%s's teeth chatter loudly.",
+ "%s yells, \"I'm a mighty demonic power!\"",
+ "%s asks, \"How could you choose the Orb over me, your best friend?\"",
+ "%s shouts, \"Let the forces of evil and voodoo overcome you!\"",
+ "%s screams, \"If I had legs, you would be dead twenty times over!\"",
+ "%s yells, \"My visage is famous all over the dungeon!\"",
+ "%s says, \"You're the second biggest fool I've ever met!\"",
+ NULL
+};
+
+static mon_dialogue vox_populi[] =
+{
+ { MONS_MURRAY, murray_silenced, NULL, NULL, NULL, NULL, NULL,
+ murray_hostile },
+};
+
+static const mon_dialogue *find_dialogue(const monsters *monster)
+{
+ for (unsigned i = 0; i < sizeof(vox_populi) / sizeof(*vox_populi); ++i)
+ if (vox_populi[i].speaker == monster->type)
+ return (&vox_populi[i]);
+ return (NULL);
+}
+
+static bool say_dialogue(const monsters *monster,
+ const char **dialogue)
+{
+ if (!dialogue)
+ return (false);
+
+ int nitems = 0;
+ for (const char **run = dialogue; *run; ++run, ++nitems)
+ ;
+
+ const char *chosen = nitems? dialogue[random2(nitems)] : NULL;
+
+ if (chosen && *chosen)
+ {
+ mprf(MSGCH_TALK, chosen, monster->name(DESC_CAP_THE).c_str());
+ return (true);
+ }
+
+ return (false);
+}
+
+static bool say_specific_dialogue(const monsters *monster,
+ const mon_dialogue *dialogue)
+{
+ if (silenced(monster->x, monster->y))
+ return (say_dialogue(monster, dialogue->silenced));
+
+ if (monster->has_ench(ENCH_CHARM))
+ return (false);
+
+ const bool friendly = (monster->attitude == ATT_FRIENDLY);
+
+ if (mons_is_confused(monster))
+ return (say_dialogue(
+ monster,
+ friendly? dialogue->confused_friend
+ : dialogue->confused));
+
+ if (monster->behaviour == BEH_FLEE)
+ return (say_dialogue(
+ monster,
+ friendly? dialogue->fleeing_friend
+ : dialogue->fleeing));
+
+ if (monster->attitude == ATT_FRIENDLY)
+ return (say_dialogue(monster, dialogue->friendly));
+
+ return (say_dialogue(monster, dialogue->hostile));
+}
+
// returns true if something is said
-bool mons_speaks(struct monsters *monster)
+bool mons_speaks(const monsters *monster)
{
int temp_rand; // probability determination
-
+
// This function is a little bit of a problem for the message channels
// since some of the messages it generates are "fake" warning to
// scare the player. In order to accomidate this intent, we're
@@ -57,6 +163,10 @@
return false;
// invisible monster tries to remain unnoticed
+ const mon_dialogue *dialogue = find_dialogue(monster);
+ if (dialogue)
+ return (say_specific_dialogue(monster, dialogue));
+
//mv: if it's also invisible, program never gets here
if (silenced(monster->x, monster->y))
{
@@ -82,7 +192,7 @@
(temp_rand == 4) ? " looks around." :
(temp_rand == 5) ? " appears indecisive." :
(temp_rand == 6) ? " ponders the situation."
- : " seems to says something.");
+ : " seems to say something.");
}
// disregard charmed critters.. they're not too expressive
else if (monster->attitude == ATT_FRIENDLY)
@@ -182,7 +292,7 @@
case 17:
strcat(info, " says, \"");
strcat(info, you.your_name);
- strcat(info, ", I'm little bit confused.\"");
+ strcat(info, ", I'm a little confused.\"");
break;
}
}
@@ -191,7 +301,7 @@
switch (random2(23)) // speaks for unfriendly confused monsters
{
case 0:
- strcat(info, " yells, \"Get them off of me!\"");
+ strcat(info, " yells, \"Get them off me!\"");
break;
case 1:
strcat(info, " screams, \"I will kill you anyway!\"");
@@ -229,7 +339,7 @@
strcat(info, " mumbles something.");
break;
case 14:
- strcat(info, " says, \"I'm little bit confused.\"");
+ strcat(info, " says, \"I'm a little confused.\"");
break;
case 15:
strcat(info, " asks, \"Where am I?\"");
@@ -250,7 +360,7 @@
strcat(info, " says, \"Why is everything spinning?\"");
break;
case 21:
- strcat(info, " screams, \"NO! I can't bear up that noise!\"");
+ strcat(info, " screams, \"NO! I can't bear that much noise!\"");
break;
case 22:
strcat(info, " is trying to cover his eyes.");
@@ -565,7 +675,7 @@
strcat(info, " says, \"It's nothing personal...\"");
break;
case 14:
- strcat(info, " says, \"A dead adventurer is good adventurer.\"");
+ strcat(info, " says, \"A dead adventurer is a good adventurer.\"");
break;
case 15:
strcat(info, " says, \"Coming here was your last mistake.\"");
@@ -590,7 +700,7 @@
break;
case 3:
strcat(info,
- " says, \"It's nothing personal but I have kill you.\"");
+ " says, \"It's nothing personal, but I have to kill you.\"");
break;
case 5:
strcat(info, " says, \"You will never get the Orb, sorry.\"");
@@ -745,12 +855,12 @@
mpr(info, MSGCH_MONSTER_SPELL);
strcpy(info, m_name);
- strcat(info, "'s fingertips starts to glow.");
+ strcat(info, "'s fingertips start to glow.");
msg_type = MSGCH_MONSTER_ENCHANT;
break;
case 16:
- strcat(info, "'s eyes starts to glow.");
+ strcat(info, "'s eyes start to glow.");
msg_type = MSGCH_MONSTER_SPELL;
break;
@@ -795,7 +905,7 @@
break;
case 7:
strcat(info,
- " shouts, \"You're disturbing me. I'll have kill you.\"");
+ " shouts, \"You're disturbing me. I'll have to kill you.\"");
break;
case 8:
strcat(info, " screams, \"You are a ghastly nuisance!\"");
@@ -838,12 +948,12 @@
simple_monster_message( monster, " casts a spell.",
MSGCH_MONSTER_SPELL );
- strcat(info, "'s eyes starts to glow with a red light. ");
+ strcat(info, "'s eyes start to glow with a red light. ");
msg_type = MSGCH_MONSTER_ENCHANT;
break;
case 10:
- strcat(info, " says, \"Look in to my eyes.\"");
+ strcat(info, " says, \"Look into my eyes.\"");
break;
case 11:
strcat(info, " says, \"I'm your fate.\"");
@@ -980,7 +1090,7 @@
break;
case 11:
strcat(info,
- " says, \"I know thousand and one way to kill you.\"");
+ " says, \"I know a thousand and one ways to kill you.\"");
break;
case 12:
strcat(info,
@@ -1140,10 +1250,10 @@
" cries, \"You want to steal my orb collection?!\"");
break;
case 13:
- strcat(info, " sings some strange song.");
+ strcat(info, " sings a strange song.");
break;
case 14:
- strcat(info, " bursts in tears.");
+ strcat(info, " bursts into tears.");
break;
case 15:
strcat(info, " sucks her thumb.");
@@ -1361,7 +1471,7 @@
break;
case 6:
strcat(info,
- " says, \"Only few hits and it's over.\".");
+ " says, \"Only a few hits and it's over.\".");
break;
case 7:
strcat(info, " says, \"You know, I'm in a hurry.\"");
@@ -1412,7 +1522,7 @@
strcat(info, " screams, \"Blood and destruction!\"");
break;
case 9:
- strcat(info, " says, \"You know, it's honour to die by my hand.\"");
+ strcat(info, " says, \"You know, it's an honour to die by my hand.\"");
break;
case 10:
strcat(info, " shouts, \"Your time has come!\"");
@@ -1445,7 +1555,7 @@
break;
case 4:
strcat(info,
- " says, \"You don't look worth for that money.\"");
+ " says, \"You don't look worth it for that money.\"");
break;
case 5:
strcat(info,
@@ -1508,7 +1618,7 @@
break;
case 5:
strcat(info,
- " says, \"I need new robe. I'll buy it from your money.\"");
+ " says, \"I need a new robe. I'll buy it with your money.\"");
break;
case 6:
strcat(info,
@@ -1596,7 +1706,7 @@
simple_monster_message( monster, " casts a spell",
MSGCH_MONSTER_SPELL );
- strcat(info, "'s hands started to glow with soft light.");
+ strcat(info, "'s hands start to glow with a soft light.");
msg_type = MSGCH_MONSTER_ENCHANT;
break;
@@ -1618,7 +1728,7 @@
break;
case 11:
strcat(info,
- " screams, \"Don't move! I want to cut your ear!\"");
+ " screams, \"Don't move! I want to cut off your ear!\"");
break;
case 12:
strcat(info,
@@ -1645,10 +1755,10 @@
strcat(info, " screams, \"Die, monster!\"");
break;
case 2:
- strcat(info, " screams, \"Give me Holy Grail!\"");
+ strcat(info, " screams, \"Give me the Holy Grail!\"");
break;
case 3:
- strcat(info, " screams, \"Red! No, blue!\"");
+ strcat(info, " screams, \"Red! No, blue!\"");
break;
case 4:
strcat(info, " looks confused.");
@@ -1657,7 +1767,7 @@
strcat(info, " looks excited.");
break;
case 6:
- strcat(info, " shouts, \"I'm great and powerful hero!\"");
+ strcat(info, " shouts, \"I'm a great and powerful hero!\"");
break;
case 7:
strcat(info,
@@ -1790,14 +1900,14 @@
break;
case 5:
- strcat(info, "'s eyes starts to glow with a red light.");
+ strcat(info, "'s eyes start to glow with a red light.");
break;
case 6:
strcat(info,
- "'s eyes starts to glow with a green light.");
+ "'s eyes start to glow with a green light.");
break;
case 7:
- strcat(info, "'s eyes starts to glow with a blue light.");
+ strcat(info, "'s eyes start to glow with a blue light.");
break;
case 8:
strcat(info, " screams, \"All trespassers must die!\"");
@@ -2232,13 +2342,13 @@
case 15:
strcat(info, " casts a spell.");
mpr(info, MSGCH_MONSTER_SPELL);
- mpr("Suddenly you are surrounded with pale green light.", MSGCH_WARN);
+ mpr("Suddenly you are surrounded with a pale green light.", MSGCH_WARN);
return (true);
case 16:
strcat(info, " casts a spell.");
mpr(info, MSGCH_MONSTER_SPELL);
- mpr("You have terrible head-ache.", MSGCH_WARN);
+ mpr("You have a terrible headache.", MSGCH_WARN);
return (true);
case 17:
Modified: branches/stone_soup-0.2/crawl-ref/source/monspeak.h
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/monspeak.h 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/monspeak.h 2007-04-02 16:30:26 UTC (rev 1192)
@@ -3,6 +3,6 @@
#include "externs.h"
-bool mons_speaks(struct monsters *monster);
+bool mons_speaks(const monsters *monster);
#endif
Modified: branches/stone_soup-0.2/crawl-ref/source/monstuff.cc
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/monstuff.cc 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/monstuff.cc 2007-04-02 16:30:26 UTC (rev 1192)
@@ -326,8 +326,8 @@
// Don't care if 'o' is changed, and it shouldn't be (corpses don't stack)
move_item_to_grid( &o, monster->x, monster->y );
- if (you.hunger_state < HS_SATIATED)
- learned_something_new(TUT_MAKE_CHUNKS);
+ if (you.hunger_state < HS_SATIATED && see_grid(monster->x, monster->y))
+ learned_something_new(TUT_MAKE_CHUNKS);
} // end place_monster_corpse()
static void tutorial_inspect_kill()
@@ -1111,12 +1111,12 @@
monster_drop_ething(monster);
- // New monster type might be interesting
- mark_interesting_monst(monster);
+ // New monster type might be interesting
+ mark_interesting_monst(monster);
- // If new monster is visible to player, then we've seen it
- if (player_monster_visible(monster) && mons_near(monster))
- seen_monster(monster);
+ // If new monster is visible to player, then we've seen it
+ if (player_monster_visible(monster) && mons_near(monster))
+ seen_monster(monster);
return (player_messaged);
} // end monster_polymorph()
@@ -1834,7 +1834,7 @@
// distant or invisible to the player ... look elsewhere for a function
// permitting output of "It" messages for the invisible {dlb}
// Intentionally avoids info and str_pass now. -- bwr
-bool simple_monster_message(struct monsters *monster, const char *event,
+bool simple_monster_message(const monsters *monster, const char *event,
int channel, int param)
{
char buff[INFO_SIZE];
@@ -3367,7 +3367,8 @@
mons_in_cloud( monster );
}
- handle_enchantment( monster );
+ if (handle_enchantment( monster ))
+ return;
}
// memory is decremented here for a reason -- we only want it
@@ -3395,7 +3396,7 @@
while (monster->speed_increment >= 80)
{ // The continues & breaks are WRT this.
- if (monster->type != -1 && monster->hit_points < 1)
+ if (!monster->alive())
break;
monster->speed_increment -= 10;
@@ -3425,7 +3426,7 @@
}
if (handle_enchantment(monster))
- continue;
+ break;
monster_regenerate(monster);
Modified: branches/stone_soup-0.2/crawl-ref/source/monstuff.h
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/monstuff.h 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/monstuff.h 2007-04-02 16:30:26 UTC (rev 1192)
@@ -87,7 +87,7 @@
* called from: beam - effects - fight - monstuff - mstuff2 - spells1 -
* spells2 - spells4
* *********************************************************************** */
-bool simple_monster_message(struct monsters *monster, const char *event,
+bool simple_monster_message(const monsters *monster, const char *event,
int channel = MSGCH_PLAIN, int param = 0);
std::string str_simple_monster_message(monsters *mons, const char *event);
Modified: branches/stone_soup-0.2/crawl-ref/source/player.cc
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/player.cc 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/player.cc 2007-04-02 16:30:26 UTC (rev 1192)
@@ -4736,11 +4736,11 @@
if (psize == PSIZE_TORSO || psize == PSIZE_PROFILE)
ret = SIZE_MEDIUM;
else
- ret = SIZE_BIG;
+ ret = SIZE_LARGE;
break;
case SP_CENTAUR:
- ret = (psize == PSIZE_TORSO) ? SIZE_MEDIUM : SIZE_BIG;
+ ret = (psize == PSIZE_TORSO) ? SIZE_MEDIUM : SIZE_LARGE;
break;
case SP_SPRIGGAN:
@@ -5080,7 +5080,7 @@
int player::res_elec() const
{
- return (player_res_electricity());
+ return (player_res_electricity() * 2);
}
int player::res_poison() const
Modified: branches/stone_soup-0.2/crawl-ref/source/religion.cc
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/religion.cc 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/religion.cc 2007-04-02 16:30:26 UTC (rev 1192)
@@ -2595,6 +2595,13 @@
return;
}
+ if (which_god == GOD_LUGONU && you.penance[GOD_LUGONU])
+ {
+ simple_god_message(" is most displeased with you!", which_god);
+ lugonu_retribution(which_god);
+ return;
+ }
+
describe_god( which_god, false );
snprintf( info, INFO_SIZE, "Do you wish to %sjoin this religion?",
Modified: branches/stone_soup-0.2/crawl-ref/source/spells2.cc
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/spells2.cc 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/spells2.cc 2007-04-02 16:30:26 UTC (rev 1192)
@@ -990,31 +990,14 @@
}
} // end drain_life()
-int vampiric_drain(int pow)
+int vampiric_drain(int pow, const dist &vmove)
{
int inflicted = 0;
int mgr = 0;
struct monsters *monster = 0; // NULL
- struct dist vmove;
- dirc:
- mpr("Which direction?", MSGCH_PROMPT);
- direction( vmove, DIR_DIR, TARG_ENEMY );
-
- if (!vmove.isValid)
- {
- canned_msg(MSG_SPELL_FIZZLES);
- return -1;
- }
-
mgr = mgrd[you.x_pos + vmove.dx][you.y_pos + vmove.dy];
- if (vmove.dx == 0 && vmove.dy == 0)
- {
- mpr("You can't do that.");
- goto dirc;
- }
-
if (mgr == NON_MONSTER)
{
mpr("There isn't anything there!");
Modified: branches/stone_soup-0.2/crawl-ref/source/spells2.h
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/spells2.h 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/spells2.h 2007-04-02 16:30:26 UTC (rev 1192)
@@ -56,11 +56,12 @@
int summon_elemental(int pow, int restricted_type, unsigned char unfriendly);
+class dist;
// last updated 24may2000 {dlb}
/* ***********************************************************************
* called from: spell
* *********************************************************************** */
-int vampiric_drain(int pow);
+int vampiric_drain(int pow, const dist &);
// last updated 24may2000 {dlb}
Modified: branches/stone_soup-0.2/crawl-ref/source/spells4.cc
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/spells4.cc 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/spells4.cc 2007-04-02 16:30:26 UTC (rev 1192)
@@ -1873,11 +1873,7 @@
else if (lvl == 4)
simple_monster_message( &menv[mon], " glows brighter for a moment." );
else
- {
- // remove old level
- menv[mon].del_ench(ENCH_BACKLIGHT, true);
simple_monster_message( &menv[mon], " glows brighter." );
- }
// this enchantment wipes out invisibility (neat)
menv[mon].del_ench(ENCH_INVIS);
Modified: branches/stone_soup-0.2/crawl-ref/source/spl-cast.cc
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/spl-cast.cc 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/spl-cast.cc 2007-04-02 16:30:26 UTC (rev 1192)
@@ -880,6 +880,9 @@
testbits( flags, SPFLAG_GRID ) ? DIR_TARGET :
testbits( flags, SPFLAG_DIR ) ? DIR_DIR : DIR_NONE);
+ if (dir == DIR_DIR)
+ mpr("Which direction? ", MSGCH_PROMPT);
+
if (spell_direction( spd, beam, dir, targ,
get_spell_target_prompt(spc2) ) == -1)
return (SPRET_ABORT);
@@ -1315,7 +1318,7 @@
break;
case SPELL_VAMPIRIC_DRAINING:
- vampiric_drain(powc);
+ vampiric_drain(powc, spd);
break;
case SPELL_SUMMON_WRAITHS:
Modified: branches/stone_soup-0.2/crawl-ref/source/tags.cc
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/tags.cc 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/tags.cc 2007-04-02 16:30:26 UTC (rev 1192)
@@ -314,7 +314,6 @@
// put in the actual string -- we'll null terminate on
// unmarshall.
memcpy(&tagBuffer[th.offset], data, len);
-
th.offset += len;
}
@@ -324,6 +323,7 @@
// get length
short len = unmarshallShort(th);
int copylen = len;
+
if (len >= maxSize && maxSize > 0)
copylen = maxSize - 1;
@@ -1137,8 +1137,7 @@
you.num_turns = unmarshallLong(th);
you.magic_contamination = unmarshallShort(th);
- unmarshallString( th, buff, 80 );
- you.last_altar_inscription = buff;
+ you.last_altar_inscription = unmarshallString(th, 80);
}
static void tag_read_you_items(struct tagHeader &th, char minorVersion)
Modified: branches/stone_soup-0.2/crawl-ref/source/util/levcomp.lpp
===================================================================
--- branches/stone_soup-0.2/crawl-ref/source/util/levcomp.lpp 2007-04-02 16:30:05 UTC (rev 1191)
+++ branches/stone_soup-0.2/crawl-ref/source/util/levcomp.lpp 2007-04-02 16:30:26 UTC (rev 1192)
@@ -27,7 +27,7 @@
static void add_to_queue(const char *s)
{
free_queue.push(s);
- flush_free_queue(20);
+ flush_free_queue(100);
}
static void clean()
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|