Skip to content
Discussion options

You must be logged in to vote

Hi Raphael,

A couple of points to note:

  • Entity index are not the same as user IDs. Entities represent all networked objects in the game (this can include props, doors, etc), so you're most likely not getting the position of the players in this instance.
  • You should check whether you're at a specific tick in tickend instead of doing a range check for currentTime. It's more efficient and more accurate.
  • You can just use ent.position on players instead of calculating it manually - you're looking at an old comment. I've edited the comment that you've linked to.

With that said, I've fixed your code here - let me know if it works:

let checkpointTick = -1;

demoFile.on('tickend', e => {
  if (de…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by saul
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #49 on February 28, 2021 14:00.