示例#1
0
文件: Spawn.cs 项目: Zamir7/urho
		public Spawn (params FiniteTimeAction[] actions)
		{
			FiniteTimeAction prev = actions [0];
			FiniteTimeAction next = null;

			if (actions.Length == 1)
			{
				next = new ExtraAction ();
			}
			else
			{
				// We create a nested set of SpawnActions out of all of the actions
				for (int i = 1; i < actions.Length - 1; i++)
				{
					prev = new Spawn (prev, actions [i]);
				}

				next = actions [actions.Length - 1];
			}

			// Can't call base(duration) because we need to determine max duration
			// Instead call base's init method here
			if (prev != null && next != null)
			{
				Duration = Math.Max (prev.Duration, next.Duration);
				InitSpawn (prev, next);
			}
		}
示例#2
0
文件: Spawn.cs 项目: yrest/urho
        public Spawn(params FiniteTimeAction[] actions)
        {
            FiniteTimeAction prev = actions [0];
            FiniteTimeAction next = null;

            if (actions.Length == 1)
            {
                next = new ExtraAction();
            }
            else
            {
                // We create a nested set of SpawnActions out of all of the actions
                for (int i = 1; i < actions.Length - 1; i++)
                {
                    prev = new Spawn(prev, actions [i]);
                }

                next = actions [actions.Length - 1];
            }

            // Can't call base(duration) because we need to determine max duration
            // Instead call base's init method here
            if (prev != null && next != null)
            {
                Duration = Math.Max(prev.Duration, next.Duration);
                InitSpawn(prev, next);
            }
        }
示例#3
0
			public ExtraActionState (ExtraAction action, Node target)
				: base (action, target)
			{
			}
示例#4
0
 public ExtraActionState(ExtraAction action, Node target)
     : base(action, target)
 {
 }