• Our software update is now concluded. You will need to reset your password to log in. In order to do this, you will have to click "Log in" in the top right corner and then "Forgot your password?".
  • Forum moderator applications are now open! Click here for details.
  • 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.

Ooka

[font=Maven Pro][color=#A75EE2]Cosmic[/color][/fon
2,626
Posts
16
Years
Alright, for some reason the naming won't work. When you select yes it just jumps to the end of the script.

Code:
#dynamic 0x804828

#org @starterselect
checkflag 0x860
if 0x1 goto @nope
lock
msgbox @message 0x5
compare LASTRESULT 0x1
if 0x1 goto @getpkmn
msgbox @message2 0x6
release
end

#org @getpkmn
givepokemon 277 5 0 0 0 0
fanfare 0x13E
msgbox @message3 0x4
waitfanfare
closeonkeypress
setflag 0x860
msgbox @message4 0x5
compare LASTRESULT 0x1
if 0x1 gosub @namepoke
applymovement 0xFF @playmove
applymovement 0x01 @profmov
waitmovement 0x0
msgbox @finally 0x6
release
end

#org @finally
= Alright, well, I'm really glad \nyou decided to take on this \pchallenge. I actually have a favor to \nask before you officially take off. \pI have a trainer coming by for \nhis Pokemon. He shows a lot of \ppromise so I'd like you to meet \nup with him and battle. \pHe'll meet you above Oldale. \nThat's all, and good luck \pin your battle!

#org @playmove
#raw 0x02
#raw 0x0A
#raw 0x0A
#raw 0x01
#raw 0x09
#raw 0x12
#raw 0x12
#raw 0xFE

#org @profmov
#raw 0x02
#raw 0x0A
#raw 0x0A
#raw 0x0A
#raw 0x00
#raw 0x12
#raw 0x12
#raw 0xFE

#org @message
= Would you like to pick Treecko, \nthe Grass type Pokemon?

#org @message2
= Alright, take your time.

#org @message3
= You picked Treecko!

#org @message4
= Would you like to nickname the \nTreecko you just received?

#org @namepoke
special 0x166
return

#org @nope
release
end
 
Last edited:
119
Posts
14
Years
The name is a bit deceptive as isn't actually a flag that you have to set for the level script type 02, but a variable. To stop the endless repetition use this command somewhere in your script:
Code:
setvar 0x7000 0xSomethingOtherThan0

The value of your chosen variable determines when your level script will be played. In your case, you has designated that when the variable is set to 0, the script will run automatically. By changing the variable somewhere in the script to something other than your chosen value it will not run again allowing you to continue with you game.

All right, thanks! I thought that "setflag 0x7000" is the same as "setvar 0x7000 0x1", but clearly it isn't! ^^
 

Binary

え?
3,977
Posts
16
Years
  • Age 29
  • Seen Apr 7, 2014
Alright, for some reason the naming won't work. When you select yes it just jumps to the end of the script.

Code:
#dynamic 0x804828

#org @starterselect
checkflag 0x860
if 0x1 goto @nope
lock
msgbox @message 0x5
compare LASTRESULT 0x1
if 0x1 goto @getpkmn
msgbox @message2 0x6
release
end

#org @getpkmn
givepokemon 277 5 0 0 0 0
fanfare 0x13E
msgbox @message3 0x4
waitfanfare
closeonkeypress
setflag 0x860
msgbox @message4 0x5
compare LASTRESULT 0x1
if 0x1 gosub @namepoke
applymovement 0xFF @playmove
applymovement 0x01 @profmov
waitmovement 0x0
msgbox @finally 0x6
release
end

#org @finally
= Alright, well, I'm really glad \nyou decided to take on this \pchallenge. I actually have a favor to \nask before you officially take off. \pI have a trainer coming by for \nhis Pokemon. He shows a lot of \ppromise so I'd like you to meet \nup with him and battle. \pHe'll meet you above Oldale. \nThat's all, and good luck \pin your battle!

#org @playmove
#raw 0x02
#raw 0x0A
#raw 0x0A
#raw 0x01
#raw 0x09
#raw 0x12
#raw 0x12
#raw 0xFE

#org @profmov
#raw 0x02
#raw 0x0A
#raw 0x0A
#raw 0x0A
#raw 0x00
#raw 0x12
#raw 0x12
#raw 0xFE

#org @message
= Would you like to pick Treecko, \nthe Grass type Pokemon?

#org @message2
= Alright, take your time.

#org @message3
= You picked Treecko!

#org @message4
= Would you like to nickname the \nTreecko you just received?

#org @namepoke
special 0x166
return

#org @nope
release
end
Try using this:
Spoiler:

Apparently, the game uses special 0x9E for nicknaming your first pokemon. fadescreen 0x1 will fade the screen out to black and waitstate just sets the script at a wait state, which is commonly used for some specials.
 
4
Posts
13
Years
  • Age 29
  • Seen Apr 19, 2012
Game: Pokemon fire red
Type: Hidesprite script
Editor: XSE
Spoiler:



Okay so after I compile and insert the script... I put the flag # down on the person ID box but when I lod my game the sprite simply dissapears. Any help please? :) . Thanks in advance
 

Ooka

[font=Maven Pro][color=#A75EE2]Cosmic[/color][/fon
2,626
Posts
16
Years

Try using this:
Spoiler:

Apparently, the game uses special 0x9E for nicknaming your first pokemon. fadescreen 0x1 will fade the screen out to black and waitstate just sets the script at a wait state, which is commonly used for some specials.

Ah, thanks for this, I just ended up using:

Code:
call 0x827378B
call 0x82723DD

But next time I'll remember that raw.
 

Logan

[img]http://pldh.net/media/pokecons_action/403.gif
10,417
Posts
15
Years
He's using 800F because it makes the sprite you last talked to disappear. It's very useful for things like Cut trees so that you can use one script for everything single one of them. Changing the hidesprite to the person's actual ID would make no difference as this is doing the exact same job. Your advice is very silly; telling him to use between 1000-2000 is wrong as flags go up to 3FFF so you could easily use those. He also doesn't need to get a new offset as 800000 is perfectly fine when you're using dynamic offsets.

Anyway, dido525, your description is very vague and is kinda weird. You say the sprite simply disappears? Well, by the looks of your script, that's exactly what it's meant to do. What exactly is wrong with everything?
 
4
Posts
13
Years
  • Age 29
  • Seen Apr 19, 2012
He's using 800F because it makes the sprite you last talked to disappear. It's very useful for things like Cut trees so that you can use one script for everything single one of them. Changing the hidesprite to the person's actual ID would make no difference as this is doing the exact same job. Your advice is very silly; telling him to use between 1000-2000 is wrong as flags go up to 3FFF so you could easily use those. He also doesn't need to get a new offset as 800000 is perfectly fine when you're using dynamic offsets.

Anyway, dido525, your description is very vague and is kinda weird. You say the sprite simply disappears? Well, by the looks of your script, that's exactly what it's meant to do. What exactly is wrong with everything?


It's only supposed to dissapear AFTER I talk to the person I inserted the offset into. However when I load the offset into advance map the sprite dosent even appear, even though I put in in the map. The funny thing is that if I remove the offset the sprite re-appears again so I don't know whats going on :S
 

Tannecho51

Pokemon Lion's Eye
11
Posts
13
Years
Hello, I'm new here. Generally, I just can't get applymovements to work. This is a script I've been trying again and again to get to work, but to no avail. Instead of the normal approach to giving starters, it's just a series of yes/no questions. I'm just a newb and I know I've done something horribly wrong in this script and that my problem has probably been answered in one of the 196 pages that I'm too lazy to read, but please bear with me.
Game: Ruby
Type: Starter Script
Editor: XSE
Script:
Spoiler:


It's a long script. Instead of posting a screenshot or video of what it does, I'll just tell you what it does: nothing. Even when I put 300 and 4050 for an applymovement, it still doesn't work. And I do have a dynamic offset, but I took it out to save space. Again, please bear with me, I'm just a newb. =D
 
119
Posts
14
Years
Hello, I'm new here. Generally, I just can't get applymovements to work. This is a script I've been trying again and again to get to work, but to no avail. Instead of the normal approach to giving starters, it's just a series of yes/no questions. I'm just a newb and I know I've done something horribly wrong in this script and that my problem has probably been answered in one of the 196 pages that I'm too lazy to read, but please bear with me.
Game: Ruby
Type: Starter Script
Editor: XSE
Script:
Spoiler:


It's a long script. Instead of posting a screenshot or video of what it does, I'll just tell you what it does: nothing. Even when I put 300 and 4050 for an applymovement, it still doesn't work. And I do have a dynamic offset, but I took it out to save space. Again, please bear with me, I'm just a newb. =D
It's very simple: after every applymovement command you should insert "waitmovement 0x0". It will work then. (The movements I mean, I don't know about the rest of the script.)

My problem: XSE gives "error 13: 'Type Mismatch' at line 37. No dynamic label.'" while debugging this script:
Spoiler:
(You understand that I deleted the text only for this post.)
Line 37 is bold. I don't quite understand why it is giving an error. Oh, and if someone could, please take a look at the trainerbattle command. It's at the bottom of the first part. Thanks in advance! :)
 

