• Just a reminder that providing specifics on, sharing links to, or naming websites where ROMs can be accessed is against the rules. If your post has any of this information it will be removed.
  • Ever thought it'd be cool to have your art, writing, or challenge runs featured on PokéCommunity? Click here for info - we'd love to spotlight your work!
  • It's time to vote for your favorite Pokémon Battle Revolution protagonist in our new weekly protagonist poll! Click here to cast your vote and let us know which PBR protagonist you like most.
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

Script Help Thread (DO NOT REQUEST SCRIPTS)

Status
Not open for further replies.
Okay, so I am having some trouble with the Pokepic commands in XSE. Fire Red base.
Code:
#org @part2
showpokepic PKMN_TENTACOOL 0x1 0x1
msgbox @ossincise 0x5
compare 0x800D 0x1
hidepokepic
if 0x1 goto @ossincisechose
showpokepic PKMN_SNORUNT 0x1 0x1
msgbox @snorunt 0x5
compare 0x800D 0x1
hidepokepic
if 0x1 goto @snoruntchose
showpokepic PKMN_LUNATONE 0x1 0x1
msgbox @birdawl 0x5
compare 0x800D 0x1
hidepokepic
if 0x1 goto @birdawlchose
msgbox @whichone 0x6
goto @part2

When I try to compile it says "unknown keyword '0x61 pokepic' on line 47" line 47 is the first showpokepic line. It also says "unknown keyword '0x60 pokepic' on line 51" line 51 is the first hidepokepic line.

Do you have any "#define"s or "#alias"es in that script or, as Spherical Ice mentioned, one of your header files? Perhaps you used "HIDE" and "SHOW" as symbols for a value which would cause XSE to replace all instances of "hide" and "show" with that value (even if they're part of a command).

Thanks for the help, but when XSE compiles it, it changes it back to 0x81A74EB.
The appended '8' doesn't change anything. XSE automatically does that to tell you that the pointer points to an address in the ROM area (as opposed to the RAM).

anyway,i have a problem with this script,i want to warp to route 1 from one map to another,which is like from vermiilion to route 1 so i do this script,its a lvel script btw.
Spoiler:

but after the messge it warp me to route 7 intead which map is no 3:19 but 3:25..
don't noe why


0x19 is 25 in decimal. You should either replace '0x19' with '25' or '0x13'.

Also, please take a moment to read over your post before clicking "Submit". Your spelling is simply atrocious.

Furthermore, you can't have Warp 0xFF, so the third parameter was incorrect. The asterisk (*) indicates that it changes depending on the warp number which you want to warp me to. I believe the 0xFF was the problem, however if not then please tell me.

Actually, 0xFF is used in place of the warp number in order to execute a warp to a specific location on the target map. The final two parameters are then used (otherwise they're '0') to specify the X- and Y-coordinates, respectively.
 
Lol, I said that I am using XSE :P


Excuse me while I slap myself silly for making a fool out of myself. I've never experienced this problem before, but I'd suggest to do it the non-fancy way. Just do:

showpokepic 0x[Insert Pokemon data in HEX here] 0x[Level In HEX] 0x[Item in HEX] 0x[Buffer] 0x[Buffer] 0x[Buffer]

Pokemon list is as follows (Ripped from diegoisawesome's huge XSE tut):
Spoiler:
 
showpokepic 0x[Insert Pokemon data in HEX here] 0x[Level In HEX] 0x[Item in HEX] 0x[Buffer] 0x[Buffer] 0x[Buffer]

Uhm, I think you've gotten 'showpokepic' confused with 'givepokemon'. What good would specifying a level and item do if all the command does is display a picture of a pokémon? The actual parameters are as follows:

Code:
showpokepic Pokémon_ID X-coordinate Y-coordinate

...where "Pokémon_ID" is a halfword and the coordinates are bytes.
 
Do you have any "#define"s or "#alias"es in that script or, as Spherical Ice mentioned, one of your header files? Perhaps you used "HIDE" and "SHOW" as symbols for a value which would cause XSE to replace all instances of "hide" and "show" with that value (even if they're part of a command).
Ah, I didn't quite understand what he was saying. This was the problem, thanks!
Even though that problem is fixed, I am still having the same problem as before(see my last post on this thread). I'm not sure if I messed up with commands, or what exactly is going on.
 
Uhm, I think you've gotten 'showpokepic' confused with 'givepokemon'. What good would specifying a level and item do if all the command does is display a picture of a pokémon? The actual parameters are as follows:

Code:
showpokepic Pokémon_ID X-coordinate Y-coordinate
...where "Pokémon_ID" is a halfword and the coordinates are bytes.
Arrgh! That's number two on the Morono-Meter! BUT I will make myself not look stupid by the end of the day!
Perhaps you could still try my idea with the replace the PKMN_[Insert Pokemon Name here]

to
showpokepic 0x[HEX number of Pokemon, just look in the previous post for the DEC numbers] 0x[Coordinate 1] 0x[Coordinate 2]
 
I made a pokescript where your mother gives you a pokemon, when I walk up to the spot she is supposed to be on there in nothing there and I am pretty sure it is the scripts fault
Spoiler:
 
Arrgh! That's number two on the Morono-Meter! BUT I will make myself not look stupid by the end of the day!
Perhaps you could still try my idea with the replace the PKMN_[Insert Pokemon Name here]

to
showpokepic 0x[HEX number of Pokemon, just look in the previous post for the DEC numbers] 0x[Coordinate 1] 0x[Coordinate 2]
Yeah, that wasn't the problem, we figured it out already. :P

I made a pokescript where your mother gives you a pokemon, when I walk up to the spot she is supposed to be on there in nothing there and I am pretty sure it is the scripts fault
Spoiler:
What is her person ID? Have you set a flag equal to her ID previously?
Also when writing messages, write them like so:
Hello\nthere \v\h01!\pHow are you?\nYou look good today\pmaybe you want to go out\nfor coffee?
not:
Hello \n there \v\h01, how are you? \p I'm good. \n How do you feel?
 
Yeah, that wasn't the problem, we figured it out already. :P


What is her person ID? Have you set a flag equal to her ID previously?
Also when writing messages, write them like so:
Hello\nthere \v\h01!\pHow are you?\nYou look good today\pmaybe you want to go out\nfor coffee?
not:
Hello \n there \v\h01, how are you? \p I'm good. \n How do you feel?
I think I did it the way you said i'm not sure because I tried compiling it and something popped out and said "Run Time Error 457 This Key is already associated with an element an element of this collection
Spoiler:
 
I think I did it the way you said i'm not sure because I tried compiling it and something popped out and said "Run Time Error 457 This Key is already associated with an element an element of this collection
Spoiler:

Perhaps that error message has something to do with the fact that you use the dynamic label "$gotit" twice. When you use "goto $gotit", the game won't know whether to go to the first "$gotit" or the second "$gotit", which is why the compiler won't let you compile.

Also, the 'givepokemon' command contains three extra parameters which are usually set to '0x00'. I haven't used Pokescript in a long time (and I suggest you switch to XSE or PKSV) but I don't think that those bytes are coded for in Pokescript's command database so you'll have to add three 'nop' commands after 'givepokemon'.
 
Perhaps that error message has something to do with the fact that you use the dynamic label "$gotit" twice. When you use "goto $gotit", the game won't know whether to go to the first "$gotit" or the second "$gotit", which is why the compiler won't let you compile.

Also, the 'givepokemon' command contains three extra parameters which are usually set to '0x00'. I haven't used Pokescript in a long time (and I suggest you switch to XSE or PKSV) but I don't think that those bytes are coded for in Pokescript's command database so you'll have to add three 'nop' commands after 'givepokemon'.
So I replace the second gotit and it should work now right?
 
I think I did it the way you said i'm not sure because I tried compiling it and something popped out and said "Run Time Error 457 This Key is already associated with an element an element of this collection
Spoiler:

Make mom's Person ID 0's all the way across. Hopefully she'd appear then.

Yeah, that wasn't the problem, we figured it out already. :P
You know what, Imma just hang up my helping hat for good before I make a fool out of myself now.
 
I took the trees out of start map but when I go to the edge of the map there are trees past map edge. How do I fix this? I'm making a desert region is why I need to know.
 
You have to change the "border block" in advance map. Replace the tree with "dust" or whatever tiles you want outside the map.
 
Actually, 0xFF is used in place of the warp number in order to execute a warp to a specific location on the target map. The final two parameters are then used (otherwise they're '0') to specify the X- and Y-coordinates, respectively.
Oh, really? That's awesome. I never knew that. :D
 
So I replace the second gotit and it should work now right?
Actually, you should just ditch the second "$gotit" section altogether. It doesn't seem, to me at least, that it's serving any purpose. It looks like an exact copy of the other "$gotit" section but without the 'end' command, which might cause bugs. Your final script should end up looking something like this:
Spoiler:

I preemptively blame any errors in that script on the fact that I haven't used Pokescript in almost two years now.

wat if two sides are sand and two sides are water how would I do two different borders? would I have to edit the ASM?

You can set the border block to water and then expand the map so that the player can't see the border on the sand side. Or vice versa.
 
thanks everyone that helped me, but there is still one problem how do I activate the pkmn menu and make the script say you have obtained "pokemon"! with the jingle?
Spoiler:
 
thanks everyone that helped me, but there is still one problem how do I activate the pkmn menu and make the script say you have obtained "pokemon"! with the jingle?
Spoiler:
Pokemon menu: Setflag 0x800 for Ruby, 0x828 for Fire Red, and 0x860 for Emerald.
givepokemon 0xspecies number 0xlevel 0xitem number
nop
nop
nop
and I'm not quite sure how the jingle command works in Pokescript.
 
do I put the flag in the beginning?
and how do I make it say Player has obtained [pokemon]
It doesn't really matter where you put it, but I would put it before the givepokemon command.

givepokemon 1 5 0
message $[pointer]
boxset 6
...
...

#org $[pointer]
$[pointer] 1 = \v\h01 received the Pokemon!
 
Status
Not open for further replies.
Back
Top