#How do I find stuff inside the folder?
1 messages · Page 1 of 1 (latest)
You usually don’t, explain what your trying to do
I have some rooms/corridors in a folder, those are variants of prefabs and I made a function in a script that gets a name upon pressing a button.
Now the problem is, how do I find that room/corridor with the name?
Those aren't in the scene yet
Do I need to have them loaded in the scene?
Or can I acces them by name from the folder?
Usually in code we try hard to avoid using strings and names of things all together
Ideally you’d want a list of the prefabs directly
Then how could I find them ...
What is that list?
So like public = ///
and then I keep making the references
until it is finsihed
doesn't that get messy with a lot of references?
I’d suggest googling more about c# lists
Ok fine I will try that
Ok but like the button returns a name, how do I find that on the list