[OPT] A few more speed optimizations.
[CHG] Fixed wrong naming of "scenes" variables/arguments to "scene".