WoR_PRC8/_module/nss/storetaerw.nss

44 lines
829 B
Plaintext
Raw Permalink Normal View History

2025-04-03 11:49:34 -04:00
object oItem;
object oTarget;
//Put this on action taken in the conversation editor
#include "nw_i0_plot"
void main()
{
object oPC = GetPCSpeaker();
object oDatabase = GetItemPossessedBy(oPC,"Database");
if (GetLocalInt(oDatabase, "PLAYERGOTTAIL")== 1)
{
oTarget = GetObjectByTag("taerweapons");
gplotAppraiseOpenStore(oTarget, oPC, 0, 0);
}
else if (GetItemPossessedBy(oPC, "Black_Dragon_Tail")!= OBJECT_INVALID)
{
oItem = GetItemPossessedBy(oPC, "Black_Dragon_Tail");
if (GetIsObjectValid(oItem))
DestroyObject(oItem);
SetLocalInt(oDatabase, "PLAYERGOTTAIL", 1);
oTarget = GetObjectByTag("taerweapons");
gplotAppraiseOpenStore(oTarget, oPC, 0, 0);
}
}
/* Original script
void main()
{
object oStore = GetObjectByTag("taerweapons");
OpenStore(oStore, GetPCSpeaker());
}