• 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.

Development: The Follow Me Script

GoGoJJTech

(☞゚ヮ゚)☞ http://GoGoJJTech.com ☜(゚ヮ゚☜)
2,475
Posts
11
Years
Im working on emerald and also would like know if is possible to do it on emerald.
If you could give the script would be great.

Look guys, it's not a script, there are no scripts, it's all 100% asm.
 

Yvtq8K3n

muhaha
91
Posts
9
Years
Look guys, it's not a script, there are no scripts, it's all 100% asm.
I know is ASM but you could send the code plz. I know c, c++ and other languages, so i woulnd't have a lot of problems to get it. Thx, im also learning ASM.(sorry for the bad english)
 

Joexv

ManMadeOfGouda joexv.github.io
1,037
Posts
11
Years
OK so I was playing with it and in the config it says set the follwers local id to fe. Does that mean the person id? Cause I cant seem to get it to work.Actually it just wont insert for me. Ill do it manually.
 
Last edited:

Touched

Resident ASMAGICIAN
625
Posts
9
Years
  • Age 122
  • Seen Feb 1, 2018
This is able to port that to Pokemon Ruby?

lolno.

Thx man. Lets see if i can upgrade the script:D

I'm actually working on a port to Emerald myself.

OK so I was playing with it and in the config it says set the follwers local id to fe. Does that mean the person id? Cause I cant seem to get it to work.Actually it just wont insert for me. Ill do it manually.

It only adds an extra ID (0xFE) for applymovement. The default person ID will work fine, but I thought it might be nice to have an easy way of accessing the follower through scripts, so I added that.
The insertion script should work fine, as long as you're running it with Python 3 (not 2!) and have DevkitARM installed (with the binaries in your path). If you have all of that, there shouldn't be any problems. Inserting manually is a bit difficult if you don't know how to hook. Besides, I made the script in the first place because inserting manually is a pain.
 

Joexv

ManMadeOfGouda joexv.github.io
1,037
Posts
11
Years
It only adds an extra ID (0xFE) for applymovement. The default person ID will work fine, but I thought it might be nice to have an easy way of accessing the follower through scripts, so I added that.
The insertion script should work fine, as long as you're running it with Python 3 (not 2!) and have DevkitARM installed (with the binaries in your path). If you have all of that, there shouldn't be any problems. Inserting manually is a bit difficult if you don't know how to hook. Besides, I made the script in the first place because inserting manually is a pain.

Ah It may be because I dont have the devkit. Ok trying again

Edit: OK this is gonna sound really stupid, but im new to python. But just putting the binaries in the same folder does not work, how do I set the path so it finds them?
 
Last edited:

Touched

Resident ASMAGICIAN
625
Posts
9
Years
  • Age 122
  • Seen Feb 1, 2018
Ah It may be because I dont have the devkit. Ok trying again

Edit: OK this is gonna sound really stupid, but im new to python. But just putting the binaries in the same folder does not work, how do I set the path so it finds them?

You need to put it in the system path, not the Python path. I'm assuming you're a Windows user: Open a command prompt and type "path" to see what directories are in your path. If you used the installer it should automatically have added the devkitARM bin folder to your path. Check this is the case by typing 'arm-none-eabi-as --version' and seeing it gives valid output. If you get an error you'll need to add the devkitARM directory (C:\devkitARM\bin or something) to your path. Not really sure how to permanently set the windows path, so just Google.
 

Joexv

ManMadeOfGouda joexv.github.io
1,037
Posts
11
Years
You need to put it in the system path, not the Python path. I'm assuming you're a Windows user: Open a command prompt and type "path" to see what directories are in your path. If you used the installer it should automatically have added the devkitARM bin folder to your path. Check this is the case by typing 'arm-none-eabi-as --version' and seeing it gives valid output. If you get an error you'll need to add the devkitARM directory (C:\devkitARM\bin or something) to your path. Not really sure how to permanently set the windows path, so just Google.

