View Single Post
  #8102    
Old April 5th, 2013 (10:45 PM).
tajaros's Avatar
tajaros
Hi I'm dawg
 
Join Date: Apr 2012
Location: Philippines
Age: 15
Gender: Male
Nature: Timid
Send a message via Windows Live Messenger to tajaros
Quote originally posted by Meowing Mewtwo:
Hey all, I wrote a script for my starter Pokemon, an Eevee, and when I tested it in my ROM, all that happened was the noise you hear when you click a text box. If someone could help me out, I'd appreciate it. Here's the script:

Code:
#dynamic 0x6B09F8

#org @start
setflag 0x828
msgbox @1 0x5
@take
msgbox @2 0x6
release
end

#org @take
givepokemon 0x133 0x5 0x0 0x0 0x0 0x0
fanfare 0x13E
msgbox @3 0x4
waitfanfare
closeonkeypress
setflag 0x828
msgbox @4 0x5
compare LASTRESULT 0x1
if 0x1 gosub @name
msgbox @5 0x6
release
end

#org @name
call 0x1A74EB
return

#org @1
= It's an EEVEE.\nBut it's covered in burns!\pWill you help it?

#org @2
= That's okay.\pSomeone else will\nprobably take it.

#org @3
= [black_rs]You received an EEVEE!

#org @4
= [black_rs]Would you like to give a\nnickname to this little EEVEE?

#org @5
= That EEVEE is looking\nbetter already[.]
Here I fixed your script I found numerous of errors in your script especially in the first part you didn't even have a decision command to check if the user picked yes or no.

Also you've placed a release command in your script but it doesn't have any lock command in it. Also the givepokemon command 133 is Eevee's Pokemon No. so you have to convert to 133 to hex, so it will be 85.

I think that's all there is to it. Here's the fixed script btw.

Code:
#dynamic 0x800000

#org @start
lock
msgbox @1 0x5
compare LASTRESULT 0x1
if 0x1 goto @take
msgbox @5 0x6
release
end

#org @take
givepokemon 0x85 0x5 0x0 0x0 0x0 0x0
setflag 0x828
fanfare 0x13E
msgbox @2 0x4
waitfanfare
closeonkeypress
msgbox @3 0x5
compare LASTRESULT 0x1
if 0x1 goto @nick
goto @good
end

#org @nick
setvar 0x8004 0x0
call @nickname
goto @good

#org @nickname
fadescreen 0x1
special 0x9E
waitstate
return

#org @good
msgbox @4 0x6
release
end

#org @1
= It's an EEVEE.\nBut it's covered in burns!\pWill you help it?

#org @2
= [black_rs]You received an EEVEE!

#org @3
= [black_rs]Would you like to give a\nnickname to this little EEVEE?

#org @4
= That EEVEE is looking\nbetter already.

#org @5
= That's okay.\pSomeone else will\nprobably take it.
__________________