Prev: 5F8F Up: Map Next: 5FCE
5FAA: Refuse Command
Used by the routine at ObeyCommand.
The scripts did not handle the command. A direction says you cannot go that way, any other verb is beyond the game, and a blank verb produces the longer refusal.
RefuseCommand 5FAA XOR A Clear *Continuation.
5FAB LD ($5B85),A
5FAE LD A,($5B7F) Jump to RefuseCommand_Verb if *Verb is unset.
5FB1 OR A
5FB2 JR Z,RefuseCommand_Verb
5FB4 CP $0B Jump to RefuseCommand_Verb if the verb is not a direction.
5FB6 JR NC,RefuseCommand_Verb
Print "you can't go that way.".
5FB8 LD A,$18 Print SystemMessage_18 using PrintSystemMessage.
5FBA JR RefuseCommand_Print
A recognised verb that is not a direction, or no verb at all.
RefuseCommand_Verb 5FBC LD A,($5B7F) Jump to RefuseCommand_None if *Verb is unset.
5FBF OR A
5FC0 JR Z,RefuseCommand_None
Print "it's beyond my power to do that.".
5FC2 LD A,$0C Print SystemMessage_0C using PrintSystemMessage.
Print the chosen refusal.
RefuseCommand_Print 5FC4 CALL PrintSystemMessage Call PrintSystemMessage.
5FC7 JP GameLoop_Act Jump to GameLoop_Act.
Print "I don't understand that verb".
RefuseCommand_None 5FCA LD A,$20 Print SystemMessage_20 using PrintSystemMessage.
5FCC JR RefuseCommand_Print
Prev: 5F8F Up: Map Next: 5FCE