I gave you a hint right in my first post. Can't you read or something?Is there a way to get the masterparent of all gui elements?
How can I get a text from textinput only knowing the id?
-
- Posts: 18
- Joined: Sat Nov 17, 2007 11:34 am
Okay... sorry didn't read the first post again...
but I have this code:
MASTERPARENT() returns getRootElement()
I lookd into the watch and elem has a good value.
elem2 however doesn't.
I don't get it... nameid has 106 code. And there is a textinput with 106 code entered. Is there any bug? am I not using it correctly??
but I have this code:
Code: Select all
IGUIElement* elem = game.INTF()->MASTERPARENT();
IGUIElement* elem2 = elem->getElementFromId(nameid);
I lookd into the watch and elem has a good value.
elem2 however doesn't.
I don't get it... nameid has 106 code. And there is a textinput with 106 code entered. Is there any bug? am I not using it correctly??
-
- Posts: 18
- Joined: Sat Nov 17, 2007 11:34 am
Just to be sure you still could try setting the second parameter to true like Vitek proposed. But I would rather suspect your game object, your INTF() function or your MASTERPARENT() function as I know about none of those.
When searching for bugs you should try to reduce the problem to the minimum before looking for help from others. There are obviously still a few layers of code which you don't post here and so we are all guessing around.
Try to reduce your problem to a short problem which you can post here completly. There's always a good chance you find the bug yourself while doing so :-)
When searching for bugs you should try to reduce the problem to the minimum before looking for help from others. There are obviously still a few layers of code which you don't post here and so we are all guessing around.
Try to reduce your problem to a short problem which you can post here completly. There's always a good chance you find the bug yourself while doing so :-)
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm