How to modify .swf from Android Flash Games

Sbenny.com is trusted by 1,312,722 happy users since 2014.
Register

Raynne

APK Fanatic Lv5️⃣
Member for 8 years



Hi Guys!

So today i will teach you how to mod .swf file for CSI Hidden Crimes for Android. The flash games was build with Adobe flash professional and the programming language is C++. You don't need to learn C++. You don't need any programming experience. you just need some basic knowledge to know on how to return a value to 999,999 or any values you want to input. For example:

Code:
public function getgreenCash() : int
{
return 999999;
}
This code means it returns green cash to 999,999 and it never change or reduce.

Install SWF Decompiler
There are many SWF decompiler softwares on the internet. if you don't know which one, just download and install the following:

JPEXS Free Flash Decompiler

Take out the .APK File from your device
Download any APK apps from Playstore that can backup installed APK file on your device. Just backup CSI Hidden Crimes APK file on your SDcard and transfer it to your computer.

I use X-plore app to copy APK file to my computer on Bluestacks.



Open .APK file using Winrar and take out the .SWF file
- Right click on the APK file, Click on "Properties".




You will see this window. Click on "Change..."



You will see the window "How do you want to open this type of file (.apk)?". Click on "More options" and click on "Look for another app on this PC"



Go to the path where Winrar is installed and click "Open". Default location is Local Disk (C :)->Program Files->Winrar.



After that, click "OK"

Open the .APK file -> Open "assets" folder and copy the "HiddenCrimesANdroidProd.swf"file to your computer



Modding .SWF file
Open the "HiddenCrimesANdroidProd.swf"file and the program will start. Note, i'm using JPEXS Free Flash Decompiler so i hope this tutorial is also useful for other SWF decompiler softwares. click on "Tools" -> "Text Search"



Search the text "get energyCount", "get coins" or "get greenCash" and click OK.



Let the program decompiling the .SWF file and it should take 15 seconds to finish decompiling (depending on your computer CPU speed). After decompile, you will see this window. Double click on "com.hiddenobject.story.vo.GameProfileVO"



Now you will see the codes. Find the functions named "energyCount", "coins" and "greenCash" and the code should look like this:

Code:
public function getgreenCash() : int
{
  returngetAllCurrencyType("GreenCash").value;
}

public function getcoins() : Number
{
returnearnedCoins + boughtCoins;
}

public functionget energyCount() : int
{
return_energyCount;
}
Click on "Edit" button below.



If you don't have PlayerGlobal library installed in your computer, you will see this message.





Click "OK" to download PlayerGlobal library from adobe website or you can download it here: DOWNLOAD PLAYERGLOBAL .swc. After you download it, put the.swc file into "C:\Users\<your name>\AppData\Roaming\JPEXS\FFDec\flashlib\"



Click on "Edit" button below again, you will see the warning message and click "OK" and now you will be able to edit the code

Change them all to return 999999; like this. DON'T ever forget the ";" at the end of "999999", otherwise the game won't work.

Code:
public function getgreenCash() : int
{
return 999999;
}
public function getcoins() : Number
{
return 999999;
}
public function get energyCount() : int
{
return 999999;
}


Saving the modded .SWF file

After you modified the code, click on "Save" button below and the code will be saved.



Now click on "File" -> "Save" and it will save modified codes in .SWF file.



Replacing the modded .SWF file inside the .APK file
Open the .APK file with Winrar, open "assets" folder and replace modded .SWF file inside.



Sign the APK file using any APK tools
Now you have to sign the .APK file using any APK tools, otherwise the APK won't install on your device.

I'm using APK-Multi-Tool to sign an .APK file



Result and Proof!
So here is the result. Energy, coins and cash are 999,999




Credits to: iAndroHackerDK
 

brox_donz

Lurker Lv0️⃣
Member for 8 years
Re: Tutorial How to modify .swf from Android Flash Games

i want try this sir.. :p
 

Kapuyuak

Veteran Lv7️⃣
Member for 8 years
Re: Tutorial How to modify .swf from Android Flash Games

this good tutor.. (y) (y) (y)
 

GtcTurbo

Apprentice Lv2️⃣
Member for 8 years
Re: Tutorial How to modify .swf from Android Flash Games

bro after save i have error
Code:
http://prntscr.com/adjjvo
 

Sbenny

A crazy scientist
Staff member
Admin
SB Mod Squad ⭐
✔ Approved Releaser
Active User
Re: Tutorial How to modify .swf from Android Flash Games

The software do not always save correctly, to overcome the issue, just modify from the right panel and not the center one.

Cheers
 

[madara]

Novice Lv1️⃣
Member for 6 years
first time to encountered this I never moddified any .swf since then so it got my attention.. anyway can you recommend .swf games aside from the game that you use for an example? or if you can give us a tip how to determine if a game is contain .swf that would be awesome! ^_~
 

AnonymousError

Apprentice Lv2️⃣
Member for 6 years
I keep getting an error when trying to save... CURLY_CLOSE expected but NAMESPACESUFFIX found on line 617
 
Top