Jump to content

How does character controller work in LE?


Crazycarpet
 Share

Recommended Posts

So I have a game where I have a dedicated server and clients with predicted movement and server reconciliation... the problem is I noticed when using SetInput it's really choppy , and when I dug into it deeper it seems that SetInput keeps moving the player with these inputs til you SetInput something else.... (Which is a problem since there's a network delay.)

 

So my question is, is there ANY way I can predict fully the outcome of character controller movement in LE... (guarantee the server/client will produce the same result when given the same input.)

 

The problem with SetInput continuing on simulating movement in one way til inputs changed is that the server of course has a delay when receiving the clients inputs.

 

So I need either a move method in the character controller in LE that you can set how much movement to do per-frame, that DOESN'T carry on to next frame.... that or I have to make my own character controller :/ anyways any tips/tricks would be appreciated. Just sort of stumped and I'd rather not write my own character controller.

 

If LE has something similar to Unity's CharacterController.Move please let me know.

I need to be-able to fully predict the movement result on the client and ensure I can (almost) always produce the same movement result on the client/server to do this I'd need something where I can specify the movement myself rather then relying on the movement through 'SetInput' that continues movement for a moment longer than it should. (Again, because of network delays.)

Link to comment
Share on other sites

If you do SetInput in an update physics callback you can control it each frame.

 

See that's what I'm doing, but I print out the input I'm passing to SetInput and it seems that he server for some reason simulates the movement for an extra frame or something before stopping it (I stop it when there's no input.) so they're getting slightly different results from identical inputs. I feel like it SHOULD be stopping the input on the server at the correct time... but it's not. I'm sure I'm doing something wrong and just missing it but this is far from my first time making predicted/reconciled movement.

 

Edit:

Okay so i found out no matter how I do this w/ LE CharacterPhysics it's not possible because the frame-delay before actual movement happens makes it so reconciliation is so far behind and of course choppy... so I need to write my own character controller... any suggestions? :o I don't even know where to start.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...