Area Changes and other fixes
added areas and ccoh, fixed some areas to work with crafting fixed some on death issues added server entry/ooc
This commit is contained in:
@@ -1,46 +0,0 @@
|
||||
#include "nw_i0_plot"
|
||||
|
||||
void main()
|
||||
{
|
||||
object oPC = GetPCSpeaker();
|
||||
object oDeed = GetLocalObject(oPC,"oDeed");
|
||||
DeleteLocalObject(oPC,"oDeed");
|
||||
|
||||
string sItemTag = GetLocalString(oDeed,"sItemTag");
|
||||
string sItemResRef = GetLocalString(oDeed,"sItemResRef");
|
||||
string sItemName = GetLocalString(oDeed,"sItemName");
|
||||
int iTotal = GetLocalInt(oDeed,"iNumberStored");
|
||||
int iTemp = GetNumItems(oPC,sItemTag);
|
||||
|
||||
SendMessageToPC(oPC,"Attempting to add "+IntToString(iTemp)+" "+sItemName+" to this bundle.");
|
||||
|
||||
object oGone = GetFirstItemInInventory(oPC);
|
||||
float fDelay = 2.0;
|
||||
|
||||
int iCounter;
|
||||
|
||||
if (oGone!=OBJECT_INVALID)
|
||||
{
|
||||
while (oGone!=OBJECT_INVALID)
|
||||
{
|
||||
if (GetTag(oGone)==sItemTag)
|
||||
{
|
||||
if (GetLocalInt(oGone,"iAmCounted")==0)
|
||||
{
|
||||
SetLocalInt(oGone,"iAmCounted",99);
|
||||
iCounter=iCounter+GetNumStackedItems(oGone);
|
||||
DestroyObject(oGone,fDelay);
|
||||
fDelay=fDelay+0.2;
|
||||
}
|
||||
}
|
||||
oGone = GetNextItemInInventory(oPC);
|
||||
if (oGone==OBJECT_INVALID) break;
|
||||
}
|
||||
}
|
||||
|
||||
iTotal = iTotal+iCounter;
|
||||
|
||||
SetLocalInt(oDeed,"iNumberStored",iTotal);
|
||||
DelayCommand(fDelay+0.5,SendMessageToPC(oPC,"Successfully added "+IntToString(iCounter)+" "+sItemName+" to the bundle."));
|
||||
DelayCommand(fDelay+0.6,SendMessageToPC(oPC,"There are now a total of "+IntToString(iTotal)+" "+sItemName+" in this bundle."));
|
||||
}
|
Reference in New Issue
Block a user