I have a scriptable tile set up, but my issue is i dont know how to access the actual tile with another script. My goal is to take a mouse click, invert a boolean value called isOpen and open/close the door. The issue im having is, how would i go about accessing the scriptable tile? I have a prefab inside the tile but that is the object that is taking input, i need the input script to call a function inside the tile itself and change between two sprites. But i cant access the scriptable object using the typical GetComponent() so how would i do so?
Events or messages?
Never thought of those, im still quite new to programming, unity, and even game development so im surprised as to how far i’ve come in the past months with unity but still you can tell im new because i forgot events were a thing