It does this for all my 4 potions.
I don't think it's a case sensitive error as the item can be added in the editor picked up/thrown/put in the inventory/used in the inventory/used in the hand. So the right icon is already known by the engine.
I commented the line with the custom gfxAtlas and the potion had the icon of a mace and I was able to create it with the mortar.
So I think it's an engine limitation that don't recognize custom gfxAtlas when creating potions
Code: Select all
defineObject{
name = "potion_shock_shield",
baseObject = "base_item",
components = {
{
class = "Model",
model = "assets/models/items/flask.fbx",
},
{
class = "Item",
uiName = "Shock Shield Potion",
gfxAtlas = "mod_assets/textures/gui/EarthFireIceShock_Shield_Potions.dds",
gfxIndex = 3,
weight = 0.3,
stackable = true,
traits = { "potion" },
},
{
class = "UsableItem",
sound = "consume_potion",
onUseItem = function(self, champion)
champion:setCondition("shock_shield")
end,
},
},
tags = { "custom_vieuxchat" },
}
defineObject{
name = "potion_ice_shield",
baseObject = "base_item",
components = {
{
class = "Model",
model = "assets/models/items/flask.fbx",
},
{
class = "Item",
uiName = "Ice Shield Potion",
gfxAtlas = "mod_assets/textures/gui/EarthFireIceShock_Shield_Potions.dds",
gfxIndex = 2,
weight = 0.3,
stackable = true,
traits = { "potion" },
},
{
class = "UsableItem",
sound = "consume_potion",
onUseItem = function(self, champion)
champion:setCondition("frost_shield")
end,
},
},
tags = { "custom_vieuxchat" },
}
defineObject{
name = "potion_fire_shield",
baseObject = "base_item",
components = {
{
class = "Model",
model = "assets/models/items/flask.fbx",
},
{
class = "Item",
uiName = "Fire Shield Potion",
gfxAtlas = "mod_assets/textures/gui/EarthFireIceShock_Shield_Potions.dds",
gfxIndex = 1,
weight = 0.3,
stackable = true,
traits = { "potion" },
},
{
class = "UsableItem",
sound = "consume_potion",
onUseItem = function(self, champion)
champion:setCondition("fire_shield")
end,
},
},
tags = { "custom_vieuxchat" },
}
defineObject{
name = "potion_earth_shield",
baseObject = "base_item",
components = {
{
class = "Model",
model = "assets/models/items/flask.fbx",
},
{
class = "Item",
uiName = "Earth Shield Potion",
gfxAtlas = "mod_assets/textures/gui/EarthFireIceShock_Shield_Potions.dds",
gfxIndex = 0,
weight = 0.3,
stackable = true,
traits = { "potion" },
},
{
class = "UsableItem",
sound = "consume_potion",
onUseItem = function(self, champion)
champion:setCondition("poison_shield")
end,
},
},
tags = { "custom_vieuxchat" },
}
Owww.... I found this :
It seems it's the same error and it lasts for a year long. It's not encouraging