View Single Post
  #1361    
Old June 14th, 2009 (12:32 PM). Edited June 14th, 2009 by [BlackEyedHacker].
[BlackEyedHacker] [BlackEyedHacker] is offline
Newb
 
Join Date: Sep 2008
Location: New Zealand
Gender: Male
Nature: Hasty
Posts: 44
Alright, so I've been wrestling with XSE for a few hours, testing code, playing with it, and been having a lot of fun, however, I am always stuck with the flag actions. I know how to set flags and do the if statements, however, when I compile and save, the if statement dissapears from the code.

Here is the code I have been using:
Spoiler:

'---------------
#dynamic 0x16A094
#org @start
lock
faceplayer
checkflag 0x1000
if 0x1 call @recieve
msgbox 0x818FC2B MSG_KEEPOPEN '"Okay!\pBe sure to read what's on t..."
setflag 0x1001
release
end

#org @recieve
msgbox @msg1 0x2
givepokemon 0x85 0x5 0x0D 0x0 0x0 0x0
msgbox @msg2 0x2
release
end

#org @msg1
= Hey, [player]! I bet you must be\nexcited! [rival] was pretty pumped\ltoo. He just ran out of here.\lYou just missed him. Anyways, I\lthink you already noticed, I have\lno more pokemon left. But don't\lfret! Professor Oak from Pallet\lhas happily said he would supply\lyou with pokemon. Why don't you\ltake my Eevee with you. It's just\lbeen a pet for me for the last\lyear or so, but Eevee should be\lable to fight just fine. You'll\lneed Eevee for Route 1.

#org @msg2
= Recieved Eevee!/lGood Luck!

'---------
' Strings
'---------
#org 0x18FC2B
= Check your mail!\pHurry or [rival] will have a big\lheadstart!


'-----------
' Movements
'-----------
#org 0x1A75E5
#raw 0x5A 'mov5A
#raw 0xFE 'End of Movements


I know it looks sloppy, I am much more organized, but why put more effort into something that never stays?

That is how I write it and how it compiles, but when I re-open it it looks like this:
Spoiler:
'---------------
#org 0x16A094
lock
faceplayer
checkflag 0x1000
msgbox 0x818FC2B MSG_KEEPOPEN '"Check your mail!\pHurry or [rival]..."
closeonkeypress
applymovement 0x1 0x81A75E5
waitmovement 0x0
release
end


'---------
' Strings
'---------
#org 0x18FC2B
= Check your mail!\pHurry or [rival] will have a big\lheadstart!


'-----------
' Movements
'-----------
#org 0x1A75E5
#raw 0x5A 'mov5A
#raw 0xFE 'End of Movements


Any help or guidance would be a great help. I am probably missing something stupid. =\.

Moved from Simple Questions Thread.