PS3 JSXviewer - A tool for viewing/Extracting .jsx files commonly found in Themes

Over at PlayStationHAX forums developer TizzyT has released a Tool called JSXviewer, this tool is not finished but can be useful to the community in it's current form. This tool will allow you to view and extract the contents of a .jsx files these are common files found in various animated Themes on the PS3. Checkout the details below from two scene developer:


JSXviewer.PNG

Original Release Notes from TizzyT
TizzyT said:
This is fairly old and is unfinished (can't automatic decompile yet) but I was told I should put this here.
Its a tool to view/extract info from .jsx files (usually found when dealing with themes). It might help in manual decompilation for now I guess. I might get around to finishing the auto decompile feature.

Thanks Sandungas for the help.

Here is a bit of an explanation from developer Sandungas about this release
sandungas said:
Before people asks... this tool is supposed to generate the original "javascript like" file used to compile .raf animations (inside dynamic themes and coldboot)

It doesnt makes the decompilation yet, but it does the previous steps like cropping tables, generating a list of opcodes, etc... usefull to study how the compilation<--->decompilation works

Thx :)
 
Last edited:
@TizzyT
I'm trying to make ManaGunZ supporting dynamic p3t... I didn't expect to see Java script in these files... long story short, I just tryed ur app, and I saw a mistake :

It wrote this :

