Hi @ all,
I have a game.cpp with the function void HelloWorld :: setupScore(){}
This functions show the actual point in my game very well
Now I created an endScreen.cpp file - the switch via : CCDirector::sharedDirector()->replaceScene(HelloWorld_End::scene()); is also no problem.
Now I want to show the last score at this screen. At the endScreen.h I #import “game.h”
But I ran into error if I call setupScore();
So, how it is possible to call and use a function from other files? I’ve seen, that many games use much files to store functions externally.
THX for your help.