EarlyMorning - Progress & Discussion
- kv83
- Maxcoderz Staff
- Posts: 2735
- Joined: Wed 15 Dec, 2004 7:26 pm
- Location: The Hague, Netherlands
- Contact:
Hmmm... anyway, I started to working on the next version. I'm working on plugin's (blame ben, the plugin-maniac ) so that people can make theire own dll's for compression for example. The compression dll actually works for a great part, but to work completly I have to rewrite a great deal of the 'core-code' of EM so that all classes are in different dll's (for example; the resource classes like "sprite" and "map" will be in the resource.dll)
- Jim e
- Calc King
- Posts: 2457
- Joined: Sun 26 Dec, 2004 5:27 am
- Location: SXIOPO = Infinite lives for both players
- Contact:
Sorry just barely tested.
My first shot at trying move to resulted in an error. I thought that was odd, But I've tried again and Im not able to recreate the error. So Im gonna call that first time a fluke or something.
compression seems to work fine as well. I like the customaztion availble for the output.
I do have 1 problem though, if compression is on there isn't an easy way to pick a map out of a collection. Or even if the maps are different sizes it would be troublesome.
So is there a way to access the name given to the maps and sprites without the 1. 2. 3. stuff?
It would also be nice to make a LUT of the labels.
My first shot at trying move to resulted in an error. I thought that was odd, But I've tried again and Im not able to recreate the error. So Im gonna call that first time a fluke or something.
compression seems to work fine as well. I like the customaztion availble for the output.
I do have 1 problem though, if compression is on there isn't an easy way to pick a map out of a collection. Or even if the maps are different sizes it would be troublesome.
So is there a way to access the name given to the maps and sprites without the 1. 2. 3. stuff?
It would also be nice to make a LUT of the labels.
He wants to get pointers to the different maps.
http://clap.timendus.com/ - The Calculator Link Alternative Protocol
http://api.timendus.com/ - Make your life easier, leave the coding to the API
http://vera.timendus.com/ - The calc lover's OS
http://api.timendus.com/ - Make your life easier, leave the coding to the API
http://vera.timendus.com/ - The calc lover's OS
- Jim e
- Calc King
- Posts: 2457
- Joined: Sun 26 Dec, 2004 5:27 am
- Location: SXIOPO = Infinite lives for both players
- Contact:
I found 2 bugs in the rle generation.
First look at this
First thing you should notice is that 271. On a DB, brass and tasm will generate errors, Spasm would would and it 255. When you do RLE you have to limit the maximum run to 255(well technically 256). so that shoould actually be 2 runs instead like this:
The second bug I found in RLE generation was that the maps were 1 byte larger than intended.
The above map is only 272 bytes long, 271 of those are 0 the last should be 4. however there is an extra 0 after the 4, so thats just wasteful.
Last about the issue I was talking about earlier. Lets say i have this map collection:
How would I address map 3? The only way I can think of is to fake decompress through all the maps untill I get to the map that I want. But that is extremely impractical.
What I was suggesting was a way to make labels and possibly luts.
Basically an output like this:
First look at this
Code: Select all
;2. egg
.db 272 ;length
.db 17 ;hieght
.db 16 ;width
.db 255 ;escape
.db 255,271,0,4,0 ;rle compressed map
Code: Select all
.db 255,255,0,255,16,0
The above map is only 272 bytes long, 271 of those are 0 the last should be 4. however there is an extra 0 after the 4, so thats just wasteful.
Last about the issue I was talking about earlier. Lets say i have this map collection:
Code: Select all
;MapCollection - mapcollection
map:
.db 4
;1. map
.db 64
.db 8
.db 8
.db 255,4,3,0,6,255,4,0,1,1,9,255,3,1,10,1
.db 9,9,15,13,13,0,1,3,0,15,15,1,7,1,13,1
.db 1,14,5,5,16,13,0,2,1,255,3,5,255,4,3,1
.db 5,1,5,12,3,18,3,255,3,5,15,12,12,3,3,0
;2. egg
.db 272
.db 17
.db 16
.db 255,255,271,0,4,0
;3. sweet
.db 240
.db 20
.db 12
.db 255,255,3,0,255,5,3,255,7,0,3,255,4,0,3,3
.db 255,5,0,3,255,11,0,3,255,11,0,3,255,11,0,3
.db 255,11,0,3,3,255,11,0,255,5,3,255,11,0,3,255
.db 11,0,3,255,10,0,3,3,255,18,0,5,255,11,0,5
.db 255,11,0,5,255,11,0,5,255,11,0,5,255,11,0,5
.db 5,255,19,0,255,12,5,0
;4. guy
.db 4
.db 2
.db 2
.db 255,0,1,2,3,0
What I was suggesting was a way to make labels and possibly luts.
Basically an output like this:
Code: Select all
mapcollection:
.db 4
.dw map ;Look up table
.dw egg
.dw sweet
.dw guy
map:
.db 64
.db 8
.db 8
.db 255,4,3,0,6,255,4,0,1,1,9,255,3,1,10,1
.db 9,9,15,13,13,0,1,3,0,15,15,1,7,1,13,1
.db 1,14,5,5,16,13,0,2,1,255,3,5,255,4,3,1
.db 5,1,5,12,3,18,3,255,3,5,15,12,12,3,3,0
egg:
.db 272
.db 17
.db 16
.db 255,255,271,0,4,0
sweet:
.db 240
.db 20
.db 12
.db 255,255,3,0,255,5,3,255,7,0,3,255,4,0,3,3
.db 255,5,0,3,255,11,0,3,255,11,0,3,255,11,0,3
.db 255,11,0,3,3,255,11,0,255,5,3,255,11,0,3,255
.db 11,0,3,255,10,0,3,3,255,18,0,5,255,11,0,5
.db 255,11,0,5,255,11,0,5,255,11,0,5,255,11,0,5
.db 5,255,19,0,255,12,5,0
guy:
.db 4
.db 2
.db 2
.db 255,0,1,2,3,0
- kv83
- Maxcoderz Staff
- Posts: 2735
- Joined: Wed 15 Dec, 2004 7:26 pm
- Location: The Hague, Netherlands
- Contact:
Jim E: your bugs have been noted btw as BG-021 and BG-022. Could you send me the .emr file, for testing purpose? (you know my mail, right?)
about the pointer problem; would it be enough to have a table with the position of the map?
example
about the pointer problem; would it be enough to have a table with the position of the map?
example
Code: Select all
map_table:
.db 0,10,25,30 ... etc.
maps:
;Map 1
.db 0,0,0,0,0,0,0,0,0,0
;Map 2
.db 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
;Map 3
.db 0,0,0,0,0
;Map 4
.db ..... etc....