In my little Tic Tac Toe game, I'm making a message box pop up and say when the player wins, the computer wins, or if there is a draw. I specified SetDialogBoxMode(true) on initialization so my Direct3D application would allow dialog boxes, and then call my message box like so:
This starts out working fine, it comes up like it should and everything looks good. Then, the next time it should come up, it pops up but gets put behind my window. It still has keyboard focus, and when I move my mouse over it I see the standard windows mouse instead of my custom cursor, and it allows me to push the ok button, but I can't see the message box. This happens with all my message boxes that I call in game, all of which are like the one above with caption and body message changes.Code:MessageBox(hWnd, "Player wins!", "Congratulations!", MB_ICONEXCLAMATION | MB_TOPMOST | MB_SETFOREGROUND | MB_OK);
Is there any reason that my message boxes aren't showing up? The amount of times they work before I can no longer see them varies, ranging from 1 time to about 10.
I'm using DirectX 9.0 with Dev-C++.



LinkBack URL
About LinkBacks



?
.