![]() |
|
Dissapearing vector |
InfiniteLoop
Member #8,434
March 2007
|
Hello All! I am currently writing a game that uses a double buffering system. It is a tile game and as such, I have tiles of bitmaps with a vector (hline, vline) grid. This works fine and dandy, except when I open my options menu. The options menu is a seperate class that recieves the buffer that I was using for my double buffering system to use as a background. After I pass the buffer (that may or may not be the problem) I can no longer see any of my vector graphics. I have tested this by drawing a big rect and before the options menu it appears, during and after the otpions menu it doesn't. Is there some form of incompatability that I am just not aware of? Thanks |
Kris Asick
Member #1,424
July 2001
|
I recommend you post the code relating to this problem. --- Kris Asick (Gemini) --- Kris Asick (Gemini) |
HoHo
Member #4,534
April 2004
![]() |
Without code it is kind of difficult to understand what might be the problem. __________ |
InfiniteLoop
Member #8,434
March 2007
|
It works until this point: menu = new CMenu(filename, challenge, buffer); setupGame(menu->getChallenge()); This is the constructor of my CMenu class: CMenu::CMenu(string name, int chal, BITMAP *back) init(); From this point on, no vector graphics will appear. |
Kris Asick
Member #1,424
July 2001
|
Probably something to do with CMenu::Init(), but you should show the code for your bitmap tile class as well. Or, if you don't mind, you should attach all of your code into a ZIP/RAR file and post that. You'd be surprised how completely unrelated a problem can be to where it occurs. --- Kris Asick (Gemini) --- Kris Asick (Gemini) |
CGamesPlay
Member #2,559
July 2002
![]() |
Also, use code tags when you post it. -- Ryan Patterson - <http://cgamesplay.com/> |
InfiniteLoop
Member #8,434
March 2007
|
Here is my CMenu::init() function. If there is a problem, I assume that it is here. The only different thing about this is the use of alpha blending for effect, maybe I need to turn alpha mode off afterwards?
|
CGamesPlay
Member #2,559
July 2002
![]() |
You haven't posted a single line of code that has anything to do with vectors. [append] -- Ryan Patterson - <http://cgamesplay.com/> |
InfiniteLoop
Member #8,434
March 2007
|
Quote: You haven't posted a single line of code that has anything to do with vectors. Irrelevant. Me writing a line of code to draw a vector graphic will do nothing to show that it does not show up. At any rate: Quote: But yeah, drawing_mode needs to be called again with DRAW_MODE_SOLID.
this was the fix. Thank you |
CGamesPlay
Member #2,559
July 2002
![]() |
Oh, my mistake. I thought "vector" referred to the STL container class, not the grid. But it's fixed -- Ryan Patterson - <http://cgamesplay.com/> |
|