Problem in transitioning between states

After writing all the code and double checking it,when I play in Unity,the starting state’s text is shown but after that I can go to only one of two next states.
When I press 1,room 1 text is displayed but after that I can’t go to starting state or room 2 text.
Same goes when I press 2,room 2 text is displayed but after that I can’t go to starting state or room 1 text.

Hi Prateek,

Please check if your room 1 has the next rooms in its nextStates array. Imagine that all states are supposed to be linked like on a website. In our case, the “link” is the reference in the array.

Ok,got it.Thanks

Did it work?


See also:

Yes it’s solved

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms