The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > Fan Games > Binary ROM Hacking
Reload this Page Other Two Way Route

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 8th, 2016 (2:17 AM). Edited June 8th, 2016 by Hajima.
Hajima's Avatar
Hajima Hajima is offline
Manga Artist 101
 
Join Date: May 2016
Gender: Male
Nature: Calm
Posts: 111
I'm making a Pokemon Rom Hack that I was hoping that can have a Two Way Route.

What I meant was, You can either be in the bad side or good side.

Is it possible? Like for example, at the very start you we're asked if you would become good or evil, and what choice you made would direct you to the good or bad route?

The script I'm going to be using to trigger the routes is this :
Spoiler:
#dynamic 0x800000

#org @start
lock
msgbox @yesno 0x5
compare lastresult 0x1
if 0x1 goto @yespart
msgbox @no 0x2
release
end

#org @yespart
lock
msgbox @yes 0x6
release
end

#org @yesno
= ???: You know, I've been thinking.\p\v\h01\: Hm?\p???: Pokemons.\pSuch horrible creatures.\pThey turn us humans into such\naddicts.\pThey kill and attack without\nhesitation.\pSomeday I'll wipe them all, with\nyou.\pRight \v\h01\?

#org @yes
= Yeah, I knew you would say that.\pWe should probably head back now.\pSayonara!

#org @no
= What? Are you crazy? You must be\none of those addicts too.\pI'm heading back, you'll regret\nthis.


I also have the problem with that script, where should I add the warp script?

Thanks!

Additional : How the heck do you make a script tile, all the tutorials I've read so far don't make sense at all.
__________________
Check out my Rom Hack! ;)
Pokemon Conjure : http://www.pokecommunity.com/showthread.php?p=9255336#post9255336
Reply With Quote
  #2   Link to this post, but load the entire thread.  
Old June 8th, 2016 (5:39 AM). Edited June 8th, 2016 by 0.
0's Avatar
0 0 is offline
Happy and at peace. :)
 
Join Date: May 2016
Location: Pallet Town
Gender: Male
Nature: Calm
Posts: 556
Quote:
Originally Posted by Hajima View Post
I'm making a Pokemon Rom Hack that I was hoping that can have a Two Way Route.

What I meant was, You can either be in the bad side or good side.

Is it possible? Like for example, at the very start you we're asked if you would become good or evil, and what choice you made would direct you to the good or bad route?

The script I'm going to be using to trigger the routes is this :
Spoiler:
#dynamic 0x800000

#org @start
lock
msgbox @yesno 0x5
compare lastresult 0x1
if 0x1 goto @yespart
msgbox @no 0x2
release
end

#org @yespart
lock
msgbox @yes 0x6
release
end

#org @yesno
= ???: You know, I've been thinking.\p\v\h01\: Hm?\p???: Pokemons.\pSuch horrible creatures.\pThey turn us humans into such\naddicts.\pThey kill and attack without\nhesitation.\pSomeday I'll wipe them all, with\nyou.\pRight \v\h01\?

#org @yes
= Yeah, I knew you would say that.\pWe should probably head back now.\pSayonara!

#org @no
= What? Are you crazy? You must be\none of those addicts too.\pI'm heading back, you'll regret\nthis.


I also have the problem with that script, where should I add the warp script?

Thanks!

Additional : How the heck do you make a script tile, all the tutorials I've read so far don't make sense at all.
To Hajima:

I added some organization tags which I myself have noticed have started to become useful, especially if you want to save an archival copy of your script in a folder or something.

For parts of these scripts, I will assume you have used the tutorial found here:
http://www.pokecommunity.com/showthread.php?t=302476

It is very useful to add this in the long run, but to each their own.

What I will be doing is using a safe, already in game flag, for a yes or no at the beginning. This flag will pretty much be used through out the entire script, and is the single most important flag you will have in your ROM.

I will be using flag 0x230 for your good or evil choice, which is the one used for the pokemart dude in route 1.

If this is set it will = 1, which means that, yes, we have chosen the evil path. If it is not set, it will automatically be 0, meaning we don't have to set it.

setflag 0x2C6 is to permanently remove the NPC from the map, so the event will never play again. This flag was from the fat guy in Viridian.

When reading the script, understand that since the 0x230 flag is already set to 0, we are automatically good. In the script, we have it set it to 1 to make the player evil.

I also added the warp script after the player is released, in an easy to understand format.

Good or evil Choice Script:
Spoiler:

#dynamic 0xYOUROFFSET

'---------
' Main Function
'---------

#org @start
lock
msgbox @yesno 0x5
setflag 0x2C6 ' This should be added to the NPC's PERSON ID, so that this NPC will NEVER appear on that map again. It's placed here to say that "regardless of the players choice, this NPC must go afterward." Check the images below to see what a "Person ID" is.
compare 0x800D 0x1 ' Same as last result, just looks cleaner.
if 0x1 goto @yespart
msgbox @no 0x6 ' You had a two here instead of six... I don't know if that was intentional.
release
warp 0xMAPBANK 0xMAPNUMBER 0xFF 0xXPOSITION 0xYPOSITION ' Warp to the good map.
end

#org @yespart
lock ' Dont need this, as we have already locked.
setflag 0x230 ' Sets the player to evil.
msgbox @yes 0x6
release
warp 0xMAPBANK 0xMAPNUMBER 0xFF 0xXPOSITION 0xYPOSITION ' Warp to the evil map.
end

'---------
' Main Function End
'---------

'---------
' Strings
'---------

#org @yesno
= ???: You know, I've been thinking.\p\v\h01\: Hm?\p???: Pokemons.\pSuch horrible creatures.\pThey turn us humans into such\naddicts.\pThey kill and attack without\nhesitation.\pSomeday I'll wipe them all, with\nyou.\pRight \v\h01\?

#org @yes
= Yeah, I knew you would say that.\pWe should probably head back now.\pSayonara!

#org @no
= What? Are you crazy? You must be\none of those addicts too.\pI'm heading back, you'll regret\nthis.

'---------
' Strings End
'---------



Now I'm also going to add an extra something that should help in the future as your hack progresses, and is also a good example as to what you can do with the above script.

Sometimes, you will probably be using the same map, but you just want certain people to appear for the good choice, and some for the bad choice.

Now, lets say for example you have 5 people on a map, total. Now, if you choose the bad side, two, lets say rockets, should be on the map. If you choose the good side, two police or whatever, should be on the map. The last person should be a bystander that changes his message based on your choice, but stays on the map either way.

To do the first part, we must add a level script to the map, setting and changing flags based on our choice that will remove two of the other sides people.

You add the below flags to each Person ID in Advance Map. Again, there is an image below for reference.

Finally since I am using the extended flags from the tutorial above, you WILL need to change these flags below to ones already used in game if you have NOT applied the hack.

EDIT: I just looked at some flags, so that you could test the script, if you decide to wait on adding that hack. The flags are 0x249, from the Magikarp guy on Route 4, and 0x232, from the fossil guy in MT. Moon. You would just exchange them out for whichever one.

Level Script:
Spoiler:

#dynamic 0xYOUROFFSET

#org @arewegoodorbad
checkflag 0x230 ' This will check our side.
if 0x1 goto @removepolice ' If we are evil, we will remove the police.
goto @removerockets ' If we are good, we will remove the rockets.

#org @removerockets
setflag 0xC01 ' This will remove the Rockets from the map. You add this to the rockets Person ID.
end

#org @removepolice
setflag 0xC02 ' This will remove the Police from the map. You add this to the police Person ID.
end


Use the tutorial here to correctly insert the level script, you WILL need to do this:
http://www.pokecommunity.com/showpost.php?p=4414826

Here is an image album to a few images explaining where to put things:
https://imgur.com/a/0d6Zs

As you can see, I simply used the variable 0x4012 and 0x0000 for the level script.

This means that when the variable 0x4012 = 0, we will run the level script.

I would personally choose a variable that will ALWAYS be zero, or you could look more into level scripts to run it when entering a map, etc.

Finally, since we also have a bystander, we will add his own unique script, changing his message based on your choice of good or evil.

Bystander Script:
Spoiler:

#dynamic 0xYOUROFFSET

'---------
' Main Function
'---------

#org @bystander
lock
faceplayer
checkflag 0x230 ' This will check our side.
if 0x1 goto @scaredashell ' If we are evil, we will display this.
goto @thankgodyouareacop ' If we are good, we will display this.

'---------
' Main Function End
'---------

'---------
' Message Functions
'---------

#org @scaredashell
msgbox @scaredashellmessage 0x6
release
end


#org @thankgodyouareacop
msgbox @thankgodyouareacopmessage 0x6
release
end

'---------
' Message Functions End
'---------

'---------
' Strings
'---------

#org @scaredashellmessage
= Ohmigod! You're a rocket!\nI'm scared as hell.

#org @thankgodyouareacopmessage
= Oh, thank god you're a cop.\nSome rockets were just here!

'---------
' Strings End
'---------


And that's pretty much it. You now have a working choice script, a working level script, and a working person who says something different based on your choice.

This is pretty comprehensive for your question, but it will future-proof your hack.

It might look like a lot at first, but read carefully and look at the images, and you'll be sure to get it.

Good luck, and happy hacking!

EDIT: Script Tile? What do you mean?
__________________

Just dance with me!!!!!!!

Reply With Quote
  #3   Link to this post, but load the entire thread.  
Old June 8th, 2016 (6:00 AM). Edited June 8th, 2016 by Hajima.
Hajima's Avatar
Hajima Hajima is offline
Manga Artist 101
 
Join Date: May 2016
Gender: Male
Nature: Calm
Posts: 111
Quote:
Originally Posted by Nonibros View Post
To Hajima:

I added some organization tags which I myself have noticed have started to become useful, especially if you want to save an archival copy of your script in a folder or something.

For parts of these scripts, I will assume you have used the tutorial found here:
http://www.pokecommunity.com/showthread.php?t=302476

It is very useful to add this in the long run, but to each their own.

What I will be doing is using a safe, already in game flag, for a yes or no at the beginning. This flag will pretty much be used through out the entire script, and is the single most important flag you will have in your ROM.

I will be using flag 0x230 for your good or evil choice, which is the one used for the pokemart dude in route 1.

If this is set it will = 1, which means that, yes, we have chosen the evil path. If it is not set, it will automatically be 0, meaning we don't have to set it.

setflag 0x2C6 is to permanently remove the NPC from the map, so the event will never play again. This flag was from the fat guy in Viridian.

When reading the script, understand that since the 0x230 flag is already set to 0, we are automatically good. In the script, we have it set it to 1 to make the player evil.

I also added the warp script after the player is released, in an easy to understand format.

Good or evil Choice Script:
Spoiler:

#dynamic 0xYOUROFFSET

'---------
' Main Function
'---------

#org @start
lock
msgbox @yesno 0x5
setflag 0x2C6 ' This should be added to the NPC's PERSON ID, so that this NPC will NEVER appear on that map again. It's placed here to say that "regardless of the players choice, this NPC must go afterward." Check the images below to see what a "Person ID" is.
compare 0x800D 0x1 ' Same as last result, just looks cleaner.
if 0x1 goto @yespart
msgbox @no 0x6 ' You had a two here instead of six... I don't know if that was intentional.
release
warp 0xMAPBANK 0xMAPNUMBER 0xFF 0xXPOSITION 0xYPOSITION ' Warp to the good map.
end

#org @yespart
lock ' Dont need this, as we have already locked.
setflag 0x230 ' Sets the player to evil.
msgbox @yes 0x6
release
warp 0xMAPBANK 0xMAPNUMBER 0xFF 0xXPOSITION 0xYPOSITION ' Warp to the evil map.
end

'---------
' Main Function End
'---------

