コード例 #1
0
 protected override void RenderUpdate()
 {
     if (!Application.isPlaying)
     {
         lossyScale = FPVector.Abs(transform.lossyScale.ToFPVector());
     }
 }
コード例 #2
0
 public void Update()
 {
     if (!Application.isPlaying)
     {
         lossyScale = FPVector.Abs(transform.lossyScale.ToFPVector());
     }
 }
コード例 #3
0
        /**
         *  @brief Creates a new {@link FPRigidBody} when there is no one attached to this GameObject.
         **/
        protected override void OnAwake()
        {
            FPTransform = this.GetComponent <FPTransform2D>();
            FPRigidBody = this.GetComponent <FPRigidBody2D>();

            if (lossyScale == FPVector.one)
            {
                lossyScale = FPVector.Abs(transform.localScale.ToFPVector());
            }
        }
コード例 #4
0
        /**
         *  @brief Creates a new {@link FPRigidBody} when there is no one attached to this GameObject.
         **/
        public void Awake()
        {
            FPTransform = this.GetComponent <FPTransform>();
            FPRigidBody = this.GetComponent <FPRigidBody>();

            if (lossyScale == FPVector.one)
            {
                lossyScale = FPVector.Abs(transform.localScale.ToFPVector());
            }
        }