I made a fun cantrip…
I call it the “Puke Cantrip”
Caster Level(s): Bard 0, Wizard / Sorcerer 0
Innate Level: 0
School: Evocation
Descriptor(s):
Component(s): Verbal, Somatic
Range: Personal
Area of Effect / Target: creature
Duration: Instantaneous
Additional Counter Spells:
Save: yes vs Fortitude
Spell Resistance: yes
This spell causes the person or creature affected to bend over and vomit. The person/creature gets a saving throw vs Fortitude. If a successful save is made the spell fails. This is a basic cantrip used by apprentices for pranking fellow apprentices, but can also be used to interrupt a caster from casting a spell.
Here is the script:
#include "x0_i0_spells"
#include "x2_inc_spellhook"
void main()
{
//--------------------------------------------------------------------------
/*
Spellcast Hook Code
Added 2003-06-20 by Georg
If you want to make changes to all spells,
check x2_inc_spellhook.nss to find out more
*/
//--------------------------------------------------------------------------
if (!X2PreSpellCastCode())
{
return;
}
// End of Spell Cast Hook
//Setup for Spell
object oTarget = GetSpellTargetObject();
location lLocal = GetSpellTargetLocation();
int nCasterLevel = GetCasterLevel(OBJECT_SELF);
float fDelay = IntToFloat(nCasterLevel)*5;
effect ePuke = EffectVisualEffect(VFX_COM_CHUNK_YELLOW_SMALL);
string sPukeTalk = "BBBLLLLAAAARRRRGGGGHHHHH!!!!";
string sPukeApology = "Ugh, why do I feel so sick!";
if(!GetIsReactionTypeFriendly(oTarget))
{
//Fire cast spell at event for the specified target
SignalEvent(oTarget, EventSpellCastAt(OBJECT_SELF, 416));
//Make SR Check
if ((!MyResistSpell(OBJECT_SELF, oTarget)) && (MySavingThrow(SAVING_THROW_FORT, oTarget, GetSpellSaveDC()) == FALSE) )
{
//Set damage effect
effect eBad = EffectAttackDecrease(1*nCasterLevel);
//Apply the VFX impact and damage effect
ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eBad, oTarget, RoundsToSeconds(10));
ClearAllActions();
AssignCommand(OBJECT_SELF, ActionPlayAnimation(ANIMATION_LOOPING_MEDITATE));
AssignCommand(OBJECT_SELF, ActionSpeakString(sPukeTalk));
DelayCommand(2.0,ApplyEffectToObject(DURATION_TYPE_TEMPORARY, ePuke, OBJECT_SELF, 1.0));
DelayCommand(5.0, ActionSpeakString(sPukeApology));
}
}
}
I took some of the scripting from the “Flare” cantrip and blended it with a script I have on an NPC that would puke when talked too because he is drunk (I got that script years ago). I thought it would be a fun cantrip.
It compiles. Problem is…the creature is targeted but my caster pukes and says the words above. I think on one trial one of the creatures actually puked.
Can someone help fix this script. I also need it to make the target:
- pause for a round if he fails his save vs fortitude
- and get the dazed effect after he fails
- make sure the target is the one puking (not the caster)
- and range??
almost got this