Move Player in Multiplayer

Blitz3D Forums/Blitz3D Beginners Area/Move Player in Multiplayer

YellBellzDotCom(Posted 2008) [#1]
Ok, Ive been working on moving a player in a multiplayer game for quite a while now and I cant seem to get this down.

Currently I am using wsad to move my character, the character is not getting rotated to face the direction it is moving yet. I am using the simple...


In your opinion, what is a good player movement code for a top down multiplayer game. What kind of code would you use to transmit movement for the players?

Thanks for any insights.


LedgerARC(Posted 2008) [#2]
I think that your way of moving sould work, but I have no experence in multi-player games. I have been trying to work on one for about a month now and cant even connect the two computers. So I have posted simply to ask how to make a multi-player game. I know it's off subject, but I really need some help as one of the best game I created is toatly useless without multi-player.

And for my movement, I use the moveentity command on all of my games, it was designed for movment, and therefore should be used for it, What I thing is the problem is that when you join the two computers, the characters of the game have the same handle (name) and therefore there might be two things and their moving at the same time, or soemthing like it. I hoped this helped a little.


YellBellzDotCom(Posted 2008) [#3]
Thanks for the reply, I have the network totally working, players can join, talk to each other and move. The problem Im having is the lag in movements. Im using the same port to send and receive, I believe this could be an issue. Ill change it and see if that helps.

Thanks again.


YellBellzDotCom(Posted 2008) [#4]
Well, sending a move command once as suggested in these forums helped alot. I send the initial move command, then will only send another move command if it is different than the previous move command. The Positions of the players are matched exactly without any lagging. WHeeew, now to try it out on 4 pc's hehehehe.


Can anyone answer if it is critical to use different ports for sending and receiving in a small network game of moving chars and chatting?