26 lines
801 B
Plaintext
26 lines
801 B
Plaintext
int StartingConditional()
|
|
{
|
|
object oPC = GetPCSpeaker();
|
|
|
|
object oItem = GetFirstItemInInventory(oPC);
|
|
int nValue;
|
|
string sValue;
|
|
string sCost;
|
|
while (GetIsObjectValid(oItem))
|
|
{
|
|
if (GetLocalInt(oItem, "Prototype") == TRUE)
|
|
{
|
|
nValue = GetGoldPieceValue(oItem);
|
|
if (GetLocalString(oItem, "Type") == "Ammo") nValue = 99*nValue;
|
|
if (GetLocalString(oItem, "Type") == "Throwing" || GetLocalString(oItem, "Type") == "MightyThrowing") nValue = 50*nValue;
|
|
sValue = IntToString(nValue);
|
|
SetCustomToken(799, sValue);
|
|
sCost = IntToString(3*nValue/4);
|
|
SetCustomToken(800, sCost);
|
|
return TRUE;
|
|
}
|
|
oItem = GetNextItemInInventory(oPC);
|
|
}
|
|
return TRUE;
|
|
}
|