Custom movement help

  • So ive worked on creating a sort of custom movement. I had to change it from WASD to more of a fps contol for gameplay reasons, so wherever your mouse is is where the character faces, and WASD is subject to the characters angle unlike the '8 direction' pluggin. Im in need of it being smoother though, I tried using 'custom movement' for it, didnt work out. So I use a variable, its the 'step' in which the character moves. My events are set to when W is down move forward at 'step' every so and so seconds

    That left... An unnecessarily complicated method of movement, acceleration and deceleration. Does anyone know of a plugin that does what I'm looking for or just a better method of doing so?

  • I'd recommend using Rex's moveto behaviour. It will handle acceleration for you. You can use the 'Move to delta X/Y' action to move according to Angle.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Rex's moveto or:

    Lerp(a, b, x) - Linear interpolation: Calculates a + x(b - a), or linearly interpolates a to b by x%. Eg. lerp(a, b, 0.25) gives the value 25% of the way from a to b

  • Hey Uglypenguin,

    I do not know exactly how your object should behave. Maybe this code can help you:

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)