The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > Fan Games > Binary ROM Hacking
Reload this Page Script givepokemon script skipping over @5 [SOLVED]

Notices
For all updates, view the main page.

Binary ROM Hacking Need a helping hand or just want to talk about binary ROM hacks? Get comments and answers to any ROM Hacking-related problems, questions or thoughts you have here.

Ad Content
Reply
 
Thread Tools
  #1   Link to this post, but load the entire thread.  
Old June 2nd, 2018 (4:59 AM). Edited June 3rd, 2018 by Thoriére.
Thoriére's Avatar
Thoriére Thoriére is offline
If everything's a dream, don't wake me.
 
Join Date: Aug 2014
Location: GMT -8:00
Gender: Male
Nature: Serious
Posts: 121
Earlier today I posted about a scripting error I was getting. I've since fixed the problem, along with a couple of issues that remained within the script itself, but there's one more issue I can't resolve.

The whole script works except for one part, the msgbox that's supposed to be triggered to display text stored at @5. I realized I hadn't included it at one point, so I put it in, but I have a feeling the placement is wrong. Nothing is wrong with the script in the sense that there are no glitches or crashes, just that @5 won't work. This prevents the nickname window from coming up, so it's very important that I fix it. Code included below.

Spoiler:
Code:
#dynamic 0x823800

#org @start
lock
faceplayer
checkflag 0x828
if 0x1 goto @done
msgbox @1 0x5
compare 0x800D 0x1
if 0x1 goto @take
msgbox @3 0x6
release
end

#org @take
lock
faceplayer
msgbox @2 0x6
givepokemon 0x85 0x5 0x0 0x0 0x0 0x0
fanfare 0x13E
msgbox @4 0x4
waitfanfare
closeonkeypress
setflag 0x828
compare LASTRESULT 0x1
if 0x1 call @name
msgbox @6 0x6
release
end

#org @name
msgbox @5 0x5
setvar 0x8004 0x0
fadescreen 0x1
special 0x9E
waitstate
return

#org @done
msgbox @6 0x6
release
end

#org @1
= Dad: Oh, \v\h01! You're\nfinally up! Did you know I was\lcoming back today?\l...\lI missed you too. Were you\lokay while I was gone? I know I\lshould have come back home sooner,\lbut it was like pulling\lteeth to get back even today...\l...\lBut I got you something special to\lmake up for it! It's a surprise,\lbut I know you'll love it.\l...\lDo you want it now, or...?

#org @2
= All right! Close your\neyes and cup your hands together\lin front of you.\p...\p...\p...\pOkay! Open your eyes!\pIt's a Pok\h1Bmon!\nYour very own!

#org @3
= Is that so? Well, let me\nknow when you want it. I'll be\lhere all day.

#org @4
= You received an Eevee!

#org @5
= Would you like to give a\nnickname to Eevee?

#org @6
= Isn't it a wonderful Pok\h1Bmon?\nI saw it and knew it was perfect\lfor you. It can evolve into\ldifferent forms depending on items\lyou give it, so you have a lot of\lfreedom when it comes to that\lPok\h1Bmon's growth.\l...\lWhy don't you go play with it in\lyour room for a bit while I\lmake dinner? I'll call for you\lwhen it's done.


All help appreciated! Thanks in advance.
__________________
pokéfarm + tumblr + pinterest + pair
New to ROM hacking? Click here!
Reply With Quote
  #2   Link to this post, but load the entire thread.  
Old June 2nd, 2018 (5:32 AM). Edited June 2nd, 2018 by Sakib66.
Sakib66's Avatar
Sakib66 Sakib66 is offline
 
Join Date: Jan 2017
Gender: Male
Nature: Adamant
Posts: 196
Spoiler:
#dynamic 0x823800

#org @start
lock
faceplayer
checkflag 0x828
if 0x1 goto @done
msgbox @1 0x5
compare 0x800D 0x1
if 0x1 goto @take
msgbox @3 0x6
release
end

#org @take
lock
faceplayer
msgbox @2 0x6
givepokemon 0x85 0x5 0x0 0x0 0x0 0x0
fanfare 0x13E
msgbox @4 0x4
waitfanfare
closeonkeypress
setflag 0x828
msgbox @5 0x5
compare 0x800D 0x1
if 0x1 call @name
msgbox @6 0x6
release
end

