Help with calling functions

Can someone help me with this error?
http://paste.ubuntu.com/1196907/
http://paste.ubuntu.com/1196910/
http://paste.ubuntu.com/1196926/

I need to access the values for my collision detection.
The syntax isn't quite right. Here's the fixed constructor.
1
2
3
4
5
6
7
8
9
Player::Player() {

	Player::playerWidth = 100.0f;
	Player::playerHeight = 100.0f;
	Player::speed = 6.0f;

	Player::setup();

}
Thanks for the fast reply but now I am getting this error, http://paste.ubuntu.com/1197009/
Moved code to github for easier access, https://github.com/MrDare360/SFML-Game
I just fixed the constructor for you. You need to correct the syntax in all the class methods.
You need to create the static members
Put float Player::playerX; //and the others in `Player.cpp'

However it seems that you don't understand the difference between a class (blueprint) and an object (building)

By the way accessing as Player::setup(); is legal (it makes sense when you want to call a method from a parent class)
Yes, I'm sorry for being noobish, OOP in C++ feels a lot different than in Java, thanks guys. :)
Topic archived. No new replies allowed.