Interface StorageProviderEntity
-
- All Known Subinterfaces:
AutomationResupplyRequired
- All Known Implementing Classes:
CrewEntity
,StorageProviderComposite
public interface StorageProviderEntity
Entities implementing StorageProviderEntity provide storage space (inventory). See also StorageEntitySupport which implements almost everything for your convencience.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description int
getEntityDef()
UUID
getParentCompositeEntity()
List<StorageItem>
getStorage()
int
getStorageAmount()
default int
getStorageAmount(int entityDefIdx)
default int
getStorageAmount(Predicate<Integer> predicate)
int
getStorageCapacity()
double
getStoredMass()
UUID
getUuid()
default boolean
hasInStock(int entityDefIdx, int amount)
default boolean
hasInStock(Predicate<Integer> predicate, int amount)
boolean
isStorageAdding()
boolean
isStorageEjecting()
boolean
isStorageTaking()
boolean
isStorageTransferring()
void
setStorage(List<StorageItem> storage)
void
setStorageAmount(int amount)
void
setStorageCapacity(int capacity)
void
setStoredMass(double storedMass)
int
storageAdd(int entityDefIdx, int amount)
void
storageEject()
void
storageEjectSingle(int entityDefIdx, int amount)
void
storageExplode()
int
storageTake(int entityDefIdx, int amount)
default boolean
storageTake(Predicate<Integer> predicate, int amount)
int
storageTransfer(StorageProviderEntity destination, int entityDefIdx, int amount)
-
-
-
Method Detail
-
storageAdd
int storageAdd(int entityDefIdx, int amount)
-
storageTake
int storageTake(int entityDefIdx, int amount)
-
storageTransfer
int storageTransfer(StorageProviderEntity destination, int entityDefIdx, int amount)
-
storageEject
void storageEject()
-
storageEjectSingle
void storageEjectSingle(int entityDefIdx, int amount)
-
storageExplode
void storageExplode()
-
isStorageAdding
boolean isStorageAdding()
-
isStorageTaking
boolean isStorageTaking()
-
isStorageTransferring
boolean isStorageTransferring()
-
isStorageEjecting
boolean isStorageEjecting()
-
getUuid
UUID getUuid()
-
getParentCompositeEntity
UUID getParentCompositeEntity()
-
getEntityDef
int getEntityDef()
-
getStorageAmount
int getStorageAmount()
-
setStorageAmount
void setStorageAmount(int amount)
-
getStorageCapacity
int getStorageCapacity()
-
setStorageCapacity
void setStorageCapacity(int capacity)
-
getStorage
List<StorageItem> getStorage()
-
setStorage
void setStorage(List<StorageItem> storage)
-
getStoredMass
double getStoredMass()
-
setStoredMass
void setStoredMass(double storedMass)
-
hasInStock
default boolean hasInStock(int entityDefIdx, int amount)
-
getStorageAmount
default int getStorageAmount(int entityDefIdx)
-
-