Ooka

[font=Maven Pro][color=#A75EE2]Cosmic[/color][/fon
2,626
Posts
16
Years
@Tannecho51

As jm said, use waitmovement 0x0 after all of your applymovements. Also, make sure to set the sprite in advancemap to 4050 (var number) and 0300 (Top Unknown)


@jm - Simple mistake, you don't have moveunknown6 defined in the bottom of the script. :P
 

Tannecho51

Pokemon Lion's Eye
11
Posts
13
Years
It's very simple: after every applymovement command you should insert "waitmovement 0x0". It will work then. (The movements I mean, I don't know about the rest of the script.)

I know that, for some reason not all of the script made it to the quote box. Here's the part of the script that got cut off:
Spoiler:


Apparently I did something wrong with the beginning because it is just not working.
 

Darthatron

巨大なトロール。
1,152
Posts
18
Years
I know that, for some reason not all of the script made it to the quote box. Here's the part of the script that got cut off:
Spoiler:


Apparently I did something wrong with the beginning because it is just not working.
You need to make you set the Variable to 4050 and the Unknown value to 0003 (on the script tile), otherwise applymovement scripts don't work.
 
2
Posts
13
Years
  • Seen Feb 15, 2011
Please Help?

I'm new to scripting and i tried to make this script. it is supposed to make it so that when you talk to a person he doesnt let you pass and then after you get birches bag he moves. the talking all works and i followed all the tutorials but the person im trying to make move doesnt move. could anyone please explain why it doesnt work or maybe fix it and show me how to do it? any help would be greatly apreciated thanks!


