From: Jaka K. <lyn...@us...> - 2010-12-28 17:47:14
|
gemrb: Infinity Engine emulator The branch master has been updated via b408b7081f6605c436c8b3617b482c09df6a4a67 (commit) Summary of changes: gemrb/core/Scriptable/ActorBlock.cpp | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) from d4d322a64433179bcc19a2a8c4996e2f3c70a69b (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- http://gemrb.git.sourceforge.net/git/gitweb.cgi?p=gemrb/gemrb;a=commitdiff;h=b408b7081f6605c436c8b3617b482c09df6a4a67 commit b408b7081f6605c436c8b3617b482c09df6a4a67 Author: Jaka Kranjc <lyn...@us...> Date: Tue Dec 28 18:48:28 2010 +0100 added some more warning/error output to spellcasting diff --git a/gemrb/core/Scriptable/ActorBlock.cpp b/gemrb/core/Scriptable/ActorBlock.cpp index c1da22a..654006f 100644 --- a/gemrb/core/Scriptable/ActorBlock.cpp +++ b/gemrb/core/Scriptable/ActorBlock.cpp @@ -738,6 +738,7 @@ int Scriptable::CastSpellPoint( const ieResRef SpellResRef, const Point &target, if (Type == ST_ACTOR) { Actor *actor = (Actor *) this; if (actor->HandleCastingStance(SpellResRef,deplete) ) { + printMessage("Scriptable", "Spell not known or memorized, aborting cast!\n", LIGHT_RED); return -1; } } @@ -755,6 +756,7 @@ int Scriptable::CastSpell( const ieResRef SpellResRef, Scriptable* target, bool if (Type == ST_ACTOR) { Actor *actor = (Actor *) this; if (actor->HandleCastingStance(SpellResRef,deplete) ) { + printMessage("Scriptable", "Spell not known or memorized, aborting cast!\n", LIGHT_RED); return -1; } } @@ -774,6 +776,7 @@ int Scriptable::SpellCast(const ieResRef SpellResRef, bool instant) Spell* spl = gamedata->GetSpell( SpellResRef ); if (!spl) { SpellHeader = -1; + printMessage("Scriptable", "Spell not found, aborting cast!\n", LIGHT_RED); return -1; } @@ -794,6 +797,7 @@ int Scriptable::SpellCast(const ieResRef SpellResRef, bool instant) // we (also) ignore nonmagic spells if (actor->Modified[IE_STATE_ID] & STATE_SILENCED) { if (!(core->GetSpecialSpell(spl->Name)&SP_SILENCE) && !(spl->Flags&SF_HLA)) { + printMessage("Scriptable", "Tried to cast while silenced!\n", YELLOW); return -1; } } ----------------------------------------------------------------------- This is an automated email from the git hooks/post-receive script. -- gemrb: Infinity Engine emulator |