void main() { object oTroll = GetLocalObject(OBJECT_SELF,"LAST_TROLL_ATTACKED"); int TORCHDMG = d4(4)+1; //This is the torch fire damage roll // Makes sure the troll_on_dmg script knows a PC torched the troll SetLocalInt(oTroll,"TROLL_WAS_TORCHED",1); // Apply the torch damage effect eDmg = EffectDamage(TORCHDMG,DAMAGE_TYPE_FIRE); ApplyEffectToObject(DURATION_TYPE_INSTANT,eDmg,oTroll); // Cleanup DeleteLocalObject(OBJECT_SELF,"LAST_TROLL_ATTACKED"); }