'---------
' Strings
'---------

#org @yesno
= ???: You know, I've been thinking.\p\v\h01\: Hm?\p???: Pokemons.\pSuch horrible creatures.\pThey turn us humans into such\naddicts.\pThey kill and attack without\nhesitation.\pSomeday I'll wipe them all, with\nyou.\pRight \v\h01\?

#org @yes
= Yeah, I knew you would say that.\pWe should probably head back now.\pSayonara!

#org @no
= What? Are you crazy? You must be\none of those addicts too.\pI'm heading back, you'll regret\nthis.

'---------
' Strings End
'---------



Now I'm also going to add an extra something that should help in the future as your hack progresses, and is also a good example as to what you can do with the above script.

Sometimes, you will probably be using the same map, but you just want certain people to appear for the good choice, and some for the bad choice.

Now, lets say for example you have 5 people on a map, total. Now, if you choose the bad side, two, lets say rockets, should be on the map. If you choose the good side, two police or whatever, should be on the map. The last person should be a bystander that changes his message based on your choice, but stays on the map either way.

To do the first part, we must add a level script to the map, setting and changing flags based on our choice that will remove two of the other sides people.

You add the below flags to each Person ID in Advance Map. Again, there is an image below for reference.

Finally since I am using the extended flags from the tutorial above, you WILL need to change these flags below to ones already used in game if you have NOT applied the hack.

EDIT: I just looked at some flags, so that you could test the script, if you decide to wait on adding that hack. The flags are 0x249, from the Magikarp guy on Route 4, and 0x232, from the fossil guy in MT. Moon. You would just exchange them out for whichever one.

Level Script:
Spoiler:

#dynamic 0xYOUROFFSET

#org @arewegoodorbad
checkflag 0x230 ' This will check our side.
if 0x1 goto @removepolice ' If we are evil, we will remove the police.
goto @removerockets ' If we are good, we will remove the rockets.

#org @removerockets
setflag 0xC01 ' This will remove the Rockets from the map. You add this to the rockets Person ID.
end

#org @removepolice
setflag 0xC02 ' This will remove the Police from the map. You add this to the police Person ID.
end


Use the tutorial here to correctly insert the level script, you WILL need to do this:
http://www.pokecommunity.com/showpost.php?p=4414826

Here is an image album to a few images explaining where to put things:
https://imgur.com/a/0d6Zs

As you can see, I simply used the variable 0x4012 and 0x0000 for the level script.

This means that when the variable 0x4012 = 0, we will run the level script.

I would personally choose a variable that will ALWAYS be zero, or you could look more into level scripts to run it when entering a map, etc.

Finally, since we also have a bystander, we will add his own unique script, changing his message based on your choice of good or evil.

Bystander Script:
Spoiler:

#dynamic 0xYOUROFFSET

'---------
' Main Function
'---------

#org @bystander
lock
faceplayer
checkflag 0x230 ' This will check our side.
if 0x1 goto @scaredashell ' If we are evil, we will display this.
goto @thankgodyouareacop ' If we are good, we will display this.

'---------
' Main Function End
'---------

'---------
' Message Functions
'---------

#org @scaredashell
msgbox @scaredashellmessage 0x6
release
end


#org @thankgodyouareacop
msgbox @thankgodyouareacopmessage 0x6
release
end

'---------
' Message Functions End
'---------

'---------
' Strings
'---------

#org @scaredashellmessage
= Ohmigod! You're a rocket!\nI'm scared as hell.

#org @thankgodyouareacopmessage
= Oh, thank god you're a cop.\nSome rockets were just here!

'---------
' Strings End
'---------


And that's pretty much it. You now have a working choice script, a working level script, and a working person who says something different based on your choice.

This is pretty comprehensive for your question, but it will future-proof your hack.

It might look like a lot at first, but read carefully and look at the images, and you'll be sure to get it.

Good luck, and happy hacking!

