1 decade ago by ChristianTellefsen
Hi,
I'm looking into using Impact for a multiplayer game.
Has anyone else used tried using Impact with an authorative nodejs server? Since the Impact engine doesn't run directly on the server out of the box, I'm looking into the following solutions:
1. Implement a parallel server implementation of the impact physics. Basically, make Server versions of entity / collision with the data needed (like acc, pos, vel), and notify the client whenever anything interesting happens. This has the disadvantage of requiring parallel implementations of a lot of code, which would then have to be kept up to date when upgrading impact. Also, parallel code is a good source of hard to find bugs...
2. Make a mock client environment for the full Impact engine to run in on the server (like mock window, document...) Has anyone had any success doing something like this? I kind of think this might be the most elegant solution, since it requires no re-implementation of client code on the server.
3. Decouple the physics simulation in the client, and use the decoupled simulation in the server as well. This requires forking impact and changing the provided impact files, which has the disadvantage of making it harder to update the engine later.
What do you think? What's the best way to do this? I'm especially interested in hearing if someone has actually succeeded in making an authorative nodejs server for Impact!
Cheers,
Christian.
I'm looking into using Impact for a multiplayer game.
Has anyone else used tried using Impact with an authorative nodejs server? Since the Impact engine doesn't run directly on the server out of the box, I'm looking into the following solutions:
1. Implement a parallel server implementation of the impact physics. Basically, make Server versions of entity / collision with the data needed (like acc, pos, vel), and notify the client whenever anything interesting happens. This has the disadvantage of requiring parallel implementations of a lot of code, which would then have to be kept up to date when upgrading impact. Also, parallel code is a good source of hard to find bugs...
2. Make a mock client environment for the full Impact engine to run in on the server (like mock window, document...) Has anyone had any success doing something like this? I kind of think this might be the most elegant solution, since it requires no re-implementation of client code on the server.
3. Decouple the physics simulation in the client, and use the decoupled simulation in the server as well. This requires forking impact and changing the provided impact files, which has the disadvantage of making it harder to update the engine later.
What do you think? What's the best way to do this? I'm especially interested in hearing if someone has actually succeeded in making an authorative nodejs server for Impact!
Cheers,
Christian.