x


Two Unity GUI questions

  1. Is there a way to parent GUI.Buttons/GUI.Boxes to an armature with an animation on it or turn them into GUITextures so that I can parent them with an armature?

  2. Is there a way to 'mask' GUI?

What I want to achieve is expressed in this image:

https://picasaweb.google.com/109558729139769464910/Mar122011#5583270749512512370

more ▼

asked Mar 12 '11 at 07:10 PM

Youngapprentice gravatar image

Youngapprentice
108 21 26 27

(comments are locked)
10|3000 characters needed characters left

2 answers: sort voted first

try drawing the button then on click get it transform across the screen. No animation involved just scripting

more ▼

answered Mar 13 '11 at 02:22 AM

AngryOldMan gravatar image

AngryOldMan
2.5k 12 21 47

(comments are locked)
10|3000 characters needed characters left
  1. If you want a GUI object to "follow" a transform you can use Camera.WorldToScreenPoint to get screen coordinates for that transforms position.
  2. Use GUI.BeginGroup and GUI.EndGroup. It will clip content outside of the group.
more ▼

answered Mar 13 '11 at 03:50 AM

Statement gravatar image

Statement ♦♦
20.1k 35 70 175

(comments are locked)
10|3000 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x5051
x3768
x3669

asked: Mar 12 '11 at 07:10 PM

Seen: 1201 times

Last Updated: Mar 12 '11 at 07:10 PM