View Single Post
  #6228    
Old November 8th, 2011 (10:05 AM).
DrerAhv's Avatar
DrerAhv DrerAhv is offline
She That Derps in the Night
 
Join Date: Mar 2011
Location: NH, USA
Age: 19
Gender: Female
Nature: Lonely
Posts: 9
Okay, I'm trying to code an event that has your mother in the back of the van with you at the beginning of the game. I want the player to be unable to input until the mother notices the character is awake, has an Alert! exclamation point over her head, and says a line of text. At that point the door of the van opens and the player is allowed to input. If they try to talk to the mother before walking out of the van, she will say a different line of text.

Needless to say I've run into some issues compiling this.
I'm using Pokemon Ruby and XSE. The code I input was this;
Code:
#org @start
checkflag 0x828
if 0x0 goto @hey!
if 0x1 goto @nightmare
end

#org @hey!
setflag 0x828
lock
applymovement 0x4 @alert
waitmovement 0x0
msgbox @awake 0x6
release
end

#org @awake
= [player], wake up! \nwe're here. We're here, \nplayer.

#org @alert
#raw 0x56 0xFE

#org @nightmare
checkflag 0x828
if 0x0 goto @hey!
if 0x1 goto @okay

#org @okay
lock
faceplayer
msgbox @feeling 0x6
release
end

#org @feeling
= [player], \nare you feeling okay? \nYou looked like you were \nhaving a nightmare.
release
end
After I compile the code, this is what I get.
Code:
'---------------
#org 0x1C6E1D
checkflag 0x828
if 0x0 goto 0x81C6E2E
if 0x1 goto 0x81C6E7E
end

'---------------
#org 0x1C6E2E
setflag 0x828
lock
msgbox 0x8000006 0x2B '"-¿\h69\h9A1ï\h3D\h84\h82\h0A\h84pÌ..."
pause 0x608
nop
checkpcitem 0x1C6E 0x608
nop1
lighten 0x6E
comparebanktobyte 0x8 0x2
'---------------
#org 0x1C6E7E

'---------
' Strings
'---------
#org 0x6
= -¿\h69\h9A1ï\h3D\h84\h82\h0A\h84pÌ.Ùô\h8B\h98F\h81\h7Fï2¡Dç\h93ÌTîŒ\h46\h4A\h4A\hF8\h27\h31x[OC]Mt\h33\h82oTE<äk\h94T\h4BÌG\h94[Ke]\h8AFÛ\h726\c\h9F\h84\h4D\h732P\h9A[LL][OC]\h972ú\c\h03\h98\h76óëM[LL]ÂÇ-[Ke]E\h38\h84 \h406Ó\v\hFF
For the hell of it I inserted that into the game regardless of how glitched it was; the result was that when I tried to talk to the mother the game froze.
Can anyone tell me where I went wrong with the original code?
__________________
The philosopher Didactylos has summed up an alternative hypothesis as "Things just happen. What the hell."