Interpolating Speed

I currently have two actors, one the player and one an enemy. I want the enemy to follow the player, which I have already done. What I can't figure out is how to make the enemy faster every second of the game. I want to interpolate his speed from say 0-1000 over 2-3 minutes. Can I use game.time to put this into effect? Just not sure what to do at the moment.
Any help would be much appreciated.

Comments

  • mataruamatarua Auckland, New ZealandMember Posts: 854
    Times the tracking method by the self time to make it do that.

    If you don't provide more details in a question like this it's a bit tricky to give an exact answer sorry - but be super careful of using game.Time - it does not stop or act like self.Time.

    Cheers, M@
  • SocksSocks London, UK.Member Posts: 12,822
    edited November 2013
    I currently have two actors, one the player and one an enemy. I want the enemy to follow the player, which I have already done. What I can't figure out is how to make the enemy faster every second of the game. I want to interpolate his speed from say 0-1000 over 2-3 minutes. Can I use game.time to put this into effect? Just not sure what to do at the moment.
    Any help would be much appreciated.
    Not quite sure what the issue is ? If you want to interpolate an actor's speed from 1-1000 over 3 minutes do this:

    Make a 'real' attribute, let's call it 'ABC'.

    Interpolate ABC to 1,000, duration 180 (which is 3 minutes).

    Move To player's X and player's Y, speed ABC.
  • CharlieG97CharlieG97 Member Posts: 52
    Sorry, forgot about this post.
    @matarua thanks, this is the method I'm using.
    @Socks Thanks for the help, but matarua's suggestion is working well :)
  • mataruamatarua Auckland, New ZealandMember Posts: 854
    Glad you got it working :)
  • SocksSocks London, UK.Member Posts: 12,822
    Sorry, forgot about this post.
    @matarua thanks, this is the method I'm using.
    @Socks Thanks for the help, but matarua's suggestion is working well :)
    :)>-
Sign In or Register to comment.