Here is the script-


'---------------
#org 0x6B12F4
checkflag 0x1000
if 0x0 call 0x8800071
msgbox 0x88000FA MSG_FACE '"You may pass."
applymovement 0x1234 0x80C3500
end

'---------------
#org 0x800071
msgbox 0x88000DF MSG_FACE '"I can't let you through."
end


'---------
' Strings
'---------
#org 0x8000FA
= You may pass.

#org 0x8000DF
= I can't let you through.


'-----------
' Movements
'-----------
#org 0xC3500
#raw 0x4 'Step Down (Slow)
#raw 0xFE 'End of Movements
 
2
Posts
13
Years
  • Seen Feb 15, 2011
Please Help?

I'm new to scripting and i tried to make this script. it is supposed to make it so that when you talk to a person he doesnt let you pass and then after you get birches bag he moves. the talking all works and i followed all the tutorials but the person im trying to make move doesnt move. could anyone please explain why it doesnt work or maybe fix it and show me how to do it? any help would be greatly apreciated thanks!


Here is the script-


'---------------
#org 0x6B12F4
checkflag 0x1000
if 0x0 call 0x8800071
msgbox 0x88000FA MSG_FACE '"You may pass."
applymovement 0x1234 0x80C3500
end

'---------------
#org 0x800071
msgbox 0x88000DF MSG_FACE '"I can't let you through."
end


'---------
' Strings
'---------
#org 0x8000FA
= You may pass.

#org 0x8000DF
= I can't let you through.


