DashingStrike / Automato

Automato LUA-based scripting engine
4 stars 2 forks source link

Automato 2.0 for ATITD #1

Closed ghost closed 9 years ago

ghost commented 9 years ago

Updating from VeggieTales 1.78 to Automato 2.0 gets VT stuck on restart for some players. Some files related to Atitd scripts are missing, so some scripts are broken.

The change from loadfile("")(); to dofile(""); breaks some custom scripts that were never pulled.

Jimbly commented 9 years ago

For custom scripts that were not part of TaleScripts, it tries to migrate them automatically on the first run, but some manual fixup might be needed, see this page on the wiki for the differences. AFAIK, dofile("") and loadfile("")() are identical, one is just more succint, however the parameters to either used to be luaScripts/foo.lua and should now just be foo.lua.

For people getting stuck, I'd love some more details or to help someone troubleshoot, does it just get stuck and then closing/killing the process and then restarting fixes it? It's possible if it's failing to patch all files that it's leaving the old VeggieTales.exe (but patching everything else), in which case directly launching Automato.exe should get them running (in theory in the new build, VeggieTales.exe just launches Automato.exe).

ghost commented 9 years ago

After Automoto update finishes and VT restarts it keeps closing itself right away. Might be a folder location related issue (VT was at C:/eGenesis/VeggieTales) because reinstalling the old version then updating to Automoto fixed this problem for me and someone else.

Jimbly commented 9 years ago

Okay, thanks for the info, I'll see if I can reproduce it, let me know if you hear anything else =).

ghost commented 9 years ago

Will do :)

ghost commented 9 years ago

Macros i tested so far seems to be running okay but using sound effects with sPlaySound results in "FMOD error! (23) File not found." with OK and CANCEL options. Macro is frozen until OK is pressed.

Jimbly commented 9 years ago

Ah! What an embarrassing oversight, I forgot to test sound playback (perhaps because I forgot there were sounds squirreled away in the images/ folder...).

Version 2.01 is released with a fix so sounds will play. It also defaults to looking for sounds in the "sounds/" folder and falls back to looking in "images/" if it's not found, so this should fix the ATITD scripts. I also moved all of the .wav files out of images/ and into sounds/ so things should be clearer going forward.

Jimbly commented 9 years ago

Ah, I reproduced the original problem, when I actually rolled out 2.00 the first step of patching cleaned up the particular file I was looking for to decided whether or not to do an upgrade process (which goes through all scripts, fixes "luaScripts" -> "scripts" and stuff like that), so I think it just totally skipped the upgrade process for you (which would have left any loose scripts not part of the repo as broken).

I think this is now resolved in version 2.02, it should correctly trigger the migration when people upgrade now, however I'm guessing most people who had this issue already got around it. If you have a copy of scripts in both luaScripts and games/ATITD/scripts, on the next run it will perform the migration again (might overwrite what's in games/ATITD/scripts with what's in luaScripts/, however it should apply the appropriate code fixes this time, but if you have a lot of loose scripts, you may want to make a backup of your installation folder just to be paranoid).

ghost commented 9 years ago

Glad to hear that :)

Everything seems to be running smooth with version 2.02. I'll let other players know and keep you informed if anything else appears. Closing this issue topic.