ONElua v3
gdljjrod wrote: "ONELua is a brand new Lua Interpreter to create our homebrews to both PSP as PSVita.
As LuaDEV, OneLua is based on OSLib, so there are many similar functions (with slightly different syntax).
In this version there are enough modules to make decent homebrews.
Autors: gdljjrod and Rober Galarga."
ONElua
http://wololo.net/talk/viewtopic.php?f=2&t=38576
[Changelog ONElua v3 AKA:
Oneluav3en.txt]
Code:
========= Added by GDL 25/06/15 ========
Changes:
--Added Support to run in VHBL mode (allows executing in user mode Homebrews VHBL (PSVita)).
Bit --Added the Lua library that allows Operations bitwise level.
More info here http://bitop.luajit.org/
--New Module Maps, for can generate maps with Tiles.
--Added Buttons.interval function ()
--Added Amg.screenshot function ()
--Added The callback "onPbpPack" for new functions:
game.pack () to package the resources of a PBP and make corresponding EBOOT.PBP.
game.add () lets you change or add a resource from a EBOOT.PBP.
game.remove () Deletes a resource from a EBOOT.PBP
--Added Functions:
image.loadv () lets you upload images directly to VRAM.
image.loadfromdata () Loads an image from data in memory.
image.move () Moves an image of VRAM to RAM and vice versa.
Image.Save () now allows saving an image with transpariencia.
image.blittint () Allows blitear an image with tinted effect.
image.blitadd () Allows blitear an image with great color effect.
image.blitsub () Allows blitear an image with color effect remains.
--Upgrade The value in the ini.read () Now you can read up to 1024 characters.
'Now the () Detects "VHBL" os.cfw function.
--Added New features:
os.messagebox () displays a message on screen in a window.
os.modetv () Turns the TV output in progressive mode. (720x480).
os.cabletv () lets you know the type of cable connected to the TV.
--Added The print with SCROLL:
Left.
Right.
Left (via).
Left Right.
--Added Full alignment with the print
--Added The screen.clip () function.
--Fix The screen.textheigth () function.
'Now the timers.new and timer.reset can give the initial value.
[Changelog V2R1]
Code:
V2R1
Added new module SIO.
Add the new Debugger
os.debug() To enable debug mode.
Added new Callback onDebug() that serve to replace our screen error
Added onelua_rdriver.prx for game.launch() function that returns you to ONElua.
(Requires onelua_rdriver.prx in seplugins to PSPGo should go in ef0:/seplugins).
New functions (batt):
batt.tonormal()
batt.topandora()
batt.toautoboot()
batt.backupbat()
batt.restorebat()
New functions (files):
files.scan()
files.extractfile()
New function (3D):
amg.rendertrans() for models with transparencies.
Fixed some bus with reflections.
New functions (hw):
hw.ofwinitial()
hw.fuseid()
hw.fusecfg()
hw.kirk()
hw.spock()
hw.nandseed()
hw.placa changed by hw.board()
hw.getmodel() now detects PSVITA model.
New functions (screen):
screen.toimage()
screen.buffertoimage()
New functions (math):
math.bitnot()
math.bitand()
math.bitor()
New functions (os):
os.getpassword()
Update os.getcfw now detects TNV/ARK
os.reset() changed by os.restart()
Modified image.save() and screen.shot() only accept PNG format.
Changed the function osk.init() Now put two modes: Normal Keyboard and Numeric Keyboard.
Code:
"This version includes a 3D demo by Mills (Downloads are in our web)"
ONElua v2 Bundle Demo:
https://dl.dropboxusercontent.com/u/48796093/Onelua/ONEluav2Bundle.rar
memstick/PSP/Game/Demo3D ONELUAv2
[Changelog]
++ Added the all-new 3D Module (special thanks to Andresmargar for AMGLib and his invaluable help... YOU ROCK MAN!).
++ Added a new error screen, now you can edit the error line directly in your PSP (no PC needed). This is still in development and tests, so some errors will not be fixable in this way.
++ Now you can access correctly to both ms0 and ef0 on PSP Go.
++ Fixed MOD sounds loading (.mod, .it, .s3m and .xm).
++ Fixed os.message(), now it returns your choice correctly.
++ files.list(),files.listfiles() and files.listdirs() were optimized.
++ Utils module renamed to game.
++ sound.getid3() got a new field: "cover", which contains the album art if available.
++ Added three new functions: image.pixel(), screen.brightness() and os.delay() (please refer the docs to get further details).
++ Now files.size() also works on directories.
-- Disabled AT3 files loading.
[TO DO]
++ Finish the new error screen, adding more support, the new OSK and the new GUI.
OneLua features basic functions, as sound load (mp3), images, ini files, functions to copy & paste and many more (feel free to explore the docs).
However, there are a bug: there aren't functions to delete sounds, images, timers and other objects, so to free them you'll need to use the basic way:
var = nil
Maybe you'll want to call collectgarbage("collect") after that to clean effectively the memory used by the object.
Features:
-Most math module functions now uses the VFPU, so the trigonometric calculations will be VERY fast.
-Color masking while loading images. This allow, for example, remove a solid-color background in your images.
-Dedicated HW module, which contains plenty of new functions, as PSP model detection, battery mode detection (normal, pandora or autoboot... only works for unbrickeable consoles), motherboard type and model detection...
-Detects correctly the free space in both ms0 and ef0 (for PSP Go).
-Detects the CFW that you're running.
-UMD functions: info and dump directly.
-Files: copy, rename, delete, fast-move (using the Total_Noob sample), unzip & unrar (with or without password).
-Unified and easy-to-use buttons reading, using constants (see the docs for an example).
-WiFi configs backup & restore.
-callbacks and constants in several functions, to ease your life
FOR PSP GO USERS
-If you want to read both ms0 and ef0 devices, your HB should be placed in ms0. <--Fixed v2.
-The function files.move doesn't work properly between devices (ms0 to ef0 and vice versa), only performs a copy. Other functions work fine.
We'll appreciate if you report us all the bugs you encounter. Any other feedback is welcomed, too.
Impotent Missing text: Solution replace jpn0.pgf in flash0 folder with original PSP fonts to get text working (or try JPCSP jpn0.pgf unconfirmed if this will fix the text). Tested with Notepad++: UTF-8 without BOM
memstick/PSP/Game/ONEluav2R1
flash0/font/jpn0.pgf
Last tested with: ppsspp-v1.0-59-gc9e6938-windows-amd64
PPSSPP issue #1 missing text with following lua code:
Code:
screen.print(0,100,"Test 1: Must replace jpn0.pgf font to see this massage")
screen.print(0,110,"Test 2: Must replace jpn0.pgf font to see this massage",0.4,color.new(250,0,0))
screen.print(0,120,"FPS: Must replace jpn0.pgf font to see this massage"..screen.fps())
New Settings:
Code:
Fast memory (unstable) -Unchecked (if this is checked it will crash)
Multithreaded (experimental) -Checked *optional speedup
(Edit) Change emulated PSP's CPU clock: 1000 *optional speedup (helps sequential images/frame by frame images)
Save path in My Documents -Checked *optional