Ignore virtual display size (SOLVED)

Is there a way to ingore virtual display size when using GUI?

I want to position my gui elements based on device’s real size.

UPD: Solution: 1, 2

Maybe there is another way to bind gui nodes to game objects or to real display resolution?

Check this answer: Gui in game object

Thank you, but if I use standart render script, then my game objects become stretched. I tried to replace

render.set_projection(vmath.matrix4_orthographic(0, render.get_width(), 0, render.get_height(), -1, 1))
render.draw(self.tile_pred)
render.draw(self.particle_pred)

with

render.set_projection(vmath.matrix4_orthographic(0, render.get_window_width(), 0, render.get_window_height(), -1, 1))
render.draw(self.tile_pred)
render.draw(self.particle_pred)

Is that a good solution for adaptive game or there are any better options?
Also still if try to place 1 game object and 1 gui node in the same position (using get_window_size()), finally there are in the different places.

UPD:

set the Adjust Mode of a gui scene from Per Node to Disable

This helps me :slight_smile: Where I can read information about this option?

1 Like

You can read about adjust mode here

1 Like

But there is no info about Per Node/Disabled or I can’t find it.

I think the assumption is that when it is disabled, no adjustment is being done. @sicher can correct me if I’m wrong?

Also, you can add suggestions to the documentation directly to the documentation page, e.g. “Please add some more info about the Per Node/Disabled options on gui”

1 Like