Go Back   The PokéCommunity Forums > ROM Hacking > Tools, Tutorials & Resources

Notices
For all updates, view the main page.

Tools, Tutorials & Resources Various tools to help you develop your hacks can be found here.
New threads in this forum are to be approved by a moderator before they are displayed.



Reply
Click here to go to the first staff post in this thread.  
Thread Tools
  #1    
Old December 9th, 2013 (01:11 PM). Edited December 14th, 2014 by karatekid552.
karatekid552's Avatar
karatekid552
What happens if I push it?....
 
Join Date: Nov 2012
Location: Do you really want to know? Really?
Gender: Male
Nature: Bold
Send a message via AIM to karatekid552 Send a message via Windows Live Messenger to karatekid552 Send a message via Skype™ to karatekid552

THUMB Editor & Assembler



So, I have always wanted to have a front end for HackMew's compiler since writing it up in notepad, opening up the command prompt, compiling the binary, and then dumping the contents into a rom honestly was just a little annoying, especially since I screw my code up so much and have to recompile far too many times. haha Either way, I finally got around to it. What this program is, is it is a very basic IDE for THUMB code that supports direct compiling to the rom, as well as a few other features:

~Simple syntax highlighting
~Test Compile
~Output to Binary
~Customize all editor colors
~.org dependent rom compiling
~Quick comment insertion

Syntax highlighting:
So, with this part, I really just wanted to improve the readability of code with a little bit of color. So, I added three types of highlighting: comments, large numbers, and labels.

-Comments are anything between "/*" and "*/" and get highest prioity over the other highlighting, meaning if you comment out code, it won't get the other highlighting (like a normal text editor).

-Labels are the heading for each section of your code, so in this piece:

Code:
Main:    ldr r5, .new_bg_table
        push {r5}
        push {r1}
        bl varloader
Main (and varloader) are considered labels. I honestly don't know what the real term for them is, but that is what I call them, otherwise they would just be "things ending in colons". These have the lowest priority.

-Large Numbers are like labels, but they serve to define static numbers that are larger than one byte. Most of the time, they look like this:

Code:
.new_bg_table:    .word    0x08F10000
As you can see, they have the same format as labels. So, I made it simple: if you start it with a period, it will get large number highlighting, and if you don't, it will get label highlighting. Now, I know I could have run a search to see if the next charactors were .word/.hword but I did it this way, so don't yell at me. (If you want it changed, by all means do so, the source code is right there will the download, haha)


Test Compile:
This option will basically compile your ASM into a binary and either return the errors or an "Assembled Successfully" message. Good for a quick test to make sure your code compiles. All temp files *should* get deleted once it is done.


Output to Binary:
This option works just like HackMew's batch file, the only difference being a "save as" dialog vs command line.


Customize all editor colors:
I really hope this doesn't need an explanation.......


.org dependent rom compiling:
This was a fun feature to implement. If your ASM has a .org, use this option, as it will jump ahead in your output file to that offset and start working from there. Without this, if you were to compile to the rom, you would get at ton of 00's inserted instead of your code. Currently, it doesn't search for the .org, you provide it, but I would like to automate that in the future.


Quick Comment Insertion:
Typing "/* */" can be cumbersome if you are moving quickly, so I just added a new feature: hit "ctrl+q" to quickly add a new comment. PLEASE comment your code. It helps so much.



---
I have been working on this for a while, and I released it on PHO on Nov. 16, but it wasn't the program I wanted it to be then. It had a lot of issues like: no normal saving, compiling required a console window open, the "open file" window didn't save where you were, etc. However, all of the big usage issues have been fixed and it is much more user friendly. So, now I'm finally releasing here on PC.

This program is in no way a response to ~Andrea's compiler. We took separate routes on this one and I urge anyone to try both and see which one you like best. Here is a link to that thread: http://www.pokecommunity.com/showthread.php?t=314358

This program is written in Python and therefore doesn't need the .net framework which allows it to run very well under wine if you are on Linux. (Main reason I use Python, haha.) The only reason it requires wine is because it runs the as.exe and objcopy.exe that HackMew's batch file used (hence, it being a "front-end gui") which only run under a Windows environment.

The future:


What I need to do:
-On close, it will NOT prompt you to save. I really need to add that in, but I haven't gotten to it yet.
-There is only a "save as" function, no regular just "save". Not a necessity, but it would be nice.
-Automated .org finding.
-Force pop-ups to stay in the foreground.
-Undo/Redo suck. No other way to put it. The Tkinter undo module is awful and I need to find a better way to do it.

