mirror of
https://github.com/wassname/GarageServer.IO.git
synced 2026-06-27 16:10:34 +08:00
Minor cleanup
This commit is contained in:
@@ -6,10 +6,8 @@ $(function () {
|
||||
onUpdatePlayerPhysics: OnProcessGamePhysics,
|
||||
onInterpolation: function (currentState, previousState, targetState, amount) {
|
||||
var interpolationState = {};
|
||||
|
||||
interpolationState.x = (previousState.x + amount * (targetState.x - previousState.x));
|
||||
interpolationState.y = (previousState.y + amount * (targetState.y - previousState.y));
|
||||
|
||||
return interpolationState;
|
||||
}
|
||||
});
|
||||
@@ -47,11 +45,8 @@ $(function () {
|
||||
|
||||
update = function () {
|
||||
requestAnimFrame(update);
|
||||
|
||||
processClientInput();
|
||||
|
||||
draw();
|
||||
|
||||
$('#fps').html('FPS: ' + GarageServerIO.getFPS());
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user