public void CopyFrom(EntityInfo obj)
{
if (null != obj) {
Object = obj;
Position = obj.GetMovementStateInfo().GetPosition3D();
Radius = obj.GetRadius();
MaxX = Position.X + Radius;
MinX = Position.X - Radius;
MaxZ = Position.Z + Radius;
MinZ = Position.Z - Radius;
Indexed = false;
} else {
Object = null;
Position = new Vector3();
Radius = 0;
MaxX = MinX = 0;
MaxZ = MinZ = 0;
Indexed = false;
}
}
static public int CopyFrom(IntPtr l) { try { GameFramework.KdTreeObject self = (GameFramework.KdTreeObject)checkSelf(l); GameFramework.EntityInfo a1; checkType(l, 2, out a1); self.CopyFrom(a1); pushValue(l, true); return(1); } catch (Exception e) { return(error(l, e)); } }