Wintermute Engine Forum

Wintermute Engine => Technical forum => Topic started by: SOLO on August 21, 2012, 12:42:09 PM

Title: Direct control and Scene scrolling
Post by: SOLO on August 21, 2012, 12:42:09 PM
    I have the main actor being controlled by a direct control script and he walks around very well. The problem comes when he walks off the screen it takes a while for the scene scrolling to catch up.

I have tried different methods to speed up the scene scrolling but this either makes the actor sprite shake and look horrible or it makes the scene scroll slower.

How can I get the scene scrolling to be as fluid as the direct control animation?

Many thanks
Title: Re: Direct control and Scene scrolling
Post by: dongo on August 21, 2012, 01:12:26 PM
I can think of something, though not much about  wintermute but the method scene.SkipTo (Object)
  when you press right on the keyboard should the program call  the method that makes the character move, well you can call others methods, then call too the method SkipTo(Object) to set the position of the scroll on the character, if that does not work, and neither are a lot of scripting yet.
I hope that helps.
Title: Re: Direct control and Scene scrolling
Post by: Spellbreaker on August 21, 2012, 01:50:20 PM
Hey there!

How do you scroll? I'd suggest the following for your scrolling, we do the same in our Project.


As you can see on the screenshot, we are always using regions to trigger scrolling. In his case, they are simply two regions from top to bottom ( the two light-blue ones). The LEFT region makes the screen scrolling to the left-end, and the RIGHT region makes the region scroll to the right, simply by using the following Script:

on "ActorEntry" {

Thats for Scrolling to left for example. As for the Settings, we use the following in scripts\scene.script :

this.ScrollSpeedX = 10;
this.ScrollPixelsX = 4;

It gives a quite fast scrolling. You can make it faster by reducing the speedX setting, or by increasing the Pixels.

Maybe this is a solution for your problem.
Title: Re: Direct control and Scene scrolling
Post by: bokkers on November 10, 2012, 09:03:19 PM
Thanks for these advices on handling the scrolling speed! Answers exactly what I have been asking myself lately.