E
E
Egyment2018-01-30 18:31:35
Unity
Egyment, 2018-01-30 18:31:35

Working with a sheet in a unit?

I have a script in which I created an item list which has an icon. name, etc. I add an item there, and inside the script I use the properties of the item. But no matter how I try to get a sheet, or items.icon, from another script, nothing comes out at all. How to get the list and properties of the added items from another script?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Ark Tarusov, 2018-02-04
@Egyment

make a list with public access. In another script, get a link to the script with the sheet and actually work with it.
Or make a list of public static and you can access without a link to the script.
It's not a unity problem, it's programming.
It would be better to write a piece of your own code.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question