Re: Webpack bundle colyseus typescript
In reference to the old post, is really a good idea to have all the physics and logic on the server side?
Wouldn't that overhead the server with calculations that should be done on the client?
What's coming to my mind is something like:
A1 - The client A press "left" > which sends a small package to the server with the action (let's say something like "A=L").
A2 - The server does nothing with that but broadcast it to every other client (again "A=L").
A3 - Then client B who receive this will calculate client A result position and update the view accordantly.
Isn't that better than:
B1 - The client A press "left" ("A=L").
B2 - The server calculates the new position and broadcast something like "A=[new-position-data]"
B3 - Then client B updates the view using [new-position-data] instead of calculating the new position for A based on A pressing left.
I'm guessing the problem will be on saving the A "real-position" as the player real state on the server, right? Something like to validate each player position after pressing left?
Could this be like something to avoid possible hacks on the client side?
@halome , do you have a final version of your integration to share? Did you used Phaser 2 or 3?
I'm looking to use Phaser 3 in my game along with Colyseus and MySQL.
No need to say I'm new into game development (I'm just working on my first game), so I have a lot of questions like this :P
Thanks in advance!