Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class A
- {
- public:
- void GetValue(void);
- private:
- sf::Sprite Sprite;
- };
- //A Code
- void A::GetValue(void)
- {
- return Sprite.GetPosition();
- }
- class B
- {
- public:
- //...
- private:
- A a;
- sf::Sprite Sprite2;
- };
- //B Code
- Sprite2.SetPosition(a.GetValue());
- //Gibt immer 0 aus obwohl die Position von Sprite wo anders ist...
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement