Ejemplo n.º 1
0
    // Equipment is on the dock, decides what type of fish the boat can get
    // equiement is a worker on the dock and gets assigned to boats to give them a resource destination
    // cannot start until equipment is assigned

    public void SetEquipment(FMEquipment equipment)
    {
        m_BoatSlots.UnassignEquipment(m_AssignedEquipment);
        m_BoatSlots.AssignEquipment(equipment);

        m_AssignedEquipment = equipment;
        Tutorial.GetOrCreateInstance().HasAssignedEquipmentToBoat = true;
    }
Ejemplo n.º 2
0
 public void AssignEquipment(FMEquipment equipment)
 {
     if (equipment)
     {
         equipment.transform.SetParent(m_EquipmentSlot.m_Transform, false);
         equipment.transform.localPosition = Vector3.zero;
     }
 }
Ejemplo n.º 3
0
 public void UnassignEquipment(FMEquipment equipment)
 {
     if (equipment != null)
     {
         var stagingArea = FMBoardReferences.GetOrCreateInstance().m_EquipmentStagingArea;
         stagingArea.AddToStaging(equipment.transform);
     }
     m_EquipmentSlot.m_AssignedObject = null;
 }