A new GUI

Okay my first smart idea for DRAW’s GUI was to just use unity’s in game GUI system. I mean it was there and is powerful so why not?

first time i re-sized the screen i found out why using absolute values with the default system was a bad idea, buttons quickly flew off the screen and others swapped crossed into the opposite side of the screen.

So i though right to fix this i will make all button sizes and positons relative to the screen width and height.

This worked well but when i got into the game i realized a problem.

There a a couple of  GUI items that need to rotate and while you can rotate them around the z-axis it is very difficult if not impossible to rotate them around the y axis (which i needed).

So plan 2 (thanks to Bernardo) have the GUI elements as 3d objects parented to the camera. you can rotate them where ever you like and don’t have to worry about positions as relative to the screen.

the only down side is anything behind these items cannot be a GUI element as they are automatically drawn on top if everything so they all have to be 3d elements as well.

Once that was sorted out I was left with the following GUI which is slowly becoming more and more complete.

Tagged ,

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: