Amon_PRC8/_module/nss/xp_deposit_100k.nss

22 lines
528 B
Plaintext
Raw Permalink Normal View History

2025-04-03 19:00:46 -04:00
#include "xp_inc"
void main()
{
object oPC =GetPCSpeaker();
if (GetHitDice(oPC) >= 20)
{
int DepositXP = 100000/fraction;
string sDepositXP = IntToString(DepositXP);
string sCDKey = GetPCPublicCDKey( oPC);
int fXP = GetCampaignInt( "XP", sCDKey) + DepositXP;
int XP = GetXP(oPC) - 100000;
SetCampaignInt( "XP", sCDKey, fXP);
SetXP(oPC, XP);
SpeakString ("You have deposited "+ sDepositXP +" XP.");
}
else
{
SpeakString ("Sorry, but you need to be at least level 20 to use this feature.");
}
}