- Home /
Is this the best way to access the Megafiers Morph Channels Dynamically
Is this the best way to access the Megafiers Morph Channels Dynamically at runtime?
(MegaMorph)this.GetComponent("MyMorphObject")).chanBank[X].Percent
Cheers
Comment
Answer by SpookyCat · Jan 02, 2012 at 11:13 AM
Best way would be to cache the component so you dont have to use GetComponent each time ie. if ( morph == null ) morph = (MegaMorph)this.GetComponent("MyMorphObject");
then use morph
Your answer
![](https://koobas.hobune.stream/wayback/20220613062241im_/https://answers.unity.com/themes/thub/images/avi.jpg)