#org @name
setvar 0x8004 0x0
fadescreen 0x1
special 0x9E
waitstate
return

#org @done
msgbox @6 0x6
release
end

#org @1
= Dad: Oh, \v\h01! You're\nfinally up! Did you know I was\lcoming back today?\l...\lI missed you too. Were you\lokay while I was gone? I know I\lshould have come back home sooner,\lbut it was like pulling\lteeth to get back even today...\l...\lBut I got you something special to\lmake up for it! It's a surprise,\lbut I know you'll love it.\l...\lDo you want it now, or...?

#org @2
= All right! Close your\neyes and cup your hands together\lin front of you.\p...\p...\p...\pOkay! Open your eyes!\pIt's a Pok\h1Bmon!\nYour very own!

#org @3
= Is that so? Well, let me\nknow when you want it. I'll be\lhere all day.

#org @4
= You received an Eevee!

#org @5
= Would you like to give a\nnickname to Eevee?

#org @6
= Isn't it a wonderful Pok\h1Bmon?\nI saw it and knew it was perfect\lfor you. It can evolve into\ldifferent forms depending on items\lyou give it, so you have a lot of\lfreedom when it comes to that\lPok\h1Bmon's growth.\l...\lWhy don't you go play with it in\lyour room for a bit while I\lmake dinner? I'll call for you\lwhen it's done.
Reply With Quote
  #3   Link to this post, but load the entire thread.  
Old June 2nd, 2018 (7:04 AM).
Thoriére's Avatar
Thoriére Thoriére is offline
If everything's a dream, don't wake me.
 
Join Date: Aug 2014
Location: GMT -8:00
Gender: Male
Nature: Serious
Posts: 121
Quote:
Originally Posted by Sakib66 View Post
Spoiler:
#dynamic 0x823800

#org @start
lock
faceplayer
checkflag 0x828
if 0x1 goto @done
msgbox @1 0x5
compare 0x800D 0x1
if 0x1 goto @take
msgbox @3 0x6
release
end

#org @take
lock
faceplayer
msgbox @2 0x6
givepokemon 0x85 0x5 0x0 0x0 0x0 0x0
fanfare 0x13E
msgbox @4 0x4
waitfanfare
closeonkeypress
setflag 0x828
msgbox @5 0x5
compare 0x800D 0x1
if 0x1 call @name
msgbox @6 0x6
release
end

#org @name
setvar 0x8004 0x0
fadescreen 0x1
special 0x9E
waitstate
return

#org @done
msgbox @6 0x6
release
end

#org @1
= Dad: Oh, \v\h01! You're\nfinally up! Did you know I was\lcoming back today?\l...\lI missed you too. Were you\lokay while I was gone? I know I\lshould have come back home sooner,\lbut it was like pulling\lteeth to get back even today...\l...\lBut I got you something special to\lmake up for it! It's a surprise,\lbut I know you'll love it.\l...\lDo you want it now, or...?

#org @2
= All right! Close your\neyes and cup your hands together\lin front of you.\p...\p...\p...\pOkay! Open your eyes!\pIt's a Pok\h1Bmon!\nYour very own!

#org @3
= Is that so? Well, let me\nknow when you want it. I'll be\lhere all day.

#org @4
= You received an Eevee!

#org @5
= Would you like to give a\nnickname to Eevee?

#org @6
= Isn't it a wonderful Pok\h1Bmon?\nI saw it and knew it was perfect\lfor you. It can evolve into\ldifferent forms depending on items\lyou give it, so you have a lot of\lfreedom when it comes to that\lPok\h1Bmon's growth.\l...\lWhy don't you go play with it in\lyour room for a bit while I\lmake dinner? I'll call for you\lwhen it's done.
Thank you so much! Works perfectly.
__________________
pokéfarm + tumblr + pinterest + pair
New to ROM hacking? Click here!
Reply With Quote
Reply

Quick Reply

Join the conversation!

Create an account to post a reply in this thread, participate in other discussions, and more!

Create a PokéCommunity Account
Ad Content

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 9:19 AM.