#include "mn_i_pwfunctions" /* Script generated by Lilac Soul's NWN Script Generator, v. 1.6 For download info, please visit: http://www.lilacsoul.revility.com */ // Modified 5 apr 2010 to use the new quest system void main() { object oPC = GetPCSpeaker(); object oTarget; object oSpawn; location lTarget; oTarget = GetWaypointByTag("ratspawn"); lTarget = GetLocation(oTarget); oSpawn = CreateObject(OBJECT_TYPE_CREATURE, "ratmenace", lTarget); // Quest system logic (start quest) int index = 1; string questId = GetMarkerString(OBJECT_SELF, ExchangeVar(EXCHANGE_QUEST_ID, index), FALSE); int visualEffect = GetLocalInt(OBJECT_SELF, ExchangeVar( EXCHANGE_VISUALEFFECT, index ) ); // Display visual effect if (visualEffect != 0) { effect vfx = EffectVisualEffect(visualEffect); ApplyEffectToObject( DURATION_TYPE_INSTANT, vfx, GetPCSpeaker()); } int questStatus = GetQuestStatus( GetPCSpeaker(), questId ); if ( questStatus == QUEST_UNKNOWN) { SetQuestStatus(GetPCSpeaker(), questId, QUEST_BEGUN); } }