Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Puchaczov

Pages: [1]
1
Graphics / filling the window with a texture
« on: November 25, 2011, 06:02:41 pm »
hi everyone, i've got a problem with filling the window. This is my code:
Code: [Select]

void textureStore::drawMap()
{
    unsigned int temp=0;
    int zm=50;
    sf::String text;
    for(int i=0; i<Y; ++i)
    {
        for(int j=0; j<X; ++j)
        {
            screen->Draw(spr[0]);
            spr[0].Move(50,0);
            temp+=50;
        }
        spr[0].SetPosition(0,temp); //it isn't working!
        screen->Draw(text);
    }
}

I try to start new line (spr[0].SetPosition(0,temp)) and it isn't working. The only first line is filling with texture. Why and what should i do to make it working.

Pages: [1]