Make the player walk somewhere in a nice looking way.

Place to get help with not working mods / modding interface.
Post Reply
User avatar
Smart Inserter
Smart Inserter
Posts: 3521
Joined: Tue Jul 12, 2016 9:03 am

Make the player walk somewhere in a nice looking way.

Post by eradicator » Thu Feb 22, 2018 10:47 pm

In my mod i want to make the player walk a short distance towards an object. Currently i'm using on_tick to set the walking_state of the player character each tick. In Singleplayer this works "okaish". The only thing that looks shitty is if the direction is changed too often (oscillating between two of the 8 directions due to angle to target) but i guess i could code around that but... In Multiplayer it looks horribly laggy. My guess is that the lag hiding mechanism reacts too aggressive. It looks like the player is teleported around every half second or so instead of properly walking.
So my questions are:
  • Is there a better way to make the player walk then using walking_state? (biter ai maybe?)
  • If not is there some hack around the lack hiding? (like temporarily detaching the player character from the player?)
  • Has anyone done something similar before somewhere?

Post Reply

Return to “Modding help”

Who is online

Users browsing this forum: No registered users