Aantioch_Infernum/_module/nss/skullball_strip.nss
Jaysyn904 22947ad4b6 Initial Upload
Initial Upload
2023-08-08 16:22:17 -04:00

30 lines
712 B
Plaintext

#include "nw_i0_tool"
void Gold(object oPC,int iGold)
{
AssignCommand(oPC, TakeGoldFromCreature(iGold-150, oPC, TRUE));
}
void main()
{
object oPC = GetEnteringObject();
int iGold = GetGold(oPC);
object oItem = GetFirstItemInInventory(oPC);
int nInt=GetLocalInt(oPC, "skullball_item");
if(!GetIsPC(oPC)) return;
if(GetIsDM(oPC)==TRUE) return;
if (nInt ==1)return;
while(GetIsObjectValid(oItem))
{
SetPlotFlag(oItem,FALSE);
DestroyObject(oItem);
oItem = GetNextItemInInventory(oPC);
}
SetLocalInt(oPC, "skullball_item", 1);
RewardPartyGP(150, oPC, FALSE);
SendMessageToPC(oPC,"Re-equipped for skullball");
if(iGold>150)Gold(oPC,iGold);
}