'-----------
' Movements
'-----------
#org 0xC3500
#raw 0x4 'Step Down (Slow)
#raw 0xFE 'End of Movements
 
26
Posts
13
Years
  • Seen Nov 24, 2010
I put in my script offset in the game, and I assigned it to a rocket grunt. When I went to test it out, my sprite for the guy wasn't there, not even an invisible person. Can someone please tell me what could've went wrong? Here's the script:

#org $rocketmajor
lock
faceplayer
checkflag 0x1209
if 0x01 goto $after
message $pie
$pie 1 = Do you want to know\lthe operation?
boxset 5
compare 0x800D 0x0001
if 0x01 goto $okay
$don't 1 = You already know?\nOkay then,\pGet to work!
boxset 6
release
end

#org $okay
message $okay1
$okay1 1 = Our Operation is to\n invade Viridian City,\lbut there's this\nlittle punk that's\l stopping us.\pHer name is May.
message $blabla
$blabla 1 = Do you want to know how\nto leave from the\lnorth and east?
boxset 5
compare 0x800D 0x0001
if 0x01 goto $yeah
$nah 1 = Get back to/nwork!
boxset 6
release
end

#org $yeah
message $yeah1
$yeah1 1 = For the north you'll/nneed a key from a/lme./pYou can't exit from the/neast.
boxset 6
release
end


#org $after
checkflag 0x1210
if 0x01 goto $woot
message $awesome
$awesome 1 = Good job soldier!\p For your service, I'll give you\n an item to show to\l the guard.
boxset 6
give item 0x106 0x01
message $sweet
$sweet 1 = Now get your pokemon ready for/nPewter City!
boxset 6
release
end

#org $woot
message $omg
$omg 1 = Now get your pokemon ready for/nPewter City!
boxset 6
release
end
 

jota_rdk

Spanish hacker [Javi4315]
98
Posts
13
Years
I put in my script offset in the game, and I assigned it to a rocket grunt. When I went to test it out, my sprite for the guy wasn't there, not even an invisible person. Can someone please tell me what could've went wrong? Here's the script:

#org $rocketmajor
lock
faceplayer
checkflag 0x1209
if 0x01 goto $after
message $pie
$pie 1 = Do you want to know\lthe operation?
boxset 5
compare 0x800D 0x0001
if 0x01 goto $okay
$don't 1 = You already know?\nOkay then,\pGet to work!
boxset 6
release
end

#org $okay
message $okay1
$okay1 1 = Our Operation is to\n invade Viridian City,\lbut there's this\nlittle punk that's\l stopping us.\pHer name is May.
message $blabla
$blabla 1 = Do you want to know how\nto leave from the\lnorth and east?
boxset 5
compare 0x800D 0x0001
if 0x01 goto $yeah
$nah 1 = Get back to/nwork!
boxset 6
release
end

#org $yeah
message $yeah1
$yeah1 1 = For the north you'll/nneed a key from a/lme./pYou can't exit from the/neast.
boxset 6
release
end


#org $after
checkflag 0x1210
if 0x01 goto $woot
message $awesome
$awesome 1 = Good job soldier!\p For your service, I'll give you\n an item to show to\l the guard.
boxset 6
give item 0x106 0x01
message $sweet
$sweet 1 = Now get your pokemon ready for/nPewter City!
boxset 6
release
end

#org $woot
message $omg
$omg 1 = Now get your pokemon ready for/nPewter City!
boxset 6
release
end

Have you put something in "People id" in advance map? I think that is the problem.
 

DrFuji

[I]Heiki Hecchara‌‌[/I]
1,691
Posts
14
Years
bobashnabala said:
applymovement 0x1234 0x80C3500

I'd say that this line is your problem. Your Person Event Number (1234) is incredibly large and as such is unlikey to actually be used on the map. Have a look at the person you are trying to move in Advance Map and write down their real event number to be used in the script.

If you have changed their event number for some reason, you should have to remember that you have to write it down in HEX in XSE. So therefore the person you're trying to move doesn't have the event number '1234' assigned to them, but '4D2'.
 
Last edited:
Status
Not open for further replies.
Back
Top