Wednesday 25 December 2013



mod apk
EVERYWHEREANDROID.BLOGSPOT.COM
how to edit/mod games

STEP A


1) You will need an APK (One you know a lot of, to learn with this tutorial)
- We will call the APK "tetris.apk" to make the tutorial easier to understand.




2) Download APK Manager
- Make a copy of the tetris.apk , and paste in APK manager folder "place here for modding"
Downloads | APK Multi-Tool

3) Open APK manager
[Image: ss2.png]

- Now hit the following keys:
22 (To set current project) (Many times you will not need this step).
9 (To Decompile the APK)
---------------------------
STEP B


1) Get Dex2Jar
Downloads - dex2jar - Tools to work with android .dex and java .class files - Google Project Hosting
- extract it.


2) Get tetris.apk , and make it a .zip
- Extract tetris.zip
- After Extracting Tetris.zip, copy the file "classes.dex" to the extracted folder of "dex2jar"


3) Drag classes.dex to the file named "dex2jar"

- A new file will have been created in that same folder.




------------------------------
STEP C


1) Download JDgui (java decompiler)
JD-GUI | Java Decompiler
- extract it


2) the new file that was just created in STEP B , 3)
- get that file and drag it to the jdgui.exe


3) It will open.
- Now you can see everything about the game / the source (But we can't do anything to it or recompile it, there is no way)
[Image: jdgui.png]


Step D


1) With the file open in jdgui.exe , browse through the files


2) Whenever you find something useful that you want to change while in the jdgui.exe application, browse in the extracted tetris.apk file in STEP A
- in the Smali folder


3) Say you find in JDgui.exe , a file named "cash1234" and it says somewhere inside "cash = 500."
go to the same file location on the Smali folder... and look file "cash1234".. and for the hex equivalent to 500 , (which would be 1F4)


on gdui.exe things are much simpler than on .smali files, but you can still change them with careful looking.


4) In gdui.exe, files you have open, have easy to understand numbers, on .smali files the number are not.
- The numbers in .smali files are in HEX.
To know which number in .smali is what number, use this tool:
Hex to decimal: Hex to Decimal Converter
Decimal to hex: Decimal to Hex Converter
OR
you can use "Calc-p" from the market.

STEP E


1) After you have modified whatever you wanted in the .smali file, save the .smali file (do not change the name or extension)
2) open APK Manager, and hit the following keys
14 (to Compile , sign, and install on your phone)


(Before installing an edited .apk, remember to uninstal the non-edited Apk that is in your phone).
( You do not need to uninstall apk(s) from your phone that you have signed with APK Manager).
------------------
STEP F


- Play have fun.


- if Step E gave you an error, you edited something wrong, or couldnt be edited.

TIPS


- IF a number on the .smali file has 2 digits, F8, and you change it to a number of more than 2 digits, 4B86, a lot of times the .apk file will not compile again.
- Every time you make 1 edit, save, and send the edited game to your phone to see if it compiles, and if it does not crash.
- mul = multiply
- sub = substract
- add = addition
- a number with a negative "-0x1" that is equal to -1 , "-0x7" that is equal to -7 , "-0x1f4" that is equal to -500
- Hex numbers do not have to be IN CAPS, can be either.

by me

0 comments:

Post a Comment