• 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?".
  • 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.
39
Posts
15
Years
  • Age 29
  • Seen Aug 20, 2010
This script is supposed to make a cave entrance appear when you press A on a signpost, but nothing happens.

'-----------------------
#org 0xE20000
setmaptile 0xE 0x4 0x28B 0x1
setmaptile 0xF 0x4 0x28C 0x1
setmaptile 0x10 0x4 0x28D 0x1
setmaptile 0xE 0x5 0x293 0x1
setmaptile 0xF 0x5 0x294 0x0
setmaptile 0x10 0x5 0x295 0x1
end
 

arpeejajo

King Of Muay Thai
36
Posts
16
Years
0x4 is to be used with closeonkeypress but i don't know why its not working. What exactly is happening?
From XSE it compiles just fine. But in game nothing happens, I walk right through the script.
The sprite that has the movements has an unknown of 03 and it's event number is 1.
The script offset is 800008, unknown 0003, and Var Number I use is 7000 (I also tried with 4050 and nothing happened).
 

Quickster

Dream or Drop?
351
Posts
16
Years
  • Seen Apr 4, 2016
From XSE it compiles just fine. But in game nothing happens, I walk right through the script.
The sprite that has the movements has an unknown of 03 and it's event number is 1.
The script offset is 800008, unknown 0003, and Var Number I use is 7000 (I also tried with 4050 and nothing happened).

So the person event number is 1. The unknown for the script tile is 0003(the unknown above var number).The var number is 4050. The var value is 0000. If you use var number 7000 put 0001 in the var value and make a script like this.

Code:
#dynamic 0x??????

#org @start
compare 0x7000 0x2
if 0x1 goto @end
setvar 0x7000 0x1
release
end

#org @end
release
end

Then in your original script after its done setvar 0x7000 0x2 so it wont happen again.
 

arpeejajo

King Of Muay Thai
36
Posts
16
Years
So the person event number is 1. The unknown for the script tile is 0003(the unknown above var number).The var number is 4050. The var value is 0000. If you use var number 7000 put 0001 in the var value and make a script like this.

Code:
#dynamic 0x??????

#org @start
compare 0x7000 0x2
if 0x1 goto @end
setvar 0x7000 0x1
release
end

#org @end
release
end
Then in your original script after its done setvar 0x7000 0x2 so it wont happen again.
So that code is in a separate offset right? I did that and added everything else, but it still doesn't work.
 

Quickster

Dream or Drop?
351
Posts
16
Years
  • Seen Apr 4, 2016
So that code is in a separate offset right? I did that and added everything else, but it still doesn't work.

Hmm,it is in a different offset.Can you tell me the steps you are doing everything in fot the original?
 

Congratulations I Hate You

Used to be itman1234...
18
Posts
14
Years
  • Age 30
  • CT
  • Seen Jan 27, 2010
This script is supposed to make a cave entrance appear when you press A on a signpost, but nothing happens.

'-----------------------
#org 0xE20000
setmaptile 0xE 0x4 0x28B 0x1
setmaptile 0xF 0x4 0x28C 0x1
setmaptile 0x10 0x4 0x28D 0x1
setmaptile 0xE 0x5 0x293 0x1
setmaptile 0xF 0x5 0x294 0x0
setmaptile 0x10 0x5 0x295 0x1
special 0x8E
end

there. try that, special 0x8E resets the map for it to work.
 

arpeejajo

King Of Muay Thai
36
Posts
16
Years
Hmm,it is in a different offset.Can you tell me the steps you are doing everything in fot the original?

So I started by placing the script on the map and filling out the variables and made the offset. Then I added the person event on the map that will be part of the script and filled out the unknown.
I put in this code and compiled it.
Code:
'---------------
#org 0x800008
lock
msgbox 0x8800027 0x6 '"Hmm. Where am I?"
closeonkeypress
applymovement 0x1 0x880003A
waitmovement 0x0
setvar 0x7000 0x2
release
end


'---------
' Strings
'---------
#org 0x800027
= Hmm. Where am I?


'-----------
' Movements
'-----------
#org 0x80003A
#raw 0x13 'Step Right (Normal)
#raw 0x13 'Step Right (Normal)
#raw 0x13 'Step Right (Normal)
#raw 0x13 'Step Right (Normal)
#raw 0x10 'Step Down (Normal)
#raw 0x10 'Step Down (Normal)
#raw 0x10 'Step Down (Normal)
#raw 0xFE 'End of Movements

After that I added your code that you gave me to a new offset and compiled it.
Code:
#dynamic 0x800044

#org @start
compare 0x7000 0x2
if 0x1 goto @end
setvar 0x7000 0x1
release
end

#org @end
release
end
Save, test, nothing.
 

Quickster

