Posted: 25th Sep 2011 9:41
Forgive me if this has been posted before, did a search and didn't find anything but you never know, but does anyone have any idea as to why it doesn't post the sprite I'm calling and it just gives me a white screen? Here's my code:

+ Code Snippet
SetDisplayAspect( 4.0/3.0 )

global GameStatus as float = 1.0

//SPLASH SCREEN PREP
splashTimer = 100
loadimage (1,"backgrounds/ADITL.png")
createsprite (1,1)

while (GameStatus = 1.0)

    //Setup Sprite
    setspritesize (1,100,100)

endwhile


I had it to where it showed a background (The ADITL.png Image) before but after I changed the image in an editor and erased/re-did some of the code all I get is a white screen. Puzzling...
Posted: 25th Sep 2011 11:06
A white sprite, means the system could not find the imagedata, please post the picturefile you are using, so we can see whats wrong with it.
Posted: 25th Sep 2011 12:26
Another cause could be that when using the SetDisplayAspect command, sprites are usually scaled massively. Try scaling down to 25% of it's original size (you may have to go even smaller). A quick way to work out if this is the problem is to temporarily use the SetVirtualResolution command and set it to the corrensponding width and height values found in the setup.agc.
Posted: 26th Sep 2011 5:02
My moneys on the virtual res being too small. 100x100 seems a low base res. Hodgey's suggestions should fix it. I only think you get a blank sprite if you specify it as an image value of 0. If it couldn't load the image it would fail with an error(or should).
Posted: 26th Sep 2011 5:35
If you are seeing a white image, my guess is that the image is not being loaded. Try moving the image into just the media folder, and as Hodgey says, use a virtual resolution to test whether it loads.

But tell us how big your device size is, so we can compare that to the 100x100 sprite size.

Oh, and by the way, you should move that sprite size outside the loop, you only have to set it once. (unless you plan to change the size in the game loop)
Posted: 26th Sep 2011 12:58
have you put the sync() command in your game loop ? not using sync makes a white screen.

chunks.
Posted: 27th Sep 2011 6:11
Well shoot...sync was the issue. Wow, I'm really sorry you guys, usually I'm not this retarded, I swear. It's just been a stressful couple of weeks at work and I've been off my game. I do have one dumb question though. DBPro I'm pretty good at, but app programming is a whole new thing to me. I just chose the basic 'landscape' project when starting this new one. That and the default 4.0/3.0 aspect should be fine for iPhones right?
Posted: 27th Sep 2011 8:39
As soon as I saw chunks's response I was like "He's probably right".

I just chose the basic 'landscape' project when starting this new one. That and the default 4.0/3.0 aspect should be fine for iPhones right?

I don't think so. The display aspect is generally set to width / height which in this case would be 480 / 320 which is 3 / 2.
Posted: 9th Oct 2011 3:12
Hi Guys, I tried to abolish Sync() somehow and bury it in the automated engine system but it just has so many useful places to exist as you code. I guess we need this level of control