Intro
About
AthenaEnv is a project that seeks to facilitate and at the same time brings a complete kit for users to create homebrew software for PlayStation 2 using the JavaScript language. It has dozens of built-in Methods, both for creating games and apps. The main advantage over using AthenaEnv project instead of the pure PS2SDK is above all the practicality, you will use one of the simplest possible languages to create what you have in mind, besides not having to compile, just script and test, fast and simple. Also it uses a slightly modified version of the QuickJS interpreter for JavaScript language, which means that it brings almost modern JavaScript features so far.
Prerequisites
Using AthenaEnv you only need one way to code and one way to test your code, that is, if you want, you can even create your code on PS2, but I'll leave some recommendations below.
- PCSX2 (1.7.0 or above) or PS2Client for test.
- Enable HostFS on PCSX2
Qt version
Enable console output
(old) WxWidgets version
Getting Started
const font = new Font("default");
os.setInterval(() => { // Basically creates an infinite loop, similar to while true(you can use it too).
Screen.clear(); // Clear screen for the next frame.
font.print(0, 0, "Hello World!"); // x, y, text
Screen.flip(); // Updates the screen.
}, 0)`
How to run it
Athena is basically a JavaScript loader, so it loads .js files. It runs "main.js" by default, but you can run other file names by passing it as the first argument when launching the ELF file.
Demo
If you try to just download it on releases tab from here and run it, that's what you will see:
That's the default dashboard, coded in default main.js file. It searchs JavaScript files with the first line containing the following structure:
// {"name": "App name", "author": "Who did it?", "version": "04012023", "icon": "app_icon.png", "file": "my_app.js"}
// Now you can freely code below:
Once it was found, it will appear on the dashboard app list.
Docs info
Parameters followed by "?" (question mark) are optional, e.g.:
Color.new(r, g, b, a?);
Parameters followed by "=" (equal sign) are default values, e.g.:
readAsString(max_size = undefined);