x


Changing the order of Components

In some cases the order affects the end result. For instance when stacking a blur on a noise, or the other way around. Does Unity have an ability to change the order? I've been looking around in the docs and Google, but couldn't find it. I was even a bit surprised that I couldn't find anything :)

more ▼

asked Oct 27 '10 at 03:34 PM

Jordii gravatar image

Jordii
158 9 11 17

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

4 answers: sort voted first

Aside from removing components and applying them in a different order, no, unfortunately there's no way.

more ▼

answered Oct 27 '10 at 05:55 PM

Eric5h5 gravatar image

Eric5h5
80.3k 42 132 521

Thanks Eric. It's quite odd though right. Say if for instance I'd have a component with a whole lot of values customized just the way I want, but then decide it would be better to have a motion blur in front. Then I would have to copy all the values in notepad or something, remove it, and add it again. It almost feels like I'm missing something, cause it'll be such a simple feature to implement.

Oct 28 '10 at 09:27 AM Jordii

yes, I also think this is not very good that we can't reorder as you progress through the project.

Oct 28 '10 at 02:31 PM Jean Fabre

if you use EZ GUI, i think order of components may also affect its ability to function correctly. Reordering components would be a welcome feature for general usability anyway.

Mar 16 '11 at 11:50 PM sampenguin

Yes, it's quite irritating really. I use (the excellent) EZ GUI and connecting scripts to functions can be a pane because Unity just takes the first script.

Jul 26 '11 at 12:03 PM Bovine

In the case of EZ GUI, you can actually open a second inspector tab to help with that. Set one to the object containing the script you want to connect, the other to the object with the parameter you want to connect it to (you'll have to lock one of the inspector tabs). Then you can drag the script from the object to the connection point, and it'll do what you want it to.

Apr 18 '12 at 02:58 PM krdluzni
(comments are locked)
10|3000 characters needed characters left

Since Unity 4, you can move components up and down by right-clicking on them (or clicking on the small gear in the right corner) and selecting the appropriate option in the context menu that is popping up.

more ▼

answered Nov 13 '12 at 11:15 PM

vwekker gravatar image

vwekker
31

Can we do this programmatically? Like sorting components by a property value?

Jan 31 at 02:30 PM chirpytime
(comments are locked)
10|3000 characters needed characters left

Found this one on the Asset Store for 2 bucks / seat:

http://u3d.as/content/man-on-edge/component-reorder/2Zb

more ▼

answered Oct 17 '12 at 02:53 AM

petrucio gravatar image

petrucio
66 1 2

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

I don't know how well this would work but what about having the components set up with a noise, a blur, then another noise. a script could turn off the first one and activate the last noise; possibly giving the effect of it changing?

more ▼

answered Nov 14 '12 at 12:13 AM

venhip gravatar image

venhip
167 7 13 16

(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:

x302
x57

asked: Oct 27 '10 at 03:34 PM

Seen: 3179 times

Last Updated: Jan 31 at 02:30 PM