[ create a new paste ] login | about

Project: ec
Link: http://ec.codepad.org/ckYXu9Of    [ raw code | output | fork ]

C++, pasted on Jul 25:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
SDL_Surface *load_image( std::string filename )
{
    //The image that's loaded
    SDL_Surface* loadedImage = NULL;

    //The optimized image that will be used
    SDL_Surface* optimizedImage = NULL;

    //Load the image
    loadedImage = IMG_Load( filename.c_str() );

    //Return the optimized image
    return loadedImage;			


if( x >= 564 && x <= 767 && y >= 213 && y <= 245 )
{
				image = load_image("\Homescreen\Start Game.png");
				apply_surface(0,0,image,screen);
				SDL_Flip(screen);
			}


Output:
1
2
Line 1: error: expected constructor, destructor, or type conversion before '*' token
compilation terminated due to -Wfatal-errors.


Create a new paste based on this one


Comments: