Lua Player for PSP
Moderators: Shine, Insert_witty_name
-
- Posts: 116
- Joined: Mon Jul 18, 2005 2:20 am
The luaplayer.org site was down again. Looks like all Lisp subprocesses were hanging, because some connection error occured, at least I saw this after I loged into the Lisp process, because there were a stack trace and an error message with a prompt waiting for input, if I would like to abort the error. I've installed Apache, until I found the real problem, so there should be no problems any more for the next time, until I install the Lisp server again :-)
-
- Posts: 21
- Joined: Fri Jul 08, 2005 2:59 am
-
- Posts: 17
- Joined: Thu Jul 21, 2005 4:42 am
I moved onto something a little bit easier for me to understand. Just outputting text on the screen depending on which button was pressed.
I also made functions for each sentence. I know this is easy for a lot of you, but I am trying to learn.
I didnt have a problem displaying different sentences for each button. How would I go about deleting the previous sentence that was printed out.
here is my short and simple code lol...
What would I do to remove the first sentence when the button is pressed ?
I also made functions for each sentence. I know this is easy for a lot of you, but I am trying to learn.
I didnt have a problem displaying different sentences for each button. How would I go about deleting the previous sentence that was printed out.
here is my short and simple code lol...
Code: Select all
green = Color.new(0,255,0)
blue = Color.new(5,179,252)
-- Define function for printing question to off screen
function printing()
screen:print(100,100,"Press X to display text...", green)
end
-- Define function for printing response to offscreen
function viewing()
screen:print(100,110,"JUST A SIMPLE TEST...", blue)
end
-- Main loop
while true do
printing()
pad = Controls.read()
if pad:cross() then
viewing()
elseif pad:start() then
break
end
screen.waitVblankStart()
screen.flip()
end
Dark Killer --> http://forums.ps2dev.org/viewtopic.php?t=3029 has released KaboomPSP, hes on a crappy freeserver so its mirrored here and a v1.0 eboot addedd --> http://psp-news.dcemu.co.uk/kaboompsp.shtml
Dude, I've already told you. Lua games should not be bundled with an eboot.emumaniac wrote:Dark Killer --> http://forums.ps2dev.org/viewtopic.php?t=3029 has released KaboomPSP, hes on a crappy freeserver so its mirrored here and a v1.0 eboot addedd --> http://psp-news.dcemu.co.uk/kaboompsp.shtml
-
- Posts: 116
- Joined: Mon Jul 18, 2005 2:20 am
-
- Posts: 17
- Joined: Thu Jul 21, 2005 4:42 am
Excellent.nevyn wrote:I'm onto that...Evil Inside wrote:Are you still working a Mac OSx version of the player?
I'm dying to get started on a few game ideas I have, but the LuaPlayer, my PSP and Mac OSx don't really play together well. I'm having a lot of problems using LuaPlayer's USB feature and my Lua scripts have been getting corrupted.
So I eagerly await the Mac LuaPlayer so I get started on some titles.
In the meantime, I'm been putting together some backgrounds, titles and character graphics. If anyone wants to collaborate on a project and needs some graphics, email me: evil_inside70 @ yahoo dot com.
Here's a few graphic someone might find useful:
Last edited by Evil Inside on Thu Aug 18, 2005 11:33 pm, edited 1 time in total.
I hate Lua's implicit pointer usage so much. Is there any way to get something like this to print on the screen:
Code: Select all
white = Color.new(255,255,255)
function myblit(myimage)
myimage:print(0,0,"yay!",white)
end
myblit(screen)
while 1 do screen.waitVblankStart() end
Please read the tutorial:Soban wrote:I hate Lua's implicit pointer usage so much. Is there any way to get something like this to print on the screen:
There are two screen buffers: one offscreen buffer and one visible screen buffer. All drawing functions goes to the offscreen buffer. This means your print is not visible until you call screen.flip(), which exchanges the offscreen buffer and the visisble screen buffer. This is known as double-buffering. It is implemented as page-flipping (see the wikipedia entry for an explanation), this is the reason for the name "flip".
If you're on a Mac, do NOT FORGET to unmount the PSP from Finder before shutting down disk mode! EXTREMELY important, as Mac buffers reads and writes. You /should/ be getting a big fat nasty warning about it every time you do it, though...Evil Inside wrote:I'm dying to get started on a few game ideas I have, but the LuaPlayer, my PSP and Mac OSx don't really play together well. I'm having a lot of problems using LuaPlayer's USB feature and my Lua scripts have been getting corrupted.
-
- Posts: 17
- Joined: Thu Jul 21, 2005 4:42 am
I usually do unmount it first, but sometimes I forget and get the warning.nevyn wrote:If you're on a Mac, do NOT FORGET to unmount the PSP from Finder before shutting down disk mode! EXTREMELY important, as Mac buffers reads and writes. You /should/ be getting a big fat nasty warning about it every time you do it, though...Evil Inside wrote:I'm dying to get started on a few game ideas I have, but the LuaPlayer, my PSP and Mac OSx don't really play together well. I'm having a lot of problems using LuaPlayer's USB feature and my Lua scripts have been getting corrupted.
I now have a problem in where the PSP does not show up in the top corner window of Finder like the rest of the mounted drives so I have to navigate to it manually and sometimes the memory stick's folders don't show up.
Try adding screen:clear() to the beginning of each button if statement like this:F34R wrote:tried that... and it only clears the screen while the button is pushed... let me try a few other things...MikeHaggar wrote:Use screen:clearF34R wrote:What would I do to remove the first sentence when the button is pressed ?
Code: Select all
green = Color.new(0, 255, 0)
pad = Controls.read()
while true do
if pad:up() then
screen:clear()
screen:print(1, 1, "You pressed up!", green)
end
if pad:down() then
screen:clear()
screen:print(1, 10, "You pressed down!", green)
end
screen.waitVblankStart()
screen.flip()
end
My Lua IDE is almost notepad now : ). It'll be there tomorrow, but I might not have internet access to post it.
Current features include:
-cut/copy/paste
-reads and writes unix and windows files (I think...)
-literal find
-new/open/save
-multiple windows (and you can have multiple windows of a single file)
-uses Lua for config files, so you can easily add features to it.
If I don't post it tomorrow you can expect it this weekend with even more stuff like:
-customizable syntax highlighting
-autotabbing
-find and replace with gfind pattern matching
-function definition lookup (push a button on a function name to jump to -the spot it's defined)
-documentation!
I'm also planning on adding an interactive debugger with all sorts of cool features, but I can't give a time estimate on that.
Current features include:
-cut/copy/paste
-reads and writes unix and windows files (I think...)
-literal find
-new/open/save
-multiple windows (and you can have multiple windows of a single file)
-uses Lua for config files, so you can easily add features to it.
If I don't post it tomorrow you can expect it this weekend with even more stuff like:
-customizable syntax highlighting
-autotabbing
-find and replace with gfind pattern matching
-function definition lookup (push a button on a function name to jump to -the spot it's defined)
-documentation!
I'm also planning on adding an interactive debugger with all sorts of cool features, but I can't give a time estimate on that.
-
- Posts: 116
- Joined: Mon Jul 18, 2005 2:20 am
Soban wrote:My Lua IDE is almost notepad now : ). It'll be there tomorrow, but I might not have internet access to post it.
Current features include:
-cut/copy/paste
-reads and writes unix and windows files (I think...)
-literal find
-new/open/save
-multiple windows (and you can have multiple windows of a single file)
-uses Lua for config files, so you can easily add features to it.
If I don't post it tomorrow you can expect it this weekend with even more stuff like:
-customizable syntax highlighting
-autotabbing
-find and replace with gfind pattern matching
-function definition lookup (push a button on a function name to jump to -the spot it's defined)
-documentation!
I'm also planning on adding an interactive debugger with all sorts of cool features, but I can't give a time estimate on that.
Oooh! Sounds good! Me wants ;)
SUPER TURBO TURKEY PUNCHER.....3 (PSP) end caps
helo, this is what you'v all been waiting for, this is the reason you all bught a PSP and the wait is almost over for.....
SUPER TURBO TURKEY PUNCHER 3 PSP edition.
This Summer, "The streets will flow with the blood of the non belivers"
now you can take the Arcade smash hit to the streets!
UPDATE: Now available for download here:
http://www.megaupload.com/?d=20JD4CX6
mirror provided by emumaniac:
http://psp-news.dcemu.co.uk/turkeypuncher.shtml
or at pspupdates here:
http://files.pspupdates.com/cgi-bin/cfi ... ,0,12,1085
source is messy but it gets the job done.
this is pretty much done unless someone finds a way to keep the music looping forever (see readme.txt).
--- have fun and by all means let me know what you guys think.
SUPER TURBO TURKEY PUNCHER 3 PSP edition.
This Summer, "The streets will flow with the blood of the non belivers"
now you can take the Arcade smash hit to the streets!
UPDATE: Now available for download here:
http://www.megaupload.com/?d=20JD4CX6
mirror provided by emumaniac:
http://psp-news.dcemu.co.uk/turkeypuncher.shtml
or at pspupdates here:
http://files.pspupdates.com/cgi-bin/cfi ... ,0,12,1085
source is messy but it gets the job done.
this is pretty much done unless someone finds a way to keep the music looping forever (see readme.txt).
--- have fun and by all means let me know what you guys think.
Last edited by dragula96 on Thu Aug 18, 2005 1:49 pm, edited 6 times in total.
-
- Posts: 15
- Joined: Tue Feb 08, 2005 6:36 pm
Re: SUPER TURBO TURKEY PUNCHER.....3 (PSP) end caps
Hehehe, here you go:dragula96 wrote:all it needs now is sound, if anyone can help me make lua player compatable wav files out of mp3s please post here.
http://webpages.charter.net/aldanafx/st ... ey_wav.zip
THANK YOU SO MUCH!
thanx, i just finished codeing the sounds in. works great.
can you please let me know what the specifications are for the wav files and what program you use to convert mp3s or ogg files to compatable wav files, so i can keep develuping such "SMASH HITS" :p
can you please let me know what the specifications are for the wav files and what program you use to convert mp3s or ogg files to compatable wav files, so i can keep develuping such "SMASH HITS" :p
Last edited by dragula96 on Thu Aug 18, 2005 9:38 am, edited 1 time in total.
-
- Posts: 17
- Joined: Thu Jul 21, 2005 4:42 am
-
- Posts: 32
- Joined: Tue Jan 25, 2005 3:10 am
Great work on the Lua player guys! The new features are slick. *thank you* for the USB support, it has made such a huge difference in development time.
I am wondering if there are any plans to include network support in a future of Lua player. Something along the lines of this:
network.listwifi() //lists all wifi profiles names & wifiId
network.isConnected()
network.connect(wifiId)
network.disconnect()
socket.open(ipaddress:port)
socket.send(message)
socket.readIncomingBuffer()
socket.clearIncomingBuffer()
socket.close()
another possible implementation is similar to what flash does with sendAndLoad() where you specify an http url and you can do an http post to a URL and get back a response from the server. Parse the response and do something useful with the new variables. This can be used to talk to server side scripts like, PSP, ASP, Python, etc, etc...
I have many uses for this including an internet community topscores system for Lua games and for communicating with other IP-enabled devices such as Xboxes, MythTV, any anything else with an ethernet port.
So far I've been able to scrape together some working code to do some of the above things using the wifi examples provided by PspPet. I would imagine, the access point connection process could be part of Lua player, only giving you access to the socket functions after a conection has been made. The VNC port for PSP had a nice wifi selector screen. I'm not quite sure how I can implement the PSP SDK networking code as a Lua function, and the code is pretty ugly anyway (but it works).
I'm intrested to hear comments on how others feel a network connectivity interface can be made inside Lua, and curious to where this feature stands on the 'wishlist' for Lua Player.
Keep up the great work!
I am wondering if there are any plans to include network support in a future of Lua player. Something along the lines of this:
network.listwifi() //lists all wifi profiles names & wifiId
network.isConnected()
network.connect(wifiId)
network.disconnect()
socket.open(ipaddress:port)
socket.send(message)
socket.readIncomingBuffer()
socket.clearIncomingBuffer()
socket.close()
another possible implementation is similar to what flash does with sendAndLoad() where you specify an http url and you can do an http post to a URL and get back a response from the server. Parse the response and do something useful with the new variables. This can be used to talk to server side scripts like, PSP, ASP, Python, etc, etc...
I have many uses for this including an internet community topscores system for Lua games and for communicating with other IP-enabled devices such as Xboxes, MythTV, any anything else with an ethernet port.
So far I've been able to scrape together some working code to do some of the above things using the wifi examples provided by PspPet. I would imagine, the access point connection process could be part of Lua player, only giving you access to the socket functions after a conection has been made. The VNC port for PSP had a nice wifi selector screen. I'm not quite sure how I can implement the PSP SDK networking code as a Lua function, and the code is pretty ugly anyway (but it works).
I'm intrested to hear comments on how others feel a network connectivity interface can be made inside Lua, and curious to where this feature stands on the 'wishlist' for Lua Player.
Keep up the great work!
-
- Posts: 15
- Joined: Tue Feb 08, 2005 6:36 pm
Re: THANK YOU SO MUCH!
I tried using Steinberg Wavelab 5 for making wav files, but it seems that it creates files that are incompatible with Lua (maybe because of weird headers). So I ended up using the free sound editor that comes with Nero and that worked. It converts the ogg files directly to wav, and the ogg files were already mono, 16 bit, 22Hz.dragula96 wrote:can you please let me know what the specifications are for the wav files and what program you use to convert mp3s or ogg files to compatable wav files, so i can keep develuping such "SMASH HITS" :p
You can also use QuickTime (www.quicktime.com) to export any sound format to WAV. (You'll need Pro though, but I'm sure you can find a serial somewhere...)
LiquidIce: YES, networking is coming to LuaPlayer, which you would have known if you had searched the forum or even just read the scrollback, you're like the tenth person asking.
LiquidIce: YES, networking is coming to LuaPlayer, which you would have known if you had searched the forum or even just read the scrollback, you're like the tenth person asking.
:) Great, network :)
Shine's mandelbrot script turned me on, so here my fractal tree demo :
Left of right to generate a new tree.
Get the source here.
I love lua !
Shine's mandelbrot script turned me on, so here my fractal tree demo :
Left of right to generate a new tree.
Get the source here.
I love lua !
Puzzle Bobble - The arcade port!
-
- Posts: 17
- Joined: Thu Jul 21, 2005 4:42 am
Re: THANK YOU SO MUCH!
There was a bug in mikmodlib, I've fixed it. Version 0.8 can be downloaded from http://www.luaplayer.orgindianajonesilm wrote: I tried using Steinberg Wavelab 5 for making wav files, but it seems that it creates files that are incompatible with Lua
Another changes in this version: it doesn't crash on PNG load failures any more and after restart the screen is cleared.
Lua Player scripts should be safe. Loading elf or pbp files can compromise the PSP system security (deleting the PSP flash, viruses etc.) and setting the speed could damage the PSP, so I don't implement it.Dark Killer wrote:I would just like to request two small features for v0.8 of luaplayer:
1. the ability to execute pbp and elf files. (or even just pbp would be ok.)
2. ability to set the psp's processor speed.