| View previous topic :: View next topic |
| Author |
Message |
mallchin
Joined: 16 Feb 2006 Posts: 36
|
Posted: Sun Jun 04, 2006 12:14 am Post subject: File Functions |
|
|
I see LuaPlayer has updated to 0.19, but does anyone have an updated list of functions?
I can't see any mention of the requests I've made, anyone managed to move/rename files? |
|
| Back to top |
|
 |
Shine
Joined: 03 Dec 2004 Posts: 728 Location: Germany
|
Posted: Sun Jun 04, 2006 4:23 am Post subject: Re: File Functions |
|
|
| mallchin wrote: | I see LuaPlayer has updated to 0.19, but does anyone have an updated list of functions?
I can't see any mention of the requests I've made, anyone managed to move/rename files? |
I've added a System.rename function for Lua Player 0.20. |
|
| Back to top |
|
 |
mallchin
Joined: 16 Feb 2006 Posts: 36
|
Posted: Mon Jun 05, 2006 3:10 am Post subject: |
|
|
Great news, thanks Shine.
I know your pushed for time developing LuaPlayer but many of us appreciate it :) |
|
| Back to top |
|
 |
mallchin
Joined: 16 Feb 2006 Posts: 36
|
Posted: Mon Jun 05, 2006 3:15 am Post subject: |
|
|
Also, if you get a chance, a move function would be neat too (if supported).
I'm mimicking moving files by copying source files then deleting them, but it doesn't work well for large files and limited space. |
|
| Back to top |
|
 |
MikeHaggar
Joined: 18 Jul 2005 Posts: 116
|
Posted: Tue Jun 06, 2006 2:28 am Post subject: |
|
|
| I guess you've already tested moving by renaming? |
|
| Back to top |
|
 |
mallchin
Joined: 16 Feb 2006 Posts: 36
|
Posted: Wed Jun 07, 2006 12:00 am Post subject: |
|
|
| I like your thinking ;) |
|
| Back to top |
|
 |
be2003
Joined: 20 Apr 2006 Posts: 144
|
Posted: Thu Jun 08, 2006 10:29 am Post subject: Re: File Functions |
|
|
| Shine wrote: | | mallchin wrote: | I see LuaPlayer has updated to 0.19, but does anyone have an updated list of functions?
I can't see any mention of the requests I've made, anyone managed to move/rename files? |
I've added a System.rename function for Lua Player 0.20. |
ya but you totally jacked up the way i write table functions and now none of my lua apps work, good job!
Just change the table sh*t back and everyone would be happier.
I had to go back to 0.19 _________________ - be2003
blog |
|
| Back to top |
|
 |
mallchin
Joined: 16 Feb 2006 Posts: 36
|
Posted: Thu Jun 08, 2006 11:52 pm Post subject: |
|
|
| What problems are you having? |
|
| Back to top |
|
 |
be2003
Joined: 20 Apr 2006 Posts: 144
|
Posted: Fri Jun 09, 2006 3:16 am Post subject: |
|
|
the 0.19 lowser wont work and "for i=1,string.len(somethin) do" doesnt work and its annoying _________________ - be2003
blog |
|
| Back to top |
|
 |
Shine
Joined: 03 Dec 2004 Posts: 728 Location: Germany
|
Posted: Fri Jun 09, 2006 3:33 am Post subject: |
|
|
| be2003 wrote: | | the 0.19 lowser wont work and "for i=1,string.len(somethin) do" doesnt work and its annoying |
You are right, 0.19 lowser doesn't work, but I've fixed it. Lowser in Lua Player 0.20 works. The only changes needed were the pairs/ipairs changes, like described in the release notes.
And I can't reproduce your problem with "for i=1,string.len(somethin) do". The following code works with Lua Player 0.19 and Lua Player 0.20:
| Code: |
something = "test"
for i=1,string.len(something) do
c = string.sub(something, i, i)
-- do something with c
end
|
But if you have some code which doesn't work, please post it and I'll try to fix it. |
|
| Back to top |
|
 |
be2003
Joined: 20 Apr 2006 Posts: 144
|
Posted: Sat Jun 10, 2006 2:55 am Post subject: |
|
|
nvm, it was "for index,value in table do". it took a while to change them to ipairs and pairs, i really needed the jpeg support! so why did you want to make it lua 5.1, wasnt that a hassle? _________________ - be2003
blog |
|
| Back to top |
|
 |
Shine
Joined: 03 Dec 2004 Posts: 728 Location: Germany
|
Posted: Sat Jun 10, 2006 3:20 am Post subject: |
|
|
| be2003 wrote: | | nvm, it was "for index,value in table do". it took a while to change them to ipairs and pairs, i really needed the jpeg support! so why did you want to make it lua 5.1, wasnt that a hassle? |
So how long do you need to replace "in table" with "in ipairs(table)", when searching all for loops with a good editor? :-)
Lua 5.1 provides some advantages: incremental GC, which may be useful for action games to prevent long GC pauses, new string and other functions and better module support for Mac OS X, which may be useful later when porting it to Mac OS X. |
|
| Back to top |
|
 |
be2003
Joined: 20 Apr 2006 Posts: 144
|
Posted: Sat Jun 10, 2006 3:47 am Post subject: |
|
|
this may seem crazy, but listen to this. i dont have a computer in this state(ca). i use tipster's unzip, links2, psp-pda, and file assistant all on my psp to do everything. i make all my lua apps on my psp. _________________ - be2003
blog |
|
| Back to top |
|
 |
romero126
Joined: 24 Dec 2005 Posts: 200
|
Posted: Sun Jun 11, 2006 6:59 am Post subject: |
|
|
| I actually think 5.1 has increased luaplayers speed substancially, I also have noticed that parsing files (reading) takes absolutly no time to do. Its fantastic! However saving it dead weight. |
|
| Back to top |
|
 |
|