Пример #1
0
        //draw
        public void Draw(ActionObject aco)
        {
            GUILayout.BeginVertical();
            GUILayout.Label("****************** event ******************");
            if (GUILayout.Button("- Event"))
            {
                aco.m_Events.Remove(this);
            }

            float rateTime = time / aco.m_Time;

            TimeLine(rateTime);
            rateTime = GUILayout.HorizontalSlider(rateTime, 0, 1f, GUILayout.Width(window_size.x));
            time     = aco.m_Time * rateTime;

            {
                GUILayout.BeginHorizontal();
                GUILayout.Label("sound");
                this.sound = GUILayout.TextField(this.sound);
                GUILayout.Label("time");
                this.time = EditorGUILayout.FloatField(this.time);
                GUILayout.EndHorizontal();
            }
            {
                hit.Draw();
            }
            {
                effect.Draw();
            }
            {
                GUILayout.BeginVertical();
                GUILayout.Label("------------------- Message -------------------");
                if (GUILayout.Button("+ Message"))
                {
                    Message msg = new Message();
                    this.messages.Add(msg);
                }
                for (int i = 0; i < messages.Count; i++)
                {
                    messages[i].Draw(this);
                }
                GUILayout.EndVertical();
            }
            GUILayout.EndVertical();
        }