I'm trying to add a new material to the forge. I've set up a new forge block that has the materials in its item list (see InputMaterials property):
<block name="masterForge">
<property name="Class" value="Forge"/>
<property name="UnlockedBy" value="masterForgeSchematic"/>
<property name="Material" value="Mstone_scrap"/>
<property name="MaxDamage" value="20000"/>
<property name="StabilitySupport" value="true"/>
<property name="Weight" value="0"/>
<property name="Shape" value="ModelEntity"/>
<property name="Path" value="solid"/>
<property name="Model" value="Entities/Crafting/forgePrefab"/>
<property name="CustomIcon" value="forge"/>
<property name="CustomIconTint" value="9E70BB"/>
<property name="CustomTint" value="9E70BB"/>
<property name="TintColor" value="158,112,187"/>
<property name="Place" value="TowardsPlacerInverted"/>
<property name="OnlySimpleRotations" value="true"/>
<property name="IsTerrainDecoration" value="true"/>
<property name="ParticleName" value="forge"/>
<property name="ParticleOffset" value="0.5,0,0.5"/>
<property name="ImposterDontBlock" value="true"/>
<property name="Stacknumber" value="1"/>
<property name="HeatMapStrength" value="6"/>
<property name="HeatMapTime" value="5000"/>
<property name="HeatMapFrequency" value="1000"/>
<property name="BuffsWhenWalkedOn" value="buffBurningEnvironment"/>
<property name="ActiveRadiusEffects" value="buffCampfireAOE(5)"/>
<property class="Workstation">
<property name="CraftingAreaRecipes" value="forge"/>
<property name="Modules" value="tools,output,fuel,material_input"/>
<property name="InputMaterials" value="iron,brass,lead,glass,stone,clay,mythril,adamantite"/>
</property>
<property name="WorkstationIcon" value="ui_game_symbol_forge"/>
<property name="OpenSound" value="forge_open"/>
<property name="CloseSound" value="forge_close"/>
<property name="CraftSound" value="forge_smelt_click"/>
<property name="CraftCompleteSound" value="forge_item_complete"/>
<property name="WorkstationJournalTip" value="forgeTip"/>
<property class="RepairItems">
<property name="resourceRockSmall" value="50"/>
<property name="resourceClayLump" value="60"/>
<property name="resourceLeather" value="20"/>
</property>
<drop event="Harvest" name="resourceRockSmall" count="40" tag="allHarvest"/>
<drop event="Harvest" name="resourceClayLump" count="20" tag="allHarvest"/>
<drop event="Harvest" name="resourceLeather" count="5" tag="allHarvest"/>
<drop event="Destroy" count="0"/>
<drop event="Fall" name="terrDestroyedStone" count="1" prob="0.75" stick_chance="1"/>
<property name="TakeDelay" value="15"/>
<property name="Group" value="Building,advBuilding"/>
<property name="DescriptionKey" value="forgeDesc"/>
<property name="EconomicValue" value="1000"/>
<property name="FilterTags" value="MC_playerBlocks,SC_decor"/>
<property name="SortOrder1" value="70i0"/>
</block>
This made the game crash whenever I looked at the forge until I used xpath to alter windows.xml to add two more rows to the grid in the content2 section of windowForgeInput (bringing the rows to 8).
<window name="windowForgeInput" width="228" height="204" panel="Right"
controller="WorkstationMaterialInputWindow" materials_accepted="iron,brass,lead,glass,stone,clay" valid_materials_color="[green]" invalid_materials_color="[red]" cursor_area="true" >
<panel style="header.panel">
<sprite style="header.icon" sprite="ui_game_symbol_forge"/>
<label style="header.name" text="INPUT" text_key="xuiSmelting" />
</panel>
<sprite depth="2" name="backgroundMain" sprite="menu_empty3px" pos="0,-46" height="228" color="[black]" type="sliced" fillcenter="false" on_press="true" />
<rect name="content" depth="1" pos="0,-46" height="228">
<grid depth="7" rows="3" cols="1" pos="3,-3" cell_width="75" cell_height="75" controller="WorkstationMaterialInputGrid" repeat_content="true">
<item_stack name="0"/>
</grid>
</rect>
<rect name="content2" depth="0" pos="78, -49" width="147" height="223">
<sprite depth="1" color="[mediumGrey]" type="sliced" on_press="true"/>
<grid rows="8" cols="1" pos="3,-3" cell_width="147" cell_height="24" repeat_content="true">
<forge_material name="0"/>
</grid>
</rect>
</window>
So now I can open the masterForge and it will show all the normal materials plus Mythril and Adamantite. But when I try to melt items made of those materials and scrappable into those materials in the forge, they count down as usual but then nothing happens and the item remains. Has anyone messed with adding items to forges before? I know I have seen it done on other servers but I don't have access to their xml to see how they did it and learn from their alterations.
<block name="masterForge">
<property name="Class" value="Forge"/>
<property name="UnlockedBy" value="masterForgeSchematic"/>
<property name="Material" value="Mstone_scrap"/>
<property name="MaxDamage" value="20000"/>
<property name="StabilitySupport" value="true"/>
<property name="Weight" value="0"/>
<property name="Shape" value="ModelEntity"/>
<property name="Path" value="solid"/>
<property name="Model" value="Entities/Crafting/forgePrefab"/>
<property name="CustomIcon" value="forge"/>
<property name="CustomIconTint" value="9E70BB"/>
<property name="CustomTint" value="9E70BB"/>
<property name="TintColor" value="158,112,187"/>
<property name="Place" value="TowardsPlacerInverted"/>
<property name="OnlySimpleRotations" value="true"/>
<property name="IsTerrainDecoration" value="true"/>
<property name="ParticleName" value="forge"/>
<property name="ParticleOffset" value="0.5,0,0.5"/>
<property name="ImposterDontBlock" value="true"/>
<property name="Stacknumber" value="1"/>
<property name="HeatMapStrength" value="6"/>
<property name="HeatMapTime" value="5000"/>
<property name="HeatMapFrequency" value="1000"/>
<property name="BuffsWhenWalkedOn" value="buffBurningEnvironment"/>
<property name="ActiveRadiusEffects" value="buffCampfireAOE(5)"/>
<property class="Workstation">
<property name="CraftingAreaRecipes" value="forge"/>
<property name="Modules" value="tools,output,fuel,material_input"/>
<property name="InputMaterials" value="iron,brass,lead,glass,stone,clay,mythril,adamantite"/>
</property>
<property name="WorkstationIcon" value="ui_game_symbol_forge"/>
<property name="OpenSound" value="forge_open"/>
<property name="CloseSound" value="forge_close"/>
<property name="CraftSound" value="forge_smelt_click"/>
<property name="CraftCompleteSound" value="forge_item_complete"/>
<property name="WorkstationJournalTip" value="forgeTip"/>
<property class="RepairItems">
<property name="resourceRockSmall" value="50"/>
<property name="resourceClayLump" value="60"/>
<property name="resourceLeather" value="20"/>
</property>
<drop event="Harvest" name="resourceRockSmall" count="40" tag="allHarvest"/>
<drop event="Harvest" name="resourceClayLump" count="20" tag="allHarvest"/>
<drop event="Harvest" name="resourceLeather" count="5" tag="allHarvest"/>
<drop event="Destroy" count="0"/>
<drop event="Fall" name="terrDestroyedStone" count="1" prob="0.75" stick_chance="1"/>
<property name="TakeDelay" value="15"/>
<property name="Group" value="Building,advBuilding"/>
<property name="DescriptionKey" value="forgeDesc"/>
<property name="EconomicValue" value="1000"/>
<property name="FilterTags" value="MC_playerBlocks,SC_decor"/>
<property name="SortOrder1" value="70i0"/>
</block>
This made the game crash whenever I looked at the forge until I used xpath to alter windows.xml to add two more rows to the grid in the content2 section of windowForgeInput (bringing the rows to 8).
<window name="windowForgeInput" width="228" height="204" panel="Right"
controller="WorkstationMaterialInputWindow" materials_accepted="iron,brass,lead,glass,stone,clay" valid_materials_color="[green]" invalid_materials_color="[red]" cursor_area="true" >
<panel style="header.panel">
<sprite style="header.icon" sprite="ui_game_symbol_forge"/>
<label style="header.name" text="INPUT" text_key="xuiSmelting" />
</panel>
<sprite depth="2" name="backgroundMain" sprite="menu_empty3px" pos="0,-46" height="228" color="[black]" type="sliced" fillcenter="false" on_press="true" />
<rect name="content" depth="1" pos="0,-46" height="228">
<grid depth="7" rows="3" cols="1" pos="3,-3" cell_width="75" cell_height="75" controller="WorkstationMaterialInputGrid" repeat_content="true">
<item_stack name="0"/>
</grid>
</rect>
<rect name="content2" depth="0" pos="78, -49" width="147" height="223">
<sprite depth="1" color="[mediumGrey]" type="sliced" on_press="true"/>
<grid rows="8" cols="1" pos="3,-3" cell_width="147" cell_height="24" repeat_content="true">
<forge_material name="0"/>
</grid>
</rect>
</window>
So now I can open the masterForge and it will show all the normal materials plus Mythril and Adamantite. But when I try to melt items made of those materials and scrappable into those materials in the forge, they count down as usual but then nothing happens and the item remains. Has anyone messed with adding items to forges before? I know I have seen it done on other servers but I don't have access to their xml to see how they did it and learn from their alterations.
