If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Thomaskkc
Posts: 134 Joined: Fri Sep 15, 2006 4:04 pm
Post
by Thomaskkc » Wed Sep 27, 2006 5:38 am
i'd like to ask why a use the function getGUIEnvironment()
the .exe will have error?
just only use the code
IGUIEnvironment* env = Device->getGUIEnvironment();
Thanks
zeno60
Posts: 342 Joined: Sun May 21, 2006 2:48 am
Location: NC, USA
Contact:
Post
by zeno60 » Wed Sep 27, 2006 5:51 am
Are you sure it is this specific line that is giving you the error? If so, what is the error and is it a comile or run-time error?
Thomaskkc
Posts: 134 Joined: Fri Sep 15, 2006 4:04 pm
Post
by Thomaskkc » Wed Sep 27, 2006 6:47 am
when i comment this line, it can run
when add this line, when it exe the file,
it has run timwe error
slang
Posts: 6 Joined: Wed Sep 27, 2006 6:34 am
Post
by slang » Wed Sep 27, 2006 6:51 am
show the block of code around where you insert that line...
Thomaskkc
Posts: 134 Joined: Fri Sep 15, 2006 4:04 pm
Post
by Thomaskkc » Wed Sep 27, 2006 6:55 am
if (node)
{
node->setMaterialFlag(EMF_LIGHTING, false);
}
IGUIEnvironment* env = Device->getGUIEnvironment();
IGUIToolBar* bar = env->addToolBar();
hybrid
Admin
Posts: 14143 Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:
Post
by hybrid » Wed Sep 27, 2006 7:59 am
It's strange that the next line does still work when commenting the getEnvironment! This should lead to a crash upon null dereferencing. Anyway, yre you sure that Driver is properly instantiated?