Ejemplo n.º 1
0
 public override void OnMouseUpdate(Vector2 currentPosition, Vector2 positionDelta, Vector2 rawDelta)
 {
     if (this.hoverable.IsHovered)
     {
         var result =
             this.sceneGraph.GetElementAt(
                 (int)MathF.Floor(currentPosition.Y / this.sceneGraphRenderer.font.LineSpacing));
         if (result.HasValue)
         {
             HoveredCrane = result.Value.crane;
         }
     }
     else
     {
         HoveredCrane = null;
     }
 }
Ejemplo n.º 2
0
        public CraneAgent(IStackingEnvironment world, ICrane crane, IDistribution <double> girderSpeed, IDistribution <double> hoistSpeed, IDistribution <double> manipulationTime)
        {
            _world           = world;
            _crane           = crane;
            GirderSpeed      = girderSpeed;
            HoistSpeed       = hoistSpeed;
            ManipulationTime = manipulationTime;

            _pendingMode          = Mode = CraneAgentMode.Work;
            State                 = CraneAgentState.Waiting;
            GoalPosition1         = GoalPosition2 = _crane.GirderPosition;
            _targetGirderPosition = _crane.GirderPosition;

            _lastUpdate  = world.Now;
            _mainProcess = world.Environment.Process(Main());

            WhenPickupOrDropoffQueue = new List <Event>();
        }
Ejemplo n.º 3
0
 public void move(ICrane element)
 {
     element.Ropelength = element.Ropelength + 0.2f;
 }   
Ejemplo n.º 4
0
 public SceneGraphNode(int depth, ICrane data)
 {
     this.depth       = depth;
     this.crane       = data;
     this.displayName = data.ToString().Split('/')[^ 1];
Ejemplo n.º 5
0
 public void move(ICrane element)
 {
     // rotating against the clock is positive
     // https://www.mathebibel.de/drehmatrix
     element.Drehwinkel = element.Drehwinkel + 5;
 }
Ejemplo n.º 6
0
 public void move(ICrane element)
 {
     element.Ropeposition = element.Ropeposition - 0.05f;
 }
Ejemplo n.º 7
0
 public void move(ICrane element)
 {
     // rotating with the clock is negative
     // https://www.mathebibel.de/drehmatrix
     element.Rotationangle = element.Rotationangle - 5;
 }
Ejemplo n.º 8
0
 public void move(ICrane element)
 {
     // rotating against the clock is positive
     // https://www.mathebibel.de/drehmatrix
     element.Rotationangle = element.Rotationangle + 5;
 }
Ejemplo n.º 9
0
 public void move(ICrane element)
 {
     // rotating with the clock is negative
     // https://www.mathebibel.de/drehmatrix
     element.Drehwinkel = element.Drehwinkel - 5;
 }