Initial commit
Initial commit [v9.7]
This commit is contained in:
49
_module/nss/enter_crumble.nss
Normal file
49
_module/nss/enter_crumble.nss
Normal file
@@ -0,0 +1,49 @@
|
||||
/* Script generated by
|
||||
Lilac Soul's NWN Script Generator, v. 2.3
|
||||
|
||||
For download info, please visit:
|
||||
http://nwvault.ign.com/View.php?view=Other.Detail&id=4683&id=625 */
|
||||
|
||||
//Put this script OnEnter
|
||||
void main()
|
||||
{
|
||||
|
||||
object oPC = GetEnteringObject();
|
||||
|
||||
if (!GetIsPC(oPC)) return;
|
||||
|
||||
if (GetItemPossessedBy(oPC, "towerofangarngit")== OBJECT_INVALID)
|
||||
return;
|
||||
|
||||
FloatingTextStringOnCreature("The Tower attacks you as it crumbles!", oPC);
|
||||
|
||||
object oTarget;
|
||||
oTarget = oPC;
|
||||
|
||||
//Visual effects can't be applied to waypoints, so if it is a WP
|
||||
//the VFX will be applied to the WP's location instead
|
||||
|
||||
int nInt;
|
||||
nInt = GetObjectType(oTarget);
|
||||
|
||||
if (nInt != OBJECT_TYPE_WAYPOINT) ApplyEffectToObject(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_COM_CHUNK_STONE_MEDIUM), oTarget);
|
||||
else ApplyEffectAtLocation(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_COM_CHUNK_STONE_MEDIUM), GetLocation(oTarget));
|
||||
|
||||
object oSpawn;
|
||||
location lTarget;
|
||||
lTarget = GetLocation(oTarget);
|
||||
|
||||
oSpawn = CreateObject(OBJECT_TYPE_PLACEABLE, "crumble1", lTarget);
|
||||
|
||||
oTarget = oSpawn;
|
||||
|
||||
//Visual effects can't be applied to waypoints, so if it is a WP
|
||||
//the VFX will be applied to the WP's location instead
|
||||
|
||||
nInt = GetObjectType(oTarget);
|
||||
|
||||
if (nInt != OBJECT_TYPE_WAYPOINT) DelayCommand(0.5, ApplyEffectToObject(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_COM_CHUNK_STONE_MEDIUM), oTarget));
|
||||
else DelayCommand(0.5, ApplyEffectAtLocation(DURATION_TYPE_INSTANT, EffectVisualEffect(VFX_COM_CHUNK_STONE_MEDIUM), GetLocation(oTarget)));
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user