예제 #1
0
        /// <summary>
        /// Get a list of the player's types.
        /// </summary>
        private ValueDropdownList <string> GetStateTypes()
        {
            ValueDropdownList <string> types = new ValueDropdownList <string>();

            foreach (Type t in PoseClip.GetSubtypesOfTypeInAssembly("HumanBuilders", typeof(PlayerState)))
            {
                string typeName = t.ToString();

                string[] subs       = typeName.Split('.');
                string   simpleName = subs[subs.Length - 1];
                string   letter     = ("" + simpleName[0]).ToUpper();

                string folder = letter + "/" + simpleName;

                types.Add(new ValueDropdownItem <string>(folder, typeName));
            }

            return(types);
        }
예제 #2
0
        public override Playable CreateTrackMixer(PlayableGraph graph, GameObject go, int inputCount)
        {
            ScriptPlayable <PlayerCharacterTrackMixer> mixerScript = ScriptPlayable <PlayerCharacterTrackMixer> .Create(graph, inputCount);

            PlayerCharacterTrackMixer mixer = mixerScript.GetBehaviour();

            mixer.Outro = Outro;

            foreach (TimelineClip clip in GetClips())
            {
                PoseClip poseClip = clip.asset as PoseClip;
                if (poseClip != null)
                {
                    poseClip.SetClip(clip);
                }
            }

            return(mixerScript);
        }