Loading Problem

BlitzPlus Forums/BlitzPlus Beginners Area/Loading Problem

Buggy(Posted 2006) [#1]
This isn't so much a problem with Blitz as it is a problem with my computer and my programming skills:

I have a text map file sort of like the one below, but bigger:

111111
100001
100001
100001
111111

I like to have a loading percentage which I got easily. My problem is that if I use Text (or Print) to write the loading percentage and the level numer onto the front buffer, it blinks obviously and annoyingly.

If, however, I use Flip or VWait, it loads much, much slower. It also flickers slightly, but this seems to be a problem with my computer (whenever I use the backbuffer/flip combo, the computer flickers if the main loop is run too quickly - for all of the blitz demos I either have to add a Delay 5 into the loop or run in windowed mode).

An alternative I just thought of would be to take out the zeros in the map file and just make it like this:

1, 0, 0
1, 10, 0
etc.

x, y, z

where x is the map image, y is the x value, and z is the y value.

Please help! Sorry if you don't understand this - just ignore the bottom part if it's too confusing.


Grey Alien(Posted 2006) [#2]
Don't bother taking the zeros out. I would only output the % after each line is loaded not each number. Having said that to be honest even a huge map should loads so fast you won't need a loading bar for them. My games have a loading bar but it progress at key stages e.g. graphics are all loaded, sounds are all loaded, levels are all loaded, arrays are created etc so it only goes up in say 20% chunks. It still loads in about 1 sec flat on my PC.


WolRon(Posted 2006) [#3]
Screw the loading screen unless it takes longer than 5-10 seconds. If it takes longer than 15-20, you should work on improving the loading time instead.


Grey Alien(Posted 2006) [#4]
yeah most of the time you won't need a bar. However, the 1-2 seconds loading on mine can be 10 secs on a slower computer, so I left it in.


CS_TBL(Posted 2006) [#5]
A 'loading' would be sufficient then I'd say. 2 seconds for a map? How big is that map then? Usually loading typical stuff is done in a splitsecond..


Buggy(Posted 2006) [#6]
Maybe my compy's just slow!

The maps are 42 x 31 (don't ask) and most of them are zeros.


CS_TBL(Posted 2006) [#7]
42x31 ???? On what compu might it be slow then??? An old model from the cold war? :D

42x31 bytes or ints should *really* load in a splitsecond!


Grey Alien(Posted 2006) [#8]
CS_TBL: "2 seconds for a map" Where did that come from? I said 1-2 seconds as my game loads in around 7Mb of media.


CS_TBL(Posted 2006) [#9]
ahyes ok..


Grey Alien(Posted 2006) [#10]
no worries :-)