Lua Picture Converter
#1
Posted 16 November 2005 - 06:31 PM
Here is the source code : Lua Pict Conv
#2
Posted 16 November 2005 - 07:31 PM
But as it is now, CPLua won't accept those files... There is a supplementary trick to do
This is a good idea, but I think that we can do better than that: the generated code is rather long for big images, and the drawing operation will take a lot of time
I will have CPLua support the use of PICT data files, as well as general data files: it will be possible to read/write a binary file manually, but it will also be possible to create some files containing a collection of byte arrays, to load those arrays at once and access them easily and individually later. Those could then be used as sprites, maps, etc
Edited by Orwell, 16 November 2005 - 07:35 PM.
#3
Posted 16 November 2005 - 08:28 PM
Interesting, but sprites will cause additional work to be needed: functions for detecting sprite-sprite collision, or sprite-background collision. I think that implementing the "io" package should have a much higher priority.I will have CPLua support the use of PICT data files, as well as general data files: it will be possible to read/write a binary file manually, but it will also be possible to create some files containing a collection of byte arrays, to load those arrays at once and access them easily and individually later. Those could then be used as sprites, maps, etc
#4
Posted 16 November 2005 - 08:34 PM
This should be a nice opportunity to use the tool 'tolua' btw
#5
Posted 17 November 2005 - 06:44 PM
Ask me, I've made such functions in ASM...
This is vary faster and the function to draw spirites draw the bitmaps in a only loop...
Alexandre
(ps: I leave my discoveries in ASM etc....because I don't have much time to work on CP)
#6
Posted 27 January 2006 - 03:08 PM
Anyway I'll not need it when Lua supports sprites.
Thanks, Goodbye.
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users