- Upvotes Received
- 1
- Posts with Upvotes
- 1
- Upvoting Members
- 1
- Downvotes Received
- 0
- Posts with Downvotes
- 0
- Downvoting Members
- 0
Sometime crashes, sometimes blank text, and sometimes works. I'm passing (I hope) a reference to TextDisplay::update() so It can draw all the text in keyBindMenu which is a vector of std::strings. I'm not sure if I'm handling this correctly. My understanding of this is very weak, but I think I … |
|
Tried searching for an answer to this, but not sure even how to explain this question so i will show a code example.(I blame java, better then saying i'm brain damaged) I have no problems with pointers. But can't seem to remember the correct way to call the constructor when … |
|
Should I loop through tiles and delete each one? Or is there a better way? if(tiles->at(i) != NULL) delete tiles->at(i); std::vector<Tile*> tiles; //TODO: need to fix this to match sprite sheet tiles size for (int y = 0; y < 10; y++) { for (int x = 0; x < … |
|
I am trying to make sure that I delete all memory allocations from the new command, ran into 1 problem and I'm not sure If I understand when how the delete in a destructor of a class will be called. Problem: I create a class in main, after the game … |