Exemplo n.º 1
0
        /// <summary>
        ///     Test the specified gameobject.
        /// </summary>
        public override bool TestGameObject(LogicGameObject gameObject)
        {
            LogicComponent component = gameObject.GetComponent(this._componentType);

            if (component != null && component.IsEnabled())
            {
                return(base.TestGameObject(gameObject));
            }

            return(false);
        }
Exemplo n.º 2
0
        /// <summary>
        ///     Gets the specified component.
        /// </summary>
        public LogicComponent GetComponent(int componentType)
        {
            LogicComponent component = this._components[componentType];

            if (component != null && component.IsEnabled())
            {
                return(component);
            }

            return(null);
        }
        public virtual void FastForwardTime(int secs)
        {
            for (int i = 0; i < LogicComponent.COMPONENT_TYPE_COUNT; i++)
            {
                LogicComponent component = this.m_components[i];

                if (component != null && component.IsEnabled())
                {
                    component.FastForwardTime(secs);
                }
            }
        }
Exemplo n.º 4
0
        /// <summary>
        ///     Creates a fast forward of time.
        /// </summary>
        public virtual void FastForwardTime(int secs)
        {
            for (int i = 0; i < this._components.Count; i++)
            {
                LogicComponent component = this._components[i];

                if (component != null)
                {
                    if (component.IsEnabled())
                    {
                        component.FastForwardTime(secs);
                    }
                }
            }
        }