Updated GarageServer.IO API calls to support client side prediction for entities - #20

This commit is contained in:
Jeremiah Billmann
2015-05-20 02:10:07 +00:00
parent 21d8fb2884
commit fbdcfe3da5
12 changed files with 48 additions and 25 deletions
+1 -1
View File
@@ -52,7 +52,7 @@ GarageServerIO.initializeGarageServer('http://insertmygameserverurlhere.com', {
onReady: function () {
// Call your game loop
},
onUpdateClientPredictionReady: function (playerId, playerCurrentState, inputs, deltaTime) {
onUpdateClientPredictionReady: function (playerId, playerCurrentState, entityCurrentStates, inputs, deltaTime) {
var newState = {};
if (!playerCurrentState.x) {
playerCurrentState.x = 0;