Files
dsrc/sku.0/sys.server/compiled/game/script/npe/npe_band_sequence.script
T
2013-09-10 23:17:15 -07:00

58 lines
1.4 KiB
Plaintext

include library.utils;
include library.ai_lib;
trigger OnAttach()
{
setInvulnerable(self, true );
// This old-school entertainer skill is possibly being used to make the NPC
// entertainers perform. It is not for certain if this is necessary.
grantSkill (self, "social_entertainer_novice");
messageTo(self,"npeSetName", null, 1, false);
return SCRIPT_CONTINUE;
}
trigger OnPreloadComplete()
{
boolean setting = utils.checkConfigFlag("ScriptFlags", "npeSequencersActive");
//if(setting == true)
//messageTo(self, "doEvents", null, 60, false);
return SCRIPT_CONTINUE;
}
messageHandler npeSetName()
{
string myName = utils.getStringObjVar(self, "strSequenceIdentifier");
if(myName != null || myName != "")
{
if(myName.equals("band1"))
{
ai_lib.setMood (self, "themepark_music_2");
setName(self, "Mako");
}
if(myName.equals("band2"))
{
obj_id instrument = createObject ("object/tangible/instrument/bandfill.iff", self, "");
equip(instrument, self);
ai_lib.setMood (self, "themepark_music_1");
setName(self, "Alisia");
}
if(myName.equals("band3"))
{
obj_id instrument = createObject ("object/tangible/instrument/kloo_horn.iff", self, "");
equip(instrument, self);
ai_lib.setMood (self, "themepark_music_3");
setName(self, "Alitra");
}
if(myName.equals("dancer"))
{
setAnimationMood(self, "npc_dance_basic");
setName(self, "Mestral");
}
}
return SCRIPT_CONTINUE;
}