Hi again
I think my problem is very simple, but maybe, from my poor english, I can´t find what I need to solve. I think I don´t know look for it properly.
I don´t undertand very well how works the prefabs with the actions or unity in this case. I have a simple example:
I have created a big window.
For testing I am using the FPS controller of Unity.
When I am near the window, a clickable icon appears.
When I click down, the window opens.
Ok. All of this works fine. To open de window I have created a controller in a "empty object".
When de icon is active I use "Mouse Pick Event". Then I use bool variable to active the animation of the window, using "Set animator Bool" on the game object "window".
How I have said, all works fine.
But I need more windows and if I put another prefab of the window in my scene, the new window doesn´t work. The button appear but when I try click it doesn´t work. (The first window still working fine).
I think it happen because in the actions I´m calling a specify object in "Set animation Bool" and the same thing for the "mouse pick event". And it doesn´t work with the another copy of the prefab (Because the prefab is another different object. Isn´t it?).
And maybe I have to use game object variable or any variable to identify what object I want to interact. Or something like this.
Now. Where can I find any tutorial to know what is the best way to do this?
I think is a very simple question (maybe), but I can´t find the answer.
Sorry for my long post. Thanks!!!