2

While watching a recorded CS:GO match, you can use the demo_goto command (or demo_gototick) to move around. Its parameters are a tad obscure though. The help says:

] demo_goto
Syntax: demo_goto <tick> [relative] [pause]
  eg: 'demo_gototick 6666' or 'demo_gototick 2523,666,370,700r 'demo_gototick 42min'
  Currently playing 67295 of 142355 ticks. Minutes:37.07 

To move forward or back, you can use eg demo_gototick -640 relative. I'm curious what the four-argument version does and how you'd figure out what they all mean, as it may offer options, but I can't find any documentation.

My goal is to bind a key to the action "jump forward to the next round". Is there any way to do this?

Edit to add context: During a match, I record notes about rounds that I want to look at afterwards (like a ridiculous ambush, or when four people rushed A Short and all died one by one to my shotgun - yeah that happens in low Silvers). When I'm reviewing, I want to jump to the rounds of interest; and once the demoui has the "Next Round" button selected, Shift-F2, Space, Shift-F2 will jump to next round - as long as I never select anything else. Having a key that actually does this exact action would be far more reliable.

Edit: Discovered the following in the binary:

Syntax: demo_goto <tick> [relative] [pause]
  eg: 'demo_gototick 6666' or 'demo_gototick 25%' or 'demo_gototick 42min'
  Currently playing %d of %d ticks. Minutes:%.2f File:%s

I think that answers the question about how the four-argument version works - or rather, why it isn't documented anywhere. There IS NO four argument version. It's a docs bug, and you can jump based on a percentage (presumably of the entire match). Hopefully the next person to wonder about this can at least save that part of the trouble.

  • Please, only put one question in a question post. – Ave Aug 4 at 13:15
  • 1
    It's really only one question and a point of reference for that question. Perhaps I worded it unclearly but the important part is highlighted in the question's title. – rosuav Aug 4 at 20:44
1

To move forward or back, you can use eg demo_gototick -640 relative. What does the four-argument version do?

I found no documentation regarding the four-argument version of demo_goto (the 2523,666,370,700r example they give.) It simply doesn't appear to be used, and if it is, it's probably far more finicky to use than what I'm going to suggest.

How do you figure out what they all mean?

Practice and play around with it! Specifying [relative] will move the demo your specified number of ticks relative to the player's current position, so -640 will move you back 640 ticks from wherever you currently are. Specifying [pause] will pause the demo once it reaches the tick you gave.

And specifically, how would you bind a key to the action "jump forward to the next round"?

Well, unfortunately, you can't. Not by using the demo commands alone, anyway.

If your goal is just to watch a specific round over and over, then I suggest just clicking the "Watch" tab on your main menu and click the round you wanted to watch on the game you have recorded. Otherwise, you can hop around more easily with the Demo UI.

Accessible by pressing Shift + F2 by default, or by passing the console command demoui, this command opens a player that allows you to use a more intuitive control scheme than trying to manually use demo_gototick.

Here's a screenshot of what it looks like:

The Demo UI without a demo loaded, with all controls visible.

This dialog lets you jump forward and backward rounds, spectated player deaths, and adjust the timescale freely.

I strongly recommend you do not try to manually slide the time bar as it's very inconsistent and sort of buggy. Instead, jump around with timescale adjustments and the round/death forward and backward buttons.

You can rebind the demo UI to somewhere more friendly to press by simply sending a bind command in your console. As an example, bind "F8" "demoui" will bind it to your F8 key.


Per your update:

When I'm reviewing, I want to jump to the rounds of interest; and once the demoui has the "Next Round" button selected, Shift-F2, Space, Shift-F2 will jump to next round - as long as I never select anything else. Having a key that actually does this exact action would be far more reliable.

Well... You can bind multiple actions to a key. The syntax for that is...

bind "Key" "action1;action2;action3;" And so forth.

The problem here is that pressing "space" in this context isn't possible through binding. If it were, you could do bind "Key" "demoui 1;(space);demoui 0;", and it would work flawlessly.

To answer your question more directly:

There is currently no way to map skipping a round (forward or backwards) to a single key.

A workaround might be using a third-party macro recorder that sets off those series of commands whenever you press a preset key. Perhaps look into that?

| improve this answer | |
  • Context edited into the original question. And unfortunately, I also have found no documentation for the four-arg version, but it looks so tempting, as if all the power I need is hidden away in there... – rosuav Aug 4 at 20:50
  • 1
    I'm okay with not using the spacebar, that's just the way my workflow currently is. I'd much rather use something else. Incidentally, Shift-F2 is actually the least of my hassles here - it's fine to use the shifted key for the UI, the hassle is that button focus is essential. – rosuav Aug 4 at 21:23
  • 1
    My current line of thinking is: con_logfile, demo_listimportantticks, a game-state-integration server, and a cfg file that gets rewritten all the time with a demo_goto command with the tick number of the next round start. Rube Goldberg would be proud. – rosuav Aug 4 at 22:26
  • 1
    Heck, I'm impressed. Nice job ;) – Spevacus Aug 4 at 22:29
  • 1
    Thanks :) I already have game state integration for the other half of this (I hit a hotkey to record notes, and it automatically tags it with the round number and stuff), so hopefully it won't be TOO hard... – rosuav Aug 4 at 22:34
1

For anyone else who wants to do this, here's what it takes:

  1. Bind a key to exec a file containing this sequence of commands:

    con_logfile demoticks.log
    demo_listimportantticks
    con_logfile ""
    
  2. Run a game state integration (GSI) server that is aware of round, and possibly allplayers_id, map, and player_id.

  3. Whenever the GSI server is notified that the current round number has changed, have it parse the demoticks.log file, looking for lines saying Tick: 6750 Event: round_start. Be aware that the file will be appended to, not overwritten.

  4. The GSI server writes out a file with a demo_goto command with the next round's tick number. Oh, and just to confuse you, CS:GO considers the round-over period to be part of the next round, not the previous one. (But that's consistent with the behaviour of the next/prev round buttons in demoui.)

  5. Bind a key to exec that file. That key is now a "next round" key.

If this seems way WAY too complicated, you're absolutely correct. Petition Valve to support demo_goto +1round relative or something.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.