Showing/Hiding User Interface panels


So I’m looking to show/hide popup menus and interface items like journals, tooltips, maps, etc, but I’m not sure how to go about it exactly. My thought is that I can have the object in question lurking on a different layer, then call it to the playable layer on demand, then send it back when it’s not needed, but I don’t know where to look for how to do that. It might be best handled with a Python script, but while I can code, I’m not familiar enough with Python (and the BGE’s capabilites with it) to just magic something out of thin air.

For an example, imagine that you’re in 3rd person follow view and you want to look up a journal with details on…anything, it’s just a book object with a lot of text, maybe an image or two. I want to hit a key and have that book move from layer 2 (where my props are) to layer 1 (where my character is) and always display it with the pages facing the camera.

If anyone has some guidance, I’d greatly appreciate it.

In GE you can’t move things from hidden layers. But you can add instances of objects that are stored on hidden layers.

You can achive this with an forground/background scenes. There is an actuator for that.

Thanks! I gave it a try and it seems like that’ll work for what I want to do, though I have some fine tuning to take care of.

An overlay scene would work for what you want to do… though it’d be more efficient to have all panels on one scene, then hide them by either A) making them invisible or B) animating them off of the screen.


That does sound like a better option–my game isn’t big enough to worry about it yet, but my guess is that changing scenes might get pretty resource intensive when one or both scenes has a lot of objects and details.

Of course, now it’s time to tackle how to make things invisible, hehe. Thanks for the suggestions.