- Home /
scripts not working at runtime?
I have attached mouseorbit, mousezoom and smoothfollow scripts to my camera and when running this via the editor everything works perfectly, I build it to 32bit Windows and it builds without error but those scripts don't work when I run the complied game as they do when I try in the editor? What is going on? I'm version 4.2.2f1
update to latest. recheck compile files. send error report to unity. mouseorbit, mousezoom and smoothfollow scripts ALL unresponsive? sounds like simple settings/input config error.
Thanks for your reply..It is a bit weird, I'll try upgrading to 4.3.3 (and make a backup of my project which is at 10GB already so will be sad to see that get corrupted), but why would the settings/input not work at runtime or differ if I did not change these? $$anonymous$$aybe I can try reset to defaults for inputs and see it that helps.. kind of frustrating as my game is nearing completion.
Hmmm, upgrading to 4.3.3 did not help, I rebuilt the game in 4.3.3 and still see the same issue, all the camera control scripts I use work in the Editor nicely but not in the runtime! Any ideas would be appreciated here!
Oh ok wait a $$anonymous$$ute,... when I start my game I get the configuration window with a Input tab, see the screenshot below: Why don't I see the mouse scrollwheel listed in the Input options at runtime on the configuration window/ panel?
Answer by khos85 · Jan 30, 2014 at 10:43 AM
Got it working, the mistake/issue was that I previously had slightly modified the smoothfollow script to use a value from mouseorbit by using getcomponent... this all works in the Editor but for some reason not at runtime. Anyway, I modified the smoothfollow script and all is working now.
Your answer
Follow this Question
Related Questions
Is it possible to run a script in the editor so it doesnt have to run it again the runtime???? 2 Answers
Is Editor API for making plug-in? 1 Answer
Playing AudioClip in Runtime 0 Answers
Perform action on save/load in editor 2 Answers
Custom Asset Icons? 2 Answers