My last state wont display the text in the UI!

I have been trying to complete my text101 and have come across an issue.
Although it all works my final state (freedom) doesn’t actually display. Unity recognises the state is active but the UI doesn’t update and freezes.

Here is the code in the fastest route I can manage at this stage;

https://gist.github.com/anonymous/2ab32bce071bbd5d639fc4a9c1858d1c

Full code:
https://gist.github.com/anonymous/4ad29d6b3c0fcd9c2d3641c142936824

After looking at the code again the next day I found the problem straight away! For those interested in my list of states I had forgotten to change the name of Floor_0 to freedom.
else if (myState == States.floor_0) {floor_0();}
else if (myState == States.floor_0) {freedom();}}
Thanks for helping!

Can you copy/paste your full script into your post please.


See also;

I have edited in the post to add a link for the whole thing. Thanks.
By adding the whole code and looking at it with fresh eyes today I have found the problem straight away but thank you for your help!

1 Like

Glad to hear you have resolved the problem and can move forward again Scott, well done for finding it yourself :slight_smile:

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

Privacy & Terms