Initial Commit
Initial Commit
This commit is contained in:
16
_module/nss/hench_pay.nss
Normal file
16
_module/nss/hench_pay.nss
Normal file
@@ -0,0 +1,16 @@
|
||||
//Pay for the henchman. If PC tried to be smart and put his gold away before choosing this option in a conversation, stop the dialogue and inform him about it.
|
||||
void main()
|
||||
{
|
||||
object oPC = GetPCSpeaker();
|
||||
if ( GetGold(oPC) >= (GetLocalInt(oPC, "hench_pay")))
|
||||
{
|
||||
TakeGoldFromCreature(GetLocalInt(oPC, "hench_pay"), oPC, TRUE);
|
||||
SetLocalInt(oPC, "hench_notaffordable", 0);
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
SpeakString("Sorry, no one is going to risk their life for free.");
|
||||
SetLocalInt(oPC, "hench_notaffordable", 1);
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user