예제 #1
0
        public SimulationVisualElevatorEntrance3D(IWaypointInfo elevator, DetailLevel detailLevel)
            : base(elevator)
        {
            _elevator = elevator;
            var visual = new BoxVisual3D
            {
                Fill   = VisualizationConstants.BrushElevatorEntranceVisual,
                Center = new Point3D(
                    _elevator.GetInfoCurrentTier().GetInfoTLX() + _elevator.GetInfoCenterX(),
                    _elevator.GetInfoCurrentTier().GetInfoTLY() + _elevator.GetInfoCenterY(),
                    _elevator.GetInfoCurrentTier().GetInfoZ() + ELEVATOR_HEIGHT / 2.0
                    ),
                Length = _elevator.GetInfoLength() * SIZE_FACTOR,
                Width  = _elevator.GetInfoWidth() * SIZE_FACTOR,
                Height = ELEVATOR_HEIGHT
            };

            Children.Add(visual);
        }
예제 #2
0
        public SimulationVisualWaypoint3D(IWaypointInfo waypoint, DetailLevel detailLevel)
            : base(waypoint)
        {
            _waypoint = waypoint;
            var visual = new SphereVisual3D
            {
                Fill   = VisualizationConstants.BrushWaypointVisual,
                Center = new Point3D(waypoint.GetInfoCenterX(), waypoint.GetInfoCenterY(), waypoint.GetInfoCurrentTier().GetInfoZ() + WAYPOINT_LIFT),
                Radius = waypoint.GetInfoLength() / 2.0
            };

            Children.Add(visual);
            // Add connections to other ones (if detailed drawing mode)
            //foreach (var otherWP in waypoint.GetInfoConnectedWaypoints())
            //{
            //    // TODO draw connection to other wp
            //}
        }