Old Scripts not running in Fusion 7.x

Sometimes scripts that run fine in Fusion 6 terminate in Fusion 7.6 with a Console-Error like:
[...].eyeonscript:9: attempt to call a table value
Fusion 6.x still had a hack in the scripting-engine that would allow code
(namely For-Next-Loops) to not follow exactly the Lua-specs.
Since the scripting engine has been updated for F7, the Lua specs must be obeyed now.
In other words, while in Fusion 6.x this would work:
as of F7 you must use ipairs(), or pairs(), that is:
or
Cheers.
Eric.
[...].eyeonscript:9: attempt to call a table value
Fusion 6.x still had a hack in the scripting-engine that would allow code
(namely For-Next-Loops) to not follow exactly the Lua-specs.
Since the scripting engine has been updated for F7, the Lua specs must be obeyed now.
In other words, while in Fusion 6.x this would work:
- Code: Select all
for i, v in composition:GetToolList() do
bla
end
as of F7 you must use ipairs(), or pairs(), that is:
- Code: Select all
for i, v in ipairs(composition:GetToolList()) do
or
- Code: Select all
for i, v in pairs(composition:GetToolList()) do
Cheers.
Eric.