Here's what I'm thinking. That code looks pretty normal to me...I only looked though it in entirety once, so I may have missed something.
But only in the mainscript is the property that says "Good idea. You can try that again later" used. My guess is that you edited the mainscript at some point. This is very important:
If you ever edit the mainscript, you must compile ALL scripts, or else all kinds of unexpected things tend to happen.
That is my guess. So, just use the "compile all scripts" function, rebuild, and run the game to see if the problem is fixed "on its own".