Class LiftHoist

java.lang.Object
megamek.common.equipment.ExternalCargo
megamek.common.equipment.LiftHoist
All Implemented Interfaces:
Serializable, Transporter

public class LiftHoist extends ExternalCargo
Transporter for Lift Hoists as described TW p. 136
See Also:
  • Constructor Details

    • LiftHoist

      public LiftHoist(Mounted<?> mounted, double tonnage)
  • Method Details

    • getUnused

      public double getUnused()
      Specified by:
      getUnused in interface Transporter
      Overrides:
      getUnused in class ExternalCargo
      Returns:
      the number of unused spaces in this transporter.
    • canLoad

      protected boolean canLoad()
      If this specific transporter is capable of loading regardless of what the object is. LiftHoists are only able to load if they are operable and not carrying anything else.
      Overrides:
      canLoad in class ExternalCargo
      Returns:
      true if the transporter is capable of loading, false otherwise.
    • canLoad

      public boolean canLoad(Entity unit)
      Determines if this object can accept the given unit. The unit may not be of the appropriate type or there may be no room for the unit.
      Specified by:
      canLoad in interface Transporter
      Overrides:
      canLoad in class ExternalCargo
      Parameters:
      unit - - the Entity to be loaded.
      Returns:
      true if the unit can be loaded, false otherwise.
    • canLoadCarryable

      public boolean canLoadCarryable(ICarryable carryable)
      Determines if this object can accept the given ICarryable. The carryable may not be of the appropriate type or there may be no room for the unit.
      Overrides:
      canLoadCarryable in class ExternalCargo
      Parameters:
      carryable - the ICarryable to be loaded
      Returns:
      true if the carryable can be loaded, false otherwise.
    • getTransporterType

      public String getTransporterType()
    • canPickupGroundObject

      public boolean canPickupGroundObject()
      Returns true if the transporter can pick up ground objects
    • alwaysDamageCargoIfTransportHit

      public boolean alwaysDamageCargoIfTransportHit()
      Returns true if the transporter damages its cargo if the transport is hit, otherwise false.