mirror of
https://github.com/wassname/GarageServer.IO.git
synced 2026-06-27 16:10:34 +08:00
Progress: Documentation
This commit is contained in:
@@ -81,11 +81,11 @@ GarageServerIO.addInput(myInput);
|
||||
```js
|
||||
GarageServerIO.getStates(function (playerStates, entityStates) {
|
||||
playerStates.forEach(function (player) {
|
||||
ctxCanvas.fillRect(player.state.x, player.state.y, 5, 5);
|
||||
ctxCanvas.fillRect(player.state.x, 0, 5, 5);
|
||||
});
|
||||
|
||||
entityStates.forEach(function (entity) {
|
||||
ctxCanvas.fillRect(entity.state.x, entity.state.y, 5, 5);
|
||||
ctxCanvas.fillRect(entity.state.x, 0, 5, 5);
|
||||
});
|
||||
});
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user