Keep the money that's in that safe in a serverr. string.
NPC Code:
if (playerchats && strequals(#c,/paycheck)) {
Ok, so
NPC Code:
if (playerchats ...
This is detected when enter is hit entering a message.
NPC Code:
&& strequals(#c,/paycheck)) {
&& is just another way of saying
and in scripting. So far we have 'if the player enters a message and'.
strequals is used to determine what a player has. In this case, it's looking for something the player is saying (notice #c). So, if the player enters a message and the player's chat text is '/paycheck', what is written in the bracers will take place.
NPC Code:
if (playerchats && strequals(#c,/paycheck)) {
playerrupees += 250;
setstring 'serverr.strings',strtofloat(#s('serverr.strings') ) - 250;
}
Of course, you will have to add another flag in there to test whether the safe has 250g or not; but that's your job.