What I might do:
-Customizable syntax highlighting so you can define your own highlights.
-More options like word wrap, disable syntax highlighting (you could just change all of the colors to match the foreground, but yeah...), and font changes.

Bugs:


None yet.:D

Screenshots:


Spoiler:







Disclaimer:


Please, always back up your roms. This program has been tested, but not extensively and something could go wrong. I am not responsible for a destroyed hack.

Download:


*Please note that this is my first ever GUI program, so the code is very messy and a little inefficient.




~karatekid552
__________________

Paired with Simba
Reply With Quote
  #2    
Old December 11th, 2013 (02:39 AM).
xGal's Avatar
xGal
Playing some ESL
 
Join Date: Nov 2011
Location: A tree
Gender: Male
Nature: Bold
Nice one, Roger! BTW I think a hex-dec calculator, like there's in XSE would be great. If there is, I probably missed it :p
__________________
Hey guys, I made a soundcloud account not long ago, and I would be very happy if you guys will check it out: https://soundcloud.com/dewombat. Thanks .

Also, if you ever wanted to make a ROM hacking tool, click here: http://www.pokecommunity.com/showthread.php?t=334348
Reply With Quote
  #3    
Old December 11th, 2013 (03:48 AM).
karatekid552's Avatar
karatekid552
What happens if I push it?....
 
Join Date: Nov 2012
Location: Do you really want to know? Really?
Gender: Male
Nature: Bold
Send a message via AIM to karatekid552 Send a message via Windows Live Messenger to karatekid552 Send a message via Skype™ to karatekid552
Quote originally posted by xGal:
Nice one, Roger! BTW I think a hex-dec calculator, like there's in XSE would be great. If there is, I probably missed it :p
That is a good feature! I will add it.
__________________

Paired with Simba
Reply With Quote
  #4    
Old December 13th, 2013 (02:33 PM).
FBI agent's Avatar
FBI agent
Ally to good, nightmare to you!
 
Join Date: Jan 2013
Location: Unknown Island
Gender: Male
Congratulations on the release of a great tool! Lazy people like myself really appreciate the hard working people like yourself :P

