generated from Jaysyn/ModuleTemplate
44 lines
1.6 KiB
Plaintext
44 lines
1.6 KiB
Plaintext
//::///////////////////////////////////////////////
|
|
//:: Caltrops
|
|
//:: x0_s3_caltrop
|
|
//:: Copyright (c) 2002 Bioware Corp.
|
|
//:://////////////////////////////////////////////
|
|
/*
|
|
Modified by LasCivious to disappear after a specific time
|
|
*/
|
|
//:://////////////////////////////////////////////
|
|
//:: Created By: Brent
|
|
//:: Created On: September 10, 2002
|
|
//:://////////////////////////////////////////////
|
|
#include "prc_inc_spells"
|
|
|
|
void SetObject(location lTarget, object oVisual)
|
|
{
|
|
object oArea = GetNearestObjectToLocation(OBJECT_TYPE_AREA_OF_EFFECT, lTarget);
|
|
if (GetIsObjectValid(oArea) == TRUE)
|
|
{
|
|
SetLocalObject(oArea, "X0_L_IMPACT", oVisual);
|
|
}
|
|
}
|
|
void main()
|
|
{
|
|
//Set duration in seconds for caltrops here
|
|
float fDuration = 300.0;
|
|
|
|
//Declare major variables including Area of Effect Object
|
|
// * passing dirge script for exit because it is an empty script (i.e., there is no special exit effects)
|
|
effect eAOE = EffectAreaOfEffect(37, "x0_s3_calEN", "x0_s3_calHB", "");
|
|
location lTarget = PRCGetSpellTargetLocation();
|
|
|
|
//effect eImpact = EffectVisualEffect(257);
|
|
|
|
//ApplyEffectAtLocation(DURATION_TYPE_INSTANT, eImpact, lTarget);
|
|
//Create an instance of the AOE Object using the Apply Effect function
|
|
ApplyEffectAtLocation(DURATION_TYPE_TEMPORARY, eAOE, lTarget, fDuration);
|
|
object oVisual = CreateObject(OBJECT_TYPE_PLACEABLE, "plc_invisobj", lTarget);
|
|
SetObject(lTarget, oVisual);
|
|
|
|
effect eFieldOfSharp = EffectVisualEffect(VFX_DUR_CALTROPS);
|
|
ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eFieldOfSharp, oVisual, fDuration);
|
|
}
|