Exemplo n.º 1
0
        public override void CalcHitBBox()
        {
            var vl = Vel.Length() + _data.Radius + 0.05f;             //!! 0.05f = paranoia

            HitBBox.Left   = _state.Pos.X - vl;
            HitBBox.Right  = _state.Pos.X + vl;
            HitBBox.Top    = _state.Pos.Y - vl;
            HitBBox.Bottom = _state.Pos.Y + vl;
            HitBBox.ZLow   = _state.Pos.Z - vl;
            HitBBox.ZHigh  = _state.Pos.Z + vl;
            HitRadiusSqr   = vl * vl;
        }