31 #include "packets/Manufacturing.h"
40 m_parentBlueprintType(_parentBlueprintType),
41 m_productType(_productType)
52 return ItemType::Load<BlueprintType>(typeID);
68 return InventoryItem::Load<Blueprint>(blueprintID);
83 if (bpType ==
nullptr)
108 if (bRef.
get() ==
nullptr)
116 bRef->SaveBlueprint();
140 Rsp_GetBlueprintAttributes rsp;
145 rsp.licensedProductionRunsRemaining =
m_data.
runs;
146 rsp.wastageFactor =
GetME();
virtual InventoryItemRef Split(int32 qty=0, bool notify=true, bool silent=false)
uint32 researchTechTime() const
const ItemType & m_productType
#define _log(type, fmt,...)
static uint32 CreateItemID(ItemData &data, EvERam::bpData &bdata)
PyDict * GetBlueprintAttributes()
Blueprint(uint32 _blueprintID, const BlueprintType &_bpType, const ItemData &_data, EvERam::bpData &_bpData)
virtual bool Merge(InventoryItemRef to_merge, int32 qty=0, bool notify=true)
BlueprintRef SplitBlueprint(int32 qty_to_take, bool notify=true)
uint32 maxProductionLimit() const
static BlueprintRef Load(uint32 blueprintID)
EvERam::bpTypeData m_data
uint32 researchCopyTime() const
static bool DeleteBlueprint(uint32 blueprintID)
BlueprintType(uint16 _id, const Inv::TypeData &_data, const BlueprintType *_parentBlueprintType, const ItemType &_productType, const EvERam::bpTypeData &_tData)
uint32 productionTime() const
const BlueprintType & m_bpType
uint16 wasteFactor() const
static bool SaveBlueprintData(uint32 blueprintID, EvERam::bpData &data)
uint16 parentBlueprintTypeID
const BlueprintType * m_parentBlueprintType
RefPtr< Blueprint > BlueprintRef
static RefPtr StaticCast(const RefPtr< Y > &oth)
Acts as static_cast from one RefPtr to another.
virtual bool Merge(InventoryItemRef to_merge, uint32 qty=0, bool notify=true)
static BlueprintRef Spawn(ItemData &data, EvERam::bpData &bdata)
uint32 researchMaterialTime() const
static uint32 CreateItemID(ItemData &data)
static bool DeleteItem(uint32 itemID)
static BlueprintType * Load(uint16 typeID)
uint32 researchProductivityTime() const
uint16 productTypeID() const
Reference-counting-based smart pointer.