hi,
In nearly every game you come to the Options by using ESC. I had testet a lot. Now, if I push ESC the Option comes, but In the background the play runs and the coursor is in the middle of the window. What can I do, to rotate with the coursor how I want. And the play dont recognice it.
how can I stop the game and preload it later on
-
- Posts: 12
- Joined: Wed Mar 28, 2007 11:53 am
-
- Posts: 12
- Joined: Wed Mar 28, 2007 11:53 am
thanks, but I have a new problem:
I have addet scene::ICameraSceneNode* camera = 0; so that there are no more problems.
But, when I start the game and klick on ESC the error is:
Demo.exe hat ein Problem festgestellt und muss beendet werden.
Demo.exe had found a problem and must be end.
here I dont know, what to do
I have addet scene::ICameraSceneNode* camera = 0; so that there are no more problems.
But, when I start the game and klick on ESC the error is:
Demo.exe hat ein Problem festgestellt und muss beendet werden.
Demo.exe had found a problem and must be end.
here I dont know, what to do
-
- Posts: 12
- Joined: Wed Mar 28, 2007 11:53 am
thx
now I have this code:
but nothing happens.
In the demo I can go around with the coursor but nothing happens, when I click on the Button.
In the game there is no unpausing, like it should be
(srry my english is so terrible)
now I have this code:
Code: Select all
if (event.EventType == EET_KEY_INPUT_EVENT &&
event.KeyInput.Key == KEY_ESCAPE &&
event.KeyInput.PressedDown == false)
{
scene::ICameraSceneNode* camera = 0;
scene::ISceneManager* scenemanager = device->getSceneManager();
camera=scenemanager->getActiveCamera();
IGUIEnvironment* guienvironment = device->getGUIEnvironment();
IGUIWindow* wnd = guienvironment ->addWindow(rect<s32>(100,100,300,200),false,L"Optionen");
guienvironment -> addStaticText(L"Wollen sie das\n Spiel wirklich beenden?",rect<s32>(50,30,350,350),false,true,wnd);
BeendenButton = guienvironment->addButton(core::rect<int>(14, 15,100,50), false, 1, L"Beenden");
device->getCursorControl()->setVisible(true);
camera->setInputReceiverEnabled(true);
}
else
if (event.GUIEvent.EventType == gui::EGET_BUTTON_CLICKED )
{
device->closeDevice();
start = false;
}
In the demo I can go around with the coursor but nothing happens, when I click on the Button.
In the game there is no unpausing, like it should be
(srry my english is so terrible)
What does your main loop look like? It might be that your are forgetting to draw the gui
Code: Select all
guienvironment->drawAll();
If you don't have anything nice to say, don't say anything at all.