While realizing the only purpose of this tool is to compile ASM code, I do have some suggestions that may help ease the process for the user.
The first one is to include a formatter. I'm not sure if you've seen one before, but generally good program tools have a format option that formats your code to be readable (note this doesn't fix bugged code). The second is to highlight errors and give error messages(the messages are a nice bonus, but jsut highlighting is great in and of itself).

I could help you with the formatter, but the error messages you're gonna have to do yourself :P
__________________
...

My name forum name is FBI Agent, though you can call me FBI because it's shorter. I ran an ASM request/resource thread feel free to check that out!
Reply With Quote
  #5    
Old December 13th, 2013 (03:24 PM).
karatekid552's Avatar
karatekid552
What happens if I push it?....
 
Join Date: Nov 2012
Location: Do you really want to know? Really?
Gender: Male
Nature: Bold
Send a message via AIM to karatekid552 Send a message via Windows Live Messenger to karatekid552 Send a message via Skype™ to karatekid552
Quote originally posted by FBI agent:
Congratulations on the release of a great tool! Lazy people like myself really appreciate the hard working people like yourself

While realizing the only purpose of this tool is to compile ASM code, I do have some suggestions that may help ease the process for the user.
The first one is to include a formatter. I'm not sure if you've seen one before, but generally good program tools have a format option that formats your code to be readable (note this doesn't fix bugged code). The second is to highlight errors and give error messages(the messages are a nice bonus, but jsut highlighting is great in and of itself).

I could help you with the formatter, but the error messages you're gonna have to do yourself
Thanks man.

Personally, the formatter would HAVE to be customize able, since everyone has a different format to their ASM that they like. However, things like auto-indent and such would be easy options and a nice touch.

The program already returns error messages from a compile, but checking for them as you type would be cool. However, the way I have been doing the syntax highlighting (searching for patterns using the built in search function and regular expressions) won't work, as I am beginning to notice a lag if I add another search area.
__________________

Paired with Simba
Reply With Quote
  #6    
Old December 13th, 2013 (05:51 PM).
karatekid552's Avatar
karatekid552
What happens if I push it?....
 
Join Date: Nov 2012
Location: Do you really want to know? Really?
Gender: Male
Nature: Bold
Send a message via AIM to karatekid552 Send a message via Windows Live Messenger to karatekid552 Send a message via Skype™ to karatekid552
Just updated! xGal, I added your base converter. (May eventually add a full programmers calculator if I feel like it.) I also fixed a couple of saving bugs. (Nothing that would corrupt your save or anything, just annoying things about saving prompts.)
__________________

Paired with Simba
Reply With Quote
  #7    
Old December 13th, 2013 (06:46 PM).
MrDollSteak's Avatar
MrDollSteak
Formerly known as 11bayerf1
 
Join Date: Dec 2008
Location: Hong Kong
Age: 19
Gender: Male
As I've said before, seriously love this tool, it's really good.
I figured a glowing testimony here wouldn't do any harm :p
__________________
Reply With Quote
  #8    
Old November 28th, 2014 (06:23 PM).
AkimotoBubble
 
Join Date: Aug 2014
Gender: Male
it is so good,and why nobody development to the android' tool...
__________________
i am bubble,and sorry my english is not good ......
Reply With Quote
  #9    
Old November 30th, 2014 (11:56 PM).
Lance32497's Avatar
Lance32497
LanceKoijer of Pokemon_Addicts
 
Join Date: Aug 2014
Location: Criscanto town-Ginoa Region xD
Gender: Male
Nature: Adamant
The download link is broken
__________________
My Threads

Reply With Quote
  #10    
Old December 14th, 2014 (06:56 PM).
Kakarot1212's Avatar
Kakarot1212
Awesome as always...
 
Join Date: Oct 2013
Location: Phillipines
Age: 17
Gender: Male
Nature: Naughty
Can someone upload the tool on MF or DB? The download link is broken :3
__________________

楓 弘詩
“ Programs must be written for people
to read, and only incidentally for
machines to execute. ”
Pair Pair | Facebook | Showdown | PHO | Twitter
| Text Hex Convert v2.1.0|
Reply With Quote
  #11    
Old December 14th, 2014 (10:23 PM).
karatekid552's Avatar
karatekid552
What happens if I push it?....
 
Join Date: Nov 2012
Location: Do you really want to know? Really?
Gender: Male
Nature: Bold
Send a message via AIM to karatekid552 Send a message via Windows Live Messenger to karatekid552 Send a message via Skype™ to karatekid552
Download should be working again. I must have forgotten to remove the ad links when I was purging them from my other stuff. Sorry for any inconvenience. They now link directly to GitHub. If this is an issue, someone please email [email protected] as I am not very active anymore due to a crazy life.

Remember, this was my first program I ever wrote so it can have issues. Back up your roms!
__________________

Paired with Simba
Reply With Quote
  #12    
Old December 15th, 2014 (04:25 PM).
Lance32497's Avatar
Lance32497
LanceKoijer of Pokemon_Addicts
 
Join Date: Aug 2014
Location: Criscanto town-Ginoa Region xD
Gender: Male
Nature: Adamant
Quote originally posted by karatekid552:
Download should be working again. I must have forgotten to remove the ad links when I was purging them from my other stuff. Sorry for any inconvenience. They now link directly to GitHub. If this is an issue, someone please email [email protected] as I am not very active anymore due to a crazy life.

Remember, this was my first program I ever wrote so it can have issues. Back up your roms!
Yayks!
Thanks for this tool!
__________________
My Threads

Reply With Quote
  #13    
Old December 16th, 2014 (01:45 AM).
Percy's Avatar
Percy
Known in the past as BlazikenXY
 
Join Date: Sep 2014
Location: Somewhere in the world, obviously
Age: 18
Gender: Male
Nature: Gentle
The tool looks great! Now I can use this instead of Notepad, and HackMew's compiler.
__________________
Credits to Ilona-the-Sinister for my avatar.

Hey, folks! I don't know what to put here, so I better just advertise.
Can you give me a hand with my hack? Just PM me.

Oh, yeah, I don't need any mappers, now, 'cause I already have 2, and now I need Music Composer, and spriting. And, if you're friendly enough, VM me, and we can chat!
Reply With Quote
Reply
Quick Reply

Sponsored Links
Thread Tools

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
Minimum Characters Per Post: 25



All times are UTC -8. The time now is 04:21 AM.