Code:
var i = 0;
if (!(i < background.length))
{
    i++;

instead of

Code:
for (var i = 0; i < background.length; i++)
{

Also it didn't close the loop with : }

Is it still in developement ?

Perhaps, someone know how I can deal with JS file in MGZ ?
 
jsx is not limited to themes. coldboots, both colored (part of themes) and white, use it. also, rco files use it. u can use rco mage (not the gui) to decode (not decrypt) jsx to js which will allow u to modify its values. that's how I made the psx place coldboot move in different directions a while back. :) btw, the camera seems to be a fixed point on the screen (coded into the coldboot) which determine the x, y, and z values, so they're not always the same for every theme or coldboot. rule of thumb for z is usually the lower the value, the closer to the user, which can make it seem as though ur modifying the size of the image, while x and y can change based on the camera point.
 
yeah, i saw it but this one is more complete.
As I already included RCOmage in MGZ, I'm trying update it thanks to JSXviewer source code (JSXviewer is coded in VB)
 
@Zar, didn't know that. it's been a long time since I've messed with the ps3. I'm dumping klicenses now.

as for themes' script file, it would be nice if everyone got together to determine what each call sign referred to. we have the same issue with the wave scripts. 'floating point' (think that's the name as it's been a long time) refers to the x, y, and z points. they go in order. the camera point is called first, then it goes to floating point x, then y, then z. each has a starting and ending position referred to as start and end which the image will drift to if u set the x, y, and z start and end position to the same respectively for each, and it's at the same camera point, the image will be centered or even full screen depending on the image, and the image will be static. :-P
 
On PS3 jsx scripts are used in many XMB Menu and icons within CFW can change position, axis, and image colors.

yes, u can find them in hex as vsmx at the beginning of the hex. they're usually at the bottom of coldboots and themes. I can't recall where they're at with rco, but they're called the same. they also don't need a complete 16 bytes from what I remember, so u don't need to pad the vsmx with 0's (this is assuming they're at the bottom).
 
finally, i didn't use the version of RCOmage because i had too many issue with it... so i translated the JSX viewer from VB to C ... then I modified it a lot when i was trying to fix it, so it became something new :
http://rgho.st/7pFjq76bd

It's not 100% accurate but it does a better job than the others. (at least with my samples).

How to use it : Drag and drop ur JSX file to jsx.exe it will generate the JS file. The commad is simple : "jsx.exe sample.jsx" then "sample.js" will be created.
 
finally, i didn't use the version of RCOmage because i had too many issue with it... so i translated the JSX viewer from VB to C ... then I modified it a lot when i was trying to fix it, so it became something new :
http://rgho.st/7pFjq76bd

It's not 100% accurate but it does a better job than the others. (at least with my samples).

How to use it : Drag and drop ur JSX file to jsx.exe it will generate the JS file. The commad is simple : "jsx.exe sample.jsx" then "sample.js" will be created.

yeah, rco mage would sometimes generate Chinese Hanzi within the script. u'd have to modify those lines or it would compile. I've experienced that many times. great job on the app!
 
@TizzyT
I'm trying to make ManaGunZ supporting dynamic p3t... I didn't expect to see Java script in these files... long story short, I just tryed ur app, and I saw a mistake :

It wrote this :

Code:
var i = 0;
if (!(i < background.length))
{
    i++;

instead of

Code:
for (var i = 0; i < background.length; i++)
{

Also it didn't close the loop with : }

Is it still in developement ?

Perhaps, someone know how I can deal with JS file in MGZ ?

Yes, this application is still in development at the time although I have since stopped working on it for a while. Recently I had the thought of coming back and working on it again (and possibly even completing it). I was interested in your C port and changes you made but the link you presented was deleted so I wasn't able to check it out. There is a high chance that I will be getting back to further develop JSXviewer sometime soon.

Now as for the for loops being decoded as an if statement that isn't entirely wrong lol. The decoder as the moment just assumes anything that is a conditional statement must be an if statement. I wanted to detect loops back then but I never got around to it, I will more than likely incorporate them in the decompiler next time around.
 
I look forward to this, because using rcomage is a pita. iirc, it only has issues decoding a jsx script file when it's a colored coldboot or a theme. white coldboots seem to be unaffected.
 
I look forward to this, because using rcomage is a pita. iirc, it only has issues decoding a jsx script file when it's a colored coldboot or a theme. white coldboots seem to be unaffected.

Well jsx has to do with themes and other things besides coldboots too. Mainly I wanted to do this to enable the community to make better custom themes although this would apply to coldboots naturally. Now all I have to do is look for @sandungas and see if he wants to help out with them opcodes lol, and anyone else for that matter.
 
Btw the tool decodes the jsx opcodes strictly and literally

With this i mean... the 2 loop examples you are talking about works in the same way in the practise... but when converted to opcodes are different things

If the tool decoded them that way is because originally the source code (in ps-javascript) was written like that

P.S.
@TizzyT loves the D.
 
Btw the tool decodes the jsx opcodes strictly and literally

With this i mean... the 2 loop examples you are talking about works in the same way in the practise... but when converted to opcodes are different things

If the tool decoded them that way is because originally the source code (in ps-javascript) was written like that

P.S.
@TizzyT loves the D.

Unfortunately while a loop can be made with an if statement it is missing a GoTo etc which my decoder/decompiler doesn't add. The if statement is only there because of the condition. The opcode for the conditional is the JUMPF (if I remember correctly). So both a for loop and an if statement has that and because I haven't added anything in JSXviewer to distinguish fors and ifs or other loops and conditionals (which jump) it just assumes its an if statement and outputs a malformed if statement at that lol, so the same thing will most likely happen with while loops too. When I start work on this again loops with be the first thing I work on promise, just hoping @sandungas will ride that D with me :P lol

PS: I have a working PS3 again :)
 
Last edited:
Lol, i dont remember much about this riding now

What i remember is the tool was confirmed to produce exact binaries (exactly like original hashes) after decoding and decompiling (and properly compiling back) for this files we used as guinea pigs:
-the script inside official coldboot.raf
-sdk sample moustache
-sdk sample slideshow
-sdk sample dontremembername

Also, some official themes from PSN store

-----------
We never tryed with the scripts inside the RCO files of PSP firmware as far i remember though (there are 2 or 3 as much)
 
Well jsx has to do with themes and other things besides coldboots too. Mainly I wanted to do this to enable the community to make better custom themes although this would apply to coldboots naturally. Now all I have to do is look for @sandungas and see if he wants to help out with them opcodes lol, and anyone else for that matter.

the script I have in my coldboot script tutorial is for a white coldboot, so no unique characters. I don't understand y it happens to the anim_1.jpg (colored coldboot, background, script) or if fixing it, which is required to reencode it, messes up the file. I haven't tried that personally.

yeah, @sandungas knows his stuff. I'm amazed by his level of knowledge with just about anything ps3-related.
 
btw, I don't know if this will help, but someone once asked me how to create a dynamic coldboot. I found a tutorial on how to do this, which must manipulate the theme script, on the ps3 themes website. there r a lot of steps from what I remember, but he said it worked for him. I've never personally made one.
 

Featured content

Trending content

Back
Top