Releases: WarlockD/GMdsam
Added some hacking features and an output
Some new features, some hacking features for Undertale! Use at your own risk, I do not modify the original data.win, but you cannot blame me if you copy over the old one:P
Anyway to use:
Underdecomp data.win [options] [-search] [chunktype|search_term]
Options
- -png to extract all the sprites and backgrounds into individual files
- -mask extracts the calculated mask that is stored in the sprites if it exists.
- -constOffsets will add a comment to all assignments that have a simple constant left value. The offset is to the data.win's start so you can use this to mod the data.win.
- -oneFile combines all the xml/json data into one mega file. EXPERIMENTAL
- -search will find code/sprites/rooms/etc that have text containing in [search_term] and output it to the directory the exe is at
- -changeInt offset value : will change a 4 byte int at offset to value and save it to changed_data.win
- -changeShort offset value : will change a 2 byte int at offset to value and save it to changed_data.win
- -changeVar [script|code name] var_name old_value new_value : will decompile the script, find all references to var_name equal to old_value and change it to new_value
- -printOffset offset : will display the data at the offset
- chunktype can be blank for eveything or one of these:
objects, backgrounds, code, sprites, fonts, scripts, rooms, sounds, paths, eveything - -output dir : redirects output to dir
For example, if you want all the sprites and the pngs from them, type:
Underdecomp data.win -png sprites
This will create a changed_data.win file with debug on
Underdecomp data.win -changeVar SCR_GAMESTART debug 0 1
It will extract everything to the folder where the exe is at.
Fixed PNG file sizes
Looks like the png files for textures were WAY to big. Fixed it as I had the wrong offset calculation again.
Anyway to use:
Underdecomp data.win [-png] [-mask] [-constOffsets] [-oneFile] [-search] [chunktype|search_term]
- -png to extract all the sprites and backgrounds into individual files
- -mask extracts the calculated mask that is stored in the sprites if it exists.
- -constOffsets will add a comment to all assignments that have a simple constant left value. The offset is to the data.win's start so you can use this to mod the data.win.
- -oneFile combines all the xml/json data into one mega file. EXPERIMENTAL
- chunktype can be blank for eveything or one of these:
objects, backgrounds, code, sprites, fonts, scripts, rooms, sounds, paths, eveything - -search will find code/sprites/rooms/etc that have text containing in [search_term] and output it to the directory the exe is at
For example, if you want all the sprites and the pngs from them, type:
Underdecomp data.win -png sprites
It will extract everything to the folder where the exe is at.
Fixed constOffsets to give the proper offset.
Fixed constOffsets to give the proper offset. Also added a fatal drop in the tasks when it hits an exception. I try to print out all the data on it for better debugging.
Anyway to use:
Underdecomp data.win [-png] [-mask] [-constOffsets] [-oneFile] [-search] [chunktype|search_term]
- -png to extract all the sprites and backgrounds into individual files
- -mask extracts the calculated mask that is stored in the sprites if it exists.
- -constOffsets will add a comment to all assignments that have a simple constant left value. The offset is to the data.win's start so you can use this to mod the data.win.
- -oneFile combines all the xml/json data into one mega file. EXPERIMENTAL
- chunktype can be blank for eveything or one of these:
objects, backgrounds, code, sprites, fonts, scripts, rooms, sounds, paths, eveything - -search will find code/sprites/rooms/etc that have text containing in [search_term] and output it to the directory the exe is at
For example, if you want all the sprites and the pngs from them, type:
Underdecomp data.win -png sprites
It will extract everything to the folder where the exe is at.
Fixed constOffsets and a few more bugs
Fixed constOffsets to display the offsets for ALL constan'ts, not just the ones for assigned. A few bug fixes for assigns as well
Anyway to use:
Underdecomp data.win [-png] [-mask] [-constOffsets] [-search] [chunktype|search_term]
-
-png to extract all the sprites and backgrounds into individual files
-
-mask extracts the calculated mask that is stored in the sprites if it exists.
-
-constOffsets will add a comment to all assignments that have a simple constant left value. The offset is to the data.win's start so you can use this to mod the data.win.
-
chunktype can be blank for eveything or one of these:
objects, backgrounds, code, sprites, fonts, scripts, rooms, sounds, paths, eveything -
-search will find code/sprites/rooms/etc that have text containing in [search_term] and output it to the directory the exe is at
For example, if you want all the sprites and the pngs from them, type:Underdecomp data.win -png sprites
It will extract everything to the folder where the exe is at.
Refactored for a Type system, added repeat statement
This release will extract all the resources from Undertale v1.001 (The new version) AND de-compile it. Directory's will be created for all the files and you an search. It will save the extra data (Sprite information, etc) as xml files and all the code as js files. Its not REALLY JavaScript, just name it that way so my text-editor highlights everything.
Anyway to use:
Underdecomp data.win [-png] [-mask] [-constOffsets] [chunktype]
-png to extract all the sprites and backgrounds into individual files
-mask extracts the calculated mask that is stored in the sprites if it exists.
-constOffsets will add a comment to all assignments that have a simple constant left value. The offset is to the data.win's start so you can use this to mod the data.win.
chunktype can be blank for eveything or one of these
objects, backgrounds, code, sprites, fonts, scripts, rooms, sounds, paths, eveything
Forexample, if you want all the sprites and the pngs from them, type:
Underdecomp data.win -png sprites
It will extract everything to the folder where the exe is at.
Added constOffsets feature
This release will extract all the resources from Undertale v1.001 (The new version) AND de-compile it. Directory's will be created for all the files and you an search. It will save the extra data (Sprite information, etc) as xml files and all the code as js files. Its not REALLY JavaScript, just name it that way so my text-editor highlights everything.
Anyway to use:
Underdecomp data.win [-png] [-mask] [-constOffsets] -all
-png to extract all the sprites and backgrounds into individual files
-mask extracts the calculated mask that is stored in the sprites if it exists.
-constOffsets will add a comment to all assignments that have a simple constant left value. The offset is to the data.win's start so you can use this to mod the data.win.
Thats it, type that in and it should extract everything to whatever folder Underdecomp is put into. Good luck!
More bug fixes
This release will extract all the resources from Undertale v1.001 (The new version) AND de-compile it. Directory's will be created for all the files and you an search. It will save the extra data (Sprite information, etc) as xml files and all the code as js files. Its not REALLY JavaScript, just name it that way so my text-editor highlights everything.
Anyway to use:
Underdecomp data.win [-png] [-mask] -all
Use -png to extract all the sprites and backgrounds into individual files and -mask extracts the calculated mask that is stored in the sprites if it exists.
Thats it, type that in and it should extract everything to whatever folder Underdecomp is put into. Good luck!
Done as its ever going to be
So many changes. I wanted to clean it up and finish this off. Eveything you need works, I just am worn out on this project and before I give it up for dead, I might as well make a release.
This release will extract all the resources from Undertale v1.001 (The new version) AND de-compile it. Directory's will be created for all the files and you an search. It will save the extra data (Sprite information, etc) as xml files and all the code as js files. Its not REALLY JavaScript, just name it that way so my text-editor highlights everything.
Anyway to use:
Underdecomp data.win [-png] [-mask] -all
Use -png to extract all the sprites and backgrounds into individual files and -mask extracts the calculated mask that is stored in the sprites if it exists.
Thats it, type that in and it should extract everything to whatever folder Underdecomp is put into. Good luck!
PS - Ok, fixed some empty xml file bugs and code bugs
LuaObject Version
I rewrote and cleaned up a a bunch of unused code for it. It works right now.
Run with:
Underdecomp "data.win" -all scripts
Underdecomp "data.win" -all objects
This will make two directory's with a bunch of lua scripts in them. It will also output errors on witch scripts have issues.
Kind of need to know how game maker with statements work and how lua works but the the code should be a little self explanatory.
It also outputs two lua files that decode the glyph's for the fonts and the sprite frames.
This might be the final release. Everything seems to be working and its good enough to get started on figuring out the boss fights.
First and probably last Release
Underdecomp!
There are a few bugs, bug right now it can de-compile Undertale 1.0 (not 1.01 as that uses a different byte-code).
underdecomp data.win -all objects
- It will extract all the object code into separate directory's
underdecomp data.win -all scripts
- This will extract all the user scripts into the scripts directory
underdecomp data.win -s search_term
- This will extract all objects and script code that has the term in it
Options:
- -asm will also extract the raw dissasembled byte code
- -debug will turn on a few debugging functions not used by the release