HiddenTradition_PRC8/_module/nss/gzcc_ropeh_init.nss
2024-06-20 15:47:42 -04:00

19 lines
886 B
Plaintext

int StartingConditional()
{
object oTarget =GetLocalObject(OBJECT_SELF,"T1_TARGET_OBJECT");
int iRange = (FloatToInt(GetDistanceToObject(oTarget)));
//abs(FloatToInt(GetPosition(oTarget).z - GetPosition(OBJECT_SELF).z))
iRange= iRange*3;
SetCustomToken(9869,IntToString(iRange));
object oArmor = GetItemInSlot (INVENTORY_SLOT_CHEST);
if (oArmor !=OBJECT_INVALID)
if (GetItemACValue(oArmor)>3)
SetCustomToken(9868,"\nWarning: You are wearing an armor which will significantly decrease your chance of climbing the rope and increase the chance of falling and taking damage!");
else
SetCustomToken(9868,"\nYour armor does not affect your chance of climbing this rope!");
else
SetCustomToken(9868,"\nWearing no Armor your chance of climbing this rope is increased!");
return (oTarget != OBJECT_INVALID);
}