EDIT: Script Tile? What do you mean?
I didn't use the tutorial from "http://www.pokecommunity.com/showthread.php?t=302476". I also have little information about flags and vars because I've only started Rom Hacking a couple weeks ago (4 1/2 to be exact).

I'll try the script and flags later! Also, what I meant by script tile was like, a message box appearing as of a narration (doesn't have an npc). But damn, this is pretty complicated and pretty hard to understand. lol
__________________
Check out my Rom Hack! ;)
Pokemon Conjure : http://www.pokecommunity.com/showthread.php?p=9255336#post9255336
Reply With Quote
  #4   Link to this post, but load the entire thread.  
Old June 8th, 2016 (7:51 AM).
0's Avatar
0 0 is offline
Happy and at peace. :)
 
Join Date: May 2016
Location: Pallet Town
Gender: Male
Nature: Calm
Posts: 556
To Hajima:

I understand why you say it's complicated. To shorten it the last post it would pretty much be this:

You set a flag: 1 for evil, 0 for good. That is your permanent choice throughout the game, and everything changes based on that choice.

As you progress, you will want different events for each choice. For example, when you enter a map, say a city, you might wish to make certain people appear for the evil side, and other people for the good.

You might also wish to have people whom appear on both sides, who say different things depending on what side you are on. If you're bad, they might be scared. If you're good, they might be relieved.

To make people disappear, you need to check the side you are on and set a flag based on that. In the games, simply assigning a set flag to a Person ID removes them from the map.

If you choose the good side, certain, non related NPC's should disappear, as they do not apply. Same for the evil side.

Those scripts are examples of what you will want to do as your game progresses, which is make certain things happen based on your choice.



The warp is easiest added after releasing the player, and will teleport you immediately to another location.

This is a sample tilescript. This particular one could make it look like an NPC is pushing the player after telling them to back off.

Tilescript:
Spoiler:

#dynamic 0x800000

#org @tilescript
lockall
textcolor 0x0
msgbox @backupbub 0x6 ' Display a message
applymovement MOVE_PLAYER @stepback ' Move player down.
waitmovement 0x0
releaseall
end


'---------
' Strings
'---------
#org @backupbub
= Hey bub, back up.

'-----------
' Movements
'-----------
#org @stepback
#raw 0x10 'Step Down (Normal)
#raw 0xFE 'End of Movements



Simple "step on this and display a message" script:
Spoiler:

#dynamic 0x800000

#org @tilescript2
lockall
textcolor 0x0
msgbox @yousteppedhere 0x6 ' Display a message
releaseall
end


'---------
' Strings
'---------
#org @yousteppedhere
= You just stepped on a tilescript!


Re read these as you go and you'll find that they are easier to understand after some trail and error.

One last tip, and this is what I was trying to do in the last post: As the game gets bigger, you will have larger events, and you will want to organize your scripts better.

If you have any questions, either VM or PM me.

Good luck, and have fun!
__________________

Just dance with me!!!!!!!

Reply With Quote
  #5   Link to this post, but load the entire thread.  
Old June 8th, 2016 (8:19 AM). Edited June 8th, 2016 by Hajima.
Hajima's Avatar
Hajima Hajima is offline
Manga Artist 101
 
Join Date: May 2016
Gender: Male
Nature: Calm
Posts: 111
Quote:
Originally Posted by Nonibros View Post
To Hajima:

I understand why you say it's complicated. To shorten it the last post it would pretty much be this:

You set a flag: 1 for evil, 0 for good. That is your permanent choice throughout the game, and everything changes based on that choice.

As you progress, you will want different events for each choice. For example, when you enter a map, say a city, you might wish to make certain people appear for the evil side, and other people for the good.

You might also wish to have people whom appear on both sides, who say different things depending on what side you are on. If you're bad, they might be scared. If you're good, they might be relieved.

To make people disappear, you need to check the side you are on and set a flag based on that. In the games, simply assigning a set flag to a Person ID removes them from the map.

If you choose the good side, certain, non related NPC's should disappear, as they do not apply. Same for the evil side.

