Jump to content

Recommended Posts

This is embarrassing but I don't think I have ever made a custom recipe using custom prefabs before. The recipe is working right, the inventory images are all working fine in both the inventory slots and the tabs BUT not in the tabs popup window thing when I hover over the custom recipe. There's just an empty background image where the inventory image would normally be but when I hover over the background image, the name comes up in the hover text. Is there something special you have to do to get the inventory image to display properly in that popup window?

local medium_preservatives = Ingredient( "medium_preservatives", 1)medium_preservatives.atlas = "images/inventoryimages/medium_preservatives.xml"local strong_preservatives = Recipe("strong_preservatives", { Ingredient("blue_cap", 1), Ingredient("ash", 30), medium_preservatives }, RECIPETABS.SURVIVAL, TECH.SCIENCE_TWO )        strong_preservatives.atlas = "images/inventoryimages/strong_preservatives.xml"

This is code from my mod to create new recipe using custom ingrediens. It cover also showing custom images in popup window.

As you see strong preservatives using medium ones as ingredient, If i want medium image to appear in recipe i must place that first line. For placing images are that "atlas" lines I think. Hope it helps.

Edited by EmielRegis
local medium_preservatives = Ingredient( "medium_preservatives", 1)medium_preservatives.atlas = "images/inventoryimages/medium_preservatives.xml"local strong_preservatives = Recipe("strong_preservatives", { Ingredient("blue_cap", 1), Ingredient("ash", 30), medium_preservatives }, RECIPETABS.SURVIVAL, TECH.SCIENCE_TWO )        strong_preservatives.atlas = "images/inventoryimages/strong_preservatives.xml"
This is code from my mod to create new recipe using custom ingrediens. It cover also showing custom images in popup window.

As you see strong preservatives using medium ones as ingredient, If i want medium image to appear in recipe i must place that first line. For placing images are that "atlas" lines I think. Hope it helps.

That was a big help. I see exactly where I was going wrong now. Thank you.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
  • Create New...