Jump to content

Recommended Posts

It's not game breaking or anything, but the icons of the custom items that my character spawns with don't show up in character select. Am I missing a file or a line of code?

Their inventory icons do show up once I spawn, so I don't know why they don't show up in this screen.

I'll leave the luas of both items attached as well just in case.

Screenshot 2021-12-07 154817.png

gutsybat.lua pklifeup.lua

Edited by CloverNoir
more details

It is honestly easier to just register your images rather than manually overriding them for every instance they are called.
You can place this anywhere in your prefab file outside of the functions before the return.
I like placing mine right after the assets and prefabs tables at the top.
 

RegisterInventoryItemAtlas("images/inventoryimages/gutsybat.xml","gutsybat.tex")

Attached is a slightly modified version of your gutsybat file to make it easier to understand what to do.

gutsybat.lua

  • Like 2
18 hours ago, IronHunter said:

It is honestly easier to just register your images rather than manually overriding them for every instance they are called.
You can place this anywhere in your prefab file outside of the functions before the return.
I like placing mine right after the assets and prefabs tables at the top.
 


RegisterInventoryItemAtlas("images/inventoryimages/gutsybat.xml","gutsybat.tex")

Attached is a slightly modified version of your gutsybat file to make it easier to understand what to do.

gutsybat.lua 4.1 kB · 1 download

This seems to be a better practice in general, it's more compatible with anything that needs to access the inventory image, such as Item Info, otherwise that mod spams the client log with complaints about being unable to find the inventory image for the equipped item. I'd also speculate that it's lighter on the games performance as well.

  • Thanks 1

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...