3 float m_PercentageUsed = 0.05;
8 m_Name =
"#STR_CraftTannedLeather0";
52 Pelt_Base ingredient1 = Pelt_Base.Cast(ingredients[0]);
53 ItemBase ingredient2 = ingredients[1];
56 float yieldQuantity = ingredient1.ConfigGetFloat(
"leatherYield");
57 float qtyModifier = (4 - ingredient1.GetHealthLevel(
""))/4;
58 yieldQuantity =
Math.Clamp(yieldQuantity * qtyModifier,1,
float.
MAX);
60 float m_NeededQuantity = (ingredient2.GetQuantityMax() * m_PercentageUsed) * yieldQuantity;
61 if( ingredient1.ConfigGetFloat(
"leatherYield") >= 0 && ingredient2.GetQuantity() >= m_NeededQuantity)
73 ItemBase ingredient1 = ingredients[0];
76 int yieldQuantity = ingredient1.ConfigGetFloat(
"leatherYield");
77 float qtyModifier = ingredient1.GetHealth01(
"",
"Health");
78 yieldQuantity =
Math.Clamp(yieldQuantity * qtyModifier,1,
float.
MAX);
81 ItemBase gardenLime = ingredients[1];
82 float usedLime = (gardenLime.GetQuantityMax() * m_PercentageUsed) * yieldQuantity;
83 gardenLime.SetQuantity(gardenLime.GetQuantity() - usedLime);
87 MiscGameplayFunctions.GetHeadBonePos(player,posHead);
89 MiscGameplayFunctions.CreateItemBasePilesDispersed(
"TannedLeather",posHead,posTarget,
UAItemsSpreadRadius.NARROW,yieldQuantity,
float.MAX,player);
Result for an object found in CGame.IsBoxCollidingGeometryProxy.
bool m_IngredientUseSoftSkills[MAX_NUMBER_OF_INGREDIENTS]
float m_IngredientAddHealth[MAX_NUMBER_OF_INGREDIENTS]
float m_IngredientSetHealth[MAX_NUMBER_OF_INGREDIENTS]
const float DEFAULT_SPAWN_DISTANCE
float m_MinDamageIngredient[MAX_NUMBER_OF_INGREDIENTS]
float m_MaxQuantityIngredient[MAX_NUMBER_OF_INGREDIENTS]
bool m_AnywhereInInventory
void InsertIngredient(int index, string ingredient, DayZPlayerConstants uid=BASE_CRAFT_ANIMATION_ID, bool showItem=false)
float m_MaxDamageIngredient[MAX_NUMBER_OF_INGREDIENTS]
float m_IngredientAddQuantity[MAX_NUMBER_OF_INGREDIENTS]
float m_MinQuantityIngredient[MAX_NUMBER_OF_INGREDIENTS]
bool m_IngredientDestroy[MAX_NUMBER_OF_INGREDIENTS]
bool CanDo(PlayerBase player, TStringVectorMap surfaceTypes)
void Do(PlayerBase player)