Oh ok yea I know how to do that. I guess I was overcomplicating things. OK well I'll get to fixin that. And the installer kinda added the path, it added the wrong one.

Edit: Ok so after many tries, I got the path installed, but that didnt help still getting file not found error, I kinda fixed that by adding
Code:
import os.path 

scriptpath = os.path.dirname(__file__)
filename = os.path.join(scriptpath, 'BPRE0.gba')
testFile=open(filename)
print(testFile.read())
to this but it couldnt figure out the decoding so adding
encoding.'utf8' kinda worked but it couldnt figure out what 0x32 was or something like that, so still having issues. I feel like somethings off with my laptop.:| I feel like its the subprocess or the sys importing that causes the issue, cause it never lists what file it cant open and it never gets past that part of the script.

Error log:
Spoiler:
 
Last edited:

Touched

Resident ASMAGICIAN
625
Posts
9
Years
  • Age 122
  • Seen Feb 1, 2018
Oh ok yea I know how to do that. I guess I was overcomplicating things. OK well I'll get to fixin that. And the installer kinda added the path, it added the wrong one.

Edit: Ok so after many tries, I got the path installed, but that didnt help still getting file not found error, I kinda fixed that by adding
Code:
import os.path 

scriptpath = os.path.dirname(__file__)
filename = os.path.join(scriptpath, 'BPRE0.gba')
testFile=open(filename)
print(testFile.read())
to this but it couldnt figure out the decoding so adding
encoding.'utf8' kinda worked but it couldnt figure out what 0x32 was or something like that, so still having issues. I feel like somethings off with my laptop.:| I feel like its the subprocess or the sys importing that causes the issue, cause it never lists what file it cant open and it never gets past that part of the script.

Error log:
Spoiler:

Yeah, this seems to be a Windows issue. Someone had the same issue on the IRC yesterday and we fixed it by copying HackMew's assembler binaries (as.exe and objcopy.exe) into the same directory as the script and changing the AS and OBJCOPY variables in the Python script to match (AS = 'as.exe' and OBJCOPY = 'objcopy.exe'). I have absolutely no idea why it can't find your binaries if they are in your path. I'll probably be changing the script in the near feature to be more user-friendly as this issue seems to come up for everybody.
 

Joexv

ManMadeOfGouda joexv.github.io
1,037
Posts
11
Years
Yeah, this seems to be a Windows issue. Someone had the same issue on the IRC yesterday and we fixed it by copying HackMew's assembler binaries (as.exe and objcopy.exe) into the same directory as the script and changing the AS and OBJCOPY variables in the Python script to match (AS = 'as.exe' and OBJCOPY = 'objcopy.exe'). I have absolutely no idea why it can't find your binaries if they are in your path. I'll probably be changing the script in the near feature to be more user-friendly as this issue seems to come up for everybody.

Well windows blows so its its own fault. Ill just boot linux, or try out that fix.

Edit: that worked thanks so much for the help!
 
Last edited:
200
Posts
10
Years
  • Age 30
  • Seen Jun 19, 2022
Windows seems to realllyyy hate this. I tried your solution for making it on windows with python and it seemed to work; compiled and all, but, when I tried the rom itself it spawned a fat/chubby man sprite on every map and crashed when you moved around.

Edit: Nevermind this... normal warp behavior. Imma dork. :P
 
Last edited:

daniilS

busy trying to do stuff not done yet
409
Posts
10
Years
  • Age 24
  • Seen Jan 29, 2024
Windows seems to realllyyy hate this. I tried your solution for making it on windows with python and it seemed to work; compiled and all, but, when I tried the rom itself it spawned a fat/chubby man sprite on every map and crashed when you moved around.

That's normal behaviour. :p just put a hashtag before hook('warp.s'..... and it should work.
 

Blah

