Okay, I have absolutely no idea what is wrong with this code. When I comment out the parameters of the functions, everything works fine. Just like last time, it may be something obvious, I don't see it, though.

#include <SDL/SDL.h>
#include <iostream>
class tnt_Player
{
      private:
              SDL_Surface *Sprite;
              int xVelocity, yVelocity;
              int Frames;
              
      public:
             tnt_Player();
             ~tnt_Player();
             SDL_Surface *TNT_LoadSprite (std::string filename);
             int TNT_DrawSprite(&tnt_Player PlayerRef);
};

All help is appreciated,
EpicAsian

Recommended Answers

All 3 Replies

line 15 should be

int TNT_DrawSprite(tnt_Player & PlayerRef);

I knew it had to be something obvious.

Thanks Again
~EpicAsian

No problem.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.