Those scripts are examples of what you will want to do as your game progresses, which is make certain things happen based on your choice.



The warp is easiest added after releasing the player, and will teleport you immediately to another location.

This is a sample tilescript. This particular one could make it look like an NPC is pushing the player after telling them to back off.

Tilescript:
Spoiler:

#dynamic 0x800000

#org @tilescript
lockall
textcolor 0x0
msgbox @backupbub 0x6 ' Display a message
applymovement MOVE_PLAYER @stepback ' Move player down.
waitmovement 0x0
releaseall
end


'---------
' Strings
'---------
#org @backupbub
= Hey bub, back up.

'-----------
' Movements
'-----------
#org @stepback
#raw 0x10 'Step Down (Normal)
#raw 0xFE 'End of Movements



Simple "step on this and display a message" script:
Spoiler:

#dynamic 0x800000

#org @tilescript2
lockall
textcolor 0x0
msgbox @yousteppedhere 0x6 ' Display a message
releaseall
end


'---------
' Strings
'---------
#org @yousteppedhere
= You just stepped on a tilescript!


Re read these as you go and you'll find that they are easier to understand after some trail and error.

One last tip, and this is what I was trying to do in the last post: As the game gets bigger, you will have larger events, and you will want to organize your scripts better.

If you have any questions, either VM or PM me.

Good luck, and have fun!
So there's no need for me to follow the tutorial from the page http://www.pokecommunity.com/showthread.php?t=302476?
EDIT : Also the flag that also indicates the pokemart dude from route 1, won't it be affected if I used it? Same goes for the other one?
EDIT: My game freezes when stepping on the "step on this and display a message" script.
__________________
Check out my Rom Hack! ;)
Pokemon Conjure : http://www.pokecommunity.com/showthread.php?p=9255336#post9255336
Reply With Quote
  #6   Link to this post, but load the entire thread.  
Old June 8th, 2016 (9:21 AM). Edited June 8th, 2016 by 0.
0's Avatar
0 0 is offline
Happy and at peace. :)
 
Join Date: May 2016
Location: Pallet Town
Gender: Male
Nature: Calm
Posts: 556
To Hajima:

I apologize. I thought you were making a completely NEW hack. If you aren't you will probably need to add both the flag hack AND the variable hack as well.

There is a list of the complete usable flags and variables: http://www.pokecommunity.com/showthread.php?t=302347, but what it boils down to is you have a VERY limited number in the vanilla game.

Most hackers who are hacking a vanilla ROM would typically take flags, like the Pokemart guys, and variables, like Professor Oaks, remove those events from the game, and use them for their own purposes. From what it sounds like, you will need the extension hack, no real way around it, especially if you are keeping normal events like the Pokemart guys.

If you ARE making a new hack, then you won't have the Pokemart guy and so you will simply take his flag. Same with the rest of the events.

I can assure you, it will be VERY difficult to make a new hack with just what is in the game.

I apologize about the tilescript. It needs a variable to run. For my test, I personally just used 0x4050, which is used by Professor Oak in Pallet Town. You will have to change this, and a guide is found here:
http://www.pokecommunity.com/showthread.php?t=161616 Check the "Scripts" Section to change the variable number.

I do apologize. This all probably just looks like a lot of words to you. Here's a simplified version:

You will probably need the hack, especially if you are using in game events, like the potion from the Pokemart guy.
You are very limited if you do not add the hack, a list of free flags and variables is here: http://www.pokecommunity.com/showthread.php?t=302347
If you choose not to add the hack, you will have to remove events in game anyways, so the point is moot.
If you hack is brand new, but you don't add the extension, you can just use the variables already in game, such as the old pokemart guy, the Route 4 Magikarp guy, etc.
Tilescript needs a variable in advance map to run. It needs to be a free one, or one that will always be zero or a specified number.

If you need help with the addition of the flag extension hack, I can make a patch for you that you would simply patch to your game and you'd be all set. 1 problem with the flags is you can't use the ingame help system, which some people are unaware of. It's typically not used, but again, you may want it.

