Clear out experimental .35 files
Clear out experimental .35 files
This commit is contained in:
@@ -1,28 +0,0 @@
|
||||
void main()
|
||||
{
|
||||
// AOE On Enter - a
|
||||
object oCreator = GetAreaOfEffectCreator(OBJECT_SELF);
|
||||
|
||||
// Check spell Id, ETC:
|
||||
int nSpellId = GetSpellId();
|
||||
int nActual = SPELL_FIREBALL;
|
||||
|
||||
// Get save DC:
|
||||
int nSpellSaveDC = GetSpellSaveDC();
|
||||
|
||||
// Get caster level
|
||||
int nCasterLevel = GetCasterLevel(oCreator);
|
||||
|
||||
// Get tag
|
||||
string sTag = GetTag(OBJECT_SELF);
|
||||
string sName = GetName(OBJECT_SELF);
|
||||
string sResRef = GetResRef(OBJECT_SELF);
|
||||
|
||||
// We relay the information.
|
||||
SendMessageToPC(oCreator, "ENTER (BLUE): (T: " + sTag + ")(N: " + sName + ")(RR: " + sResRef + "). ID1: " + IntToString(nSpellId) + ". ID2: " + IntToString(nActual) + ". SaveDC: " + IntToString(nSpellSaveDC) + ". CasterLevel: " + IntToString(nCasterLevel) + ".");
|
||||
|
||||
// Apply an On Enter effect
|
||||
object oTarget = GetEnteringObject();
|
||||
effect eDur = EffectVisualEffect(VFX_DUR_IOUNSTONE_BLUE);
|
||||
ApplyEffectToObject(DURATION_TYPE_PERMANENT, eDur, oTarget);
|
||||
}
|
@@ -1,33 +0,0 @@
|
||||
void main()
|
||||
{
|
||||
// AOE On Heartbeat - b
|
||||
object oCreator = GetAreaOfEffectCreator(OBJECT_SELF);
|
||||
|
||||
// Check spell Id, ETC:
|
||||
int nSpellId = GetSpellId();
|
||||
int nActual = SPELL_FIREBALL;
|
||||
|
||||
// Get save DC:
|
||||
int nSpellSaveDC = GetSpellSaveDC();
|
||||
|
||||
// Get caster level
|
||||
int nCasterLevel = GetCasterLevel(oCreator);
|
||||
|
||||
// Get tag
|
||||
string sTag = GetTag(OBJECT_SELF);
|
||||
string sName = GetName(OBJECT_SELF);
|
||||
string sResRef = GetResRef(OBJECT_SELF);
|
||||
|
||||
// We relay the information.
|
||||
SendMessageToPC(oCreator, "ENTER (BLUE): (T: " + sTag + ")(N: " + sName + ")(RR: " + sResRef + "). ID1: " + IntToString(nSpellId) + ". ID2: " + IntToString(nActual) + ". SaveDC: " + IntToString(nSpellSaveDC) + ". CasterLevel: " + IntToString(nCasterLevel) + ".");
|
||||
|
||||
// Apply an On Enter effect
|
||||
object oTarget = GetFirstInPersistentObject();
|
||||
effect eDur = EffectVisualEffect(VFX_DUR_IOUNSTONE_GREEN);
|
||||
|
||||
while(GetIsObjectValid(oTarget))
|
||||
{
|
||||
ApplyEffectToObject(DURATION_TYPE_PERMANENT, eDur, oTarget);
|
||||
oTarget = GetNextInPersistentObject();
|
||||
}
|
||||
}
|
@@ -1,40 +0,0 @@
|
||||
void main()
|
||||
{
|
||||
// AOE On Exit - C
|
||||
object oCreator = GetAreaOfEffectCreator(OBJECT_SELF);
|
||||
|
||||
// Check spell Id, ETC:
|
||||
int nSpellId = GetSpellId();
|
||||
int nActual = SPELL_FIREBALL;
|
||||
|
||||
// Get save DC:
|
||||
int nSpellSaveDC = GetSpellSaveDC();
|
||||
|
||||
// Get caster level
|
||||
int nCasterLevel = GetCasterLevel(oCreator);
|
||||
|
||||
// Get tag
|
||||
string sTag = GetTag(OBJECT_SELF);
|
||||
string sName = GetName(OBJECT_SELF);
|
||||
string sResRef = GetResRef(OBJECT_SELF);
|
||||
|
||||
// We relay the information.
|
||||
SendMessageToPC(oCreator, "ENTER (BLUE): (T: " + sTag + ")(N: " + sName + ")(RR: " + sResRef + "). ID1: " + IntToString(nSpellId) + ". ID2: " + IntToString(nActual) + ". SaveDC: " + IntToString(nSpellSaveDC) + ". CasterLevel: " + IntToString(nCasterLevel) + ".");
|
||||
|
||||
// Check effects on target
|
||||
object oTarget = GetExitingObject();
|
||||
string sCreator, sEffectId, sType, sSubtype;
|
||||
effect eCheck = GetFirstEffect(oTarget);
|
||||
while(GetIsEffectValid(eCheck))
|
||||
{
|
||||
sCreator = GetName(GetEffectCreator(eCheck));
|
||||
sEffectId = IntToString(GetEffectSpellId(eCheck));
|
||||
sType = IntToString(GetEffectType(eCheck));
|
||||
sSubtype = IntToString(GetEffectSubType(eCheck));
|
||||
|
||||
// Relay message
|
||||
SendMessageToPC(oCreator, "EXIT: EXITER: " + GetName(oTarget) + ". Creator: " + sCreator + ". Spell ID: " + sEffectId + ". Type: " + sType + ". Subtype: " + sSubtype + ".");
|
||||
|
||||
eCheck = GetNextEffect(oTarget);
|
||||
}
|
||||
}
|
@@ -1,49 +0,0 @@
|
||||
/*
|
||||
001_testcut
|
||||
|
||||
Cutscene test
|
||||
|
||||
*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void Debug(string sString)
|
||||
{
|
||||
SendMessageToPC(GetFirstPC(), sString);
|
||||
}
|
||||
|
||||
void main()
|
||||
{
|
||||
// Set cutscene mode
|
||||
Debug("Setting cutscene mode - using the special spells function");
|
||||
|
||||
location lLoc = GetStartingLocation();
|
||||
|
||||
|
||||
PHS_ForceMovementToLocation(lLoc, VFX_FNF_TELEPORT_OUT, VFX_FNF_TELEPORT_IN);
|
||||
|
||||
/*
|
||||
|
||||
SetCutsceneMode(OBJECT_SELF, TRUE);
|
||||
|
||||
// Attempt to make them cast a spell first
|
||||
Debug("Attempting to jump to the start point");
|
||||
|
||||
if(GetCommandable(OBJECT_SELF) == FALSE)
|
||||
{
|
||||
SetCommandable(TRUE, OBJECT_SELF);
|
||||
ClearAllActions();
|
||||
ActionJumpToLocation(lLoc);
|
||||
Debug("Attempting to set back to normal 1");
|
||||
ActionDoCommand(SetCutsceneMode(OBJECT_SELF, FALSE));
|
||||
SetCommandable(FALSE, OBJECT_SELF);
|
||||
}
|
||||
else
|
||||
{
|
||||
ClearAllActions();
|
||||
JumpToLocation(lLoc);
|
||||
Debug("Attempting to set back to normal 2");
|
||||
SetCutsceneMode(OBJECT_SELF, FALSE);
|
||||
}
|
||||
*/
|
||||
}
|
@@ -1,18 +0,0 @@
|
||||
// 0_onattacked
|
||||
|
||||
// On Attacked report. report feedback information via. Speak String.
|
||||
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
object oAttacker = GetLastAttacker();// returns the object that last attacked OBJECT_SELF.
|
||||
object oDamager = GetLastDamager();// returns the object that actually dealt damage last (not neccessarily the last attacker).
|
||||
object oWeapon = GetLastWeaponUsed(oAttacker);// will return the last weapon used to attack the creature, if any.
|
||||
int nMode = GetLastAttackMode(oAttacker);// will return the last combat mode the attacking creature used, if any.
|
||||
int nType = GetLastAttackType(oAttacker);// will return the last special attack the attacking creature used, if any.
|
||||
|
||||
SpeakString("[ATTACKED] By: " + GetName(oAttacker) + ". With: " + GetName(oWeapon) +
|
||||
". Last Damager: " + GetName(oDamager) + ". nMode: " + IntToString(nMode) +
|
||||
". nType: " + IntToString(nType));
|
||||
}
|
@@ -1,10 +0,0 @@
|
||||
// 0_onblock
|
||||
|
||||
// On Blocked report. report feedback information via. Speak String.
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
// Report
|
||||
SpeakString("[BLOCKED]");
|
||||
}
|
@@ -1,10 +0,0 @@
|
||||
// 0_oncombat
|
||||
|
||||
// On Combat Round End report. report feedback information via. Speak String.
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
// Report
|
||||
SpeakString("[COMBAT ROUND END] [" + GetName(OBJECT_SELF) + "]");
|
||||
}
|
@@ -1,10 +0,0 @@
|
||||
// 0_onconver
|
||||
|
||||
// On Conversation report. report feedback information via. Speak String.
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
// Report
|
||||
SpeakString("[CONVERSATION]");
|
||||
}
|
@@ -1,17 +0,0 @@
|
||||
// 0_ondamaged
|
||||
|
||||
// On Damage report. report feedback information via. Speak String.
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
object oDamager = GetLastDamager(); // returns the object that last dealt damage to OBJECT_SELF, causing this event to fire.
|
||||
int nTotalDamage = GetTotalDamageDealt();// returns the amount of damage dealt to a creature (returns 0 when used in a Door's or Placeable Object's OnDamaged event).
|
||||
//int n = GetDamageDealtByType(int nDamageType);// returns the amount of damage dealt by particular attacks.
|
||||
int nCurHP = GetCurrentHitPoints(OBJECT_SELF);// can be used to return the current hit points of the caller.
|
||||
int nMaxHP = GetMaxHitPoints(OBJECT_SELF);// can be used to return the maximum hit points (and used with GetCurrentHitPoints(object oObject = OBJECT_SELF) for determining how threatened the creature is with death).
|
||||
|
||||
// Report
|
||||
SpeakString("[DAMAGED] [" + GetName(OBJECT_SELF) + "] By: " + GetName(oDamager) + ". Total: " + IntToString(nTotalDamage) +
|
||||
". Current HP: " + IntToString(nCurHP) + ". MaxHP: " + IntToString(nMaxHP));
|
||||
}
|
@@ -1,11 +0,0 @@
|
||||
// 0_ondeath
|
||||
// On Death report. report feedback information via. Speak String.
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
object oKiller = GetLastKiller();// returns the object that killed OBJECT_SELF.
|
||||
|
||||
// Report
|
||||
SpeakString("[KILLED] [" + GetName(OBJECT_SELF) + "] By: " + GetName(oKiller) + ".");
|
||||
}
|
@@ -1,15 +0,0 @@
|
||||
// 0_ondisturb
|
||||
|
||||
// On Disturbed report. report feedback information via. Speak String.
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
object oDisturber = GetLastDisturbed();// returns the object that last disturbed OBJECT_SELF.
|
||||
int nType = GetInventoryDisturbType();//returns one of the INVENTORY_DISTURB_TYPE_* constants to determine what occured.
|
||||
object oItem = GetInventoryDisturbItem();// returns the item that was either added or removed to the inventory of OBJECT_SELF.
|
||||
|
||||
// Report
|
||||
SpeakString("[DISTURBED] [" + GetName(OBJECT_SELF) + "] By: " + GetName(oDisturber) + ". Took: " + GetName(oItem) + ". Type: " + IntToString(nType));
|
||||
}
|
@@ -1,16 +0,0 @@
|
||||
// 0_onperception
|
||||
|
||||
// On Perception report. report feedback information via. Speak String.
|
||||
|
||||
void main()
|
||||
{
|
||||
object oPerceived = GetLastPerceived();// returns the last perceived creature (whether or not it was actually seen or heard).
|
||||
int bHeard = GetLastPerceptionHeard();// returns TRUE or FALSE as to whether the last perceived object was also heard.
|
||||
int bInaudible = GetLastPerceptionInaudible();// returns TRUE or FALSE as to whether or not the last perceived object has become inaudible (unable to be heard).
|
||||
int bSeen = GetLastPerceptionSeen();// returns TRUE or FALSE as to whether or not the last perceived object was seen.
|
||||
int bVanished = GetLastPerceptionVanished();// returns TRUE or FALSE as to whether or not the last perceived object can no longer be seen (invisible).
|
||||
|
||||
SpeakString("[PERCEPTION] [" + GetName(OBJECT_SELF) + "] Perceived: " + GetName(oPerceived) + ". bHeard: " + IntToString(bHeard) +
|
||||
". bInaudible: " + IntToString(bInaudible) + ". bSeen: " + IntToString(bSeen) +
|
||||
". bVanished: " + IntToString(bVanished));
|
||||
}
|
@@ -1,10 +0,0 @@
|
||||
// 0_onrested
|
||||
|
||||
// On Rested report. report feedback information via. Speak String.
|
||||
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
SpeakString("[RESTED] [" + GetName(OBJECT_SELF) + "] ");
|
||||
}
|
@@ -1,10 +0,0 @@
|
||||
// 0_onspawn
|
||||
|
||||
// On Spawn report. report feedback information via. Speak String.
|
||||
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
SpeakString("[SPAWN] [" + GetName(OBJECT_SELF) + "] ");
|
||||
}
|
@@ -1,14 +0,0 @@
|
||||
// 0_onspellcast
|
||||
|
||||
// On Spell Cast At report. report feedback information via. Speak String.
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
int nSpell = GetLastSpell();// returns the SPELL_* that was cast.
|
||||
object oCaster = GetLastSpellCaster();// returns the object that cast the spell.
|
||||
int bHarmful = GetLastSpellHarmful();// returns TRUE if the spell was marked as hostile, FALSE otherwise.
|
||||
|
||||
SpeakString("[SPELL CAST AT] [" + GetName(OBJECT_SELF) + "] Caster: " + GetName(oCaster) +
|
||||
". nSpell: " + IntToString(nSpell) + ". bHarmful: " + IntToString(bHarmful));
|
||||
}
|
@@ -1,40 +0,0 @@
|
||||
#include "phs_inc_visuals"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Fires set VFX
|
||||
int iVFX = GetLocalInt(OBJECT_SELF, "VFX");
|
||||
|
||||
if(iVFX > 0)
|
||||
{
|
||||
object oTarget = GetNearestObjectByTag("CombatDummy");
|
||||
|
||||
if(!GetIsObjectValid(oTarget)) return;
|
||||
|
||||
effect eVis;
|
||||
|
||||
if(iVFX == VFX_BEAM_DISINTEGRATE ||
|
||||
iVFX == VFX_BEAM_FLAME ||
|
||||
iVFX == VFX_BEAM_BLACK ||
|
||||
iVFX == VFX_BEAM_CHAIN ||
|
||||
iVFX == VFX_BEAM_COLD ||
|
||||
iVFX == VFX_BEAM_EVIL ||
|
||||
iVFX == VFX_BEAM_FIRE ||
|
||||
iVFX == VFX_BEAM_FIRE_LASH ||
|
||||
iVFX == VFX_BEAM_FIRE_W ||
|
||||
iVFX == VFX_BEAM_FIRE_W_SILENT ||
|
||||
iVFX == VFX_BEAM_HOLY ||
|
||||
iVFX == VFX_BEAM_LIGHTNING ||
|
||||
iVFX == VFX_BEAM_MIND ||
|
||||
iVFX == VFX_BEAM_ODD)
|
||||
{
|
||||
eVis = EffectBeam(iVFX, OBJECT_SELF, BODY_NODE_CHEST);
|
||||
}
|
||||
else
|
||||
{
|
||||
eVis = EffectVisualEffect(iVFX);
|
||||
}
|
||||
|
||||
ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eVis, oTarget, 12.0);
|
||||
}
|
||||
}
|
@@ -1,5 +0,0 @@
|
||||
void main()
|
||||
{
|
||||
SetListening(OBJECT_SELF, TRUE);
|
||||
SetListenPattern(OBJECT_SELF, "**", 0);
|
||||
}
|
@@ -1,18 +0,0 @@
|
||||
void main()
|
||||
{
|
||||
if(GetListenPatternNumber() == -1)
|
||||
{
|
||||
BeginConversation();
|
||||
}
|
||||
|
||||
if(GetListenPatternNumber() == 0 && GetIsPC(GetLastSpeaker()))
|
||||
{
|
||||
string sSpeak = GetMatchedSubstring(0);
|
||||
|
||||
SendMessageToPC(GetLastSpeaker(), "Said: " + sSpeak);
|
||||
|
||||
int iSpeak = StringToInt(sSpeak);
|
||||
|
||||
SetLocalInt(OBJECT_SELF, "VFX", iSpeak);
|
||||
}
|
||||
}
|
@@ -1,38 +0,0 @@
|
||||
void main()
|
||||
{
|
||||
// Display info about the target
|
||||
object oUser = GetItemActivator();
|
||||
object oTarget = GetItemActivatedTarget();
|
||||
string sInfo = "[INFO] [Of: " + GetName(oTarget);
|
||||
|
||||
// Get effects
|
||||
if(GetIsObjectValid(oTarget))
|
||||
{
|
||||
sInfo += "] [Tag: " + GetTag(oTarget);
|
||||
sInfo += "] [CurHP: " + IntToString(GetCurrentHitPoints(oTarget));
|
||||
sInfo += "] [MaxHP: " + IntToString(GetMaxHitPoints(oTarget));
|
||||
sInfo += "] [Reputation: " + IntToString(GetReputation(oTarget, oUser));
|
||||
sInfo += "] [Effects: ";
|
||||
|
||||
// Effects
|
||||
int nAmount = 0;
|
||||
effect eCheck = GetFirstEffect(oTarget);
|
||||
while(GetIsEffectValid(eCheck))
|
||||
{
|
||||
nAmount++;
|
||||
// Name creator, spell name and id, duration type, subtype and effect type.
|
||||
sInfo += "[" + IntToString(nAmount) + ". [Type:" + IntToString(GetEffectType(eCheck)) +
|
||||
"] [Id:" + IntToString(GetEffectSpellId(eCheck)) +
|
||||
"] [Name:" + GetStringByStrRef(StringToInt(Get2DAString("Spells", "Name", GetEffectSpellId(eCheck)))) +
|
||||
"] [Subtype:" + IntToString(GetEffectSubType(eCheck)) +
|
||||
"] [Duration:" + IntToString(GetEffectDurationType(eCheck)) + "]";
|
||||
eCheck = GetNextEffect(oTarget);
|
||||
}
|
||||
|
||||
sInfo += "]";
|
||||
}
|
||||
|
||||
// Say it
|
||||
AssignCommand(oUser, SpeakString(sInfo));
|
||||
|
||||
}
|
@@ -1,18 +0,0 @@
|
||||
void main()
|
||||
{
|
||||
SpeakString("CONVERSATION");
|
||||
|
||||
object oPC = GetLastSpeaker();
|
||||
|
||||
// Repeat the string said
|
||||
string sSaid = GetMatchedSubstring(0);
|
||||
|
||||
SpeakString("CONV. " + GetName(oPC) + " said: " + sSaid);
|
||||
|
||||
if(sSaid == "exit")
|
||||
{
|
||||
SpeakString("EXIT");
|
||||
SetPlotFlag(OBJECT_SELF, FALSE);
|
||||
DestroyObject(OBJECT_SELF);
|
||||
}
|
||||
}
|
@@ -1,19 +0,0 @@
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spawn in "genie"
|
||||
|
||||
SetListening(OBJECT_SELF, TRUE);
|
||||
SetListenPattern(OBJECT_SELF, "**", 0);
|
||||
|
||||
SetFacingPoint(GetPosition(GetFirstPC()));
|
||||
ActionSpeakString("You can speak your wish sir");// Never appers
|
||||
SendMessageToPC(GetFirstPC(), "Wish debug: Spawn");
|
||||
|
||||
effect eTime = EffectTimeStop();
|
||||
|
||||
// 4 seconds too long
|
||||
// 1 second too little, by a small margin.
|
||||
// 1.5 should be fine
|
||||
DelayCommand(1.5, ApplyEffectToObject(DURATION_TYPE_PERMANENT, eTime, OBJECT_SELF));
|
||||
}
|
@@ -1,34 +0,0 @@
|
||||
void WrapperDelayRemoval(float fDuration);
|
||||
void CheckAndRemove(int nSpellId, int nTimesCast, object oTarget);
|
||||
|
||||
void main() // This would be the spell script.
|
||||
{
|
||||
float fDuration = 4.0; // fDuration = the duration of the tempoary effect
|
||||
WrapperDelayRemoval(fDuration);// Put this at the end of all spell scripts with polymorph in
|
||||
}
|
||||
|
||||
void WrapperDelayRemoval(float fDuration)
|
||||
{
|
||||
int nSpell = GetSpellId();
|
||||
int nCastTimes = GetLocalInt(OBJECT_SELF, "TIMES_CAST" + IntToString(nSpell));
|
||||
nCastTimes++; // Add one to cast times
|
||||
SetLocalInt(OBJECT_SELF, "TIMES_CAST" + IntToString(nSpell), nCastTimes);
|
||||
DelayCommand(fDuration, CheckAndRemove(nSpell, nCastTimes, OBJECT_SELF));
|
||||
}
|
||||
|
||||
void CheckAndRemove(int nSpellId, int nTimesCast, object oTarget)
|
||||
{
|
||||
if(GetHasSpellEffect(nSpellId, oTarget) &&
|
||||
GetLocalInt(oTarget, "TIMES_CAST" + IntToString(nSpellId)) == nTimesCast)
|
||||
{
|
||||
effect eCheck = GetFirstEffect(oTarget);
|
||||
while(GetIsEffectValid(eCheck))
|
||||
{
|
||||
if(GetEffectSpellId(eCheck) == nSpellId)
|
||||
{
|
||||
RemoveEffect(oTarget, eCheck);
|
||||
}
|
||||
eCheck = GetNextEffect(oTarget);
|
||||
}
|
||||
}
|
||||
}
|
@@ -1,240 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Name Jasperre's 3 Level Puzzle script for tom23
|
||||
//:: FileName J_Levelpuzzle
|
||||
//:://////////////////////////////////////////////
|
||||
This will be put in 3 levers On Used events.
|
||||
|
||||
- Door, must be TAGGED as "JAS_3LEVERDOOR", exactly!
|
||||
|
||||
- Each plate (there are 3 you have to stand on in order) must be tagged
|
||||
seperatly:
|
||||
"JAS_3LEVER1"
|
||||
"JAS_3LEVER2"
|
||||
"JAS_3LEVER3"
|
||||
|
||||
How it works:
|
||||
|
||||
- Door can be in "LOCK_OPEN", TRUE or FALSe state. If TRUE, the levers
|
||||
do not work, because the door is open!
|
||||
- Door handles the total order via. strings. It hsa the "Randomise" pattern
|
||||
set as a string, 123, for example, while it has the order already done
|
||||
also set to a string, eg could be a partial: "32", and 1 would be the last
|
||||
to add.
|
||||
|
||||
- If the door has a randomise pattern, we will add our number to the list
|
||||
|
||||
- If the door hasn't got a randomise pattern (IE: Its been reset from
|
||||
completetion) then we make one, and add this as the first one said.
|
||||
|
||||
This does a special string whenever something happens to show something
|
||||
has happened.
|
||||
|
||||
WE ONLY RANDOMISE IF WE HAVE NOT BEEN COMPLETED ONCE, thus it will stay
|
||||
forever, for example, 312, until they have pressed 312.
|
||||
|
||||
Not too complicated really.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//:: Created On: 25 May
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
|
||||
// Set all the levers to "unpressed" and delete the order.
|
||||
void ResetLockStatus(object oDoor);
|
||||
|
||||
// Do small animation.
|
||||
// SpeakString(sSpeak) too.
|
||||
void DoAnimation(string sSpeak);
|
||||
|
||||
// Set this lock to have been pressed
|
||||
// If all have been done, it may open it too.
|
||||
void SetLockPressed(object oDoor, string sRandomSet, string sDoneAlready, string sLever);
|
||||
|
||||
// Randomise what order the locks have to be pressed
|
||||
void RandomiseLocks(object oDoor);
|
||||
|
||||
// Reset lock on this
|
||||
void DelayedLockResetDoor(object oDoor);
|
||||
// Assigned from DelayedLockResetDoor.
|
||||
void DoCloseSelf();
|
||||
|
||||
void main()
|
||||
{
|
||||
// Get what lever we are
|
||||
object oSelf = OBJECT_SELF;
|
||||
string sLever = GetStringRight(GetTag(oSelf), 1);
|
||||
object oDoor = GetObjectByTag("JAS_3LEVERDOOR");
|
||||
string sRandomSet = GetLocalString(oDoor, "JASP_RANDOM_LOCKNUMBER");
|
||||
string sDoneAlready = GetLocalString(oDoor, "JASP_LOCK_NUMBERS");
|
||||
|
||||
// Get the status - is the thing active. If the lock is NOT off, we
|
||||
// are OK.
|
||||
if(GetLocalInt(oDoor, "JASP_LOCK_OPEN") == FALSE)
|
||||
{
|
||||
// Check if we will reset because its been pressed once already
|
||||
if(FindSubString(sLever, sDoneAlready) >= 0)
|
||||
{
|
||||
// "We have been pressed, reset the puzzle"
|
||||
DoAnimation("*Wiiirrrr, chug chug chug*");
|
||||
// Reset the current set pattern
|
||||
DeleteLocalInt(oDoor, "JASP_LOCK_NUMBERS");
|
||||
}
|
||||
else
|
||||
{
|
||||
// We will now start, or simply add it to the done list
|
||||
if(sRandomSet == "")
|
||||
{
|
||||
// Not started, start it up
|
||||
RandomiseLocks(oDoor);
|
||||
SetLockPressed(oDoor, sRandomSet, "", sLever);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Else, do that we've done
|
||||
SetLockPressed(oDoor, sRandomSet, sDoneAlready, sLever);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// "Failed to do anything, its already open!"
|
||||
DoAnimation("*Wiirrr, clunk*");
|
||||
}
|
||||
}
|
||||
|
||||
// Set all the levers to "unpressed" and delete the order.
|
||||
void ResetLockStatus(object oDoor)
|
||||
{
|
||||
// Delete the locals for the door randomise and door already done strings
|
||||
DeleteLocalString(oDoor, "JASP_RANDOM_LOCKNUMBER");
|
||||
DeleteLocalString(oDoor, "JASP_LOCK_NUMBERS");
|
||||
}
|
||||
|
||||
// Do small animation.
|
||||
// SpeakString(sSpeak) too.
|
||||
void DoAnimation(string sSpeak)
|
||||
{
|
||||
SpeakString(sSpeak);
|
||||
PlayAnimation(ANIMATION_PLACEABLE_ACTIVATE);
|
||||
DelayCommand(1.5, PlayAnimation(ANIMATION_PLACEABLE_DEACTIVATE));
|
||||
}
|
||||
|
||||
// Set this lock to have been pressed
|
||||
// If all have been done, it may open it too.
|
||||
void SetLockPressed(object oDoor, string sRandomSet, string sDoneAlready, string sLever)
|
||||
{
|
||||
// We check if this is the last one
|
||||
if(GetStringLength(sDoneAlready) == 2)
|
||||
{
|
||||
// Add it, and check if we have completed the puzzle or should
|
||||
// just reset sDoneAlready
|
||||
sDoneAlready += sLever;
|
||||
|
||||
// check against sRandomSet
|
||||
if(sDoneAlready == sRandomSet)
|
||||
{
|
||||
// WOO! done it!
|
||||
// "Completed the puzzle!"
|
||||
DoAnimation("*Wiirrr, chi-ching!*");
|
||||
// Delete locked code too
|
||||
ResetLockStatus(oDoor);
|
||||
// Open the door
|
||||
SetLocalInt(oDoor, "JASP_LOCK_OPEN", TRUE);
|
||||
SetLocked(oDoor, TRUE);
|
||||
AssignCommand(oDoor, ActionOpenDoor(oDoor));
|
||||
// Delay closing
|
||||
DelayCommand(60.0, DelayedLockResetDoor(oDoor));
|
||||
}
|
||||
else
|
||||
{
|
||||
// Must have failed - DO NOT RESET LOCKS, just delete JASP_LOCK_NUMBERS
|
||||
DoAnimation("*Wiirrr, blonk!*");
|
||||
DeleteLocalInt(oDoor, "JASP_LOCK_NUMBERS");
|
||||
}
|
||||
}
|
||||
// Thus this just the first or second one
|
||||
else
|
||||
{
|
||||
// We know if its been pressed already. No more checks here
|
||||
|
||||
// Add the lever to exsisting string
|
||||
sDoneAlready += sLever;
|
||||
|
||||
// Set string to the door
|
||||
DoAnimation("*Wiirrr, clink clunk!*");
|
||||
SetLocalString(oDoor, "JASP_LOCK_NUMBERS", sDoneAlready);
|
||||
}
|
||||
}
|
||||
|
||||
// Randomise what order the locks have to be pressed
|
||||
void RandomiseLocks(object oDoor)
|
||||
{
|
||||
// Thanks to Olias for this. Yes, I can't be bothered
|
||||
// to even do it for something this simple myself.
|
||||
string sComplete;
|
||||
int nOne = d3();
|
||||
if(nOne == 1)
|
||||
{
|
||||
// First string "1"
|
||||
sComplete += "1";
|
||||
|
||||
if(d2() == 1)
|
||||
{
|
||||
// Second string "2", last "3"
|
||||
sComplete += "23";
|
||||
}
|
||||
else
|
||||
{
|
||||
// Second string "3", last "2"
|
||||
sComplete += "32";
|
||||
}
|
||||
}
|
||||
else if(nOne == 2)
|
||||
{
|
||||
// First string "2"
|
||||
sComplete += "2";
|
||||
|
||||
if(d2() == 1)
|
||||
{
|
||||
// Second string "1", last "3"
|
||||
sComplete += "13";
|
||||
}
|
||||
else
|
||||
{
|
||||
// Second string "3", last "1"
|
||||
sComplete += "31";
|
||||
}
|
||||
}
|
||||
else// if(nOne == 3)
|
||||
{
|
||||
// First string "3"
|
||||
sComplete += "3";
|
||||
|
||||
if(d2() == 1)
|
||||
{
|
||||
// Second string "1", last "2"
|
||||
sComplete += "12";
|
||||
}
|
||||
else
|
||||
{
|
||||
// Second string "2", last "1"
|
||||
sComplete += "21";
|
||||
}
|
||||
}
|
||||
// Randomise and set to the string JASP_RANDOM_LOCKNUMBER, on oDoor,
|
||||
// a combination of sComplete (123, 132, etc).
|
||||
SetLocalString(oDoor, "JASP_RANDOM_LOCKNUMBER", sComplete);
|
||||
}
|
||||
|
||||
// Reset lock on this
|
||||
void DelayedLockResetDoor(object oDoor)
|
||||
{
|
||||
SetLocalInt(oDoor, "JASP_LOCK_OPEN", FALSE);
|
||||
AssignCommand(oDoor, DoCloseSelf());
|
||||
}
|
||||
// Assigned from DelayedLockResetDoor.
|
||||
void DoCloseSelf()
|
||||
{
|
||||
ActionCloseDoor(OBJECT_SELF);
|
||||
SetLocked(OBJECT_SELF, TRUE);
|
||||
}
|
@@ -1,138 +0,0 @@
|
||||
// NO LONGER USED. HERE INCASE I NEED IT. 2 SCRIPTS.
|
||||
|
||||
void main(){return;}
|
||||
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Cloudkill - Create second ETC ones.
|
||||
//:: Spell FileName phs_cloudkilly
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Creates the first AOE when the creature created is created. This then will
|
||||
jump to new locations 3.3 M away from the starting location (increments
|
||||
thereof) and then destroy itself after the duration.
|
||||
|
||||
This is the "Heartbeat round file" of the creature.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//:://///////////////////////////////////////////
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
// Does exactly what is says on the tin
|
||||
void DestroySelf();
|
||||
|
||||
void main()
|
||||
{
|
||||
// Create first instance by Executing a Script on the caster, if valid
|
||||
object oCaster = GetLocalObject(OBJECT_SELF, PHS_CLOUDKILL_CASTER);
|
||||
// Get original location
|
||||
location lOriginal = GetLocalLocation(OBJECT_SELF, PHS_CLOUDKILL_LOCATION);
|
||||
|
||||
if(GetIsObjectValid(oCaster))
|
||||
{
|
||||
// Get new location for X rounds done
|
||||
int iLastRounds = GetLocalInt(OBJECT_SELF, PHS_CLOUDKILL_ROUNDS_DONE);
|
||||
|
||||
// Check if the duration is up to the rounds limit
|
||||
if(iLastRounds <= GetLocalInt(OBJECT_SELF, PHS_CLOUDKILL_DURATION))
|
||||
{
|
||||
// Increment
|
||||
iLastRounds++;
|
||||
// Get location based on this
|
||||
float fFromOriginal = iLastRounds * 3.33;
|
||||
|
||||
// New location
|
||||
location lMove = PHS_GetLocationBehindLocation(lOriginal, GetLocation(oCaster), fFromOriginal);
|
||||
|
||||
// Move me
|
||||
ClearAllActions();
|
||||
JumpToLocation(lMove);
|
||||
|
||||
// New effect for 6 seconds
|
||||
// - apply at lOriginal
|
||||
effect eFog = EffectAreaOfEffect(AOE_PER_FOGKILL, "phs_s_cloudkilla", "****", "****");
|
||||
ApplyEffectAtLocation(DURATION_TYPE_TEMPORARY, eFog, GetLocation(OBJECT_SELF), 6.0);
|
||||
|
||||
// 6 second "Pesudo-heartbeat" heartbeat
|
||||
DelayCommand(6.0, ExecuteScript("phs_cloudkilly", OBJECT_SELF));
|
||||
}
|
||||
else
|
||||
{
|
||||
// Stop the script
|
||||
return;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
DestroySelf();
|
||||
}
|
||||
}
|
||||
|
||||
void DestroySelf()
|
||||
{
|
||||
SetPlotFlag(OBJECT_SELF, FALSE);
|
||||
DestroyObject(OBJECT_SELF);
|
||||
}
|
||||
|
||||
:://////////////////////////////////////////////
|
||||
//:: Spell Name Cloudkill - Create First AOE
|
||||
//:: Spell FileName phs_cloudkillx
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Creates the first AOE when the creature created is created. This then will
|
||||
jump to new locations 3.3 M away from the starting location (increments
|
||||
thereof) and then destroy itself after the duration.
|
||||
|
||||
This is the "Spawn file" of the creature.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//:://///////////////////////////////////////////
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
// Does exactly what is says on the tin
|
||||
void DestroySelf();
|
||||
|
||||
void main()
|
||||
{
|
||||
// Apply Ghost as starting one
|
||||
// Ghost
|
||||
effect eGhost = EffectCutsceneGhost();
|
||||
// No dispel
|
||||
eGhost = SupernaturalEffect(eGhost);
|
||||
// Apply effects
|
||||
ApplyEffectToObject(DURATION_TYPE_PERMANENT, eGhost, OBJECT_SELF);
|
||||
|
||||
// Create first instance by Executing a Script on the caster, if valid
|
||||
object oCaster = GetLocalObject(OBJECT_SELF, PHS_CLOUDKILL_CASTER);
|
||||
// Get original location
|
||||
location lOriginal = GetLocalLocation(OBJECT_SELF, PHS_CLOUDKILL_LOCATION);
|
||||
|
||||
if(GetIsObjectValid(oCaster))
|
||||
{
|
||||
// Move me
|
||||
ClearAllActions();
|
||||
JumpToLocation(lOriginal);
|
||||
|
||||
// New effect for 6 seconds
|
||||
// - apply at lOriginal
|
||||
effect eFog = EffectAreaOfEffect(AOE_PER_FOGKILL, "phs_s_cloudkilla", "****", "****");
|
||||
ApplyEffectAtLocation(DURATION_TYPE_TEMPORARY, eFog, GetLocation(OBJECT_SELF), 6.0);
|
||||
|
||||
// 6 second "Pesudo-heartbeat" heartbeat
|
||||
DelayCommand(6.0, ExecuteScript("phs_cloudkilly", OBJECT_SELF));
|
||||
}
|
||||
else
|
||||
{
|
||||
DestroySelf();
|
||||
}
|
||||
}
|
||||
|
||||
void DestroySelf()
|
||||
{
|
||||
SetPlotFlag(OBJECT_SELF, FALSE);
|
||||
DestroyObject(OBJECT_SELF);
|
||||
}
|
||||
*/
|
@@ -1,36 +0,0 @@
|
||||
void main()
|
||||
{
|
||||
// walks to the nearest waypoint ,if we are not already walking
|
||||
object oWP1 = GetWaypointByTag("MOVETO1");
|
||||
object oWP2 = GetWaypointByTag("MOVETO2");
|
||||
int nAction = GetCurrentAction();
|
||||
int nCommand = GetCommandable();
|
||||
|
||||
// Get if we are moving
|
||||
if(nAction == ACTION_MOVETOPOINT)
|
||||
{
|
||||
SpeakString("Cannot do new move, we are moving [Action] " + IntToString(nAction) + " [Command] " + IntToString(nCommand));
|
||||
}
|
||||
else if(nCommand == FALSE)
|
||||
{
|
||||
SpeakString("Cannot do new move, uncommandable [Action] " + IntToString(nAction) + " [Command] " + IntToString(nCommand));
|
||||
}
|
||||
else
|
||||
{
|
||||
// Check distance
|
||||
if(GetDistanceToObject(oWP1) <= 1.5)
|
||||
{
|
||||
// Go to 2.
|
||||
ClearAllActions();
|
||||
SpeakString("Moving to waypoint 2 [Action] " + IntToString(nAction) + " [Command] " + IntToString(nCommand));
|
||||
ActionMoveToLocation(GetLocation(oWP2), FALSE);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Else, go to 1
|
||||
ClearAllActions();
|
||||
SpeakString("Moving to waypoint 1 [Action] " + IntToString(nAction) + " [Command] " + IntToString(nCommand));
|
||||
ActionMoveToLocation(GetLocation(oWP1), FALSE);
|
||||
}
|
||||
}
|
||||
}
|
@@ -1,14 +0,0 @@
|
||||
|
||||
void main()
|
||||
{
|
||||
/*
|
||||
// Make sure they are not immune to spells
|
||||
!PHS_TotalSpellImmunity(oTarget))
|
||||
// Make sure they are not immune to spells
|
||||
if(PHS_TotalSpellImmunity(oTarget)) return;
|
||||
|
||||
// Signal Spell cast at
|
||||
PHS_SignalSpellCastAt(oTarget, SPELL_INVALID);
|
||||
|
||||
*/
|
||||
}
|
@@ -1,154 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Name Jasperre's 3 Level Puzzle script for tom23
|
||||
//:: FileName J_Levelpuzzle
|
||||
//:://////////////////////////////////////////////
|
||||
This will be put in 3 levers On Used events.
|
||||
|
||||
- Door, must be TAGGED as "JAS_3LEVERDOOR", exactly!
|
||||
|
||||
- Each plate (there are 3 you have to stand on in order) must be tagged
|
||||
seperatly:
|
||||
"JAS_3LEVER1"
|
||||
"JAS_3LEVER2"
|
||||
"JAS_3LEVER3"
|
||||
|
||||
How it works:
|
||||
|
||||
- Door can be in "LOCK_OPEN", TRUE or FALSe state. If TRUE, the levers
|
||||
do not work, because the door is open!
|
||||
- Door handles the total order via. strings. It hsa the "Randomise" pattern
|
||||
set as a string, 123, for example, while it has the order already done
|
||||
also set to a string, eg could be a partial: "32", and 1 would be the last
|
||||
to add.
|
||||
|
||||
- If the door has a randomise pattern, we will add our number to the list
|
||||
|
||||
- If the door hasn't got a randomise pattern (IE: Its been reset from
|
||||
completetion) then we make one, and add this as the first one said.
|
||||
|
||||
This does a special string whenever something happens to show something
|
||||
has happened.
|
||||
|
||||
WE ONLY RANDOMISE IF WE HAVE NOT BEEN COMPLETED ONCE, thus it will stay
|
||||
forever, for example, 312, until they have pressed 312.
|
||||
|
||||
Not too complicated really.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//:: Created On: 25 May
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
const int CONST_LEVER_COUNT = 3;
|
||||
|
||||
// Do small animation.
|
||||
// SpeakString(sSpeak) too.
|
||||
void DoAnimation(string sSpeak);
|
||||
|
||||
// Reset lock on this
|
||||
void DelayedLockResetDoor(object oDoor);
|
||||
// Assigned from DelayedLockResetDoor.
|
||||
void DoCloseSelf();
|
||||
|
||||
void main()
|
||||
{
|
||||
// Get what lever we are
|
||||
object oSelf = OBJECT_SELF;
|
||||
string sLever = GetStringRight(GetTag(oSelf), 1);
|
||||
object oDoor = GetObjectByTag("JAS_3LEVERDOOR");
|
||||
int nPulled = GetLocalInt(oDoor, "JASP_PULLED_COUNT");
|
||||
|
||||
// Get the status - is the thing active. If the lock is NOT off, we
|
||||
// are OK.
|
||||
if(GetLocalInt(oDoor, "JASP_LOCK_OPEN") == FALSE)
|
||||
{
|
||||
// Check if we will reset because its been pressed once already
|
||||
if(GetLocalInt(oDoor, "JASP_LEVERDONE_" + sLever) == TRUE)
|
||||
{
|
||||
// "We have been pressed, reset the puzzle"
|
||||
DoAnimation("*Wiiirrrr, chug chug chug*");
|
||||
// Reset the current set pattern
|
||||
DeleteLocalInt(oDoor, "JASP_LOCK_NUMBERS");
|
||||
}
|
||||
else
|
||||
{
|
||||
// We will now start, or simply add it to the done list
|
||||
if(Random(CONST_LEVER_COUNT - nPulled) == 0)
|
||||
{
|
||||
// Correct lever
|
||||
nPulled++;
|
||||
SetLocalInt(oDoor, "JASP_PULLED_COUNT", nPulled);
|
||||
|
||||
// Combination Successful
|
||||
if(nPulled == CONST_LEVER_COUNT)
|
||||
{
|
||||
// DONE:
|
||||
|
||||
// Reset levers done
|
||||
int nCnt;
|
||||
for(nCnt = 1; nCnt <= 3; nCnt++)
|
||||
{
|
||||
DeleteLocalInt(oDoor, "JASP_LEVERDONE_" + IntToString(nCnt));
|
||||
}
|
||||
DeleteLocalInt(oDoor, "JASP_PULLED_COUNT");
|
||||
|
||||
// Open door
|
||||
// WOO! done it!
|
||||
// "Completed the puzzle!"
|
||||
DoAnimation("*Wiirrr, chi-ching!*");
|
||||
|
||||
// Open the door
|
||||
SetLocalInt(oDoor, "JASP_LOCK_OPEN", TRUE);
|
||||
SetLocked(oDoor, TRUE);
|
||||
AssignCommand(oDoor, ActionOpenDoor(oDoor));
|
||||
// Delay closing
|
||||
DelayCommand(60.0, DelayedLockResetDoor(oDoor));
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Incorrect lever, duh-duh-duh, duuuuhhhh
|
||||
// Just clank away, and leave the variables
|
||||
DoAnimation("*Wiirrr, clink clunk!*");
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// "Failed to do anything, its already open!"
|
||||
DoAnimation("*Wiirrr, clunk*");
|
||||
}
|
||||
}
|
||||
|
||||
// Do small animation.
|
||||
// SpeakString(sSpeak) too.
|
||||
void DoAnimation(string sSpeak)
|
||||
{
|
||||
SpeakString(sSpeak);
|
||||
PlayAnimation(ANIMATION_PLACEABLE_ACTIVATE);
|
||||
DelayCommand(1.5, PlayAnimation(ANIMATION_PLACEABLE_DEACTIVATE));
|
||||
}
|
||||
|
||||
// Randomise what order the locks have to be pressed
|
||||
void RandomiseLocks(object oDoor)
|
||||
{
|
||||
// Reset levers done
|
||||
int nCnt;
|
||||
for(nCnt = 1; nCnt <= 3; nCnt++)
|
||||
{
|
||||
DeleteLocalInt(oDoor, "JASP_LEVERDONE_" + IntToString(nCnt));
|
||||
}
|
||||
DeleteLocalInt(oDoor, "JASP_PULLED_COUNT");
|
||||
}
|
||||
|
||||
// Reset lock on this
|
||||
void DelayedLockResetDoor(object oDoor)
|
||||
{
|
||||
SetLocalInt(oDoor, "JASP_LOCK_OPEN", FALSE);
|
||||
AssignCommand(oDoor, DoCloseSelf());
|
||||
}
|
||||
// Assigned from DelayedLockResetDoor.
|
||||
void DoCloseSelf()
|
||||
{
|
||||
ActionCloseDoor(OBJECT_SELF);
|
||||
SetLocked(OBJECT_SELF, TRUE);
|
||||
}
|
@@ -1,43 +0,0 @@
|
||||
// In this code, we will say wether the item aquired was on a logon
|
||||
// attempt, a normal addition, or a relog.
|
||||
// The OnItemAquire event would use this.
|
||||
|
||||
void main()
|
||||
{
|
||||
// Get item aquired
|
||||
object oItem = GetModuleItemAcquired();
|
||||
// Who by?
|
||||
object oPC = GetModuleItemAcquiredBy();
|
||||
object oPC2 = GetItemPossessor(oItem);
|
||||
|
||||
// Who was it taken from?
|
||||
object oLostBy = GetModuleItemAcquiredFrom();
|
||||
|
||||
// If oLostBy is invalid, we must have logged in - we are not
|
||||
// taking this from anyone
|
||||
if(!GetIsObjectValid(oLostBy) || oLostBy == oPC2)
|
||||
{
|
||||
// Is it a relog in or not?
|
||||
// It will be if oPC is invalid
|
||||
if(!GetIsObjectValid(oPC))
|
||||
{
|
||||
// It is a relog, we can use oPC2 as the person who
|
||||
// reloged in with this item to send the message to.
|
||||
SendMessageToPC(oPC2, "You have relogged in carrying the item: " + GetName(oItem));
|
||||
}
|
||||
else
|
||||
{
|
||||
// Not a relog, a normal login, we can use oPC to send
|
||||
// a message to.
|
||||
// * Note: oPC2 is always valid to use
|
||||
SendMessageToPC(oPC, "You just logged in, carrying the item: " + GetName(oItem));
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// This fires when it is a normal case of the event
|
||||
// and so oPC can be used to send the message.
|
||||
// * Note: oPC2 is always valid to use
|
||||
SendMessageToPC(oPC, "You have aquired the item: " + GetName(oItem));
|
||||
}
|
||||
}
|
@@ -1,65 +0,0 @@
|
||||
/* Script generated by
|
||||
Lilac Soul's NWN Script Generator, v. 1.6
|
||||
|
||||
For download info, please visit:
|
||||
http://www.lilacsoul.revility.com */
|
||||
|
||||
//Put this on action taken in the conversation editor
|
||||
|
||||
// Moves oPC to "dst_zarni_cut3", out of the area, and resets thier cutscene mode
|
||||
// status.
|
||||
void MovePC(object oPC);
|
||||
|
||||
void main()
|
||||
{
|
||||
//Introducing the cast, player and Zarniwoop
|
||||
object oPC = GetPCSpeaker();
|
||||
object oNPC = OBJECT_SELF;
|
||||
|
||||
//Making sure nobody is doing anything
|
||||
AssignCommand(oPC, ClearAllActions());
|
||||
AssignCommand(oNPC, ClearAllActions());
|
||||
|
||||
// Set the PC into cutscene mode
|
||||
SetCutsceneMode(oPC, TRUE);
|
||||
|
||||
//Take your positions
|
||||
AssignCommand(oPC, ActionMoveToObject(GetWaypointByTag("dst_zarni_cut1"), FALSE, 0.0));
|
||||
AssignCommand(oPC, SetFacing(GetFacing(GetWaypointByTag("dst_zarni_cut1"))));
|
||||
|
||||
AssignCommand(oNPC, ActionMoveToObject(GetWaypointByTag("dst_zarni_cut2"), FALSE, 0.0));
|
||||
AssignCommand(oNPC, SetFacing(GetFacing(GetWaypointByTag("dst_zarni_cut2"))));
|
||||
|
||||
//DebugMessage
|
||||
//AssignCommand(oNPC, SpeakString("Adams will sue me for this!"));
|
||||
|
||||
//Jumping to the unknown
|
||||
DelayCommand(6.0, MovePC(oPC));
|
||||
}
|
||||
|
||||
// Moves oPC to "dst_zarni_cut3", out of the area, and resets thier cutscene mode
|
||||
// status.
|
||||
void MovePC(object oPC)
|
||||
{
|
||||
// Define some stuff
|
||||
object oMoveTo = GetWaypointByTag("dst_zarni_cut3");
|
||||
location lTarget = GetLocation(oMoveTo);
|
||||
effect eVis = EffectVisualEffect(VFX_IMP_UNSUMMON);
|
||||
|
||||
// Apply the visual
|
||||
ApplyEffectAtLocation(DURATION_TYPE_INSTANT, eVis, GetLocation(oPC));
|
||||
|
||||
// move them to the waypoint (and turn off cutscene mode)
|
||||
if(GetCommandable(oPC))
|
||||
{
|
||||
AssignCommand(oPC, JumpToLocation(lTarget));
|
||||
DelayCommand(1.0, SetCutsceneMode(oPC, FALSE));
|
||||
}
|
||||
else
|
||||
{
|
||||
SetCommandable(TRUE, oPC);
|
||||
AssignCommand(oPC, JumpToLocation(lTarget));
|
||||
SetCommandable(FALSE, oPC);
|
||||
DelayCommand(1.0, SetCutsceneMode(oPC, FALSE));
|
||||
}
|
||||
}
|
@@ -1,35 +0,0 @@
|
||||
void Debug(string sString)
|
||||
{
|
||||
SendMessageToPC(GetFirstPC(), sString);
|
||||
}
|
||||
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
object oMaster = GetMaster();
|
||||
// heartbeat of summon
|
||||
Debug("Heartbeat script Id: " + ObjectToString(OBJECT_SELF) + ". Name: " + GetName(OBJECT_SELF) + ". Tag: " + GetTag(OBJECT_SELF) + ". ResRef: " + GetResRef(OBJECT_SELF));
|
||||
|
||||
// Debug properties
|
||||
Debug("Master: " + GetName(oMaster));
|
||||
|
||||
Debug("Effects Debug");
|
||||
|
||||
effect eCheck = GetFirstEffect(OBJECT_SELF);
|
||||
while(GetIsEffectValid(eCheck))
|
||||
{
|
||||
Debug("Effect: " + IntToString(GetEffectType(eCheck)) + ". Creator: " + GetName(GetEffectCreator(eCheck)) + ".");
|
||||
|
||||
eCheck = GetNextEffect(OBJECT_SELF);
|
||||
}
|
||||
|
||||
// Master effects
|
||||
eCheck = GetFirstEffect(oMaster);
|
||||
while(GetIsEffectValid(eCheck))
|
||||
{
|
||||
Debug("Effect: " + IntToString(GetEffectType(eCheck)) + ". Creator: " + GetName(GetEffectCreator(eCheck)) + ".");
|
||||
|
||||
eCheck = GetNextEffect(oMaster);
|
||||
}
|
||||
}
|
@@ -1,34 +0,0 @@
|
||||
void Debug(string sString)
|
||||
{
|
||||
SendMessageToPC(GetFirstPC(), sString);
|
||||
}
|
||||
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
object oMaster = GetMaster();
|
||||
// death of summon
|
||||
Debug("Death! (Id: " + ObjectToString(OBJECT_SELF) + ". Name: " + GetName(OBJECT_SELF) + ". Tag: " + GetTag(OBJECT_SELF) + ". ResRef: " + GetResRef(OBJECT_SELF));
|
||||
|
||||
// Debug properties
|
||||
Debug("Master: " + GetName(oMaster));
|
||||
|
||||
Debug("Effects Debug");
|
||||
|
||||
effect eCheck = GetFirstEffect(OBJECT_SELF);
|
||||
while(GetIsEffectValid(eCheck))
|
||||
{
|
||||
Debug("Effect: " + IntToString(GetEffectType(eCheck)) + ". Creator: " + GetName(GetEffectCreator(eCheck)) + ".");
|
||||
|
||||
eCheck = GetNextEffect(OBJECT_SELF);
|
||||
}
|
||||
|
||||
// Master effects
|
||||
eCheck = GetFirstEffect(oMaster);
|
||||
while(GetIsEffectValid(eCheck))
|
||||
{
|
||||
Debug("Effect: " + IntToString(GetEffectType(eCheck)) + ". Creator: " + GetName(GetEffectCreator(eCheck)) + ".");
|
||||
|
||||
eCheck = GetNextEffect(oMaster);
|
||||
}}
|
@@ -1,41 +0,0 @@
|
||||
void Debug(string sString)
|
||||
{
|
||||
SendMessageToPC(GetFirstPC(), sString);
|
||||
}
|
||||
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
object oMaster = GetMaster();
|
||||
// Spawn of summon
|
||||
Debug("Spawn Script: Spawned (My Name: " + GetName(OBJECT_SELF) + ". Tag: " + GetTag(OBJECT_SELF) + ". ResRef: " + GetResRef(OBJECT_SELF));
|
||||
|
||||
SetIsDestroyable(FALSE);
|
||||
DelayCommand(0.01, SetIsDestroyable(TRUE));
|
||||
|
||||
// Debug properties
|
||||
Debug("Master: " + GetName(oMaster));
|
||||
Debug("My 'Type of companion': " + IntToString(GetAssociateType(OBJECT_SELF)));
|
||||
|
||||
|
||||
Debug("Effects Debug");
|
||||
|
||||
effect eCheck = GetFirstEffect(OBJECT_SELF);
|
||||
while(GetIsEffectValid(eCheck))
|
||||
{
|
||||
Debug("Effect: " + IntToString(GetEffectType(eCheck)) + ". Creator: " + GetName(GetEffectCreator(eCheck)) + ".");
|
||||
|
||||
eCheck = GetNextEffect(OBJECT_SELF);
|
||||
}
|
||||
|
||||
// Master effects
|
||||
eCheck = GetFirstEffect(oMaster);
|
||||
while(GetIsEffectValid(eCheck))
|
||||
{
|
||||
Debug("Effect: " + IntToString(GetEffectType(eCheck)) + ". Creator: " + GetName(GetEffectCreator(eCheck)) + ".");
|
||||
|
||||
eCheck = GetNextEffect(oMaster);
|
||||
}
|
||||
|
||||
}
|
Binary file not shown.
@@ -1,40 +0,0 @@
|
||||
//::///////////////////////////////////////////////
|
||||
//:: Fireball
|
||||
//:: NW_S0_Fireball
|
||||
//:: Copyright (c) 2001 Bioware Corp.
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
// Testing summoning spell
|
||||
|
||||
|
||||
void main()
|
||||
{
|
||||
// Create summon effect
|
||||
string sResRef = "phs_kobold";
|
||||
string sResRef2 = "phs_balor";
|
||||
effect eSummon = EffectSummonCreature(sResRef, VFX_FNF_SUMMON_MONSTER_1);
|
||||
effect eSummon2 = EffectSummonCreature(sResRef2, VFX_FNF_SUMMON_MONSTER_2);
|
||||
effect eLink = EffectLinkEffects(eSummon, eSummon2);
|
||||
location lTarget = GetSpellTargetLocation();
|
||||
|
||||
SpeakString("Summoning monster: Kobold");
|
||||
|
||||
// Set the associates (summons) to destroyable: FALSE for a sec.
|
||||
int nCnt = 1;
|
||||
object oAssociate = GetAssociate(ASSOCIATE_TYPE_SUMMONED, OBJECT_SELF, nCnt);
|
||||
while(GetIsObjectValid(oAssociate))
|
||||
{
|
||||
SpeakString("Summon: " + GetName(oAssociate) + ". changing to destroyable");
|
||||
AssignCommand(oAssociate, SetIsDestroyable(FALSE));
|
||||
DelayCommand(0.1, AssignCommand(oAssociate, SetIsDestroyable(TRUE)));
|
||||
nCnt++;
|
||||
oAssociate = GetAssociate(ASSOCIATE_TYPE_SUMMONED, OBJECT_SELF, nCnt);
|
||||
}
|
||||
// Apply it for 10 minutes
|
||||
ApplyEffectAtLocation(DURATION_TYPE_TEMPORARY, eLink, lTarget, TurnsToSeconds(10));
|
||||
|
||||
// Apply it for 10 minutes
|
||||
//ApplyEffectAtLocation(DURATION_TYPE_TEMPORARY, eSummon, lTarget, TurnsToSeconds(10));
|
||||
// 2 of them - Apply it for 10 minutes
|
||||
//ApplyEffectAtLocation(DURATION_TYPE_TEMPORARY, eSummon2, lTarget, TurnsToSeconds(10));
|
||||
}
|
@@ -1,74 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Invisibility, Greater
|
||||
//:: Spell FileName PHS_S_InvisGreat
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Illusion (Glamer)
|
||||
Level: Brd 4, Sor/Wiz 4
|
||||
Components: V, S
|
||||
Casting Time: 1 standard action
|
||||
Range: Personal or touch
|
||||
Target: You or creature touched
|
||||
Duration: 1 round/level (D)
|
||||
Saving Throw: Will negates (harmless)
|
||||
Spell Resistance: Yes (harmless)
|
||||
|
||||
This spell functions like invisibility, except that it doesn<73>t end if the
|
||||
subject attacks.
|
||||
|
||||
Arcane Material Component: An eyelash encased in a bit of gum arabic.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Only difference to invisiblity is the 1 round/level, and that we
|
||||
are attempting to use the
|
||||
|
||||
INVISIBILITY_TYPE_IMPROVED
|
||||
|
||||
Constant to see if it won't get removed when they attack.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell hook check.
|
||||
if(!PHS_SpellHookCheck(PHS_SPELL_INVISIBILITY_GREATER)) return;
|
||||
|
||||
// Declare Major Variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject();
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
|
||||
// Make sure they are not immune to spells
|
||||
if(PHS_TotalSpellImmunity(oTarget)) return;
|
||||
|
||||
// Determine duration in rounds
|
||||
float fDuration = PHS_GetDuration(PHS_ROUNDS, nCasterLevel, nMetaMagic);
|
||||
|
||||
// Declare effects
|
||||
effect eInvisibility = EffectInvisibility(INVISIBILITY_TYPE_IMPROVED);
|
||||
effect eCessate = EffectVisualEffect(VFX_DUR_CESSATE_POSITIVE);
|
||||
|
||||
// Link effects
|
||||
effect eLink = EffectLinkEffects(eInvisibility, eCessate);
|
||||
|
||||
// Remove pervious castings of it
|
||||
PHS_RemoveSpellEffectsFromTarget(PHS_SPELL_INVISIBILITY_GREATER, oTarget);
|
||||
|
||||
// Fire cast spell at event for the specified target
|
||||
PHS_SignalSpellCastAt(oTarget, PHS_SPELL_INVISIBILITY_GREATER, FALSE);
|
||||
|
||||
// Report effects
|
||||
PHS_DebugReportEffects(oTarget);
|
||||
|
||||
// Apply VNF and effect.
|
||||
PHS_ApplyDuration(oTarget, eLink, fDuration);
|
||||
|
||||
// Report effects
|
||||
PHS_DebugReportEffects(oTarget);
|
||||
}
|
@@ -1 +0,0 @@
|
||||
// Empty used for testing
|
@@ -1,53 +0,0 @@
|
||||
//::///////////////////////////////////////////////
|
||||
// Tests:
|
||||
// - Paralysis: Non-commandable is TRUE, so cannot even use Verbal spells (urg)
|
||||
// - EffectCutsceneImmobilize() - Commandable, but cannot move at all, can cast.
|
||||
// - EffectCutsceneParalyze() - Bypasses normal palarysis immunities. No icon. Not commandable.
|
||||
// - reports :"you cannot speak, cannot cast spells with verbal components" - a boo boo
|
||||
// -
|
||||
|
||||
// ActionMoveXXX will not work in Entangle, Paralsis, Immobilize, and therefore
|
||||
// pushback (which is logical in entanglements case) will not work.
|
||||
|
||||
|
||||
void Send(string sMessage, object oTarget);
|
||||
void Report(object oTarget);
|
||||
|
||||
void main()
|
||||
{
|
||||
// Effect
|
||||
effect eApply = EffectDispelMagicAll(10);
|
||||
|
||||
// Get target
|
||||
object oTarget = GetSpellTargetObject();
|
||||
|
||||
// Message
|
||||
Send("EffectDispelMagicAll(10)", oTarget);
|
||||
|
||||
ApplyEffectToObject(DURATION_TYPE_INSTANT, eApply, oTarget, 30.0);
|
||||
|
||||
// Delay a report
|
||||
DelayCommand(10.0, Report(oTarget));
|
||||
}
|
||||
|
||||
void Send(string sMessage, object oTarget)
|
||||
{
|
||||
if(oTarget != OBJECT_SELF) SendMessageToPC(OBJECT_SELF, sMessage);
|
||||
SendMessageToPC(oTarget, sMessage);
|
||||
}
|
||||
|
||||
void Report(object oTarget)
|
||||
{
|
||||
int bCommandable = GetCommandable(oTarget);
|
||||
int bPlot = GetPlotFlag(oTarget);
|
||||
int bDead = GetIsDead(oTarget);
|
||||
|
||||
string sMessage = "STATUS: " + GetName(oTarget) + "| COM: " + IntToString(bCommandable) + "| PLOT: " + IntToString(bPlot) + "| DEAD: " + IntToString(bDead) + "|";
|
||||
|
||||
SendMessageToPC(oTarget, sMessage);
|
||||
|
||||
if(oTarget != OBJECT_SELF)
|
||||
{
|
||||
SendMessageToPC(OBJECT_SELF, sMessage);
|
||||
}
|
||||
}
|
@@ -1,41 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
|
||||
Test for:
|
||||
|
||||
Wish, Timestop, and stuff like that...
|
||||
1. Can you have a timestop conversation
|
||||
2. Can you use stun with timestop.
|
||||
etc.
|
||||
|
||||
|
||||
If linked damage, in a tempoary effect, will actually apply the linked effects
|
||||
if the damage is made out to be 0 somehow. (most likely yes)
|
||||
(it will apply the effects, tested with stoneskin)
|
||||
|
||||
Old ones:
|
||||
|
||||
If invisibility + Link effects will remove all linked efffects when invis goes
|
||||
(it does)
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
void main()
|
||||
{
|
||||
// Declare Major Variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = oCaster;
|
||||
|
||||
// Create the genie
|
||||
object oGenie = CreateObject(OBJECT_TYPE_CREATURE, "wish_test", GetLocation(oCaster));
|
||||
|
||||
//AssignCommand(oGenie, ActionStartConversation(oCaster, "", TRUE));
|
||||
//ActionStartConversation(oCaster, "test_wish", TRUE);
|
||||
|
||||
// Apply timestop
|
||||
//effect eTime = EffectTimeStop();
|
||||
|
||||
//SpeakString("Appling Time Stop and creating creature (1.5 delay), to " + GetName(oTarget));
|
||||
|
||||
// Apply cutscene stuff to the PC
|
||||
//AssignCommand(oTarget, ClearAllActions());
|
||||
//SetCutsceneMode(oTarget, TRUE);
|
||||
}
|
@@ -1,27 +0,0 @@
|
||||
//::///////////////////////////////////////////////
|
||||
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Apply some paralsis to the target
|
||||
object oTarget = GetSpellTargetObject();
|
||||
|
||||
// Declare Effects
|
||||
effect eParalyze = EffectParalyze();
|
||||
effect eDur1 = EffectVisualEffect(VFX_DUR_PARALYZED);
|
||||
effect eDur2 = EffectVisualEffect(VFX_DUR_PARALYZE_HOLD);
|
||||
effect eCessate = EffectVisualEffect(VFX_DUR_CESSATE_NEGATIVE);
|
||||
|
||||
// Link effects
|
||||
effect eLink = EffectLinkEffects(eParalyze, eDur1);
|
||||
eLink = EffectLinkEffects(eLink, eDur2);
|
||||
eLink = EffectLinkEffects(eLink, eCessate);
|
||||
|
||||
SpeakString("PARALSIS: 120 seconds :" + GetName(oTarget));
|
||||
|
||||
// Apply VFX Impact and daze effect
|
||||
PHS_ApplyDuration(oTarget, eLink, 120.0);
|
||||
|
||||
}
|
@@ -1,56 +0,0 @@
|
||||
// Empty, used for testing
|
||||
|
||||
// Test repel on things.
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void Test(float fDistance, object oSource);
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
object oSource = OBJECT_SELF;
|
||||
|
||||
float fDistance = 10.0;
|
||||
|
||||
object oTarget = GetSpellTargetObject();
|
||||
|
||||
//SpeakString("Doing Move Back: Cutscene only test: " + GetName(oTarget));
|
||||
//AssignCommand(oTarget, Test(fDistance, oSource));
|
||||
|
||||
|
||||
|
||||
SpeakString("Setting the target via. assign command to destroyable TRUE");
|
||||
|
||||
AssignCommand(oTarget, SetIsDestroyable(TRUE));
|
||||
|
||||
|
||||
|
||||
// Move them
|
||||
// SpeakString("DOING MOVE BACK/ REPEL SPECAIL: " + GetName(oTarget));
|
||||
// AssignCommand(oTarget, PHS_ActionRepel(fDistance, oSource));
|
||||
|
||||
}
|
||||
void Test(float fDistance, object oSource)
|
||||
{
|
||||
location lSource = GetLocation(oSource);
|
||||
|
||||
// Commandable?
|
||||
SpeakString("Test (CUTSCENE, 10 seconds till out): Commandable: " + IntToString(GetCommandable(OBJECT_SELF)));
|
||||
|
||||
// Cutscene mdoe
|
||||
SetCutsceneMode(OBJECT_SELF, TRUE);
|
||||
|
||||
if(GetCommandable() == FALSE)
|
||||
{
|
||||
SetCommandable(TRUE);
|
||||
AssignCommand(OBJECT_SELF, ActionMoveAwayFromLocation(lSource, TRUE, fDistance));
|
||||
SetCommandable(FALSE);
|
||||
}
|
||||
else
|
||||
{
|
||||
AssignCommand(OBJECT_SELF, ActionMoveAwayFromLocation(lSource, TRUE, fDistance));
|
||||
}
|
||||
|
||||
DelayCommand(10.0, SetCutsceneMode(OBJECT_SELF, FALSE));
|
||||
}
|
||||
|
@@ -1,32 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Cursed Water
|
||||
//:: Spell FileName PHS_M_CurseWater
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Cursed Water: Cursed water damages good outsiders almost as if it were acid.
|
||||
A flask of cursed water can be thrown as a splash weapon.
|
||||
|
||||
Treat this attack as a ranged touch attack, with a maximum range of 8M. A
|
||||
direct hit by a flask of holy water deals 2d4 points of damage to a good
|
||||
outsider. Each such creature within 1.67M (5 feet) of the point where the
|
||||
flask hits takes 1 point of damage from the splash.
|
||||
|
||||
Temples to evil deities sell cursed water at cost (making no profit).
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
As above, damage similar to Biowares.
|
||||
|
||||
This is required for the Curse Water spell.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Use the function to do the hit, blast ETC
|
||||
PHS_Grenade(d4(2), 1, VFX_IMP_HEAD_EVIL, VFX_IMP_PULSE_NEGATIVE, DAMAGE_TYPE_NEGATIVE, RADIUS_SIZE_FEET_5, OBJECT_TYPE_CREATURE, RACIAL_TYPE_OUTSIDER, RACIAL_TYPE_ALL, ALIGNMENT_GOOD);
|
||||
}
|
@@ -1,30 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Holy Water
|
||||
//:: Spell FileName PHS_M_HolyWater
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Holy Water: Holy water damages undead creatures and evil outsiders almost as
|
||||
if it were acid. A flask of holy water can be thrown as a splash weapon.
|
||||
|
||||
Treat this attack as a ranged touch attack, with a maximum range of 8M. A
|
||||
direct hit by a flask of holy water deals 2d4 points of damage to an undead
|
||||
creature or an evil outsider. Each such creature within 1.67M (5 feet) of
|
||||
the point where the flask hits takes 1 point of damage from the splash.
|
||||
|
||||
Temples to good deities sell holy water at cost (making no profit).
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
As above.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Use the function to do the hit, blast ETC
|
||||
PHS_Grenade(d4(2), 1, VFX_IMP_HEAD_HOLY, VFX_IMP_PULSE_HOLY, DAMAGE_TYPE_DIVINE, RADIUS_SIZE_FEET_5, OBJECT_TYPE_CREATURE, RACIAL_TYPE_UNDEAD, RACIAL_TYPE_OUTSIDER, ALIGNMENT_EVIL);
|
||||
}
|
@@ -1,76 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Script Name Negative Energy Plane - Major - Heartbeat
|
||||
//:: Script FileName PHS_OT_NegPlnMaj
|
||||
//:://////////////////////////////////////////////
|
||||
//:: File Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Major Negative Energy Plane. Very unlucky if you end up here!
|
||||
|
||||
Description:
|
||||
|
||||
Negative-Dominant: Planes with this trait are vast, empty reaches that suck
|
||||
the life out of travelers who cross them. They tend to be lonely, haunted
|
||||
planes, drained of color and filled with winds bearing the soft moans of
|
||||
those who died within them. As with positive-dominant planes,
|
||||
negative-dominant planes can be either minor or major. On minor
|
||||
negative-dominant planes, living creatures take 1d6 points of damage per
|
||||
round. At 0 hit points or lower, they crumble into ash.
|
||||
|
||||
Major negative-dominant planes are even more severe. Each round, those
|
||||
within must make a DC 25 Fortitude save or gain a negative level. A
|
||||
creature whose negative levels equal its current levels or Hit Dice is
|
||||
slain, becoming a wraith. The death ward spell protects a traveler from
|
||||
the damage and energy drain of a negative-dominant plane.
|
||||
|
||||
Basically:
|
||||
- Deals a negative level (delayed just in case of it not reacting correctly
|
||||
to stacking) on a failed DC25 fortitude save, eachround.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Loop all objects in the area. DMs excepted.
|
||||
object oTarget = GetFirstObjectInArea(OBJECT_SELF);
|
||||
|
||||
if(!GetIsObjectValid(oTarget)) return;
|
||||
|
||||
// Delcare effects - Negative Level
|
||||
effect eVis = EffectVisualEffect(VFX_IMP_NEGATIVE_ENERGY);
|
||||
effect eNeg = EffectNegativeLevel(1);
|
||||
effect eDur = EffectVisualEffect(VFX_DUR_CESSATE_NEGATIVE);
|
||||
effect eLink = SupernaturalEffect(EffectLinkEffects(eNeg, eDur));
|
||||
float fDuration;
|
||||
|
||||
// Loop all objects in the area. DMs excepted.
|
||||
while(GetIsObjectValid(oTarget))
|
||||
{
|
||||
// Is it a creature? (Not a DM)
|
||||
if(GetObjectType(oTarget) == OBJECT_TYPE_CREATURE &&
|
||||
PHS_CanCreatureBeDestroyed(oTarget))
|
||||
{
|
||||
// Are they dead? If yes, ignore.
|
||||
if(!GetIsDead(oTarget))
|
||||
{
|
||||
// Immune to negative levels?
|
||||
if(!PHS_ImmunityCheck(oTarget, IMMUNITY_TYPE_NEGATIVE_LEVEL))
|
||||
{
|
||||
// DC 25 fortitude save for a permanent negative level.
|
||||
if(!PHS_NotSpellSavingThrow(SAVING_THROW_FORT, oTarget, 25, SAVING_THROW_TYPE_NEGATIVE))
|
||||
{
|
||||
// Fortitude save: Death
|
||||
SendMessageToPC(oTarget, "You gain a negative level due to being on the negative plane.");
|
||||
|
||||
// Apply the negative level.
|
||||
DelayCommand(0.1, PHS_ApplyPermanentAndVFX(oTarget, eVis, eLink));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
// Get next object
|
||||
oTarget = GetNextObjectInArea(OBJECT_SELF);
|
||||
}
|
||||
}
|
@@ -1,129 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Script Name Positive Energy Plane - Major - Heartbeat
|
||||
//:: Script FileName PHS_OT_PosiPlMaj
|
||||
//:://////////////////////////////////////////////
|
||||
//:: File Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Major Positive Energy Plane heartbeat. For those unlucky enough to get here...
|
||||
|
||||
Description:
|
||||
|
||||
Positive-Dominant: An abundance of life characterizes planes with this trait.
|
||||
The two kinds of positive-dominant traits are minor positive-dominant and
|
||||
major positive-dominant.
|
||||
|
||||
A minor positive-dominant plane is a riotous explosion of life in all its
|
||||
forms. Colors are brighter, fires are hotter, noises are louder, and
|
||||
sensations are more intense as a result of the positive energy swirling
|
||||
through the plane. All individuals in a positive-dominant plane gain fast
|
||||
healing 2 as an extraordinary ability.
|
||||
|
||||
Major positive-dominant planes go even further. A creature on a major
|
||||
positive-dominant plane must make a DC 15 Fortitude save to avoid being
|
||||
blinded for 10 rounds by the brilliance of the surroundings. Simply being
|
||||
on the plane grants fast healing 5 as an extraordinary ability. In addition,
|
||||
those at full hit points gain 5 additional temporary hit points per round.
|
||||
These temporary hit points fade 1d20 rounds after the creature leaves the
|
||||
major positive- dominant plane. However, a creature must make a DC 20
|
||||
Fortitude save each round that its temporary hit points exceed its normal
|
||||
hit point total. Failing the saving throw results in the creature exploding
|
||||
in a riot of energy, killing it.
|
||||
|
||||
Despite the beneficial effects of the plane, it is one of the most hostile
|
||||
of the Inner Planes. An unprotected character on this plane swells with
|
||||
power as positive energy is force-fed into her. Then, her mortal frame
|
||||
unable to contain that power, she immolates as if she were a small planet
|
||||
caught at the edge of a supernova. Visits to the Positive Energy Plane
|
||||
are brief, and even then travelers must be heavily protected.
|
||||
|
||||
Basically:
|
||||
- Heals 5HP per round.
|
||||
- If at full health, provides 5HP bonus in temp HP.
|
||||
- Saving throw based on how many temp HP bonuses are applied from this
|
||||
area object.
|
||||
- Temp HP is only added for 1d20 rounds, as per the description (Yes, it is
|
||||
permanent in this realm, but it is hard to remove it otherwise!)
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Loop all objects in the area. DMs excepted.
|
||||
object oTarget = GetFirstObjectInArea(OBJECT_SELF);
|
||||
|
||||
if(!GetIsObjectValid(oTarget)) return;
|
||||
|
||||
// Healing and Temp HP effect. Same VFX for each.
|
||||
effect eVis = EffectVisualEffect(VFX_IMP_HEALING_G);
|
||||
effect eHeal = EffectHeal(5);
|
||||
effect eHP = EffectTemporaryHitpoints(5);
|
||||
effect eDur = EffectVisualEffect(VFX_DUR_CESSATE_POSITIVE);
|
||||
effect eLink = SupernaturalEffect(EffectLinkEffects(eHP, eDur));
|
||||
effect eBlind = SupernaturalEffect(EffectBlindness());
|
||||
float fDuration;
|
||||
|
||||
// Loop all objects in the area. DMs excepted.
|
||||
while(GetIsObjectValid(oTarget))
|
||||
{
|
||||
// Is it a creature? (Not a DM)
|
||||
if(GetObjectType(oTarget) == OBJECT_TYPE_CREATURE &&
|
||||
PHS_CanCreatureBeDestroyed(oTarget))
|
||||
{
|
||||
// Are they dead? If yes, ignore.
|
||||
if(!GetIsDead(oTarget))
|
||||
{
|
||||
// DC 15 fortitude save for blindness for 10 rounds, if not
|
||||
// already blinded or otherwise.
|
||||
if(PHS_GetCanSee(oTarget))
|
||||
{
|
||||
// Temp HP, and save for death.
|
||||
// Save first:
|
||||
if(!PHS_NotSpellSavingThrow(SAVING_THROW_FORT, oTarget, 15, SAVING_THROW_TYPE_POSITIVE))
|
||||
{
|
||||
// Fortitude save: Death
|
||||
SendMessageToPC(oTarget, "You are blinded for 10 rounds due to the brilliance of the positive plane.");
|
||||
|
||||
// Duration of 10 rounds
|
||||
fDuration = PHS_GetDuration(PHS_ROUNDS, 10, FALSE);
|
||||
PHS_ApplyDurationAndVFX(oTarget, eVis, eBlind, fDuration);
|
||||
}
|
||||
}
|
||||
|
||||
// Heal if below max HP
|
||||
if(GetCurrentHitPoints(oTarget) < GetMaxHitPoints(oTarget))
|
||||
{
|
||||
// Tell them
|
||||
SendMessageToPC(oTarget, "You are healed with massive positive energy flowing through your body.");
|
||||
|
||||
// Apply healing effect
|
||||
PHS_ApplyInstantAndVFX(oTarget, eVis, eHeal);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Temp HP, and save for death.
|
||||
// Save first:
|
||||
if(!PHS_NotSpellSavingThrow(SAVING_THROW_FORT, oTarget, 20, SAVING_THROW_TYPE_POSITIVE))
|
||||
{
|
||||
// Fortitude save: Death
|
||||
SendMessageToPC(oTarget, "Your body explodes in a massive burst of positive energy.");
|
||||
PHS_ApplyDeathByDamageAndVFX(oTarget, eVis, DAMAGE_TYPE_POSITIVE);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Temp HP addition
|
||||
SendMessageToPC(oTarget, "You gain temporary hit points with massive positive energy flowing through your body.");
|
||||
|
||||
// Duration of 1d20 rounds
|
||||
fDuration = PHS_GetRandomDuration(PHS_ROUNDS, 20, 1, FALSE);
|
||||
PHS_ApplyDurationAndVFX(oTarget, eVis, eLink, fDuration);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
// Get next object
|
||||
oTarget = GetNextObjectInArea(OBJECT_SELF);
|
||||
}
|
||||
}
|
@@ -1,44 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Name Read
|
||||
//:: FileName PHS_OT_Read
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Notes
|
||||
//:://////////////////////////////////////////////
|
||||
When activated, as a spell (like Unique Power is) it will start an approprate
|
||||
conversation for the book/scroll/whatever.
|
||||
|
||||
Includes "Explosive Runes" check too.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Declare major variables
|
||||
object oSelf = OBJECT_SELF;
|
||||
|
||||
// Get conversation based on the item used tag
|
||||
object oUsed = GetSpellCastItem();
|
||||
|
||||
if(GetIsObjectValid(oUsed))
|
||||
{
|
||||
// Get tag and activate "cnv_" + tag
|
||||
string sConversastion = "cnv_" + GetTag(oUsed);
|
||||
|
||||
// Stop other things
|
||||
ClearAllActions();
|
||||
|
||||
// Play some reading animation if it wasn't a scroll
|
||||
if(GetBaseItemType(oUsed) != BASE_ITEM_SCROLL)
|
||||
{
|
||||
ActionPlayAnimation(ANIMATION_FIREFORGET_READ);
|
||||
}
|
||||
// See if Explosive Runes explode..
|
||||
if(PHS_ExplosiveRunes()) return;
|
||||
|
||||
// Start the conversation with self.
|
||||
ActionStartConversation(oSelf, sConversastion, TRUE, FALSE);
|
||||
}
|
||||
}
|
@@ -1,118 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Name Trap Disarm
|
||||
//:: FileName PHS_OT_Trapdisar
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Notes
|
||||
//:://////////////////////////////////////////////
|
||||
When activated (When they know about a magical trap in the area) a rogue
|
||||
or anyone can use this power on an item to diarm the trap from the perimeter.
|
||||
|
||||
They have a local int set on any AOE's (the magical traps) which are
|
||||
detected by the PC.
|
||||
|
||||
Explosive runes and the like are detected if the item targeted has it, and
|
||||
it is sucessfully detected. It will be disarmed if they detect it.
|
||||
|
||||
Item description:
|
||||
|
||||
Rogue only.
|
||||
|
||||
Use this tool on yourself to disarm magical traps you know about in the area
|
||||
such as Symbol: Death. It requires you to be aware the magical trap is there
|
||||
(visible runes and magical traps you always know about) and have a sucessful
|
||||
Disarm Trap check against 25 + Spell level.
|
||||
|
||||
If you target an item, you check to see if has any Explosive Runes or similar
|
||||
spells on it, and attempt to disarm them if it does. Once you know it has
|
||||
Explosive runes upon it, use the tool again to disarm them, or attempt to.
|
||||
The DC for this is also 25 + Spell level.
|
||||
|
||||
If you ever fail a Disarm Trap check and get a 1, you trigger the runes or
|
||||
magical trap, and it goes off instantly as if you were the triggerer.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
// Disarm oTrap with special checks. Must be in fDistance meters to do so.
|
||||
void ActionDisarmTheMagicTrap(object oTrap, float fDistance = 8.0, object oDisarmer = OBJECT_SELF);
|
||||
|
||||
void main()
|
||||
{
|
||||
// Declare major variables
|
||||
object oSelf = OBJECT_SELF;
|
||||
object oDisarm;
|
||||
string sName = GetName(oSelf);
|
||||
int nCnt = 1;
|
||||
|
||||
// Only PC's can disarm magical traps. No faries ETC
|
||||
if(!GetIsPC(oSelf)) return;
|
||||
|
||||
// Only a rogue can use this
|
||||
if(!GetLevelByClass(CLASS_TYPE_ROGUE, oSelf)) return;
|
||||
|
||||
// See if we know of any traps nearby. Loop until we find on in 20M
|
||||
object oAOE = GetNearestObject(OBJECT_TYPE_AREA_OF_EFFECT, oSelf, nCnt);
|
||||
while(GetIsObjectValid(oAOE) && GetDistanceToObject(oAOE) <= 20.0)
|
||||
{
|
||||
// Check if detected. PC's should have unique names.
|
||||
if((GetLocalInt(oAOE, PHS_MAGICAL_TRAP_DETECTED_BY + sName) == TRUE ||
|
||||
GetLocalInt(oAOE, PHS_MAGICAL_TRAP_ALWAYS_DETECTED) == TRUE) &&
|
||||
GetLocalInt(oAOE, PHS_MAGICAL_TRAP_LEVEL) >= 1)
|
||||
{
|
||||
// Stop
|
||||
oDisarm = oAOE;
|
||||
break;
|
||||
}
|
||||
// Get next one
|
||||
nCnt++;
|
||||
oAOE = GetNearestObject(OBJECT_TYPE_AREA_OF_EFFECT, oSelf, nCnt);
|
||||
}
|
||||
|
||||
// Is oDiarm valid?
|
||||
if(GetIsObjectValid(oDisarm))
|
||||
{
|
||||
// The DC in each case is 25 + spell level, (EG: 31 for symbol of fear).
|
||||
SendMessageToPC(oSelf, "You have detected a magical trap, so you plan on disarming it");
|
||||
|
||||
// Get the DC of the disarm check
|
||||
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
// Disarm oTrap with special checks. Must be in fDistance meters to do so.
|
||||
void ActionDisarmTheMagicTrap(object oTrap, float fDistance = 8.0, object oDisarmer = OBJECT_SELF)
|
||||
{
|
||||
// Make sure we are fDistance or nearer
|
||||
if(GetDistanceToObject(oTrap) <= fDistance)
|
||||
{
|
||||
// Get DC and do a check
|
||||
int nDC = GetLocalInt(oTrap, PHS_MAGICAL_TRAP_LEVEL);
|
||||
if(GetIsSkillSuccessful(oDisarmer, SKILL_DISABLE_TRAP, nDC))
|
||||
{
|
||||
SendMessageToPC(oDisarmer, "PASS: You disable the magical trap with your tools.");
|
||||
DestroyObject(oTrap);
|
||||
}
|
||||
else if(d20() == 1)
|
||||
{
|
||||
// Trap goes off!
|
||||
SendMessageToPC(oDisarmer, "FAIL: You fail to disable the magical trap, and it goes off!");
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
// Fail to disable it but no trap goes off
|
||||
SendMessageToPC(oDisarmer, "FAIL: You fail to disable the magical trap with your tools.");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
FloatingTextStringOnCreature("You are too far away from the magical trap to disarm it", oDisarmer);
|
||||
}
|
||||
}
|
@@ -1,32 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name
|
||||
//:: Spell FileName
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
3E Spellcasting
|
||||
Universal
|
||||
Level: All 0
|
||||
Components: V, S, M/DF
|
||||
Casting Time: 1 standard action
|
||||
Range: Personal
|
||||
Target: You
|
||||
|
||||
This lets you read the book of knowledge - all there is to know about
|
||||
casting spells in NwN and the 3.5E rules governing them. It pops up in
|
||||
conversation form.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Starts conversation (privatly, with self) for all information for spell
|
||||
casting is.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
void main()
|
||||
{
|
||||
// Start conversation PHS_Magicoverview
|
||||
ClearAllActions();
|
||||
ActionStartConversation(OBJECT_SELF, "phs_magicoverview", TRUE, FALSE);
|
||||
}
|
@@ -1,63 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Acid Splash
|
||||
//:: Spell FileName PHS_S_AcidSplash
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Conjuration (Creation) [Acid]
|
||||
Level: Sor/Wiz 0
|
||||
Components: V, S
|
||||
Casting Time: 1 standard action
|
||||
Range: Close (8M)
|
||||
Effect: One missile of acid
|
||||
Duration: Instantaneous
|
||||
Saving Throw: None
|
||||
Spell Resistance: No
|
||||
|
||||
You fire a small orb of acid at the target. You must succeed on a ranged
|
||||
touch attack to hit your target. The orb deals 1d3 points of acid damage.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Notes about this: No spell resistance or spell turning. Only check spell
|
||||
immunity :-)
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell hook check.
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
//Declare major variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
// Requires a touch attack
|
||||
int nTouch = PHS_SpellTouchAttack(PHS_TOUCH_RAY, oTarget, TRUE);
|
||||
// Damage + Double for a critical hit.
|
||||
int nDamage = PHS_MaximizeOrEmpower(3, 1, nMetaMagic, FALSE, nTouch);
|
||||
|
||||
// Declare Effects
|
||||
effect eVis = EffectVisualEffect(VFX_IMP_ACID_S);
|
||||
|
||||
// Check PvP
|
||||
if(!GetIsReactionTypeFriendly(oTarget) &&
|
||||
// Make sure they are not immune to spells
|
||||
!PHS_TotalSpellImmunity(oTarget))
|
||||
{
|
||||
// Fire cast spell at event for the specified target
|
||||
PHS_SignalSpellCastAt(oTarget, PHS_SPELL_ACID_SPLASH);
|
||||
|
||||
// Do we even hit?
|
||||
if(nTouch)
|
||||
{
|
||||
//Apply the VFX impact and damage effect
|
||||
PHS_ApplyDamageVFXToObject(oTarget, eVis, nDamage, DAMAGE_TYPE_ACID);
|
||||
}
|
||||
// Else we miss - do nothing
|
||||
}
|
||||
}
|
@@ -1,70 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Air Walk
|
||||
//:: Spell FileName PHS_S_AirWalk
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Transmutation [Air]
|
||||
Level: Air 4, Clr 4, Drd 4
|
||||
Components: V, S, DF
|
||||
Casting Time: 1 standard action
|
||||
Range: Touch
|
||||
Target: Creature (Gargantuan or smaller) touched
|
||||
Duration: 10 min./level
|
||||
Saving Throw: None
|
||||
Spell Resistance: Yes (harmless)
|
||||
|
||||
This is a DM run spell, and this spell only applies a visual effect.
|
||||
|
||||
The subject can tread on air as if walking on solid ground. Moving upward is
|
||||
similar to walking up a hill. The maximum upward or downward angle possible
|
||||
is 45 degrees, at a rate equal to one-half the air walker<65>s normal speed.
|
||||
|
||||
A strong wind (21+ mph) can push the subject along or hold it back. At the
|
||||
end of its turn each round, the wind blows the air walker 5 feet for each 5
|
||||
miles per hour of wind speed. The creature may be subject to additional
|
||||
penalties in exceptionally strong or turbulent winds, such as loss of control
|
||||
over movement or physical damage from being buffeted about.
|
||||
|
||||
Should the spell duration expire while the subject is still aloft, the magic
|
||||
fails slowly. The subject floats downward 60 feet per round for 1d6 rounds.
|
||||
If it reaches the ground in that amount of time, it lands safely. If not, it
|
||||
falls the rest of the distance, taking 1d6 points of damage per 10 feet of
|
||||
fall. Since dispelling a spell effectively ends it, the subject also
|
||||
descends in this way if the air walk spell is dispelled, but not if it is
|
||||
negated by an antimagic field.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
DM run spell.
|
||||
|
||||
Visual effect, thats about it.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell Hook Check.
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Declare Major Variables
|
||||
object oTarget = GetSpellTargetObject();
|
||||
|
||||
// Make sure they are not immune to spells
|
||||
if(PHS_TotalSpellImmunity(oTarget)) return;
|
||||
|
||||
// Fire cast spell at event for the specified target
|
||||
PHS_SignalSpellCastAt(oTarget, PHS_SPELL_AIR_WALK, FALSE);
|
||||
|
||||
// Create an air pulse effect
|
||||
effect eVis = EffectVisualEffect(VFX_IMP_PULSE_WIND);
|
||||
|
||||
// Apply the effect.
|
||||
PHS_ApplyVFX(oTarget, eVis);
|
||||
|
||||
// Signal the spell cast to DM's.
|
||||
PHS_AlertDMsOfSpell("Air Walk", PHS_GetSpellSaveDC(), PHS_GetCasterLevel());
|
||||
}
|
@@ -1,80 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Alarm
|
||||
//:: Spell FileName PHS_S_Alarm
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Abjuration
|
||||
Level: Brd 1, Rgr 1, Sor/Wiz 1
|
||||
Components: V, S, F/DF
|
||||
Casting Time: 1 standard action
|
||||
Range: Close (8M)
|
||||
Area: 6.67M.-radius (20-ft.) emanation centered on a point in space
|
||||
Duration: 2 hours/level (D)
|
||||
Saving Throw: None
|
||||
Spell Resistance: No
|
||||
|
||||
Alarm sounds a mental or audible alarm each time a creature of Tiny or
|
||||
larger size enters the warded area or touches it. A creature in your party
|
||||
does not set off the alarm as they speak the password automatically as they
|
||||
come near it. You decide at the time of casting whether the alarm will be
|
||||
mental or audible.
|
||||
|
||||
Mental Alarm: A mental alarm alerts you (and only you) so long as you remain
|
||||
within the warded area. You note a single mental <20>ping<6E> that awakens you
|
||||
from normal sleep but does not otherwise disturb concentration. A silence
|
||||
spell has no effect on a mental alarm.
|
||||
|
||||
Audible Alarm: An audible alarm produces the sound of a hand bell, and
|
||||
anyone within hearing distance will hear it. The sound lasts for 1 round.
|
||||
Creatures within a silence spell cannot hear the ringing.
|
||||
|
||||
Ethereal or astral creatures do not trigger the alarm.
|
||||
|
||||
Arcane Focus: A tiny bell and a piece of very fine silver wire.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
2 version - audible (gong sounds on AOE) or message (floating text to caster).
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell Hook Check.
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Declare Major Variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
location lTarget = GetSpellTargetLocation();
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
int nSpellID = GetSpellId();
|
||||
|
||||
// Duration in hours.
|
||||
float fDuration = PHS_GetDuration(PHS_HOURS, nCasterLevel * 2, nMetaMagic);
|
||||
|
||||
// Default to noisy
|
||||
if(nSpellID == PHS_SPELL_ALARM)
|
||||
{
|
||||
nSpellID = PHS_SPELL_ALARM_MESSAGE;
|
||||
}
|
||||
|
||||
// What script shall the OnEnter be?
|
||||
// Starts as the "PHS_SPELL_ALARM_MESSAGE" one (number 2)
|
||||
string sEnterScript = "PHS_S_Alarm2a";
|
||||
// But may change to the 1 version...for J_SPELL_ALARM_AUDIBLE.
|
||||
if(nSpellID == PHS_SPELL_ALARM_AUDIBLE)
|
||||
{
|
||||
sEnterScript = "PHS_S_Alarm1a";
|
||||
}
|
||||
|
||||
// Create an Area of Effect effect
|
||||
effect eAOE = EffectAreaOfEffect(PHS_AOE_PER_ALARM, sEnterScript);
|
||||
|
||||
// Create an instance of the AOE Object using the Apply Effect function
|
||||
PHS_ApplyLocationDuration(lTarget, eAOE, fDuration);
|
||||
}
|
@@ -1,42 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Alarm : Auidible : On Enter
|
||||
//:: Spell FileName phs_s_alarm1a
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Audible version. If enemy or neutral, signal event.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// AOE check
|
||||
if(!PHS_CheckAOECreator()) return;
|
||||
|
||||
//Declare major variables
|
||||
int nCnt;
|
||||
float fDelay;
|
||||
object oTarget = GetEnteringObject();
|
||||
object oCreator = GetAreaOfEffectCreator();
|
||||
// Faction stuff. It doesn't get removed until the duration runs out too.
|
||||
if(!GetFactionEqual(oTarget, oCreator))
|
||||
{
|
||||
// Fire cast spell at event for the target
|
||||
PHS_SignalSpellCastAt(oTarget, PHS_SPELL_ALARM);
|
||||
// Speakstring for AI.
|
||||
SpeakString("NW_CALL_TO_ARMS", TALKVOLUME_SILENT_TALK);
|
||||
// Alarm activated string, which should pop up in clients text's boxes.
|
||||
SpeakString("Alarm Bells Sound");
|
||||
// 5 lots of bells.
|
||||
PlaySound("nw_bells");
|
||||
// fDelay starts as 0.0, and immediantly adds 0.2.
|
||||
for(nCnt = 1; nCnt < 5; nCnt++)
|
||||
{
|
||||
fDelay += 0.2;
|
||||
DelayCommand(fDelay, PlaySound("nw_bells"));
|
||||
}
|
||||
}
|
||||
}
|
@@ -1,32 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Alarm : Mental : On Enter
|
||||
//:: Spell FileName phs_s_alarm2a
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Message version. Caster must be in area and a message is sent to them.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// AOE check
|
||||
if(!PHS_CheckAOECreator()) return;
|
||||
|
||||
//Declare major variables
|
||||
object oTarget = GetEnteringObject();
|
||||
object oCreator = GetAreaOfEffectCreator();
|
||||
if(!GetFactionEqual(oTarget, oCreator))
|
||||
{
|
||||
// Only display a message if we are in the same area as the creator!
|
||||
if(GetArea(oCreator) == GetArea(OBJECT_SELF))
|
||||
{
|
||||
string sMessage = "Your mental alarm has been set off!";
|
||||
SpeakString("I_WAS_ATTACKED", TALKVOLUME_SILENT_TALK);
|
||||
SendMessageToPC(oCreator, sMessage);
|
||||
}
|
||||
}
|
||||
}
|
@@ -1,97 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Align Weapon
|
||||
//:: Spell FileName PHS_S_AlignWeap
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Transmutation [see text]
|
||||
Level: Clr 2
|
||||
Components: V, S, DF
|
||||
Casting Time: 1 standard action
|
||||
Range: Touch
|
||||
Target: Weapon touched
|
||||
Duration: 1 min./level
|
||||
Saving Throw: Will negates (harmless, object)
|
||||
Spell Resistance: Yes (harmless, object)
|
||||
|
||||
Align weapon makes a weapon good, evil, lawful, or chaotic, as you choose.
|
||||
A weapon that is aligned gains a +1 attack bonus per 5 caster levels
|
||||
(maxium +3) against the chosen alignment (and can bypass that amount of
|
||||
damage reduction). This spell has no effect on a weapon that grants any
|
||||
form of attack bonus.
|
||||
|
||||
You can<61>t cast this spell on a natural weapon, such as an unarmed strike.
|
||||
|
||||
When you make a weapon good, evil, lawful, or chaotic, align weapon is a
|
||||
good, evil, lawful, or chaotic spell, respectively.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Basically, it gives +1 attack to the weapon affected, versus the alignment
|
||||
chosen. It goes up to a max of +3, every 5 levels.
|
||||
|
||||
Only can be used on weapons with no attack bonus at all, and cannot be cast
|
||||
on ammo (as they cannot be given attack bonuses!)
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell hook check.
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Delcare major variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject(); // Should be an item
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nSpellCast = GetSpellId();
|
||||
int nAlignment;
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
|
||||
// Make sure they are not immune to spells
|
||||
if(PHS_TotalSpellImmunity(oTarget)) return;
|
||||
|
||||
// It is +1/5 levels, to a max of 3
|
||||
int nBonus = PHS_LimitInteger(nCasterLevel/5, 3);
|
||||
|
||||
// Duration in turns (minutes)
|
||||
float fDuration = PHS_GetDuration(PHS_MINUTES, nCasterLevel, nMetaMagic);
|
||||
|
||||
// Get the alignment to be against
|
||||
if(nSpellCast == PHS_SPELL_ALIGN_WEAPON_GOOD)
|
||||
{
|
||||
nAlignment = IP_CONST_ALIGNMENTGROUP_GOOD;
|
||||
}
|
||||
else if(nSpellCast == PHS_SPELL_ALIGN_WEAPON_CHAOTIC)
|
||||
{
|
||||
nAlignment = IP_CONST_ALIGNMENTGROUP_CHAOTIC;
|
||||
}
|
||||
else if(nSpellCast == PHS_SPELL_ALIGN_WEAPON_LAWFUL)
|
||||
{
|
||||
nAlignment = IP_CONST_ALIGNMENTGROUP_LAWFUL;
|
||||
}
|
||||
// Default to evil
|
||||
else // if(nSpellCast == PHS_SPELL_ALIGN_WEAPON_EVIL)
|
||||
{
|
||||
nAlignment = IP_CONST_ALIGNMENTGROUP_EVIL;
|
||||
}
|
||||
|
||||
// Declare effects
|
||||
itemproperty IP_Alignbonus = ItemPropertyAttackBonusVsAlign(nAlignment, nBonus);
|
||||
|
||||
// Declare effects
|
||||
effect eCessate = EffectVisualEffect(VFX_DUR_CESSATE_POSITIVE);
|
||||
effect eVis = EffectVisualEffect(VFX_IMP_SUPER_HEROISM);
|
||||
|
||||
// Apply it to the item if it doens't have an attack bonus
|
||||
if(!GetItemHasItemProperty(oTarget, ITEM_PROPERTY_ATTACK_BONUS_VS_ALIGNMENT_GROUP))
|
||||
{
|
||||
// Apply duration effect
|
||||
PHS_ApplyDurationAndVFX(oTarget, eVis, eCessate, fDuration);
|
||||
// Add it to the item
|
||||
AddItemProperty(DURATION_TYPE_TEMPORARY, IP_Alignbonus, oTarget, fDuration);
|
||||
}
|
||||
}
|
@@ -1,156 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Alter Self
|
||||
//:: Spell FileName PHS_S_AlterSelf
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Transmutation
|
||||
Level: Brd 2, Sor/Wiz 2
|
||||
Components: V, S
|
||||
Casting Time: 1 standard action
|
||||
Range: Personal
|
||||
Target: You
|
||||
Duration: 10 min./level (D)
|
||||
|
||||
You assume the form of a creature of the same type as your normal form. The
|
||||
new form must be within one size category of your normal size and the
|
||||
different forms are limited to those listed below. You can change into a
|
||||
member of your own kind or even into yourself.
|
||||
|
||||
You only change your appearance, and have no changes to any of your ability
|
||||
scores, class, level, hit points, alignment, base attack bonus or saves.
|
||||
You can cast spells normally and keep all feats and special abilities.
|
||||
|
||||
You acquire the physical qualities of the new form while retaining your own
|
||||
mind. You do not gain any extraordinary special attacks or special qualities
|
||||
such as darkvision, low-light vision, blindsense, blindsight, fast healing,
|
||||
regeneration, scent, and so forth. Your creature type and subtype (if any)
|
||||
remain the same regardless of your new form.
|
||||
|
||||
You become effectively disguised as an average member of the new form<72>s
|
||||
race. If you use this spell to create a disguise, you get a +10 bonus on
|
||||
your Disguise check. When the change occurs, your equipment, if any, remains
|
||||
worn or held by the new form.
|
||||
|
||||
The forms you can take can be; elf, human, half-elf, half-orc, halfling,
|
||||
gnome, Orc, Goblin, Bugbear or Gnoll.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
This is done via. SetAppearanceType().
|
||||
|
||||
I will, for now at least, use a heartbeat that is run on the creature, to
|
||||
check if it has been removed/dispelled, and thus change them back. It will
|
||||
also remove the effects of this spell if they polymorph.
|
||||
|
||||
Polymorphing, because of how it will change the appearance more tempoarily,
|
||||
will be wrappered so that it'll change them back THEN apply polymorph, after
|
||||
a tiny delay.
|
||||
|
||||
Valid ones (Remember: Gender stays the same):
|
||||
APPEARANCE_TYPE_BUGBEAR_A (And other bugbears?)
|
||||
APPEARANCE_TYPE_DWARF
|
||||
APPEARANCE_TYPE_ELF
|
||||
APPEARANCE_TYPE_GNOLL_WARRIOR (And the other gnoll?)
|
||||
APPEARANCE_TYPE_GNOME
|
||||
APPEARANCE_TYPE_GOBLIN_A (And other goblins?)
|
||||
APPEARANCE_TYPE_HALF_ELF
|
||||
APPEARANCE_TYPE_HALF_ORC
|
||||
APPEARANCE_TYPE_HALFLING
|
||||
APPEARANCE_TYPE_HUMAN
|
||||
APPEARANCE_TYPE_ORC_A (And other orcs?)
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
// If they don't have the spell's effects, or do and are polymorphed, we take
|
||||
// action. Else, it is fired again.
|
||||
void AlterSelfHeartbeat(object oTarget);
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell hook check.
|
||||
if(!PHS_SpellHookCheck(PHS_SPELL_ALTER_SELF)) return;
|
||||
|
||||
// Declare Major Variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject();// Should be OBJECT_SELF
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
|
||||
// Get what to turn into
|
||||
int nAppearance = GetLocalInt(oTarget, "PHS_ALTER_SELF_CHOICE");
|
||||
|
||||
// If 0, we default to human
|
||||
if(nAppearance == 0)
|
||||
{
|
||||
nAppearance = APPEARANCE_TYPE_HUMAN;
|
||||
}
|
||||
|
||||
// Duration is 10 minutes/level
|
||||
float fDuration = PHS_GetDuration(PHS_MINUTES, nCasterLevel * 10, nMetaMagic);
|
||||
|
||||
// Delcare Effects
|
||||
effect eVis = EffectVisualEffect(VFX_IMP_POLYMORPH);
|
||||
effect eDur = EffectVisualEffect(VFX_DUR_CESSATE_POSITIVE);
|
||||
|
||||
// Fire spell cast at event for target
|
||||
PHS_SignalSpellCastAt(oTarget, PHS_SPELL_ALTER_SELF);
|
||||
|
||||
// Remove previous effects
|
||||
PHS_RemoveSpellEffectsFromTarget(PHS_SPELL_ALTER_SELF, oTarget);
|
||||
|
||||
// Remove any polymorph
|
||||
PHS_RemoveSpecificEffect(EFFECT_TYPE_POLYMORPH, oTarget, SUBTYPE_IGNORE);
|
||||
|
||||
// Set original appearance if not already set - NPC only!
|
||||
if(!GetIsPC(oTarget))
|
||||
{
|
||||
// We check the integer
|
||||
if(PHS_GetLocalConstant(oTarget, "PHS_DEFAULT_APPEARANCE") == -1)
|
||||
{
|
||||
PHS_SetLocalConstant(oTarget, "PHS_DEFAULT_APPEARANCE", GetAppearanceType(oTarget));
|
||||
}
|
||||
}
|
||||
// Apply visual. Change appearance
|
||||
PHS_ApplyDurationAndVFX(oTarget, eVis, eDur, fDuration);
|
||||
SetCreatureAppearanceType(oTarget, nAppearance);
|
||||
|
||||
// New heartbeat to remove the appearance change
|
||||
DelayCommand(6.0, AlterSelfHeartbeat(oTarget));
|
||||
}
|
||||
|
||||
// If they don't have the spell's effects, or do and are polymorphed, we take
|
||||
// action. Else, it is fired again.
|
||||
void AlterSelfHeartbeat(object oTarget)
|
||||
{
|
||||
// Check for Polymorph (IE: New one)
|
||||
int bPolymorph = PHS_GetHasEffect(EFFECT_TYPE_POLYMORPH, oTarget);
|
||||
int bAlterSelf = GetHasSpellEffect(PHS_SPELL_ALTER_SELF, oTarget);
|
||||
|
||||
// Case 1: Alter self now gone, new polymorph there.
|
||||
if(bAlterSelf == FALSE && bPolymorph == TRUE)
|
||||
{
|
||||
// Stop this heartbeat
|
||||
return;
|
||||
}
|
||||
// Case 2: New polymorph, but still got Alter Self (somehow!) we will just
|
||||
// remove Alter Self's effects.
|
||||
else if(bPolymorph == TRUE)
|
||||
{
|
||||
PHS_RemoveSpellEffectsFromTarget(PHS_SPELL_ALTER_SELF, oTarget);
|
||||
}
|
||||
// Case 3: Not Got the effect, no new polymorph
|
||||
else if(bAlterSelf == TRUE)
|
||||
{
|
||||
// Reset apperance
|
||||
PHS_RevertAppearance(oTarget);
|
||||
}
|
||||
// Case 4: None of the above. We do another heartbeat.
|
||||
else
|
||||
{
|
||||
DelayCommand(6.0, AlterSelfHeartbeat(oTarget));
|
||||
}
|
||||
}
|
@@ -1,84 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Analyze Dweomer
|
||||
//:: Spell FileName PHS_S_AnalyzeDwe
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Divination
|
||||
Level: Brd 6, Sor/Wiz 6
|
||||
Components: V, S, F
|
||||
Casting Time: 1 standard action
|
||||
Range: Close (8M)
|
||||
Targets: One creature per caster level
|
||||
Duration: 1 round/level; or until target limit reached
|
||||
Saving Throw: None
|
||||
Spell Resistance: No
|
||||
|
||||
You discern all spells and magical properties present in a number of
|
||||
creatures or objects. Starting with the targeted creature, this will decern
|
||||
each spell, and its caster level. Subsequent rounds will target nearby seen
|
||||
creatures within 8M range of the caster, but not the same one twice, until
|
||||
none are left or the duration runs out.
|
||||
|
||||
Focus: A tiny lens of ruby or sapphire set in a small golden loop. The
|
||||
gemstone must be worth at least 1,500 gp.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
This only works on creatures. Easier, I mean, what can we do with looking
|
||||
at objects, unless they, for example, are equipped by a creature?
|
||||
|
||||
To check for spell effects, it does this:
|
||||
|
||||
- Loop effects
|
||||
- If from a spell, and a valid creator (else set to caster level -1) then
|
||||
it'll get caster level, set that into integer.
|
||||
- Then, loops the integers, and gets the valid ones, and sends them to
|
||||
the caster.
|
||||
|
||||
It shouldn't TMI, and is not really "CPU intensive" so should be fine.
|
||||
|
||||
Oh, and the targets are chosen to be within 8M. They are set in a local
|
||||
integer, on the target (deleted after a while) if they are done already, too.
|
||||
|
||||
While the HB is running for the duration (only one at once, see
|
||||
acid arrow) it'll check for sight of these targets, in order of the array
|
||||
they are stored in, with an integer saying if they are done or not (so
|
||||
if one becomes visible, they are done).
|
||||
|
||||
Note: 1500 focus needed (not a MC though, so not removed).
|
||||
Cannot be extended.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
// Analyze oTarget.
|
||||
void AnalyzePerson(object oTarget);
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell hook check
|
||||
if(!PHS_SpellHookCheck(PHS_SPELL_ANALYZE_DWEOMER)) return;
|
||||
|
||||
// Focus component check
|
||||
if(!PHS_ComponentFocusItem(PHS_ITEM_RUBY_IN_LOOP_1500, "Ruby set in a golden loop", "Analyze Dweomer")) return;
|
||||
|
||||
// Declare Major Variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject();
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
|
||||
// Projectile timing.
|
||||
float fDelay = GetDistanceToObject(oTarget)/25.0;
|
||||
|
||||
// Duration can be up to 7 rounds.
|
||||
float fDuration = PHS_GetDuration(PHS_ROUNDS, nCasterLevel, FALSE);
|
||||
|
||||
// Delcare Effects
|
||||
effect eDur = EffectVisualEffect(VFX_DUR_CESSATE_NEUTRAL);
|
||||
|
||||
// Fire spell cast at event for target
|
||||
PHS_SignalSpellCastAt(oTarget, 1);
|
||||
}
|
@@ -1,71 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Animal Shapes
|
||||
//:: Spell FileName PHS_S_AnimalShap
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Animal Shapes
|
||||
Transmutation
|
||||
Level: Animal 7, Drd 8
|
||||
Components: V, S, DF
|
||||
Casting Time: 1 standard action
|
||||
Range: Close (8M)
|
||||
Targets: Up to 1 ally/level, in a 10M radius.
|
||||
Duration: 1 hour/level (D)
|
||||
Saving Throw: None; see text
|
||||
Spell Resistance: Yes (harmless)
|
||||
|
||||
As polymorph, except you polymorph up to one willing creature per caster
|
||||
level into an animal of your choice; the spell has no effect on unwilling
|
||||
creatures. All creatures must take the same kind of animal form. Recipients
|
||||
remain in the animal form until the spell expires or until you dismiss it
|
||||
for all recipients. In addition, an individual subject may choose to resume
|
||||
its normal form as a full-round action; doing so ends the spell for that
|
||||
subject alone. The maximum HD of an assumed form is equal to the subject<63>s
|
||||
HD or your caster level, whichever is lower, to a maximum of 20 HD at 20th
|
||||
level.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Need to add in quite a few polymorphs,
|
||||
|
||||
Example animals:
|
||||
|
||||
- Bears (Polar, Dire, Black, Brown, Kodiak)
|
||||
- Dogs (Blinkdog, Dire Wolf, Dog, Fenhound, Shadow Massif, Worg, Winter Wolf, Wolf)
|
||||
- Wolves
|
||||
- Deer (Stag and Normal)
|
||||
- Boars (Dire and Normal)
|
||||
- Bat
|
||||
- Beetle
|
||||
- Chicken
|
||||
- Cats (Leopard, Crag Cat, Tiger, Krenshar, Lion, Jaguar, Panther, Cougar, Malar Panther)
|
||||
- Falcon
|
||||
- Raven
|
||||
- Spider (Dire, Giant, Phase, Sword, Wraith) (Is it an animal?)
|
||||
- Rat (Dire, Rat)
|
||||
- Harpy
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell hook check
|
||||
if(!PHS_SpellHookCheck(PHS_SPELL_ANIMAL_SHAPES)) return;
|
||||
|
||||
// Declare major variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget;
|
||||
location lTarget = GetSpellTargetLocation();
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
|
||||
// Make sure they are not immune to spells
|
||||
if(PHS_TotalSpellImmunity(oTarget)) return;
|
||||
|
||||
// Declare effects
|
||||
effect ePolymorph;
|
||||
}
|
@@ -1,103 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Animal Trance
|
||||
//:: Spell FileName PHS_S_AnimalTrnc
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Enchantment (Compulsion) [Mind-Affecting, Sonic], Close range, target is
|
||||
animals or beasts with intelligence 3 (1 or 2 in 3E)
|
||||
Duration: Concentration
|
||||
Saving Throw: Will negates; see text
|
||||
Spell Resistance: Yes
|
||||
|
||||
Your swaying motions and music (or singing, or chanting) compel animals and
|
||||
magical beasts to do nothing but watch you. Only a creature with an
|
||||
Intelligence score of 1 or 2 can be fascinated by this spell. Roll 2d6 to
|
||||
determine the total number of HD worth of creatures that you fascinate. The
|
||||
closest targets are selected first until no more targets within range can
|
||||
be affected.
|
||||
|
||||
A magical beast, a dire animal, or an animal trained to attack or guard is
|
||||
allowed a saving throw; an animal not trained to attack or guard is not.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
As spell. They always get the save unless they are actually set as a
|
||||
non-attack animal.
|
||||
|
||||
Also, the concentration is taken as not doing another action and staying
|
||||
within the spell range of the creatures (else it is broken).
|
||||
|
||||
The action check is done every 2 seconds.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell hook check
|
||||
if(!PHS_SpellHookCheck(PHS_SPELL_ANIMAL_TRANCE)) return;
|
||||
|
||||
// Declare major variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget;
|
||||
location lTarget = GetSpellTargetLocation();
|
||||
int nSpellSaveDC = PHS_GetSpellSaveDC();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
int nHD, nCnt, nRace;
|
||||
float fDelay, fDistance;
|
||||
|
||||
// Get max to mesmorise
|
||||
int nMesmoriseMax = PHS_MaximizeOrEmpower(6, 2, nMetaMagic);
|
||||
|
||||
// Declare effect
|
||||
effect eDur = EffectVisualEffect(VFX_DUR_MIND_AFFECTING_DISABLED);
|
||||
//effect eStun =
|
||||
|
||||
// Up to 8M range, so all from the target location up to 8M from the caster.
|
||||
// They must be able to see the caster to be mesmorised.
|
||||
nCnt = 1;
|
||||
oTarget = GetNearestObjectToLocation(OBJECT_TYPE_CREATURE, lTarget, nCnt);
|
||||
while(GetIsObjectValid(oTarget))
|
||||
{
|
||||
// Must be within 8M, PvP check and can hear, and are not immune to magic
|
||||
fDistance = GetDistanceBetween(oCaster, oTarget);
|
||||
if(fDistance <= 8.0 && !GetIsReactionTypeFriendly(oTarget) &&
|
||||
// Make sure they are not immune to spells
|
||||
!PHS_TotalSpellImmunity(oTarget))
|
||||
{
|
||||
// Need to be an animal
|
||||
nRace = GetRacialType(oTarget);
|
||||
if((nRace == RACIAL_TYPE_ANIMAL ||
|
||||
nRace == RACIAL_TYPE_MAGICAL_BEAST) &&
|
||||
// Needs to have 3 intelligence
|
||||
GetAbilityScore(oTarget, ABILITY_INTELLIGENCE) <= 3)
|
||||
{
|
||||
// Trance them
|
||||
// Trance!
|
||||
|
||||
// Get delay
|
||||
fDelay = fDistance/20;
|
||||
|
||||
// Spell resistance and immunity
|
||||
if(!PHS_SpellResistanceCheck(oCaster, oTarget, fDelay))
|
||||
{
|
||||
// Immunity VS mind spells
|
||||
if(!PHS_ImmunityCheck(oTarget, IMMUNITY_TYPE_MIND_SPELLS, fDelay))
|
||||
{
|
||||
// Will save VS mind spells.
|
||||
if(!PHS_SavingThrow(SAVING_THROW_WILL, oTarget, nSpellSaveDC, SAVING_THROW_TYPE_MIND_SPELLS, oCaster, fDelay))
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
// Next one to the location
|
||||
nCnt++;
|
||||
oTarget = GetNearestObjectToLocation(OBJECT_TYPE_CREATURE, lTarget, nCnt);
|
||||
}
|
||||
}
|
@@ -1,58 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Animate Objects
|
||||
//:: Spell FileName PHS_S_AnimateObj
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Transmutation
|
||||
Level: Brd 6, Chaos 6, Clr 6
|
||||
Components: V, S
|
||||
Casting Time: 1 standard action
|
||||
Range: Medium (20M)
|
||||
Targets: One Small object per caster level; see text
|
||||
Duration: 1 round/level
|
||||
Saving Throw: None
|
||||
Spell Resistance: No
|
||||
|
||||
Description.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Rating: 8: need more appearances, as creatures, so maybe can animate chests
|
||||
to attack and so on. Chest already exsists for this. Might work fine.
|
||||
|
||||
Placeholder script.
|
||||
|
||||
What might happen:
|
||||
|
||||
- Targets placables
|
||||
- If not plot, and not containing items (but can be trapped still) we check the tag
|
||||
- Depending on the tag, we destroy the placable, and replace it with a monster
|
||||
we have animated (or it failes if the tag doesn't match anything).
|
||||
- We copy the placable we destroy to a location in the spells area (yeah,
|
||||
at one point) which is then stored on the module/spells area/creature.
|
||||
|
||||
- End of the duration, recopy the object back to where the new location is
|
||||
and destroy the copy of the original. This new copy will then occupy that
|
||||
spot (which might get in the way of non-PC things, so maybe a variable
|
||||
for them so monsters keep attacking the object).
|
||||
|
||||
|
||||
Notes:
|
||||
|
||||
- Should Animated Objects still have thier hardness? Probably so (in
|
||||
a way), but have bad stats (be damage soakers). That'll mean 5DR to everything
|
||||
then, normally.
|
||||
- The AI is so basic it probably won't follow the master and just attacks
|
||||
things it "see's".
|
||||
- Added as a henchman? Or a cutscene dominated thing?
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
}
|
@@ -1,38 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Animate Plants
|
||||
//:: Spell FileName PHS_S_AnimatePla
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Transmutation
|
||||
Level: Drd 7, Plant 7
|
||||
Components: V
|
||||
Casting Time: 1 standard action
|
||||
Range: Close (8M)
|
||||
Targets: One Large plant per three caster levels or all plants within range;
|
||||
see text
|
||||
Duration: 1 round/level or 1 hour/level; see text
|
||||
Saving Throw: None
|
||||
Spell Resistance: No
|
||||
|
||||
Description.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Rating: As above (IE: Animate Objects): Need plant appearance things.
|
||||
If cast in an area of plants, maybe just do an high-powered-entangle
|
||||
|
||||
Placeholder script.
|
||||
|
||||
See Animate Objects. We'll just use "plant" appearances instead of "object"
|
||||
ones.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
}
|
@@ -1,169 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Animate Rope
|
||||
//:: Spell FileName PHS_S_AnimateRop
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Animate Rope
|
||||
Transmutation
|
||||
Level: Brd 1, Sor/Wiz 1
|
||||
Components: V, S
|
||||
Casting Time: 1 standard action
|
||||
Range: Medium (100 ft. + 10 ft./level)
|
||||
Target: One ropelike object, in your inventory
|
||||
Duration: 1 round/level
|
||||
Saving Throw: None
|
||||
Spell Resistance: No
|
||||
|
||||
You can animate a nonliving ropelike object.
|
||||
|
||||
The rope can enwrap only a creature or an object within 1 foot of it-it does
|
||||
not snake outward-so it must be thrown near the intended target. Doing so
|
||||
requires a successful ranged touch attack roll. A typical 1- inch-diameter
|
||||
hempen rope requires a DC 23 Strength check to burst it. The rope does not
|
||||
deal damage, but can be used to cause a single opponent that fails a Reflex
|
||||
saving throw to become entangled.
|
||||
|
||||
An entangled creature can break free with a DC 23 Strength check each
|
||||
futher round they are entangled, until the duration of the spell expires.
|
||||
They can not be entangled by more then one animated rope.
|
||||
|
||||
The rope itself and any knots tied in it are not magical, and so cannot be
|
||||
resisted by spell resistance nor spell immunities.
|
||||
|
||||
The spell cannot animate objects carried or worn by another creature, and
|
||||
any rope animated is lost in battle.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
This needs a ranged touch attack to work. Once it has hit, if the target
|
||||
failes a reflex save (spell save DC), they are entangled.
|
||||
|
||||
they stay entangled until the duration until a strength check of 23 is
|
||||
achieved.
|
||||
|
||||
It requires a item of the tag "PHS_Rope" to be in the inventory. This is
|
||||
lost AFTER any use magical device checks are made.
|
||||
|
||||
Ranged attack means no spell turning.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
// Delayed every 6 seconds we have duration for. This performs the
|
||||
// strength burst check.
|
||||
void RopeRoundCheck(object oTarget, object oCaster, int nRoundsRemaining);
|
||||
// Strength checks, at DC 23 by default. Reports to oTarget and oCaster
|
||||
// of the result.
|
||||
int RopeStrengthCheck(object oTarget, object oCaster, int nDC = 23);
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell Hook Check.
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// We need a rope.... ("PHS_Rope")
|
||||
if(!PHS_ComponentExactItem(PHS_ITEM_ROPE, "Rope", "Animate Rope")) return;
|
||||
|
||||
//Declare major variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject();
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nSpellSaveDC = PHS_GetSpellSaveDC();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
|
||||
// Make sure they are not immune to spells
|
||||
if(PHS_TotalSpellImmunity(oTarget)) return;
|
||||
|
||||
// Duration is every 6 seconds, remove one from rounds counter
|
||||
int nRounds = nCasterLevel;
|
||||
if(nMetaMagic == METAMAGIC_EXTEND)
|
||||
{
|
||||
nRounds *= 2;
|
||||
}
|
||||
// Need this for visual
|
||||
float fDuration = RoundsToSeconds(nRounds);
|
||||
|
||||
// Declare effects
|
||||
effect eDur = EffectVisualEffect(VFX_DUR_ENTANGLE);
|
||||
effect eEntangle = EffectEntangle();
|
||||
effect eLink = EffectLinkEffects(eDur, eEntangle);
|
||||
|
||||
// We make sure we are not targeting someone in bad PvP
|
||||
// And we make sure they are not already affected with the spell
|
||||
if(!GetIsReactionTypeFriendly(oTarget) &&
|
||||
!GetHasSpellEffect(PHS_SPELL_ANIMATE_ROPE, oTarget) &&
|
||||
// Make sure they are not immune to spells
|
||||
!PHS_TotalSpellImmunity(oTarget))
|
||||
{
|
||||
//Fire cast spell at event for the specified target
|
||||
PHS_SignalSpellCastAt(oTarget, PHS_SPELL_ANIMATE_ROPE, TRUE);
|
||||
|
||||
// Must hit the target - Ranged spell touch attack
|
||||
if(PHS_SpellTouchAttack(PHS_TOUCH_RANGED, oTarget, TRUE))
|
||||
{
|
||||
// Reflex save to negate
|
||||
if(!PHS_SavingThrow(SAVING_THROW_REFLEX, oTarget, nSpellSaveDC))
|
||||
{
|
||||
PHS_ApplyDuration(oTarget, eLink, fDuration);
|
||||
// Every 6 seconds apply a new effect.
|
||||
DelayCommand(6.0, RopeRoundCheck(oTarget, oCaster, nRounds));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
// Strength checks, at DC 23 by default. Reports to oTarget and oCaster
|
||||
// of the result.
|
||||
int RopeStrengthCheck(object oTarget, object oCaster, int nDC = 23)
|
||||
{
|
||||
// Set default results.
|
||||
string sResult = "FAIL";
|
||||
int bReturn = FALSE;
|
||||
|
||||
// Strenght modifier.
|
||||
int nModifier = GetAbilityModifier(ABILITY_STRENGTH, oTarget);
|
||||
string sMod = "+" + IntToString(nModifier);
|
||||
// Should have a -X, so remove the +X, if negative.
|
||||
if(nModifier < 0)
|
||||
{
|
||||
sMod = IntToString(nModifier);
|
||||
}
|
||||
// Roll.
|
||||
int nRoll = d20();
|
||||
string sRoll = IntToString(nRoll);
|
||||
// Did we pass?
|
||||
if((nRoll + nModifier) >= nDC)
|
||||
{
|
||||
sResult = "PASS";
|
||||
bReturn = TRUE;
|
||||
}
|
||||
// Send result messages.
|
||||
string sReport = "Strength Check: DC + "+IntToString(nDC)+". Roll: "+sRoll+". Modifier: "+sMod+". " + sResult;
|
||||
SendMessageToPC(oTarget, sReport);
|
||||
SendMessageToPC(oCaster, sReport);
|
||||
|
||||
return bReturn;
|
||||
}
|
||||
// Delayed every 6 seconds we have duration for. This performs the
|
||||
// strength burst check.
|
||||
void RopeRoundCheck(object oTarget, object oCaster, int nRoundsRemaining)
|
||||
{
|
||||
// Break if dead.
|
||||
if(!GetIsDead(oTarget) && GetIsObjectValid(oCaster) && GetIsObjectValid(oTarget) &&
|
||||
GetHasSpellEffect(PHS_SPELL_ANIMATE_ROPE, oTarget))
|
||||
{
|
||||
int nNewRounds = nRoundsRemaining - 1;
|
||||
// A strengh check to break out. Sends a message to PC and caster.
|
||||
if(RopeStrengthCheck(oTarget, oCaster))
|
||||
{
|
||||
PHS_RemoveSpellEffects(PHS_SPELL_ANIMATE_ROPE, oCaster, oTarget);
|
||||
nNewRounds = 0;
|
||||
}
|
||||
if(nNewRounds > 0)
|
||||
{
|
||||
DelayCommand(6.0, RopeRoundCheck(oTarget, oCaster, nNewRounds));
|
||||
}
|
||||
}
|
||||
}
|
@@ -1,61 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Antilife Shell
|
||||
//:: Spell FileName PHS_S_AntilifeS
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
3.2M.- Radius, 10 min/level. Sepll resistance: Yes.
|
||||
|
||||
Hedges out living creatures:
|
||||
- The effect hedges out animals, aberrations, dragons, fey, giants, humanoids,
|
||||
magical beasts, monstrous humanoids, oozes, plants, and vermin, but not
|
||||
constructs, elementals, outsiders, or undead.
|
||||
- Any creature already inside the Antilife Shell when cast can remain there.
|
||||
This spell may be used only defensively, not aggressively. If anything enters
|
||||
while moving, it breaks the spell.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
It is a mobile barrier, with a special AOE.
|
||||
|
||||
Basically, if the caster is doing an ACTION_TYPE_MOVE_TO_POINT and someone
|
||||
activates the OnEnter script, that creature makes the barrier collapse.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell Hook Check.
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Declare major variables
|
||||
object oTarget = GetSpellTargetObject();// Should be OBJECT_SELF.
|
||||
object oCaster = OBJECT_SELF;
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
|
||||
// Make sure they are not immune to spells
|
||||
if(PHS_TotalSpellImmunity(oTarget)) return;
|
||||
|
||||
// Duration in 10 minutes/level
|
||||
float fDuration = PHS_GetDuration(PHS_MINUTES, nCasterLevel * 10, nMetaMagic);
|
||||
|
||||
// Declare effects - only an enter script.
|
||||
// - Use scripts defined in the 2da.
|
||||
effect eMob = EffectAreaOfEffect(PHS_AOE_MOB_ANTILIFE_SHELL);
|
||||
|
||||
// Remove previous effects
|
||||
PHS_RemoveSpellEffectsFromTarget(PHS_SPELL_ANTILIFE_SHELL, oTarget);
|
||||
|
||||
// Set local integer so that the first ones will not be affected, which
|
||||
// is removed after 1.0 seconds.
|
||||
string sLocal = PHS_MOVING_BARRIER_START + IntToString(PHS_SPELL_ANTILIFE_SHELL);
|
||||
SetLocalInt(oCaster, sLocal, TRUE);
|
||||
DelayCommand(1.0, DeleteLocalInt(oCaster, sLocal));
|
||||
|
||||
// Apply effects
|
||||
PHS_ApplyDuration(oTarget, eMob, fDuration);
|
||||
}
|
@@ -1,72 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Antilife Shell : On Enter
|
||||
//:: Spell FileName PHS_S_AntilifeSA
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
It is a mobile barrier, with a special AOE.
|
||||
|
||||
Basically, if the caster is doing an ACTION_TYPE_MOVE_TO_POINT and someone
|
||||
activates the OnEnter script, that creature makes the barrier collapse.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Declare major variables
|
||||
object oCaster = GetAreaOfEffectCreator();
|
||||
object oTarget = GetEnteringObject();
|
||||
|
||||
// Stop if they are not an alive thing, or is plot, or is a DM
|
||||
if(GetIsDM(oTarget) || GetPlotFlag(oTarget) || oTarget == oCaster) return;
|
||||
|
||||
// If we are starting still, do not hedge back
|
||||
if(GetLocalInt(oCaster, PHS_MOVING_BARRIER_START + IntToString(PHS_SPELL_ANTILIFE_SHELL))) return;
|
||||
|
||||
// Races:
|
||||
// animals, aberrations, dragons, fey, giants, humanoids,
|
||||
// magical beasts, monstrous humanoids, oozes, plants, and vermin,
|
||||
// But not:
|
||||
// constructs, elementals, outsiders, or undead
|
||||
switch(GetRacialType(oTarget))
|
||||
{
|
||||
case RACIAL_TYPE_CONSTRUCT:
|
||||
case RACIAL_TYPE_ELEMENTAL:
|
||||
case RACIAL_TYPE_OUTSIDER:
|
||||
case RACIAL_TYPE_INVALID:
|
||||
case RACIAL_TYPE_UNDEAD:
|
||||
return;
|
||||
break;
|
||||
}
|
||||
|
||||
// Check if we are moving, and therefore cannot force it agsint soemthing
|
||||
// that would be affected!
|
||||
vector vVector = GetPosition(oCaster);
|
||||
object oArea = GetArea(oCaster);
|
||||
DelayCommand(0.1, PHS_MobileAOECheck(oCaster, PHS_SPELL_ANTILIFE_SHELL, vVector, oArea));
|
||||
|
||||
// The target is allowed a Spell resistance and immunity check to force
|
||||
// thier way through the barrier
|
||||
if(PHS_SpellResistanceCheck(oCaster, oTarget)) return;
|
||||
|
||||
// Make sure they are not immune to spells
|
||||
if(PHS_TotalSpellImmunity(oTarget)) return;
|
||||
|
||||
// Distance we need to move them back is going to be 4M away, so out of the
|
||||
// AOE.
|
||||
|
||||
// Therefore, this is 4 - Current Distance.
|
||||
float fDistance = 4.0 - GetDistanceBetween(oCaster, oTarget);
|
||||
|
||||
// Debug stuff, obviously we'll need to move them at least 1 meter away.
|
||||
if(fDistance < 1.0)
|
||||
{
|
||||
fDistance = 1.0;
|
||||
}
|
||||
|
||||
// Move the enterer back from the caster.
|
||||
PHS_PerformMoveBack(oCaster, oTarget, fDistance, GetCommandable(oTarget));
|
||||
}
|
@@ -1,35 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Antimagic Field
|
||||
//:: Spell FileName PHS_S_AntimagF
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Antimagic Field
|
||||
Abjuration
|
||||
Level: Clr 8, Magic 6, Protection 6, Sor/Wiz 6
|
||||
Components: V, S, M/DF
|
||||
Casting Time: 1 standard action
|
||||
Range: 3.33 M.
|
||||
Area: 3.33-M.-radius emanation, centered on you
|
||||
Duration: 10 min./level (D)
|
||||
Saving Throw: None
|
||||
Spell Resistance: See text
|
||||
|
||||
Description.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Rating: 10: This is very hard: Will it remove effects OnEnter, or just
|
||||
not allow spells to be cast in it, or what?
|
||||
|
||||
Placeholder script.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
}
|
@@ -1,35 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Antipathy
|
||||
//:: Spell FileName PHS_S_Antipathy
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Enchantment (Compulsion) [Mind-Affecting]
|
||||
Level: Drd 9, Sor/Wiz 8
|
||||
Components: V, S, M/DF
|
||||
Casting Time: 1 hour
|
||||
Range: Close (8M)
|
||||
Target: One location (up to a 3.33-M. cube/level) or one object
|
||||
Duration: 2 hours/level (D)
|
||||
Saving Throw: Will partial
|
||||
Spell Resistance: Yes
|
||||
|
||||
Description.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
As antilife shell, I guess. It will force them back if they come within,
|
||||
say, 10M, else they'll feel urged to leave futher away. The save means no
|
||||
moving.
|
||||
|
||||
Placeholder script.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
}
|
@@ -1,62 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Antiplant Shell
|
||||
//:: Spell FileName PHS_S_AntiPlntS
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Casting Time: 1 standard action
|
||||
Range: 3.3 M.
|
||||
Area: 3.3-M.-radius emanation, centered on you
|
||||
Duration: 10 min./level (D)
|
||||
Saving Throw: None
|
||||
Spell Resistance: Yes
|
||||
|
||||
The antiplant shell spell creates an invisible, mobile barrier that keeps
|
||||
all creatures within the shell protected from attacks by plant creatures or
|
||||
animated plants. As with many abjuration spells, forcing the barrier against
|
||||
creatures that the spell keeps at bay strains and collapses the field.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
It is a mobile barrier, with a special AOE.
|
||||
|
||||
Basically, if the caster is doing an ACTION_TYPE_MOVE_TO_POINT and someone
|
||||
activates the OnEnter script, that creature makes the barrier collapse.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell Hook Check.
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Declare major variables
|
||||
object oTarget = GetSpellTargetObject();// Should be OBJECT_SELF.
|
||||
object oCaster = OBJECT_SELF;
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
|
||||
// Make sure they are not immune to spells
|
||||
if(PHS_TotalSpellImmunity(oTarget)) return;
|
||||
|
||||
// Duration in 10 minutes/level
|
||||
float fDuration = PHS_GetDuration(PHS_MINUTES, nCasterLevel * 10, nMetaMagic);
|
||||
|
||||
// Declare effects - only an enter script.
|
||||
// - Use scripts defined in the 2da.
|
||||
effect eMob = EffectAreaOfEffect(PHS_AOE_MOB_ANTIPLANT_SHELL);
|
||||
|
||||
// Remove previous effects
|
||||
PHS_RemoveSpellEffectsFromTarget(PHS_SPELL_ANTIPLANT_SHELL, oTarget);
|
||||
|
||||
// Set local integer so that the first ones will not be affected, which
|
||||
// is removed after 1.0 seconds.
|
||||
SetLocalInt(oTarget, PHS_MOVING_BARRIER_START, TRUE);
|
||||
DelayCommand(1.0, DeleteLocalInt(oTarget, PHS_MOVING_BARRIER_START));
|
||||
|
||||
// Apply effects
|
||||
PHS_ApplyDuration(oTarget, eMob, fDuration);
|
||||
}
|
@@ -1,79 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Antiplant Shell : On Enter
|
||||
//:: Spell FileName PHS_S_AntiPlntSA
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
It is a mobile barrier, with a special AOE.
|
||||
|
||||
Basically, if the caster is doing an ACTION_TYPE_MOVE_TO_POINT and someone
|
||||
activates the OnEnter script, that creature makes the barrier collapse.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
// Moves back oTarget from oCaster, fDistance.
|
||||
void DoMoveBack(object oCaster, object oTarget, float fDistance, int iOriginalCommandable);
|
||||
|
||||
void main()
|
||||
{
|
||||
// Declare major variables
|
||||
object oCaster = GetAreaOfEffectCreator();
|
||||
object oTarget = GetEnteringObject();
|
||||
|
||||
// Stop if they are not an alive thing, or is plot, or is a DM
|
||||
if(GetIsDM(oTarget) || GetPlotFlag(oTarget) || oTarget == oCaster) return;
|
||||
|
||||
// If we are starting still, do not hedge back
|
||||
if(GetLocalInt(oCaster, PHS_MOVING_BARRIER_START)) return;
|
||||
|
||||
// Races:
|
||||
// plants
|
||||
// But not:
|
||||
// anything else
|
||||
if(!PHS_GetIsPlant(oTarget)) return;
|
||||
|
||||
// Check if we are moving, and therefore cannot force it agsint soemthing
|
||||
// that would be affected!
|
||||
vector vVector = GetPosition(oCaster);
|
||||
object oArea = GetArea(oCaster);
|
||||
DelayCommand(0.1, PHS_MobileAOECheck(oCaster, PHS_SPELL_ANTIPLANT_SHELL, vVector, oArea));
|
||||
|
||||
// The target is allowed a Spell resistance and immunity check to force
|
||||
// thier way through the barrier
|
||||
if(PHS_SpellResistanceCheck(oCaster, oTarget)) return;
|
||||
|
||||
// Make sure they are not immune to spells
|
||||
if(PHS_TotalSpellImmunity(oTarget)) return;
|
||||
|
||||
// Distance we need to move them back is going to be 4M away, so out of the
|
||||
// AOE.
|
||||
|
||||
// Therefore, this is 4 - Current Distance.
|
||||
float fDistance = 4.0 - GetDistanceBetween(oCaster, oTarget);
|
||||
|
||||
// Debug stuff, obviously we'll need to move them at least 1 meter away.
|
||||
if(fDistance < 1.0)
|
||||
{
|
||||
fDistance = 1.0;
|
||||
}
|
||||
|
||||
// Move the enterer back from the caster.
|
||||
DoMoveBack(oCaster, oTarget, fDistance, GetCommandable(oTarget));
|
||||
}
|
||||
|
||||
// Moves back oTarget from oCaster, fDistance.
|
||||
void DoMoveBack(object oCaster, object oTarget, float fDistance, int iOriginalCommandable)
|
||||
{
|
||||
// Get new location, fDistance, behind them.
|
||||
location lMoveTo = PHS_GetLocationBehind(oCaster, oTarget, fDistance);
|
||||
|
||||
// Move the target back to that point
|
||||
SetCommandable(TRUE, oTarget);
|
||||
// Assign commands
|
||||
AssignCommand(oTarget, JumpToLocation(lMoveTo));
|
||||
// Set to original commandability.
|
||||
SetCommandable(iOriginalCommandable);
|
||||
}
|
@@ -1,22 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name AOE - Heartbeat - Auto Detected Magical Trap AOE, level 1.
|
||||
//:: Spell FileName PHS_S_AOE_Auto1
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Sets to be automatically detected, level 1 spell "magical trap".
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Automatically detected
|
||||
if(!GetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED))
|
||||
{
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED, TRUE);
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_LEVEL, 1);
|
||||
}
|
||||
}
|
@@ -1,22 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name AOE - Heartbeat - Auto Detected Magical Trap AOE, level 2.
|
||||
//:: Spell FileName PHS_S_AOE_Auto2
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Sets to be automatically detected, level 2 spell "magical trap".
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Automatically detected
|
||||
if(!GetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED))
|
||||
{
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED, TRUE);
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_LEVEL, 2);
|
||||
}
|
||||
}
|
@@ -1,22 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name AOE - Heartbeat - Auto Detected Magical Trap AOE, level 3.
|
||||
//:: Spell FileName PHS_S_AOE_Auto3
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Sets to be automatically detected, level 3 spell "magical trap".
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Automatically detected
|
||||
if(!GetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED))
|
||||
{
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED, TRUE);
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_LEVEL, 3);
|
||||
}
|
||||
}
|
@@ -1,22 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name AOE - Heartbeat - Auto Detected Magical Trap AOE, level 4.
|
||||
//:: Spell FileName PHS_S_AOE_Auto4
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Sets to be automatically detected, level 4 spell "magical trap".
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Automatically detected
|
||||
if(!GetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED))
|
||||
{
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED, TRUE);
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_LEVEL, 4);
|
||||
}
|
||||
}
|
@@ -1,22 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name AOE - Heartbeat - Auto Detected Magical Trap AOE, level 5.
|
||||
//:: Spell FileName PHS_S_AOE_Auto5
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Sets to be automatically detected, level 5 spell "magical trap".
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Automatically detected
|
||||
if(!GetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED))
|
||||
{
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED, TRUE);
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_LEVEL, 5);
|
||||
}
|
||||
}
|
@@ -1,22 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name AOE - Heartbeat - Auto Detected Magical Trap AOE, level 6.
|
||||
//:: Spell FileName PHS_S_AOE_Auto6
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Sets to be automatically detected, level 6 spell "magical trap".
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Automatically detected
|
||||
if(!GetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED))
|
||||
{
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED, TRUE);
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_LEVEL, 6);
|
||||
}
|
||||
}
|
@@ -1,22 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name AOE - Heartbeat - Auto Detected Magical Trap AOE, level 7.
|
||||
//:: Spell FileName PHS_S_AOE_Auto7
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Sets to be automatically detected, level 7 spell "magical trap".
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Automatically detected
|
||||
if(!GetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED))
|
||||
{
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED, TRUE);
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_LEVEL, 7);
|
||||
}
|
||||
}
|
@@ -1,22 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name AOE - Heartbeat - Auto Detected Magical Trap AOE, level 8.
|
||||
//:: Spell FileName PHS_S_AOE_Auto8
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Sets to be automatically detected, level 8 spell "magical trap".
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Automatically detected
|
||||
if(!GetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED))
|
||||
{
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED, TRUE);
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_LEVEL, 7);
|
||||
}
|
||||
}
|
@@ -1,22 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name AOE - Heartbeat - Auto Detected Magical Trap AOE, level 9.
|
||||
//:: Spell FileName PHS_S_AOE_Auto9
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Sets to be automatically detected, level 9 spell "magical trap".
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Automatically detected
|
||||
if(!GetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED))
|
||||
{
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_ALWAYS_DETECTED, TRUE);
|
||||
SetLocalInt(OBJECT_SELF, PHS_MAGICAL_TRAP_LEVEL, 9);
|
||||
}
|
||||
}
|
@@ -1,22 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name AOE - Heartbeat - Normal Magical Trap AOE, level 9.
|
||||
//:: Spell FileName PHS_S_AOE_Norm9
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Checks for PC's (rogues) nearby. May detect this magical trap - DC is
|
||||
25 + spell level.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Declare major variables
|
||||
int nLevel = 9;
|
||||
|
||||
// Detect traps! Who is near enough?
|
||||
PHS_MagicalTrapsDetect(nLevel);
|
||||
}
|
@@ -1,54 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Arcane Eye
|
||||
//:: Spell FileName PHS_S_ArcaneEye
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Divination (Scrying)
|
||||
Level: Sor/Wiz 4
|
||||
Components: V, S, M
|
||||
Casting Time: 10 minutes
|
||||
Range: Unlimited
|
||||
Effect: Magical sensor
|
||||
Duration: 1 min./level (D)
|
||||
Saving Throw: None
|
||||
Spell Resistance: No
|
||||
|
||||
Description.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Rating: 9: Requires cutseens to see what the eye sees, but it is
|
||||
possible to do I guess.
|
||||
|
||||
Placeholder script.
|
||||
|
||||
As in:
|
||||
- Create a new object (and cutscene dominate or whatever it), which is the eye.
|
||||
- MAke it very easy to kill
|
||||
- "possess" it via. using a power or something
|
||||
- Move the caster (and make a copy of the caster) and turn them into the
|
||||
eye.
|
||||
- If they (or thier body) is attacked, end the spell.
|
||||
|
||||
Note: Note in description the eye isn't too small, and will trigger traps
|
||||
and if attacked will go away.
|
||||
|
||||
Note 2: Make sure that the PC knows that any invisiblity effects they have will go
|
||||
away when they use the spell to look at something (the spell makes the
|
||||
creature cutscene invisible to mean we don't see lots of visuals, but it
|
||||
still can be attacked by things. Or maybe make it so it can't?)
|
||||
|
||||
Maybe make the PC not cutscene invisible, but actually make a quick eye
|
||||
for this, which yes, will have all effects (but will never be invisible etc.)
|
||||
visible, but thats more a hinderence then anything.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
}
|
@@ -1,35 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Arcane Lock
|
||||
//:: Spell FileName PHS_S_ArcaneLock
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Abjuration
|
||||
Level: Sor/Wiz 2
|
||||
Components: V, S, M
|
||||
Casting Time: 1 standard action
|
||||
Range: Touch
|
||||
Target: The door, chest, or portal touched, up to 10 sq. M./level in size
|
||||
Duration: Permanent
|
||||
Saving Throw: None
|
||||
Spell Resistance: No
|
||||
|
||||
Description.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Rating: Depends. If simply put as "Locks a door", as long as it doesn't
|
||||
require a key and isn't plot anyway, it'd work great.
|
||||
|
||||
Placeholder script.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
}
|
||||
|
@@ -1,64 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Arcane Mark
|
||||
//:: Spell FileName PHS_S_ArcaneMark
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Universal
|
||||
Level: Sor/Wiz 0
|
||||
Components: V, S
|
||||
Casting Time: 1 standard action
|
||||
Range: 0M.
|
||||
Effect: One personal rune or mark, all of which must fit within 0.33 sq. M.
|
||||
Duration: Permanent
|
||||
Saving Throw: None
|
||||
Spell Resistance: No
|
||||
|
||||
This spell allows you to inscribe your personal rune or mark, which can
|
||||
consist of no more than six characters. The writing can be visible or
|
||||
invisible. An arcane mark spell enables you to etch the rune upon any
|
||||
substance without harm to the material upon which it is placed. If an
|
||||
invisible mark is made, a detect magic spell causes it to glow and be visible,
|
||||
though not necessarily understandable.
|
||||
|
||||
See invisibility, true seeing, a gem of seeing, or a robe of eyes likewise
|
||||
allows the user to see an invisible arcane mark. A read magic spell reveals
|
||||
the words, if any. The mark cannot be dispelled, but it can be removed by
|
||||
the caster or by an erase spell.
|
||||
|
||||
If an arcane mark is placed on a living being, normal wear gradually causes
|
||||
the effect to fade in about a month.
|
||||
|
||||
Arcane mark must be cast on an object prior to casting instant summons on
|
||||
the same object (see that spell description for details).
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Creates a placeable which does the visual effect and stuff.
|
||||
|
||||
Mainly a placeholder!
|
||||
|
||||
Rating: 1: Need to add a thing to look at the markings (placeable
|
||||
probably), and set the text on that. Text is setup beforehand.
|
||||
|
||||
Set the text on chat, and when set, set to a custom number thingy.
|
||||
|
||||
Then make the placable have that custom number as it's text - like a converation,
|
||||
because it works.
|
||||
|
||||
Possibly make it so it can never be made invisible.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell Hook Check
|
||||
if(!PHS_SpellHookCheck(PHS_SPELL_ARCANE_MARK)) return;
|
||||
|
||||
// Declare major variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
location lTarget = GetLocation(oCaster);
|
||||
}
|
@@ -1,57 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Arcane Sight
|
||||
//:: Spell FileName PHS_S_ArcaneSht
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Divination
|
||||
Level: Sor/Wiz 3
|
||||
Components: V, S
|
||||
Casting Time: 1 standard action
|
||||
Range: Personal
|
||||
Target: You
|
||||
Duration: 1 min./level (D)
|
||||
|
||||
This spell makes your eyes glow blue and allows you to see magical auras
|
||||
within 120 feet of you. The effect is similar to that of a detect magic
|
||||
spell, but arcane sight does not require concentration and discerns aura
|
||||
location and power more quickly.
|
||||
|
||||
You know the location and power of all magical auras within your sight.
|
||||
An aura<72>s power depends on a spell<6C>s functioning level or an item<65>s caster
|
||||
level, as noted in the description of the detect magic spell. If the items
|
||||
or creatures bearing the auras are in line of sight, you can make Spellcraft
|
||||
skill checks to determine the school of magic involved in each. (Make one
|
||||
check per aura; DC 15 + spell level, or 15 + one-half caster level for a
|
||||
nonspell effect.)
|
||||
|
||||
If you concentrate on a specific creature within 120 feet of you as a
|
||||
standard action, you can determine whether it has any spellcasting or
|
||||
spell-like abilities, whether these are arcane or divine (spell-like
|
||||
abilities register as arcane), and the strength of the most powerful
|
||||
spell or spell-like ability the creature currently has available for use.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Rating: 6: Need to have some DB accessing and stuff...hmmm.
|
||||
|
||||
Scratch the DB accessing stuff, I think...
|
||||
|
||||
Placeholder script.
|
||||
|
||||
Ok, what it can do:
|
||||
|
||||
- Look at things in a heartbeat, and tell the player what he see's glowing
|
||||
(visible creatures, objects etc.)
|
||||
- Can specifically target something with a power to access more information
|
||||
about it.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
}
|
@@ -1,31 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Arcane Sight, Greater
|
||||
//:: Spell FileName PHS_S_ArcaneShtG
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Divination
|
||||
Level: Sor/Wiz 7
|
||||
Components: V, S
|
||||
Casting Time: 1 standard action
|
||||
Range: Personal
|
||||
Target: You
|
||||
Duration: 1 min./level (D)
|
||||
|
||||
Description.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Rating: As arcane sight. More powerful!
|
||||
|
||||
Placeholder script.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
}
|
@@ -1,33 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Astral Projection
|
||||
//:: Spell FileName PHS_S_AstralProj
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Necromancy
|
||||
Level: Clr 9, Sor/Wiz 9, Travel 9
|
||||
Components: V, S, M
|
||||
Casting Time: 30 minutes
|
||||
Range: Touch
|
||||
Targets: You plus one additional willing creature touched per two caster levels
|
||||
Duration: See text
|
||||
Saving Throw: None
|
||||
Spell Resistance: Yes
|
||||
|
||||
Description.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Rating: 10: Needs plane work.
|
||||
|
||||
Placeholder script.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
}
|
@@ -1,33 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Atonement
|
||||
//:: Spell FileName PHS_S_Atonement
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Abjuration
|
||||
Level: Clr 5, Drd 5
|
||||
Components: V, S, M, F, DF, XP
|
||||
Casting Time: 1 hour
|
||||
Range: Touch
|
||||
Target: Living creature touched
|
||||
Duration: Instantaneous
|
||||
Saving Throw: None
|
||||
Spell Resistance: Yes
|
||||
|
||||
Description.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
|
||||
|
||||
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
}
|
@@ -1,105 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Augury
|
||||
//:: Spell FileName PHS_S_Augury
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Divination
|
||||
Level: Clr 2
|
||||
Components: V, S, M, F
|
||||
Casting Time: 1 minute
|
||||
Range: Personal
|
||||
Target: You
|
||||
Duration: Instantaneous
|
||||
DM Spell
|
||||
|
||||
An augury can tell you whether a particular action will bring good or bad
|
||||
results for you in the immediate future.
|
||||
|
||||
The base chance for receiving a meaningful reply is 70% + 1% per caster level,
|
||||
to a maximum of 90%; this roll is made secretly. A question may be so
|
||||
straightforward that a successful result is automatic, or so vague as to have
|
||||
no chance of success. If the augury succeeds, you get one of four results:
|
||||
|
||||
<20> Weal (if the action will probably bring good results).
|
||||
<20> Woe (for bad results).
|
||||
<20> Weal and woe (for both).
|
||||
<20> Nothing (for actions that don<6F>t have especially good or bad results).
|
||||
|
||||
If the spell fails, you get the <20>nothing<6E> result. A cleric who gets the
|
||||
<20>nothing<6E> result has no way to tell whether it was the consequence of a
|
||||
failed or successful augury.
|
||||
|
||||
The augury can see into the future only about half an hour, so anything that
|
||||
might happen after that does not affect the result. Thus, the result might
|
||||
not take into account the long-term consequences of a contemplated action.
|
||||
All auguries cast by the same person about the same topic use the same dice
|
||||
result as the first casting.
|
||||
|
||||
This is a DM spell, and only a DM can determine if a result will be one of
|
||||
the 4 above. Make sure a DM knows what you asked. Everything but the result
|
||||
is automatic.
|
||||
|
||||
Material Component: Incense worth at least 25 gp.
|
||||
|
||||
Focus: A set of marked sticks, bones, or similar tokens of at least 25 gp
|
||||
value.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Automatic stuff, apart from the result.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell hook check.
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Check for material componant
|
||||
if(!PHS_ComponentExactItemRemove(PHS_ITEM_INCENSE_25, "Incense worth 25GP", "Augury")) return;
|
||||
|
||||
// Check for spell focus
|
||||
if(!PHS_ComponentFocusItem(PHS_ITEM_MARKED_STICKS_25, "Marked sticks or similar worth 25GP", "Augury")) return;
|
||||
|
||||
//Declare major variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject(); // Should be OBJECT_SELF.
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
// - 70% + 1% per caster level, to a maximum of 90%;
|
||||
int nPercent = 70 + PHS_LimitInteger(nCasterLevel, 20);
|
||||
|
||||
// Make sure they are not immune to spells
|
||||
if(PHS_TotalSpellImmunity(oTarget)) return;
|
||||
|
||||
// Delcare effects
|
||||
effect eVis = EffectVisualEffect(VFX_IMP_MAGICAL_VISION);
|
||||
|
||||
// Alery DM's
|
||||
PHS_AlertDMsOfSpell("Augury", PHS_GetSpellSaveDC(), nCasterLevel);
|
||||
|
||||
// d100 % roll - needs to be under nPercent (71 to 90)
|
||||
if(d100() <= nPercent)
|
||||
{
|
||||
// PASS
|
||||
// Send message of pass
|
||||
SendMessageToAllDMs("Augury: Result: PASS. Allow Meaningfull Reply");
|
||||
}
|
||||
else
|
||||
{
|
||||
// Send message of fail
|
||||
SendMessageToAllDMs("Augury: Result: FAIL. No meaningfull reply");
|
||||
}
|
||||
|
||||
// Signal event
|
||||
PHS_SignalSpellCastAt(oTarget, PHS_SPELL_AUGURY, FALSE);
|
||||
|
||||
// Apply effects
|
||||
PHS_ApplyVFX(oTarget, eVis);
|
||||
|
||||
// Also play animation - pray
|
||||
PlayAnimation(ANIMATION_LOOPING_MEDITATE);
|
||||
}
|
@@ -1,97 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Awaken
|
||||
//:: Spell FileName PHS_S_Awaken
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
This will awaken a tree (not in) or animal. Casting time is 24 hours!? well,
|
||||
is actually 10 rounds in NwN because it is a real time game.
|
||||
Will save of 10 + animals HD to suceeed.
|
||||
Awakened animal will be friendly, and will join your party as
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
As it says (animals only).
|
||||
|
||||
Permament duration and effects, like the spell says. Henchmen until it is
|
||||
attacked by the caster or released from its duty.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell hook check.
|
||||
if(!PHS_SpellHookCheck(PHS_SPELL_AWAKEN)) return;
|
||||
|
||||
// Declare major variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
|
||||
// Make sure they are not immune to spells
|
||||
if(PHS_TotalSpellImmunity(oTarget)) return;
|
||||
|
||||
// Check we have the XP needed
|
||||
if(!PHS_ComponentXPCheck(250, oCaster)) return;
|
||||
|
||||
// Remove the XP
|
||||
PHS_ComponentXPRemove(250, oCaster);
|
||||
|
||||
// Check if the target is valid! (IE animal!)
|
||||
if(GetRacialType(oTarget) != RACIAL_TYPE_ANIMAL ||
|
||||
GetAbilityScore(oTarget, ABILITY_INTELLIGENCE) >= 10)
|
||||
{
|
||||
SendMessageToPC(oCaster, "Your chosen target is either not an animal, or is already quite intelligent");
|
||||
return;
|
||||
}
|
||||
|
||||
// Make sure they do not try and get another faction member's animal to come.
|
||||
if(GetIsObjectValid(GetMaster(oTarget)) && GetMaster(oTarget) != oCaster)
|
||||
{
|
||||
SendMessageToPC(oCaster, "You cannot awaken a creature who is summoned and not your own");
|
||||
return;
|
||||
}
|
||||
|
||||
// Save DC is 10 + animals current HD
|
||||
int nWillDC = 10 + GetHitDice(oTarget);
|
||||
|
||||
// Random Intelligence and charisma bonuses
|
||||
int nInt = PHS_MaximizeOrEmpower(6, 3, nMetaMagic);
|
||||
int nCha = PHS_MaximizeOrEmpower(3, 1, nMetaMagic);
|
||||
|
||||
// Declare effects
|
||||
effect eVis = EffectVisualEffect(PHS_VFX_FNF_AWAKEN);
|
||||
effect eInt = EffectAbilityIncrease(ABILITY_INTELLIGENCE, nInt);
|
||||
effect eCha = EffectAbilityIncrease(ABILITY_CHARISMA, nCha);
|
||||
effect eAttack = EffectAttackIncrease(1);
|
||||
effect eCessate = EffectVisualEffect(VFX_DUR_CESSATE_POSITIVE);
|
||||
|
||||
// Link effects - they are just magical, mind you.
|
||||
effect eLink = EffectLinkEffects(eInt, eCha);
|
||||
eLink = EffectLinkEffects(eLink, eAttack);
|
||||
eLink = EffectLinkEffects(eLink, eCessate);
|
||||
|
||||
// Will save check
|
||||
if(PHS_NotSpellSavingThrow(SAVING_THROW_WILL, oCaster, nWillDC))
|
||||
{
|
||||
// Signal spell cast at
|
||||
PHS_SignalSpellCastAt(oTarget, PHS_SPELL_AWAKEN, FALSE);
|
||||
|
||||
// Remove previous effects
|
||||
PHS_RemoveSpellEffectsFromTarget(PHS_SPELL_AWAKEN, oTarget);
|
||||
|
||||
// Apply VFX and permanent effect.
|
||||
PHS_ApplyPermanentAndVFX(oTarget, eVis, eLink);
|
||||
|
||||
// Also add them as a henchmen if they can be
|
||||
if(!GetIsImmune(oTarget, IMMUNITY_TYPE_MIND_SPELLS) &&
|
||||
!GetIsImmune(oTarget, IMMUNITY_TYPE_CHARM) &&
|
||||
!GetFactionEqual(oTarget, oCaster))
|
||||
{
|
||||
AddHenchman(oCaster, oTarget);
|
||||
}
|
||||
}
|
||||
}
|
@@ -1,187 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Baleful Polymorph
|
||||
//:: Spell FileName PHS_S_BaleflPoly
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Transmutation
|
||||
Level: Drd 5, Sor/Wiz 5
|
||||
Components: V, S
|
||||
Casting Time: 1 standard action
|
||||
Range: Close (8M)
|
||||
Target: One creature
|
||||
Duration: Permanent
|
||||
Saving Throw: Fortitude negates, Will partial; see text
|
||||
Spell Resistance: Yes
|
||||
|
||||
As polymorph, except that you change the subject into a Small or smaller
|
||||
animal of no more than 1 HD. If this is cast at a non-party member, the target
|
||||
recieves a +4 save bonus, for it being fatal.
|
||||
|
||||
Small animals include:
|
||||
- Rat, Parrot, Seagull, Snake
|
||||
|
||||
If the spell succeeds, the subject must also make a Will save. If this
|
||||
second save fails, the creature gains the new Wisdom, intelligence and
|
||||
Charisma of the new form.
|
||||
|
||||
Even if the second save suceeds, the target is unable to cast spells, but
|
||||
does retain its orignal hit dice and classes.
|
||||
|
||||
Shapechangers, Incorporeal or gaseous creatures are immune to being
|
||||
polymorphed, and Shapeshifter classes can revert back to thier normal form
|
||||
even if all the saves were failed, after one round.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Rating: 3: But requires polymorph entries. Toad and Rat will be 2 of them,
|
||||
maybe more. It will be permament - ouch
|
||||
|
||||
Not too sure...hmm...
|
||||
|
||||
An enemy polymorph spell. Can change it and just make it an un-cancleable
|
||||
polymorph (which can be dispelled) which is obivously quite powerful.
|
||||
|
||||
Shifters are immune to the cancle part.
|
||||
|
||||
- Rat
|
||||
- Parrot
|
||||
- Seagull
|
||||
- Snake
|
||||
|
||||
Maybe:
|
||||
- Toad (?)
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Turning Notes
|
||||
//:://////////////////////////////////////////////
|
||||
This does apply. After Spell Resistance is checked on the target (IE: If
|
||||
they are naturally immune, especially via immunity to this specific spell)
|
||||
we check for spell turning.
|
||||
|
||||
If it is sucessful, the caster makes the SR and save check against the
|
||||
effect.
|
||||
|
||||
If they both have it, then it does as the rules say - % chance of being
|
||||
the affected one.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
// Do effects of spell (here for Spell turning)
|
||||
void DoBalefulEffects(object oTarget, int nPolymorph, int nSpellSaveDC, object oCaster = OBJECT_SELF);
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell Hook Check
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Declare major variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject();
|
||||
int nSpellSaveDC = PHS_GetSpellSaveDC();
|
||||
int nPolymorph = PHS_GetLocalConstant(oCaster, "PHS_BALEFUL_POLYMORPH_CHOICE");
|
||||
int bLocked = TRUE;
|
||||
|
||||
// Default to Rat
|
||||
if(nPolymorph == -1)
|
||||
{
|
||||
nPolymorph = 1;
|
||||
}
|
||||
|
||||
// PvP
|
||||
if(!GetIsReactionTypeFriendly(oTarget))
|
||||
{
|
||||
// Signal Spell cast at
|
||||
PHS_SignalSpellCastAt(oTarget, PHS_SPELL_BALEFUL_POLYMORPH, TRUE);
|
||||
|
||||
// Do a spell reistance check
|
||||
if(!PHS_SpellResistanceCheck(oCaster, oTarget))
|
||||
{
|
||||
// Spell turning!
|
||||
int nSpellTurning = PHS_SpellTurningCheck(oCaster, oTarget, PHS_ArrayGetSpellLevel(PHS_SPELL_BALEFUL_POLYMORPH, GetLastSpellCastClass()));
|
||||
|
||||
// 1 = No effect
|
||||
if(nSpellTurning == 1)
|
||||
{
|
||||
// Stop
|
||||
return;
|
||||
}
|
||||
else if(nSpellTurning == 2)
|
||||
{
|
||||
// Affect the caster only, full power.
|
||||
DoBalefulEffects(oCaster, nPolymorph, nSpellSaveDC);
|
||||
}
|
||||
else if(nSpellTurning == 3)
|
||||
{
|
||||
// Affects the caster OR the target, a % type thing. Set on local that can be
|
||||
// retrieved. If damaging, part damage each. If not, % chance to affect either.
|
||||
// Get the %. This one it is a chance of affecting us...
|
||||
int nFraction = FloatToInt(GetLocalFloat(oCaster, PHS_SPELL_TURNING_FRACTION) * 100);
|
||||
|
||||
// Check
|
||||
// - If the d100 is LESS then nFaction, it is GOOD for the target -
|
||||
// thus we affect the caster. Else, affect the target normally.
|
||||
if(d100() <= nFraction)
|
||||
{
|
||||
DoBalefulEffects(oCaster, nPolymorph, nSpellSaveDC);
|
||||
}
|
||||
else
|
||||
{
|
||||
DoBalefulEffects(oTarget, nPolymorph, nSpellSaveDC);
|
||||
}
|
||||
}
|
||||
else //if(nSpellTurning == 4)
|
||||
{
|
||||
// 4 = Spell affects both people equally at full effect.
|
||||
DoBalefulEffects(oCaster, nPolymorph, nSpellSaveDC);
|
||||
DoBalefulEffects(oTarget, nPolymorph, nSpellSaveDC);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Do effects of spell (here for Spell turning)
|
||||
void DoBalefulEffects(object oTarget, int nPolymorph, int nSpellSaveDC, object oCaster = OBJECT_SELF)
|
||||
{
|
||||
int bContinue = TRUE;
|
||||
if(oTarget == oCaster)
|
||||
{
|
||||
bContinue = PHS_SpellResistanceCheck(oCaster, oTarget);
|
||||
}
|
||||
if(bContinue)
|
||||
{
|
||||
// If they are not a friend (in the same faction) we take 4 away from the DC
|
||||
if(!GetFactionEqual(oTarget))
|
||||
{
|
||||
nSpellSaveDC -= 4;
|
||||
}
|
||||
|
||||
// They can auto cancle if they are a shapechanger.
|
||||
int bLocked = (PHS_GetIsShapechangerSubtype(oTarget) == FALSE);
|
||||
|
||||
// Declare effects
|
||||
effect eVis = EffectVisualEffect(PHS_VFX_IMP_BALEFUL_POLYMORPH);
|
||||
effect ePolymorph = EffectPolymorph(nPolymorph, bLocked);
|
||||
|
||||
// Fortitude save negates
|
||||
if(!PHS_SavingThrow(SAVING_THROW_FORT, oTarget, nSpellSaveDC))
|
||||
{
|
||||
// Gaseous and so on are polymorph immune
|
||||
if(!PHS_ImmuneToPolymorph(oTarget))
|
||||
{
|
||||
// Apply polymorph effects
|
||||
PHS_ApplyPolymorphPermanentAndVFX(oTarget, eVis, ePolymorph);
|
||||
|
||||
// If they fail a will save, we also apply penalties to thier
|
||||
// Intelligence, will and Charisma.
|
||||
if(!PHS_SavingThrow(SAVING_THROW_WILL, oTarget, nSpellSaveDC))
|
||||
{
|
||||
// Penalties applied...somehow, on the hide probably...
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@@ -1,113 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Bane
|
||||
//:: Spell FileName PHS_S_Bane
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Bane
|
||||
Enchantment (Compulsion) [Fear, Mind-Affecting]
|
||||
Level: Clr 1
|
||||
Components: V, S, DF
|
||||
Casting Time: 1 standard action
|
||||
Range: 10 Meters
|
||||
Area: All enemies within 10 Meters
|
||||
Duration: 1 min./level
|
||||
Saving Throw: Will negates
|
||||
Spell Resistance: Yes
|
||||
|
||||
Bane fills your enemies with fear and doubt. Each affected creature takes a
|
||||
-1 penalty on attack rolls and a -1 penalty on saving throws against fear
|
||||
effects.
|
||||
|
||||
Bane counters and dispels bless.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
If they have bless, it dispels it, else it causes -1 to attack rolls
|
||||
and saves VS fear.
|
||||
|
||||
This counters bless.
|
||||
|
||||
It is a fear saving throw too :-)
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell hook check.
|
||||
if(PHS_SpellHookCheck()) return;
|
||||
|
||||
// Define major variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
location lSelf = GetLocation(oCaster);
|
||||
object oTarget;
|
||||
// Delay = distance / 20
|
||||
float fDelay;
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nSpellSaveDC = PHS_GetSpellSaveDC();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
// Duration is in turns
|
||||
float fDuration = PHS_GetDuration(PHS_MINUTES, nCasterLevel, nMetaMagic);
|
||||
|
||||
// Effect - attack -1, effect -1 save vs. fear.
|
||||
effect eAttack = EffectAttackDecrease(1);
|
||||
effect eMorale = EffectSavingThrowDecrease(SAVING_THROW_ALL, 1, SAVING_THROW_TYPE_FEAR);
|
||||
effect eDur = EffectVisualEffect(VFX_DUR_CESSATE_NEGATIVE);
|
||||
effect eVis = EffectVisualEffect(VFX_IMP_HEAD_EVIL);
|
||||
// Link effects
|
||||
effect eLink = EffectLinkEffects(eAttack, eMorale);
|
||||
eLink = EffectLinkEffects(eLink, eDur);
|
||||
eLink = EffectLinkEffects(eLink, eVis);
|
||||
|
||||
// This is the dispel effect used when they have bless.
|
||||
effect eDispel = EffectVisualEffect(VFX_IMP_HEAD_EVIL);
|
||||
|
||||
// AOE visual applied.
|
||||
effect eImpact = EffectVisualEffect(VFX_FNF_LOS_EVIL_30);
|
||||
PHS_ApplyLocationVFX(lSelf, eImpact);
|
||||
|
||||
// Loop enemies - and apply the effects.
|
||||
oTarget = GetFirstObjectInShape(SHAPE_SPHERE, RADIUS_SIZE_FEET_30, lSelf);
|
||||
while(GetIsObjectValid(oTarget))
|
||||
{
|
||||
// Only affects non-friends. PvP Check. Must be able to be affected
|
||||
if(!GetIsFriend(oTarget) && !GetFactionEqual(oTarget) &&
|
||||
oTarget != oCaster && GetIsReactionTypeHostile(oTarget) &&
|
||||
// Make sure they are not immune to spells
|
||||
!PHS_TotalSpellImmunity(oTarget))
|
||||
{
|
||||
//Fire cast spell at event for the specified target
|
||||
PHS_SignalSpellCastAt(oTarget, PHS_SPELL_BANE);
|
||||
|
||||
// Delay for visuals and effects.
|
||||
fDelay = GetDistanceBetween(oCaster, oTarget)/20;
|
||||
|
||||
// Resistance and immunity checking. Check fear + mind immunity too
|
||||
if(!PHS_SpellResistanceCheck(oCaster, oTarget, fDelay) &&
|
||||
!PHS_ImmunityCheck(oTarget, IMMUNITY_TYPE_MIND_SPELLS) &&
|
||||
!PHS_ImmunityCheck(oTarget, IMMUNITY_TYPE_FEAR))
|
||||
{
|
||||
// Fear will-based saving throw.
|
||||
if(!PHS_SavingThrow(SAVING_THROW_WILL, oTarget, nSpellSaveDC, SAVING_THROW_TYPE_FEAR, oCaster, fDelay))
|
||||
{
|
||||
// Remove bless - dispells it.
|
||||
if(PHS_RemoveSpellEffectsFromTarget(SPELL_BLESS, oTarget, fDelay))
|
||||
{
|
||||
// Apply effect if we remove any.
|
||||
DelayCommand(fDelay, PHS_ApplyVFX(oTarget, eDispel));
|
||||
}
|
||||
else
|
||||
{
|
||||
//Apply the VFX impact and effects
|
||||
DelayCommand(fDelay, PHS_ApplyVFX(oTarget, eVis));
|
||||
PHS_ApplyDuration(oTarget, eLink, fDuration);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
oTarget = GetNextObjectInShape(SHAPE_SPHERE, RADIUS_SIZE_FEET_30, lSelf);
|
||||
}
|
||||
}
|
@@ -1,35 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Banishment
|
||||
//:: Spell FileName PHS_S_Banishment
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Abjuration
|
||||
Level: Clr 6, Sor/Wiz 7
|
||||
Components: V, S, F
|
||||
Casting Time: 1 standard action
|
||||
Range: Close (8M)
|
||||
Targets: One or more enemy extraplanar creatures within a 5M-radius sphere
|
||||
Duration: Instantaneous
|
||||
Saving Throw: Will negates
|
||||
Spell Resistance: Yes
|
||||
|
||||
Desciption.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Rating: 8: because of the "improve the chances of sucess" bit. Probably 3
|
||||
otherwise. You get NO XP when using this. And needs extra integers for
|
||||
planes and stuff
|
||||
|
||||
Placeholder script.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
}
|
@@ -1,70 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Bear<61>s Endurance
|
||||
//:: Spell FileName PHS_S_BearsEnd
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Transmutation
|
||||
Level: Clr 2, Drd 2, Rgr 2, Sor/Wiz 2
|
||||
Components: V, S, DF
|
||||
Casting Time: 1 standard action
|
||||
Range: Touch
|
||||
Target: Creature touched
|
||||
Duration: 1 min./level
|
||||
Saving Throw:Will negates (harmless)
|
||||
Spell Resistance: Yes
|
||||
|
||||
The affected creature gains greater vitality and stamina. The spell grants
|
||||
the subject a +4 enhancement bonus to Constitution, which adds the usual
|
||||
benefits to hit points, Fortitude saves, Constitution checks, and so forth.
|
||||
|
||||
Hit points gained by a temporary increase in Constitution score are not
|
||||
temporary hit points. They go away when the subject<63>s Constitution drops
|
||||
back to normal. They are not lost first as temporary hit points are.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
+4 to stat, doesn't stack with mass version.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell hook check.
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Declare major variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject();
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
// Ability to use
|
||||
int nAbility = ABILITY_CONSTITUTION;
|
||||
|
||||
// Duration - 1 minute/level
|
||||
float fDuration = PHS_GetDuration(PHS_MINUTES, nCasterLevel, nMetaMagic);
|
||||
|
||||
// Make sure they are not immune to spells
|
||||
if(PHS_TotalSpellImmunity(oTarget)) return;
|
||||
|
||||
// Check if oTarget has better effects already
|
||||
if(PHS_GetHasAbilityBonusOfPower(oTarget, nAbility, 4) == 2) return;
|
||||
|
||||
// Delcare Effects
|
||||
effect eAbility = EffectAbilityIncrease(nAbility, 4);
|
||||
effect eVis = EffectVisualEffect(VFX_IMP_IMPROVE_ABILITY_SCORE);
|
||||
effect eCessate = EffectVisualEffect(VFX_DUR_CESSATE_POSITIVE);
|
||||
effect eLink = EffectLinkEffects(eAbility, eCessate);
|
||||
|
||||
// Signal the spell cast at event
|
||||
PHS_SignalSpellCastAt(oTarget, PHS_SPELL_BEARS_ENDURANCE, FALSE);
|
||||
|
||||
// Remove these abilities effects
|
||||
PHS_RemoveAnyAbilityBonuses(oTarget, nAbility);
|
||||
|
||||
// Apply effects and VFX to target
|
||||
PHS_ApplyDurationAndVFX(oTarget, eVis, eLink, fDuration);
|
||||
}
|
@@ -1,95 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Bear<61>s Endurance, Mass
|
||||
//:: Spell FileName PHS_S_BearsEndM
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Transmutation
|
||||
Level: Clr 6, Drd 6, Sor/Wiz 6
|
||||
Components: V, S, DF
|
||||
Casting Time: 1 standard action
|
||||
Range: Close (10M)
|
||||
Target: One creature/level, in a 6.67M radius.
|
||||
Duration: 1 min./level
|
||||
Saving Throw: Will negates (harmless)
|
||||
Spell Resistance: Yes
|
||||
|
||||
The subjects in the area gains greater vitality and stamina. The spell
|
||||
grants the subjects a +4 enhancement bonus to Constitution, which adds the
|
||||
usual benefits to hit points, Fortitude saves, Constitution checks, and so
|
||||
forth.
|
||||
|
||||
Hit points gained by a temporary increase in Constitution score are not
|
||||
temporary hit points. They go away when the subject<63>s Constitution drops
|
||||
back to normal. They are not lost first as temporary hit points are.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
+4 In the stat, Doesn't stack with normal, and can affect up to 1 target/
|
||||
level. Friends only targeted.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell hook check.
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Declare major variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget;
|
||||
location lTarget = GetSpellTargetLocation();
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
int nCnt, nFriend;
|
||||
// Ability to use
|
||||
int nAbility = ABILITY_CONSTITUTION;
|
||||
|
||||
// Duration - 1 minute/level
|
||||
float fDuration = PHS_GetDuration(PHS_MINUTES, nCasterLevel, nMetaMagic);
|
||||
|
||||
// Delcare Effects
|
||||
effect eAbility = EffectAbilityIncrease(nAbility, 4);
|
||||
effect eVis = EffectVisualEffect(VFX_IMP_IMPROVE_ABILITY_SCORE);
|
||||
effect eCessate = EffectVisualEffect(VFX_DUR_CESSATE_POSITIVE);
|
||||
effect eLink = EffectLinkEffects(eAbility, eCessate);
|
||||
|
||||
// Loop all allies in a huge sphere
|
||||
nCnt = 1;
|
||||
oTarget = GetNearestObjectToLocation(OBJECT_TYPE_CREATURE, lTarget, nCnt);
|
||||
// 1 target/level, nearest to location within a 5.0M radius
|
||||
while(GetIsObjectValid(oTarget) && nFriend < nCasterLevel &&
|
||||
GetDistanceBetweenLocations(lTarget, GetLocation(oTarget)) <= 5.0)
|
||||
{
|
||||
// Friendly check
|
||||
if(oTarget == OBJECT_SELF ||
|
||||
GetIsFriend(oTarget) ||
|
||||
GetFactionEqual(oTarget))
|
||||
{
|
||||
// Make sure they are not immune to spells
|
||||
if(!PHS_TotalSpellImmunity(oTarget))
|
||||
{
|
||||
// Check if oTarget has better effects already
|
||||
if(PHS_GetHasAbilityBonusOfPower(oTarget, nAbility, 4) != 2)
|
||||
{
|
||||
// Add one to counter
|
||||
nFriend++;
|
||||
|
||||
// Signal the spell cast at event
|
||||
PHS_SignalSpellCastAt(oTarget, PHS_SPELL_BEARS_ENDURANCE_MASS, FALSE);
|
||||
|
||||
// Remove these abilities effects
|
||||
PHS_RemoveAnyAbilityBonuses(oTarget, nAbility);
|
||||
|
||||
//Apply effects and VFX to target
|
||||
PHS_ApplyDurationAndVFX(oTarget, eVis, eLink, fDuration);
|
||||
}
|
||||
}
|
||||
}
|
||||
// Get next target
|
||||
oTarget = GetNearestObjectToLocation(OBJECT_TYPE_CREATURE, lTarget, nCnt);
|
||||
}
|
||||
}
|
@@ -1,246 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Bestow Curse
|
||||
//:: Spell FileName PHS_S_BestowCurs
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Necromancy
|
||||
Level: Clr 3, Sor/Wiz 4
|
||||
Components: V, S
|
||||
Casting Time: 1 standard action
|
||||
Range: Touch
|
||||
Target: Creature touched
|
||||
Duration: Permanent
|
||||
Saving Throw: Will negates
|
||||
Spell Resistance: Yes
|
||||
|
||||
You place a curse on the subject, if they were not already cursed. Choose
|
||||
one of the following three effects.
|
||||
|
||||
<20> -6 decrease to an ability score (minimum 3).
|
||||
<20> -4 penalty on attack rolls, saves, and skill checks.
|
||||
<20> Each turn, the target has a 50% chance to act normally; otherwise, it takes
|
||||
no action.
|
||||
|
||||
The curse bestowed by this spell cannot be dispelled, but it can be removed
|
||||
with a break enchantment, limited wish, miracle, remove curse, or wish
|
||||
spell.
|
||||
|
||||
Bestow curse counters remove curse.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
As above. The 3rd effect is taken as a delayed effect (and a visual makes
|
||||
sure it is kept going) via. DelayCommand and a function here.
|
||||
|
||||
Set the ability type in the spell menu (defaults to strength)
|
||||
|
||||
Note:
|
||||
- The first one can be setup in the spells menu.
|
||||
- The 3 options are 3 subdial choices.
|
||||
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Turning Notes
|
||||
//:://////////////////////////////////////////////
|
||||
This is like Baleful polymorph. Some parts of the final effects are moved
|
||||
into a function and so on.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
const int PHS_BESTOW_CURSE_ABILITY = 0;
|
||||
const int PHS_BESTOW_CURSE_ROLLS = 1;
|
||||
const int PHS_BESTOW_CURSE_RANDOM = 2;
|
||||
|
||||
// This is executed after 6 seconds, or 60 seconds. It will 50% of the time make
|
||||
// the creature immobile via. Uncommandable.
|
||||
// - When uncommandable, they have a pesudo-heartbeat run on them which will
|
||||
// remove the uncommandableness if they get the curse removed
|
||||
void DoRandomCurseBehaviour(object oTarget, int nCastTimes);
|
||||
// Spellturning implimented effects
|
||||
void DoEffects(object oTarget, effect eDur, effect eVis, int nSpellId, int nSpellSaveDC, object oCaster = OBJECT_SELF);
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell hook check.
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Declare major variables.
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject();
|
||||
int nSpellSaveDC = PHS_GetSpellSaveDC();
|
||||
int nSpellId = GetSpellId();
|
||||
|
||||
// Make sure they are not immune to spells
|
||||
if(PHS_TotalSpellImmunity(oTarget)) return;
|
||||
|
||||
// We link cirtain effects and apply eLink
|
||||
effect eVis = EffectVisualEffect(VFX_IMP_REDUCE_ABILITY_SCORE);
|
||||
effect eCurse;
|
||||
|
||||
// -4 penalty on attack rolls, saves, ability checks, and skill checks.
|
||||
if(nSpellId == PHS_SPELL_BESTOW_CURSE_ROLLS)
|
||||
{
|
||||
effect eRollsSkill = EffectSkillDecrease(SKILL_ALL_SKILLS, 4);
|
||||
effect eRollsSave = EffectSavingThrowDecrease(SAVING_THROW_ALL, 4);
|
||||
effect eRollsAttack = EffectAttackDecrease(4);
|
||||
// Link them - No visual
|
||||
eCurse = EffectLinkEffects(eRollsSkill, eRollsSave);
|
||||
eCurse = EffectLinkEffects(eCurse, eRollsAttack);
|
||||
}
|
||||
// Each turn, the target has a 50% chance to act normally; otherwise, it
|
||||
// takes no action.
|
||||
else if(nSpellId == PHS_SPELL_BESTOW_CURSE_CHANCE_NO_ACTION)
|
||||
{
|
||||
// Only a visual
|
||||
eCurse = EffectVisualEffect(VFX_DUR_MIND_AFFECTING_NEGATIVE);
|
||||
}
|
||||
// Default to ability
|
||||
else// if(nSpellId == PHS_SPELL_BESTOW_CURSE_ABILITY)
|
||||
{
|
||||
// Ability decrease in a stored constant, else strength.
|
||||
int nAbility = PHS_GetLocalConstant(oCaster, "PHS_BESTOW_CURSE_ABIlITY_TYPE");
|
||||
|
||||
// Apply effects
|
||||
// - The function defaults to strength
|
||||
eCurse = PHS_SpecificAbilityCurse(nAbility, 6);
|
||||
}
|
||||
|
||||
// Make it supernatural
|
||||
eCurse = SupernaturalEffect(eCurse);
|
||||
|
||||
// Check PvP
|
||||
if(!GetIsReactionTypeFriendly(oTarget))
|
||||
{
|
||||
// Signal spell cast at event
|
||||
PHS_SignalSpellCastAt(oTarget, PHS_SPELL_BESTOW_CURSE);
|
||||
|
||||
// Check spell resistance
|
||||
if(!PHS_SpellResistanceCheck(oCaster, oTarget))
|
||||
{
|
||||
// Check spell turning
|
||||
int nSpellTurning = PHS_SpellTurningCheck(oCaster, oTarget, PHS_ArrayGetSpellLevel(PHS_SPELL_BALEFUL_POLYMORPH, GetLastSpellCastClass()));
|
||||
|
||||
// 1 = No effect
|
||||
if(nSpellTurning == 1)
|
||||
{
|
||||
// Stop
|
||||
return;
|
||||
}
|
||||
else if(nSpellTurning == 2)
|
||||
{
|
||||
// Affect the caster only, full power.
|
||||
DoEffects(oCaster, eCurse, eVis, nSpellId, nSpellSaveDC);
|
||||
}
|
||||
else if(nSpellTurning == 3)
|
||||
{
|
||||
// Affects the caster OR the target, a % type thing. Set on local that can be
|
||||
// retrieved. If damaging, part damage each. If not, % chance to affect either.
|
||||
// Get the %. This one it is a chance of affecting us...
|
||||
int nFraction = FloatToInt(GetLocalFloat(oCaster, PHS_SPELL_TURNING_FRACTION) * 100);
|
||||
|
||||
// Check
|
||||
// - If the d100 is LESS then nFaction, it is GOOD for the target -
|
||||
// thus we affect the caster. Else, affect the target normally.
|
||||
if(d100() <= nFraction)
|
||||
{
|
||||
DoEffects(oCaster, eCurse, eVis, nSpellId, nSpellSaveDC);
|
||||
}
|
||||
else
|
||||
{
|
||||
DoEffects(oTarget, eCurse, eVis, nSpellId, nSpellSaveDC);
|
||||
}
|
||||
}
|
||||
else //if(nSpellTurning == 4)
|
||||
{
|
||||
// 4 = Spell affects both people equally at full effect.
|
||||
DoEffects(oTarget, eCurse, eVis, nSpellId, nSpellSaveDC);
|
||||
DoEffects(oCaster, eCurse, eVis, nSpellId, nSpellSaveDC);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// This is executed after 6 seconds, or 60 seconds. It will 50% of the time make
|
||||
// the creature immobile via. Uncommandable.
|
||||
// - When uncommandable, they have a pesudo-heartbeat run on them which will
|
||||
// remove the uncommandableness if they get the curse removed
|
||||
void DoRandomCurseBehaviour(object oTarget, int nCastTimes)
|
||||
{
|
||||
// Check if they have the spells effects + is valid
|
||||
if(GetHasSpellEffect(PHS_SPELL_BESTOW_CURSE_CHANCE_NO_ACTION, oTarget) &&
|
||||
!GetIsDead(oTarget) && GetIsObjectValid(oTarget) &&
|
||||
GetLocalInt(oTarget, "PHS_BESTOW_CURSE_TIMES_CAST_ON") == nCastTimes)
|
||||
{
|
||||
// 50% chance of no moving this turn
|
||||
if(d100() <= 50)
|
||||
{
|
||||
// Fail!
|
||||
FloatingTextStringOnCreature("The curse causes you to take no action this turn!", oTarget, FALSE);
|
||||
|
||||
// Apply a tempoary undispellable stais effect
|
||||
effect eStop = EffectCutsceneImmobilize();
|
||||
ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eStop, oTarget, 5.9);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Pass!
|
||||
FloatingTextStringOnCreature("The curse lets you take a normal action this turn.", oTarget, FALSE);
|
||||
}
|
||||
// Another check 6 seconds from now.
|
||||
DelayCommand(6.0, DoRandomCurseBehaviour(oTarget, nCastTimes));
|
||||
}
|
||||
else
|
||||
{
|
||||
PHS_SetCommandableOnSafe(oTarget, PHS_SPELL_BESTOW_CURSE);
|
||||
}
|
||||
}
|
||||
|
||||
// Spellturning implimented effects
|
||||
void DoEffects(object oTarget, effect eDur, effect eVis, int nSpellId, int nSpellSaveDC, object oCaster = OBJECT_SELF)
|
||||
{
|
||||
int bContinue = TRUE;
|
||||
if(oTarget == oCaster)
|
||||
{
|
||||
bContinue = PHS_SpellResistanceCheck(oCaster, oTarget);
|
||||
}
|
||||
if(bContinue)
|
||||
{
|
||||
// Times we have cast this spell stops the pesudo-turn checking running
|
||||
// more then at once on a target
|
||||
int nTimesCast = PHS_IncreaseStoredInteger(oTarget, "PHS_BESTOW_CURSE_TIMES_CAST_ON");
|
||||
|
||||
// Duration is permament (supernatural effect too)
|
||||
|
||||
// Check if they have the effects already.
|
||||
if(GetHasSpellEffect(PHS_SPELL_BESTOW_CURSE, oTarget) ||
|
||||
GetHasSpellEffect(PHS_SPELL_BESTOW_CURSE_ROLLS, oTarget) ||
|
||||
GetHasSpellEffect(PHS_SPELL_BESTOW_CURSE_ABILITY, oTarget) ||
|
||||
GetHasSpellEffect(PHS_SPELL_BESTOW_CURSE_CHANCE_NO_ACTION, oTarget) ||
|
||||
PHS_GetHasEffect(EFFECT_TYPE_CURSE, oTarget))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
// Check immunity
|
||||
if(!PHS_ImmunityCheck(oTarget, IMMUNITY_TYPE_CURSED))
|
||||
{
|
||||
// Check will save
|
||||
if(!PHS_SavingThrow(SAVING_THROW_WILL, oTarget, nSpellSaveDC))
|
||||
{
|
||||
// Apply effects
|
||||
PHS_ApplyPermanentAndVFX(oTarget, eVis, eDur);
|
||||
|
||||
// If it was the "Random" one, we start the check after 6
|
||||
// seconds.
|
||||
if(nSpellId == PHS_SPELL_BESTOW_CURSE_CHANCE_NO_ACTION)
|
||||
{
|
||||
DelayCommand(6.0, DoRandomCurseBehaviour(oTarget, nTimesCast));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -1,83 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Bigby's Clenched Fist
|
||||
//:: Spell FileName PHS_S_BigbyClenched
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Evocation [Force]
|
||||
Level: Sor/Wiz 8, Strength 8
|
||||
Components: V, S, F/DF
|
||||
Casting Time: 1 standard action
|
||||
Range: Medium (20M)
|
||||
Effect: Large hand
|
||||
Duration: 1 round/level (D)
|
||||
Saving Throw: None
|
||||
Spell Resistance: Yes
|
||||
|
||||
This spell functions like interposing hand, except that the hand can
|
||||
interpose itself, push, or strike one opponent that you select.
|
||||
|
||||
The hand attacks once per round, and its attack bonus equals your caster
|
||||
level + your Intelligence, Wisdom, or Charisma modifier (for a wizard,
|
||||
cleric, or sorcerer, respectively), +11 for the hand<6E>s Strength score (33),
|
||||
-1 for being Large. The hand deals 1d8+11 points of damage on each attack,
|
||||
and any creature struck must make a Fortitude save (against this spell<6C>s
|
||||
save DC) or be stunned for 1 round.
|
||||
|
||||
The clenched fist can also interpose itself as interposing hand does, or it
|
||||
can bull rush an opponent as forceful hand does, but at a +17 bonus on the
|
||||
Strength check (+11 for Strength 33, +4 for being Large, and a +2 bonus for
|
||||
charging, which it always gets).
|
||||
|
||||
Clerics who cast this spell name it for their deities.
|
||||
|
||||
Arcane Focus: A leather glove.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
The attack is using the attack function, if it hits, it may stun for 6
|
||||
seconds.
|
||||
|
||||
Cannot be redirected, too hard, like the others.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_BIGBY"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell Hook Check
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Declare Major Variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject();
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
int nSpellSaveDC = PHS_GetSpellSaveDC();
|
||||
int nSpellId = GetSpellId();
|
||||
|
||||
// Duration - 1 round/level
|
||||
float fDuration = PHS_GetDuration(PHS_ROUNDS, nCasterLevel, nMetaMagic);
|
||||
|
||||
// Do interposing hand
|
||||
if(nSpellId == PHS_SPELL_BIGBYS_CLENCHED_FIST_INTERPOSING)
|
||||
{
|
||||
ApplyInterposingHand(oTarget, nSpellId, fDuration, oCaster);
|
||||
}
|
||||
// Do forceful hand
|
||||
else if(nSpellId == PHS_SPELL_BIGBYS_CLENCHED_FIST_FORCEFUL)
|
||||
{
|
||||
// +18 bonus to the forceful hand pushback.
|
||||
ApplyForcefulHand(oTarget, 18, nSpellId, fDuration, oCaster);
|
||||
}
|
||||
// Do Clenched Fist
|
||||
else if(nSpellId == PHS_SPELL_BIGBYS_CLENCHED_FIST_CLENCHED)
|
||||
{
|
||||
// Clenched fist, Attack bonus of Caster Level + Ability Bonus +
|
||||
// 11 (STR) - 1 (large).
|
||||
int nBonus = nCasterLevel + PHS_GetAppropriateAbilityBonus() + 10 - 1;
|
||||
ApplyClenchedFist(oTarget, nBonus, nSpellSaveDC, nSpellId, fDuration, oCaster);
|
||||
}
|
||||
}
|
@@ -1,113 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Bigby's Forceful Hand
|
||||
//:: Spell FileName PHS_S_BigbyForce
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Evocation [Force]
|
||||
Level: Sor/Wiz 6
|
||||
Components: V, S, F
|
||||
Casting Time: 1 standard action
|
||||
Range: Medium (20M)
|
||||
Effect: Large hand
|
||||
Duration: 1 round/level (D)
|
||||
Saving Throw: None
|
||||
Spell Resistance: Yes
|
||||
|
||||
This spell functions like interposing hand, except that the forceful hand
|
||||
pushes away the opponent that you designate. Treat this attack as a bull
|
||||
rush with a +14 bonus on the Strength check (+8 for Strength 27, +4 for
|
||||
being Large, and a +2 bonus for charging, which it always gets). The
|
||||
opponent and you roll a d20, you add the +14 bonus, and the target adds
|
||||
thier own strength and size bonuses, +4 if they are steady. The hand always
|
||||
moves with the opponent to push that target back the full distance allowed.
|
||||
that is 2M per round, until they are 20M away.
|
||||
|
||||
Each new round, another bull rush is attempted. If the hand is sucessful,
|
||||
it pushes the target back yet futher, if not, then the target can move
|
||||
normally.
|
||||
|
||||
Focus: A sturdy glove made of leather or heavy cloth.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: 3E Bull rush description
|
||||
//:://////////////////////////////////////////////
|
||||
BULL RUSH
|
||||
You can make a bull rush as a standard action (an attack) or as part of a
|
||||
charge (see Charge, below). When you make a bull rush, you attempt to push
|
||||
an opponent straight back instead of damaging him. You can only bull rush
|
||||
an opponent who is one size category larger than you, the same size, or
|
||||
smaller.
|
||||
|
||||
Initiating a Bull Rush: First, you move into the defender<65>s space. Doing
|
||||
this provokes an attack of opportunity from each opponent that threatens
|
||||
you, including the defender. (If you have the Improved Bull Rush feat, you
|
||||
don<6F>t provoke an attack of opportunity from the defender.) Any attack of
|
||||
opportunity made by anyone other than the defender against you during a bull
|
||||
rush has a 25% chance of accidentally targeting the defender instead, and
|
||||
any attack of opportunity by anyone other than you against the defender
|
||||
likewise has a 25% chance of accidentally targeting you. (When someone
|
||||
makes an attack of opportunity, make the attack roll and then roll to see
|
||||
whether the attack went astray.)
|
||||
|
||||
Second, you and the defender make opposed Strength checks. You each add a
|
||||
+4 bonus for each size category you are larger than Medium or a -4 penalty
|
||||
for each size category you are smaller than Medium. You get a +2 bonus if
|
||||
you are charging. The defender gets a +4 bonus if he has more than two legs
|
||||
or is otherwise exceptionally stable.
|
||||
|
||||
Bull Rush Results: If you beat the defender<65>s Strength check result, you
|
||||
push him back 5 feet. If you wish to move with the defender, you can push
|
||||
him back an additional 5 feet for each 5 points by which your check result
|
||||
is greater than the defender<65>s check result. You can<61>t, however, exceed your
|
||||
normal movement limit. (Note: The defender provokes attacks of opportunity
|
||||
if he is moved. So do you, if you move with him. The two of you do not
|
||||
provoke attacks of opportunity from each other, however.)
|
||||
|
||||
If you fail to beat the defender<65>s Strength check result, you move 5 feet
|
||||
straight back to where you were before you moved into his space. If that
|
||||
space is occupied, you fall prone in that space.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
We will attempt a move back
|
||||
|
||||
Bull rush is simple, and there is wrappers for:
|
||||
|
||||
- Bull rush check
|
||||
- Size modifier
|
||||
- Steady or not
|
||||
|
||||
Forceful hand only can force them back OR interpose, not both.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_BIGBY"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell Hook Check
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Declare Major Variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject();
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
int nSpellId = GetSpellId();
|
||||
|
||||
// Duration - 1 round/level
|
||||
float fDuration = PHS_GetDuration(PHS_ROUNDS, nCasterLevel, nMetaMagic);
|
||||
|
||||
// Do interposing hand
|
||||
if(nSpellId == PHS_SPELL_BIGBYS_FORCEFUL_HAND_INTERPOSING)
|
||||
{
|
||||
ApplyInterposingHand(oTarget, nSpellId, fDuration, oCaster);
|
||||
}
|
||||
// Do forceful hand
|
||||
else if(nSpellId == PHS_SPELL_BIGBYS_FORCEFUL_HAND_FORCEFUL)
|
||||
{
|
||||
// +14 bonus to the forceful hand pushback.
|
||||
ApplyForcefulHand(oTarget, 14, nSpellId, fDuration, oCaster);
|
||||
}
|
||||
}
|
@@ -1,87 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Bigby's Grasping Hand
|
||||
//:: Spell FileName PHS_S_BigbyGrasp
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Evocation [Force]
|
||||
Level: Sor/Wiz 7, Strength 7
|
||||
Components: V, S, F/DF
|
||||
Casting Time: 1 standard action
|
||||
Range: Medium (20M)
|
||||
Effect: Large hand
|
||||
Duration: 1 round/level (D)
|
||||
Saving Throw: None
|
||||
Spell Resistance: Yes
|
||||
|
||||
This spell functions like interposing hand, except the hand can also grapple
|
||||
one opponent that you select. The grasping hand gets one grapple attack per
|
||||
round.
|
||||
|
||||
Its attack bonus to make contact equals your caster level + your
|
||||
Intelligence, Wisdom, or Charisma modifier (for wizards, clerics, and
|
||||
sorcerers, respectively), +10 for the hand<6E>s Strength score (31), -1 for
|
||||
being Large. Its grapple bonus is this same figure, except with a +4
|
||||
modifier for being Large instead of -1. The hand holds but does not harm
|
||||
creatures it grapples.
|
||||
|
||||
The grasping hand can also bull rush an opponent as forceful hand does, but
|
||||
at a +16 bonus on the Strength check (+10 for Strength 31, +4 for being
|
||||
Large, and a +2 bonus for charging, which it always gets), or interpose
|
||||
itself as interposing hand does.
|
||||
|
||||
Clerics who cast this spell name it for their deities.
|
||||
|
||||
Arcane Focus: A leather glove.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Grapple:
|
||||
|
||||
Use grapple function, need to attack if we didn't sucessfully hit and grapple
|
||||
last time.
|
||||
|
||||
And we will stop them moving using Entangle, for now.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_BIGBY"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell Hook Check
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Declare Major Variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject();
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
int nSpellId = GetSpellId();
|
||||
|
||||
// Duration - 1 round/level
|
||||
float fDuration = PHS_GetDuration(PHS_ROUNDS, nCasterLevel, nMetaMagic);
|
||||
|
||||
// Do interposing hand
|
||||
if(nSpellId == PHS_SPELL_BIGBYS_GRASPING_HAND_INTERPOSING)
|
||||
{
|
||||
ApplyInterposingHand(oTarget, nSpellId, fDuration, oCaster);
|
||||
}
|
||||
// Do forceful hand
|
||||
else if(nSpellId == PHS_SPELL_BIGBYS_GRASPING_HAND_FORCEFUL)
|
||||
{
|
||||
// +16 bonus to the forceful hand pushback.
|
||||
ApplyForcefulHand(oTarget, 16, nSpellId, fDuration, oCaster);
|
||||
}
|
||||
// Do grasping hand
|
||||
else if(nSpellId == PHS_SPELL_BIGBYS_GRASPING_HAND_GRASPING)
|
||||
{
|
||||
// Do the grasping hand.
|
||||
// Attack bonus: Caster Level + Ability Bonus + 10 (STR) - 1 (Large).
|
||||
// Grapple bonus: Caster Level + Ability Bonus + 10 (STR) + 4 (Large, grapple).
|
||||
int nBonus = nCasterLevel + PHS_GetAppropriateAbilityBonus() + 10;
|
||||
// We add 4 for grapple, -1 for attack.
|
||||
ApplyGraspingHand(oTarget, nBonus - 1, nBonus + 4, nSpellId, fDuration, oCaster);
|
||||
}
|
||||
}
|
@@ -1,73 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Bigby's Interposing Hand
|
||||
//:: Spell FileName PHS_S_BigbyInter
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Evocation [Force]
|
||||
Level: Sor/Wiz 5
|
||||
Components: V, S, F
|
||||
Casting Time: 1 standard action
|
||||
Range: Medium (20M)
|
||||
Effect: Large hand
|
||||
Duration: 1 round/level (D)
|
||||
Saving Throw: None
|
||||
Spell Resistance: Yes
|
||||
|
||||
Interposing hand creates a Large magic hand that appears at the position of
|
||||
one opponent. This floating, disembodied hand then moves to block that
|
||||
enemies attacks against other creatures, regardless of how the opponent
|
||||
tries to get around it, which has the effect of reducing the targets attack
|
||||
rolls by 4.
|
||||
|
||||
Disintegrate or a successful dispel magic destroys the hand.
|
||||
|
||||
Any creature weighing 2,000 pounds or less that tries to moves is slowed to
|
||||
half its normal speed. The hand cannot reduce the speed of a creature
|
||||
weighing more than 2,000 pounds, but it still affects the creature<72>s attacks.
|
||||
|
||||
Focus: A soft glove.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Ok, interposing hand:
|
||||
|
||||
-4 Attack (And possibly 50% movement speed decrease depending on weight
|
||||
of the target)
|
||||
Is destroyed by Dintegrate damage on the target
|
||||
|
||||
Currently, however, it cannot be redirected. Might add this in, of course...
|
||||
|
||||
Oh, and no save, but SR applies as normal (and nothing else, not even a
|
||||
touch attack, is required).
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_BIGBY"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell Hook Check.
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Declare major variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject();
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
|
||||
// Duration - 1 round/level
|
||||
float fDuration = PHS_GetDuration(PHS_ROUNDS, nCasterLevel, nMetaMagic);
|
||||
|
||||
// PvP check
|
||||
if(!GetIsReactionTypeFriendly(oTarget))
|
||||
{
|
||||
// Spell resistance check
|
||||
if(!PHS_SpellResistanceCheck(oCaster, oTarget))
|
||||
{
|
||||
// Use function
|
||||
ApplyInterposingHand(oTarget, PHS_SPELL_BIGBYS_INTERPOSING_HAND, fDuration, oCaster);
|
||||
}
|
||||
}
|
||||
}
|
@@ -1,85 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Bigby's Crushing Hand
|
||||
//:: Spell FileName PHS_S_BigbysCrus
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Evocation [Force]
|
||||
Level: Sor/Wiz 9, Strength 9
|
||||
Components: V, S, M, F/DF
|
||||
Casting Time: 1 standard action
|
||||
Range: Medium (20M)
|
||||
Effect: Large hand
|
||||
Duration: 1 round/level (D)
|
||||
Saving Throw: None
|
||||
Spell Resistance: Yes
|
||||
|
||||
This spell functions like interposing hand, except that the hand can interpose
|
||||
itself, push, or crush one opponent that you select.
|
||||
|
||||
The crushing hand can grapple an opponent like grasping hand does. Its grapple
|
||||
bonus equals your caster level + your Intelligence, Wisdom, or Charisma
|
||||
modifier (for a wizard, cleric, or sorcerer, respectively), +12 for the
|
||||
hand<6E>s Strength score (35), +4 for being Large. The hand deals 2d6+12 points
|
||||
of damage on each successful grapple check against an opponent.
|
||||
|
||||
The crushing hand can also interpose itself as interposing hand does, or it
|
||||
can bull rush an opponent as forceful hand does, but at a +18 bonus on the
|
||||
Strength check (+12 for Strength 35, +4 for being Large, and a +2 bonus for
|
||||
charging, which it always gets).
|
||||
|
||||
Clerics who cast this spell name it for their deities.
|
||||
|
||||
Arcane Material Component: The shell of an egg.
|
||||
|
||||
Arcane Focus: A glove of snakeskin.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Similar to Grasping Hand, as in the grapple checks and stuff (attack bonuses
|
||||
etc).
|
||||
|
||||
And does damage in addition to holding.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_BIGBY"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell Hook Check
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Declare Major Variables
|
||||
object oCaster = OBJECT_SELF;
|
||||
object oTarget = GetSpellTargetObject();
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
int nSpellId = GetSpellId();
|
||||
|
||||
// Duration - 1 round/level
|
||||
float fDuration = PHS_GetDuration(PHS_ROUNDS, nCasterLevel, nMetaMagic);
|
||||
|
||||
// Do interposing hand
|
||||
if(nSpellId == PHS_SPELL_BIGBYS_CRUSHING_HAND_INTERPOSING)
|
||||
{
|
||||
ApplyInterposingHand(oTarget, nSpellId, fDuration, oCaster);
|
||||
}
|
||||
// Do forceful hand
|
||||
else if(nSpellId == PHS_SPELL_BIGBYS_CRUSHING_HAND_FORCEFUL)
|
||||
{
|
||||
// +16 bonus to the forceful hand pushback.
|
||||
ApplyForcefulHand(oTarget, 16, nSpellId, fDuration, oCaster);
|
||||
}
|
||||
// Do grasping hand
|
||||
else if(nSpellId == PHS_SPELL_BIGBYS_CRUSHING_HAND_CRUSHING)
|
||||
{
|
||||
// Do the crushing hand.
|
||||
// Attack bonus: Caster Level + Ability Bonus + 12 (STR) - 1 (Large).
|
||||
// Grapple bonus: Caster Level + Ability Bonus + 12 (STR) + 4 (Large, grapple).
|
||||
int nBonus = nCasterLevel + PHS_GetAppropriateAbilityBonus() + 12;
|
||||
// We add 4 for grapple, -1 for attack.
|
||||
ApplyCrushingHand(oTarget, nBonus - 1, nBonus + 4, nSpellId, fDuration, oCaster);
|
||||
}
|
||||
}
|
@@ -1,34 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Binding
|
||||
//:: Spell FileName PHS_S_Binding
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Enchantment (Compulsion) [Mind-Affecting]
|
||||
Level: Sor/Wiz 8
|
||||
Components: V, S, M
|
||||
Casting Time: One minute
|
||||
Range: Close (8M)
|
||||
Target: One living creature
|
||||
Duration: See text (D)
|
||||
Saving Throw: Will negates; see text
|
||||
Spell Resistance: Yes
|
||||
|
||||
Description.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Rating: 9: Many containments...but this is entirely possible as there
|
||||
are effects which penetrate anything.
|
||||
|
||||
Placeholder script.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
|
||||
}
|
@@ -1,76 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Evard's Black Tentacles
|
||||
//:: Spell FileName PHS_S_BlackTent
|
||||
//:://////////////////////////////////////////////
|
||||
//:: In Game Spell desctiption
|
||||
//:://////////////////////////////////////////////
|
||||
Conjuration (Creation)
|
||||
Level: Sor/Wiz 4
|
||||
Components: V, S, M
|
||||
Casting Time: 1 standard action
|
||||
Range: Medium (20M)
|
||||
Area: 6.67-M.-radius spread
|
||||
Duration: 1 round/level (D)
|
||||
Saving Throw: None
|
||||
Spell Resistance: No
|
||||
|
||||
This spell conjures a field of rubbery black tentacles. These waving members
|
||||
seem to spring forth from the earth, floor, or whatever surface is underfoot.
|
||||
They grasp and entwine around creatures that enter the area, holding them
|
||||
fast and crushing them with great strength.
|
||||
|
||||
Every creature within the area of the spell must make a grapple check,
|
||||
opposed by the grapple check of the tentacles. Treat the tentacles attacking
|
||||
a particular target as a Large creature with a base attack bonus equal to
|
||||
your caster level and a Strength score of 19. Thus, its grapple check
|
||||
modifier is equal to your caster level +8. The tentacles cannot be attacked.
|
||||
|
||||
Once the tentacles grapple an opponent, causing them to become entangled,
|
||||
they may make a grapple check each round to deal 1d6+4 points of bludgeoning
|
||||
damage. The tentacles continue to crush the opponent until the spell ends or
|
||||
the opponent escapes by the tentacles failing a later check. Unless the
|
||||
target enters the area again, tentacles will not attempt to grapple them again.
|
||||
|
||||
Any creature that enters the area of the spell is immediately attacked by
|
||||
the tentacles. Even creatures who aren<65>t grappling with the tentacles may
|
||||
move through the area at only half normal speed.
|
||||
|
||||
Material Component: A piece of tentacle from a giant octopus or a giant squid.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Note: Changed name to Evard's Black Tentacles
|
||||
|
||||
Grapple check uses the functions created for this, and other spells-which-grapple
|
||||
things.
|
||||
|
||||
The tentacles will only attack (using a proper attack thing) On Enter.
|
||||
|
||||
If they have the entanglement of tentacles, the HB will continue to grapple.
|
||||
|
||||
Always applies 50% movement speed decrease. Removes all effects On Exit. Will
|
||||
not grapple someone with the spells effects already.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Spell hook check.
|
||||
if(!PHS_SpellHookCheck()) return;
|
||||
|
||||
// Declare major variables
|
||||
location lTarget = GetSpellTargetLocation();
|
||||
int nCasterLevel = PHS_GetCasterLevel();
|
||||
int nMetaMagic = PHS_GetMetaMagicFeat();
|
||||
// Duration - 1 round/level
|
||||
float fDuration = PHS_GetDuration(PHS_ROUNDS, nCasterLevel, nMetaMagic);
|
||||
|
||||
// Declare effects
|
||||
effect eAOE = EffectAreaOfEffect(PHS_AOE_PER_EVARDS_BLACK_TENTACLES);
|
||||
|
||||
// Apply effects
|
||||
PHS_ApplyLocationDuration(lTarget, eAOE, fDuration);
|
||||
}
|
@@ -1,70 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Black Tentacles: On Enter
|
||||
//:: Spell FileName PHS_S_BlackTentA
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Grapple check uses the functions created for this, and other spells-which-grapple
|
||||
things.
|
||||
|
||||
The tentacles will only attack (using a proper attack thing) On Enter.
|
||||
|
||||
If they have the entanglement of tentacles, the HB will continue to grapple.
|
||||
|
||||
Always applies 50% movement speed decrease. Removes all effects On Exit. Will
|
||||
not grapple someone with the spells effects already.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Check AOE status
|
||||
if(!PHS_CheckAOECreator()) return;
|
||||
|
||||
// Declare major variables
|
||||
object oTarget = GetEnteringObject();
|
||||
object oCaster = GetAreaOfEffectCreator();
|
||||
int nCasterLevel = PHS_GetAOECasterLevel();
|
||||
|
||||
// Get opposed grapple roll
|
||||
int nOpposedGrappleRoll = d20() + GetBaseAttackBonus(oTarget) +
|
||||
GetAbilityModifier(ABILITY_STRENGTH, oTarget) +
|
||||
PHS_GrappleSizeBonus(oTarget);
|
||||
|
||||
// We always apply the slow for the spell, as a supernatural effect, using
|
||||
// the standard On Enter things.
|
||||
effect eSlow = EffectMovementSpeedDecrease(50);
|
||||
|
||||
// We may also entangle them (and later do damage) and sucessfully grapple
|
||||
// with a tentacle
|
||||
effect eEntangle = EffectEntangle();
|
||||
effect eDur = EffectVisualEffect(PHS_VFX_DUR_BLACK_TENTACLE);
|
||||
effect eLink = EffectLinkEffects(eEntangle, eDur);
|
||||
|
||||
// PvP Check
|
||||
if(!GetIsReactionTypeFriendly(oTarget, oCaster) &&
|
||||
// Make sure they are not immune to spells
|
||||
!PHS_TotalSpellImmunity(oTarget))
|
||||
{
|
||||
// Fire cast spell at event for the target
|
||||
PHS_SignalSpellCastAt(oTarget, PHS_SPELL_EVARDS_BLACK_TENTACLES);
|
||||
|
||||
// Now we make an attack to hold them, if we can
|
||||
if(!GetHasSpellEffect(PHS_SPELL_EVARDS_BLACK_TENTACLES, oTarget))
|
||||
{
|
||||
// Check grapple roll
|
||||
if(PHS_GrappleCheck(oTarget, nCasterLevel, 4, 4, nOpposedGrappleRoll, oCaster))
|
||||
{
|
||||
// Now we entangle, later rounds do damage.
|
||||
// * Can be dispelled as normal, not supernatural.
|
||||
PHS_ApplyPermanent(oTarget, eLink);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Apply slow effects always
|
||||
PHS_AOE_OnEnterEffects(eLink, oTarget, PHS_SPELL_EVARDS_BLACK_TENTACLES);
|
||||
}
|
@@ -1,18 +0,0 @@
|
||||
/*:://////////////////////////////////////////////
|
||||
//:: Spell Name Black Tentacles: On Exit
|
||||
//:: Spell FileName PHS_S_BlackTentB
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Spell Effects Applied / Notes
|
||||
//:://////////////////////////////////////////////
|
||||
Exit removes stuff.
|
||||
//:://////////////////////////////////////////////
|
||||
//:: Created By: Jasperre
|
||||
//::////////////////////////////////////////////*/
|
||||
|
||||
#include "PHS_INC_SPELLS"
|
||||
|
||||
void main()
|
||||
{
|
||||
// Exit - remove effects
|
||||
PHS_AOE_OnExitEffects(PHS_SPELL_EVARDS_BLACK_TENTACLES);
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user