How can I move the camera smoothly from one point to another? I'm aware of the SetViewport() function, but that just jumps the camera from one place to another.
I need a nice smooth pan for a dramatic moment. Thanks!
You can use SetViewport() with repeatedly_execute or repeatedly_execute_always to move the viewport 1, 2 or 3 pixels each frame. Just remember to call ReleaseViewport() when you're done.
Or even simpler, with the Tween module, you can tween the viewport position, which will give a smooth camera move effect.
The Tween module will give great results, but if you want smoother camera movement in general then you could also try my Smooth Scrolling and Parallax Module: http://www.adventuregamestudio.co.uk/forums/index.php?topic=33142.msg636501798#msg636501798
You can create pans and more complex camera moves by directing the camera to an invisible character (targetCharacter = cDummy;).
+1 for "Smooth Scrolling & Parallax" module
If you're not using parallax, is there any benefit to using that module over Tween?
Quote from: Snarky on Tue 15/09/2015 16:27:07
If you're not using parallax, is there any benefit to using that module over Tween?
I haven't tried tween 2.0 and its new magic (including tweening the viewport). So the answer is: Tween is probably doing it right, but you'd need to script a little, and watch out for the potential corner cases, whereas Smooth scrolling works out of the box and is flawless.