Free supporter
1,924
Posts
11
Years
My idea is using appearing a pokepic that's is an overworld of a pokemon,but now you will say nicksid14 pokepics have a frame!But no anymore!Because of gogojjtech and his knowledge about asm.We can make the pokepic frame disappear by overwriting 0809d3a0 routine with changing it to 00 00 00 00.Gogojjtech said it NOT ME.So i give him a lot of thanks.

The next think is making a script that checks where the player is facing and showing ex. a pikachu overworld,then the script will have closeonkeypress and then checking again where the player is facing,after that will hide the pokepic and will appear another to another section of the screen,that will be based on the playerfacing.Here is how the script will be:


This is my idea and my script
Don't fear to say your opinion and post!
The script isn't done yet,it needs some work......
If you think that it will not work then post,say the reason why,and your own idea!
If the script is working and you want to use it then USE IT,but give credits to nicksid14 and gogojjtech.

The current follow me already solved the following sprite problem. Also your solution is a little lackluster in the sense that the Pokepic is a static image. Formatting it and making it animate at certain points will become a much harder problem than the actual follow me itself.
Not to mention a scripting solution would be rather slow in comparison to the normal ASM solution and making a script run in a loop would freeze the game :)
 
Last edited:

Touched

Resident ASMAGICIAN
625
Posts
9
Years
  • Age 122
  • Seen Feb 1, 2018
My idea is using appearing a pokepic that's is an overworld of a pokemon,but now you will say nicksid14 pokepics have a frame!But no anymore!Because of gogojjtech and his knowledge about asm.We can make the pokepic frame disappear by overwriting 0809d3a0 routine with changing it to 00 00 00 00.Gogojjtech said it NOT ME.So i give him a lot of thanks.

The next think is making a script that checks where the player is facing and showing ex. a pikachu overworld,then the script will have closeonkeypress and then checking again where the player is facing,after that will hide the pokepic and will appear another to another section of the screen,that will be based on the playerfacing.Here is how the script will be:

#dyn 0x740000
#org @start
compare playerfacing up
if == jump @appeardown
compare playerfacing down
if == jump @appearup
compare playerfacing right
if == jump @appearleft
compare playerfacing left
if == jump @appearright
end

#org @appeardown
showpokepic 0x1fe 0x(x) 0x(y)
closeonkeypress
hidepokepic
jump @again

#org @appearup
showpokepic 0x1fe 0x(x) 0x(y)
closeonkeypress
hidepokepic
jump @again

#org @appearright
showpokepic 0x1fe 0x(x) 0x(y)
closeonkeypress
hidepokepic
jump @again

#org @appearleft
showpokepic 0x1fe 0x(x) 0x(y)
closeonkeypress
hidepokepic
jump @again

#org @again
compare playerfacing up
if == jump @appeardown
compare playerfacing down
if == jump @appearup
compare playerfacing right
if == jump @appearleft
compare playerfacing left
if == jump @appearright
end


This is my idea and my script
Don't fear to say your opinion and post!
The script isn't done yet,it needs some work......
If you think that it will not work then post,say the reason why,and your own idea!
If the script is working and you want to use it then USE IT,but give credits to nicksid14 and gogojjtech.

We thank you for your contribution to the realm of Follow Me. Hackers will surely use this wonderful idea that does 0.000001% of what follow me actually does. The lack of an actual pokemon following you is wonderful indeed.
 

GoGoJJTech

(☞゚ヮ゚)☞ http://GoGoJJTech.com ☜(゚ヮ゚☜)
2,475
Posts
11
Years
My idea is using appearing a pokepic that's is an overworld of a pokemon,but now you will say nicksid14 pokepics have a frame!But no anymore!Because of gogojjtech and his knowledge about asm.We can make the pokepic frame disappear by overwriting 0809d3a0 routine with changing it to 00 00 00 00.Gogojjtech said it NOT ME.So i give him a lot of thanks.

