Joined
Last Seen
0 Reputation Points
Unknown Quality Score
No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
0 Endorsements
Ranked #31.8K
Hello, I am in school programming a game using SDL. It's a simple game where the player shoots at ships, which spawns randomly. For this I call random function rand() each time in the game loop, then using the modulus operator to determine wether a new enemy will spawn. The … |
|
I have this Instance of class A, which i first assign, then assign again, but the compiler calls the destructor AFTER they class has been constructed the second time, why? [code] class A{ public: int *Int; A(int b) { Int = new int(b); cout << "CONSTRUCTOR " <<endl; }; ~A() … |