Dream or Drop?
351
Posts
16
Years
  • Seen Apr 4, 2016
So I started by placing the script on the map and filling out the variables and made the offset. Then I added the person event on the map that will be part of the script and filled out the unknown.
I put in this code and compiled it.
Code:
'---------------
#org 0x800008
lock
msgbox 0x8800027 0x6 '"Hmm. Where am I?"
closeonkeypress
applymovement 0x1 0x880003A
waitmovement 0x0
setvar 0x7000 0x2
release
end


'---------
' Strings
'---------
#org 0x800027
= Hmm. Where am I?


'-----------
' Movements
'-----------
#org 0x80003A
#raw 0x13 'Step Right (Normal)
#raw 0x13 'Step Right (Normal)
#raw 0x13 'Step Right (Normal)
#raw 0x13 'Step Right (Normal)
#raw 0x10 'Step Down (Normal)
#raw 0x10 'Step Down (Normal)
#raw 0x10 'Step Down (Normal)
#raw 0xFE 'End of Movements

After that I added your code that you gave me to a new offset and compiled it.
Code:
#dynamic 0x800044

#org @start
compare 0x7000 0x2
if 0x1 goto @end
setvar 0x7000 0x1
release
end

#org @end
release
end
Save, test, nothing.


Hmm,maybe can you send me an ips file in a pm and I can take a look at it?
 

NarutoActor

The rocks cry out to me
1,974
Posts
15
Years
you need a level map (set map tile) I knew that you where going to ask this. what you should do is after the script put setvar 0x5000 0x1 and add a level script like this
'---------------
#org @levelscript
#raw 0x1
#raw pointer @example
#raw 0x0

'---------------
#org @example
compare 0x5000 0x1
if 0x1 goto @map
release
end

'---------------
#org @map
setmaptile 0x33 0x2B 0x299 0x1
setmaptile 0x34 0x2B 0x299 0x1
setmaptile 0x35 0x2B 0x299 0x1
setmaptile 0x36 0x2B 0x299 0x1
setmaptile 0x33 0x2A 0x2E1 0x1
setmaptile 0x34 0x2A 0x2E1 0x1
setmaptile 0x35 0x2A 0x2E1 0x1
setmaptile 0x36 0x2A 0x2E1 0x1
return
 

arpeejajo

King Of Muay Thai
36
Posts
16
Years
So my script has a givepokemon but when I get the Pokemon and press start, the Pokemon option is not there.

Also, how do I get a script to activate only once?
 
39
Posts
15
Years
  • Age 29
  • Seen Aug 20, 2010
With a scripted warp, is there any way to change the direction that the character is facing? Normally, the character is automatically facing down, regardless of the direction he was facing before.
 

arpeejajo

King Of Muay Thai
36
Posts
16
Years
Here's a sample script. I'm not sure where the offset for the POKEMON menu goes.

Here's a basic talking script with a checkflag/setflag:
Spoiler:

There is also a third command called clearflag that checks for flag 0x200 in the sample script above and removes it, allowing the script to be activated again. It wouldn't be useful in some cases, but there are some practical uses for it.
Thank you very much, that helped a lot and it worked perfectly.
I also need to know how you call the 0x828 to my script and how to make a person disappear. Please and thank you.
 
Last edited:

arpeejajo

King Of Muay Thai
36
Posts
16
Years
I can't remember how to place in a flag, I'm figuring that out myself. As well, I don't know how to remove a sprite after you're done interacting with it. Check this AMAZING scripting thread, it may answer this and many more of your questions.
HTML:
http://www.pokecommunity.com/showthread.php?t=128887
All credits go to thethethethe for the tutorial.

I cannot thank you enough. I got the Pokemenu to show, and I got the person to disappear. That tutorial is amazing.
 

Quickster

Dream or Drop?
351
Posts
16
Years
  • Seen Apr 4, 2016
I cannot thank you enough. I got the Pokemenu to show, and I got the person to disappear. That tutorial is amazing.

Just to let you know, diegoisawesome translated that tutorial to XSE. Its in the doucuments section.
 

trebornosliw

Learning
516
Posts
14
Years
  • Age 31
  • Seen Jul 22, 2012
So Special 0x8E is a must for all setmaptile scripts, then?
Also, thanks to NarutoActor for his explanation of the setmaptile level script, I was looking for a description of how to do that.

Update to my question. Here are the scripts I've made for an event on what used to be the Route 5 FR map. I'm just double-checking to make sure I didn't forget anything. The first script is the actual encounter, the second is my level script.

Spoiler:

Spoiler:
 
Last edited:

trebornosliw

Learning
516
Posts
14
Years
  • Age 31
  • Seen Jul 22, 2012
Oops, actually I forgot to include the first half of the script :\
Here it is
Spoiler:
 
Status
Not open for further replies.
Back
Top