The next think is making a script that checks where the player is facing and showing ex. a pikachu overworld,then the script will have closeonkeypress and then checking again where the player is facing,after that will hide the pokepic and will appear another to another section of the screen,that will be based on the playerfacing.Here is how the script will be:

#dyn 0x740000
#org @start
compare playerfacing up
if == jump @appeardown
compare playerfacing down
if == jump @appearup
compare playerfacing right
if == jump @appearleft
compare playerfacing left
if == jump @appearright
end

#org @appeardown
showpokepic 0x1fe 0x(x) 0x(y)
closeonkeypress
hidepokepic
jump @again

#org @appearup
showpokepic 0x1fe 0x(x) 0x(y)
closeonkeypress
hidepokepic
jump @again

#org @appearright
showpokepic 0x1fe 0x(x) 0x(y)
closeonkeypress
hidepokepic
jump @again

#org @appearleft
showpokepic 0x1fe 0x(x) 0x(y)
closeonkeypress
hidepokepic
jump @again

#org @again
compare playerfacing up
if == jump @appeardown
compare playerfacing down
if == jump @appearup
compare playerfacing right
if == jump @appearleft
compare playerfacing left
if == jump @appearright
end


This is my idea and my script
Don't fear to say your opinion and post!
The script isn't done yet,it needs some work......
If you think that it will not work then post,say the reason why,and your own idea!
If the script is working and you want to use it then USE IT,but give credits to nicksid14 and gogojjtech.

https://m.youtube.com/watch?list=UUOf_Pc6rtBhhcqhczkib7JQ&v=boRbK37qP5o

Follow me has been done, and it's not a script at all. Most things like this are not to be done with scripts anyway.
 

Dionen

deprived of sleep
295
Posts
12
Years
Why this attitude towards the guy's script?
He's just trying to help. Stop acting as "I'm superior because I know asm" because that is nothing but disgusting.
The pokepic idea is extremely creative. Extremely. It may not be pratical, but I doubt that someone would ever think of something like that.
 

Shiny Quagsire

I'm Still Alive, Elsewhere
697
Posts
14
Years
Why this attitude towards the guy's script?
He's just trying to help. Stop acting as "I'm superior because I know asm" because that is nothing but disgusting.
The pokepic idea is extremely creative. Extremely. It may not be pratical, but I doubt that someone would ever think of something like that.

Scripts are great, and there are a lot of things best done with scripts. A lot of people have already tried doing this with scripts, and the results were the same every time: sluggish, slow, and not very good. And depending on how it's done, it would take a lot of work map-wise just to get it usable (walk scripts and the like). He wasn't trying to state superiority really, but he was just saying that while it *might* be possible to do it in a script, it's already been done in ASM and currently the best implementation will probably remain in ASM.

The main problem I see with the script (and it's also the main problem with a lot of the static-following-pokemon overworlds) is that checking where the player is facing isn't the best idea (not to mention the script would need to run every time the player moves, which is also not a good idea). Following Pokemon "echo" the last action of the player. If you moved left and then moved right, you and your pokemon should face opposite directions. This is why you can't just make a 32x32 overworld and slap a Pikachu behind the player; it looks extremely awkward and weird. And since we can't check what the player's last action was via script, it would still need ASM even if we did most of the core code in script anyhow.
 
6,355
Posts
18
Years
  • Seen Apr 16, 2020
While I do agree that NICKSID14's script doesn't really help at all with the follow me, there is no need for unnecessary comments on it.

There's nothing wrong with posts explaining why such a script won't work for a proper follow me, but rude or sarcastic posts are not tolerated in the forums and any further such comments in this thread will be deleted, and infractions will be handed out if necessary.
 

jAvAcOlA

Banned
152
Posts
15
Years
  • Seen Feb 22, 2015
So how far are we from getting this into what it needs to be for a Yellow remake? Gogo said he hasn't figured out ledges and warps. How big of a problem will that be?
 
Back
Top