That's what I figured. But I have learned never to assume anything when considering how someone else codes.
Okay, no idea then.
Just for giggles, what happens if you try this (I am only wondering if the local variables defined within the for loop are an issue):
// put these outside of app so that they can be used for cleanup
int iImageID;
int iSpriteID[30];
void app::Begin( void )
{
// local variables
int i;
// whatever your other setup is
// load the image
iImageID = agk::LoadImage("Menu_Background.png");
// create the sprites
for (i=0; i<30; i++)
{
// create the sprite and save the id
iSpriteID[i] = agk::CreateSprite(iImageID);
// position the sprite
agk::SetSpriteY(iSpriteID[i], 0+i*10);
}
}
Your original post talked about loading multiple images and your snippet only does one. The above can easily be adjusted to accommodate more images (store the ids in an array for later cleanup, I never assume that stuff will be cleared up properly).
Cheers,
Ancient Lady
AGK Community Tester and AppGameKit Master