decentraland / decentraland/creator-hub
[BUG] Missing keypress events in `PointerEventsResult` reports
- Dominant language
- TypeScript
- Stars
- 7
- Forks
- 14
- Avg merge
- 2d 8h
- Merged PRs (30d)
- 44
Description
### **Steps To Reproduce:**
Press a few times the keys for moving the Avatar around, with the mouse pointer locked, and while running the following code:
```
import { engine, PointerEventsResult } from '@dcl/sdk/ecs'
engine.addSystem(() =>
[...[...engine.getEntitiesWith(PointerEventsResult)][0]?.[1] || []]
.forEach(result => console.log(JSON.stringify(result)))
)
```
### **Expected:**
A log trace of up to 100 of the latest keys pressed and/or unpressed.
### **Actual:**
Various key changes are missing in the list.
### **Notes:**
The entries are such as this one: `{ "button": 6, "state": 1, "timestamp": 1097, "tickNumber": 250 }`, with only every one entry per timestamp number.
Clearly the timestamps are not fine-grained enough (perhaps due to them being improperly scaled when relayed from the engine), and thus preceding entries are being over-written by subsequent ones (or preventing them from being entered).
Contributor guide
Assessment
This issue has not been assessed yet.