예제 #1
0
        public void ChangePosition(float d_x, float d_y, float d_z)
        {
            byte flag = 0;

            if (d_x != 0)
            {
                flag    = BitFlag.AddByteFlag(flag, 0);
                this.x += d_x;
            }
            if (d_y != 0)
            {
                flag    = BitFlag.AddByteFlag(flag, 1);
                this.y += d_y;
            }
            if (d_z != 0)
            {
                flag    = BitFlag.AddByteFlag(flag, 2);
                this.z += d_z;
            }
            if (flag != 0)
            {
                battle.recorder.PushPosition(this, flag);
            }
        }
예제 #2
0
        public void SetPosition(float _x, float _y, float _z)
        {
            byte flag = 0;

            if (_x != this.x)
            {
                flag   = BitFlag.AddByteFlag(flag, 0);
                this.x = _x;
            }
            if (_y != this.y)
            {
                flag   = BitFlag.AddByteFlag(flag, 1);
                this.y = _y;
            }
            if (_z != this.z)
            {
                flag   = BitFlag.AddByteFlag(flag, 2);
                this.z = _z;
            }
            if (flag != 0)
            {
                battle.recorder.PushPosition(this, flag);
            }
        }