Good luck, let me know if you have questions.
__________________

Just dance with me!!!!!!!

Reply With Quote
  #7   Link to this post, but load the entire thread.  
Old June 8th, 2016 (9:38 AM).
Hajima's Avatar
Hajima Hajima is offline
Manga Artist 101
 
Join Date: May 2016
Gender: Male
Nature: Calm
Posts: 111
Quote:
Originally Posted by Nonibros View Post
To Hajima:

I apologize. I thought you were making a completely NEW hack. If you aren't you will probably need to add both the flag hack AND the variable hack as well.

There is a list of the complete usable flags and variables: http://www.pokecommunity.com/showthread.php?t=302347, but what it boils down to is you have a VERY limited number in the vanilla game.

Most hackers who are hacking a vanilla ROM would typically take flags, like the Pokemart guys, and variables, like Professor Oaks, remove those events from the game, and use them for their own purposes. From what it sounds like, you will need the extension hack, no real way around it, especially if you are keeping normal events like the Pokemart guys.

If you ARE making a new hack, then you won't have the Pokemart guy and so you will simply take his flag. Same with the rest of the events.

I can assure you, it will be VERY difficult to make a new hack with just what is in the game.

I apologize about the tilescript. It needs a variable to run. For my test, I personally just used 0x4050, which is used by Professor Oak in Pallet Town. You will have to change this, and a guide is found here:
http://www.pokecommunity.com/showthread.php?t=161616 Check the "Scripts" Section to change the variable number.

I do apologize. This all probably just looks like a lot of words to you. Here's a simplified version:

You will probably need the hack, especially if you are using in game events, like the potion from the Pokemart guy.
You are very limited if you do not add the hack, a list of free flags and variables is here: http://www.pokecommunity.com/showthread.php?t=302347
If you choose not to add the hack, you will have to remove events in game anyways, so the point is moot.
If you hack is brand new, but you don't add the extension, you can just use the variables already in game, such as the old pokemart guy, the Route 4 Magikarp guy, etc.
Tilescript needs a variable in advance map to run. It needs to be a free one, or one that will always be zero or a specified number.

If you need help with the addition of the flag extension hack, I can make a patch for you that you would simply patch to your game and you'd be all set. 1 problem with the flags is you can't use the ingame help system, which some people are unaware of. It's typically not used, but again, you may want it.

Good luck, let me know if you have questions.
I'd very much appreciate it if you do make a patch, it will totally boost up the process.
__________________
Check out my Rom Hack! ;)
Pokemon Conjure : http://www.pokecommunity.com/showthread.php?p=9255336#post9255336
Reply With Quote
  #8   Link to this post, but load the entire thread.  
Old June 8th, 2016 (10:17 AM).
0's Avatar
0 0 is offline
Happy and at peace. :)
 
Join Date: May 2016
Location: Pallet Town
Gender: Male
Nature: Calm
Posts: 556
You must have free space at 0xA00000 - 0xA001A0. If you don't let me know.

Patch is attached and added some other fixes, listed in the readme. Apply the no running indoors patch if you don't want that. Do that after applying the first.
Attached Files
File Type: zip Hajima-Patch.zip‎ (1.9 KB, 5 views) (Save to Dropbox)
__________________

Just dance with me!!!!!!!

Reply With Quote
  #9   Link to this post, but load the entire thread.  
Old June 8th, 2016 (10:39 AM). Edited June 8th, 2016 by Hajima.
Hajima's Avatar
Hajima Hajima is offline
Manga Artist 101
 
Join Date: May 2016
Gender: Male
Nature: Calm
Posts: 111
Quote:
Originally Posted by Nonibros View Post
You must have free space at 0xA00000 - 0xA001A0. If you don't let me know.

Patch is attached and added some other fixes, listed in the readme. Apply the no running indoors patch if you don't want that. Do that after applying the first.
It works but, one other question. If i used the var 4050, am I able to use it again on an other script?

Thanks! This has really helped me alot!

EDIT : After setting flag 0x230 as the evil route, how do I actually set it up on other events?
__________________
Check out my Rom Hack! ;)
Pokemon Conjure : http://www.pokecommunity.com/showthread.php?p=9255336#post9255336
Reply With Quote
  #10   Link to this post, but load the entire thread.  
Old June 8th, 2016 (10:53 AM).
0's Avatar
0 0 is offline
Happy and at peace. :)
 
Join Date: May 2016
Location: Pallet Town
Gender: Male
Nature: Calm
Posts: 556
Let me put it like this. Since you've patched the ROM, just use var 0x5000. This would just stay at zero, which is what you'll want. If you change the variable, let's say to 1, when you step on the tilescript, it will NOT work. This can be useful if you need to run a script one time, or if, as you progress, need a certain event to activate after another one.

Short answer, for constant tilescripts that you always want to run, use a variable, like 0x5000, and never change it.

For tilescripts that should run once use variable 0x5001, and change it as it goes.

BTW: I would keep 0x230 as the choice flag, since it was built into the game, it is NOT subject to any glitches, and if you need to, change the Pokemart dudes script to have like 0x900, one of the new ones. This isn't necessary but it is bulletproof.

Also, my friend, keep a list of your variables, both for your own reference, and to tell what you have already used. Trust me this helps alot.

Good luck, and PM with any questions.
__________________

Just dance with me!!!!!!!

Reply With Quote
  #11   Link to this post, but load the entire thread.  
Old June 8th, 2016 (11:07 AM).
0's Avatar
0 0 is offline
Happy and at peace. :)
 
Join Date: May 2016
Location: Pallet Town
Gender: Male
Nature: Calm
Posts: 556
To answer your edited question.

Level script snippet:
Spoiler:

#dynamic 0xYOUROFFSET

#org @arewegoodorbad
checkflag 0x230 ' This will check our side.
if 0x1 goto @removepolice ' If we are evil, we will remove the police.
goto @removerockets ' If we are good, we will remove the rockets.

#org @removerockets
setflag 0xC01 ' This will remove the Rockets from the map. You add this to the rockets Person ID.
end

#org @removepolice
setflag 0xC02 ' This will remove the Police from the map. You add this to the police Person ID.
end


Use the tutorial here to correctly insert the level script. It's fairly simply, just read it slowly and carefully:
http://www.pokecommunity.com/showpost.php?p=4414826

Here is an image album to a few images explaining where to put things:
https://imgur.com/a/0d6Zs

As you can see, I used the variable 0x4012 and 0x0000 for the level script. Change this to your alwayszero variable, which above, I suggested 0x5000.

This means that when the variable 0x5000 = 0, we will run the level script. Running the level script sets flags depending on our choice.

For that level script, when 0x230 = 1, we set the map so it has people from the evil side on the map. When 0x230 = 0, those people will not appear and people from the good side will appear.This is one example of what can be done with our level script. Changing the people shown on the map to the player.

To give you a better example tell me what you would like to do, and I will try to engineer a script to suite that idea.
__________________

Just dance with me!!!!!!!

Reply With Quote
  #12   Link to this post, but load the entire thread.  
Old June 8th, 2016 (11:08 AM).
Hajima's Avatar
Hajima Hajima is offline
Manga Artist 101
 
Join Date: May 2016
Gender: Male
Nature: Calm
Posts: 111
Thanks! This thread is done then. :)
__________________
Check out my Rom Hack! ;)
Pokemon Conjure : http://www.pokecommunity.com/showthread.php?p=9255336#post9255336
Reply With Quote
  #13   Link to this post, but load the entire thread.  
Old June 8th, 2016 (11:22 AM).
0's Avatar
0 0 is offline
Happy and at peace. :)
 
Join Date: May 2016
Location: Pallet Town
Gender: Male
Nature: Calm
Posts: 556
Perfect, glad I could help. PM me if you have more questions.
__________________

Just dance with me!!!!!!!

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:08 AM.