Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

-timedemo does not play/time demo #64

Closed
Xymph opened this issue May 16, 2021 · 21 comments
Closed

-timedemo does not play/time demo #64

Xymph opened this issue May 16, 2021 · 21 comments

Comments

@Xymph
Copy link

Xymph commented May 16, 2021

Describe the bug
After recording a demo, -playdemo to view it works, but -timedemo to time it doesn't: a black screen is shown, which can be exited by traversing the (invisible) menu, and no tics count message is shown.

To Reproduce
Steps to reproduce the behavior:

  1. Start a command prompt window and go into Steam's D3BFG folder which has BFA installed.
  2. Record a demo on (e.g.) Nerve map01: DoomBFA -record nervemap01 -exp 2 -warp 1
  3. Time it: DoomBFA -timedemo nervemap01
  4. After selecting DoomII in the main BFG screen, a black screen appears but nothing happens for 10-15 minutes.
  5. Hitting Esc, cursor Up, Enter, Enter allows to close the game cleanly.

Expected behavior
A timed playback of the demo (usually without fps limiter), ending in a message with the number of gametics in the demo (and optionally realtics and FPS). That's how other Doom ports do it at least.

Desktop (please complete the following information):

  • OS: Win7 64-bit

Additional context
View demo: DoomBFA -playdemo nervemap01
After selecting DoomII in the main screen, this plays back the demo as expected (although it desyncs within a few minutes, which is probably a separate problem).

@MadDeCoDeR
Copy link
Owner

I will have to undust a little bit the Demo code and do some tests on my own. Thanks for the feedback.
As for the desync, make sure you are not toying with the settings while it's playing.

@MadDeCoDeR
Copy link
Owner

One issue I found is that the file name has more than 8 characters. On Classic DOOM files must be named with max 8 chars. Also I mentioned another bug that might be causing desync issues

@Xymph
Copy link
Author

Xymph commented May 16, 2021

Oh, confession time: the actual filename I used was 'ttt' as a quick first go. But that sounded too silly for this report, so I changed it, only here. ;)
I recorded another demo with "-doom -record doome1m8 -warp 1 8" but it exhibits the same -timedemo behavior as the Nerve map01 one. Just doesn't desync in playback but it runs for only 3:08 -- the Nerve one lasts 8:06 and I didn't touch mouse/keyboard, but desync happens after about 2:40.

@MadDeCoDeR
Copy link
Owner

Ok, as for the timedemo. What you are trying to achieve with it? When any demo plays or is getting recorded the engine is forced to the original framerate (35FPS) for compatibility reasons. Also the ENDOOM screen is not available in the first place.

@Xymph
Copy link
Author

Xymph commented May 16, 2021

I added support for this demo format in my stats library (forums thread), and would like to confirm the exact tics count in demo samples with the engine's count.

@MadDeCoDeR
Copy link
Owner

I see. Ok, then I will try to rewrite -timedemo command in order to output in a text file demo's statistics. (I think the original code for it might be removed)

@Xymph
Copy link
Author

Xymph commented May 16, 2021

A file is one option, other ports just display a pop-up box, or a console message, or an exit message in the command window -- e.g. depending on whether or not the application closes after timedemo finishes.

[nevermind, found my mistake]

MadDeCoDeR added a commit that referenced this issue May 18, 2021
…es (ref #64)

NOTE: For compatibility with the vanilla engine (v1.11) avoid using weapon circling
@MadDeCoDeR
Copy link
Owner

MadDeCoDeR commented May 18, 2021

The source code is updated and -timedemo aside from playing the demo, in it's end it will generate a .txt file in the same folder and with the same name the demo has (aka usually in C:\Users\ "username"\Saved Games\Id Software\DOOM BFA\ "base or name of D3 mod"\DEMO)

@Xymph
Copy link
Author

Xymph commented May 19, 2021

Thanks. I'm unable to build BFA from source atm, so I'll try it after the next binaries release.

@MadDeCoDeR
Copy link
Owner

That's gonna take some time. I want to add two new features and they require quite some work (even through some basics are done)

@Xymph
Copy link
Author

Xymph commented May 19, 2021

I understand, no problem. Thanks again for attending to this small issue so quickly.

@MadDeCoDeR
Copy link
Owner

Is now available. (I hope I didn't break it)

@Xymph
Copy link
Author

Xymph commented Nov 1, 2021

Hmm, maybe that happened: using the ttt.lmp (renamed to nerve01.lmp) demo I recorded in May, both DoomBFA -playdemo nerve01 and DoomBFA -timedemo nerve01 lock up the launcher as soon as I select Doom II. A rotating "application not responding" mouse cursor results, and Escape exits everything.

Also, DoomBFA -record nerve02 -exp 2 -warp 2 (to try another level) plays the game fine, but doesn't actually save the .lmp file after exiting.

@MadDeCoDeR
Copy link
Owner

Are you sure the lmp is on C:\Users\ "username"\Saved Games\Id Software\DOOM BFA\ "base or name of D3 mod"\DEMO folder?

@MadDeCoDeR
Copy link
Owner

Also make sure that you have either finished the level or died in order to finish the demo recording

@Xymph
Copy link
Author

Xymph commented Nov 2, 2021

Oops, I hastily forgot to look in that folder. Yes, nerve02.lmp was written there, I did finish the level. But as before, after copying to the game directory, it doesn't playdemo or timedemo.

@MadDeCoDeR
Copy link
Owner

Load it from the same directory that is written

@Xymph
Copy link
Author

Xymph commented Nov 2, 2021

That is a very long path, annoying to type. And the file exists in both DEMO and game directories anyway, so why should that matter? The game can most easily be invoked in a command prompt window after first cd-ing to the game directory. In other ports, the game will load the demo from the local directory, without path or extension, too.

If you can actually play back / time a demo, please explain the detailed steps.

@MadDeCoDeR
Copy link
Owner

Well I used the -record command like you do. And then I used either the -playdemo or -timedemo followed by the name of the demo lump (I haven't moved it from the folder). So it's something like DoomBFA -playdemo nerve02

@Xymph
Copy link
Author

Xymph commented Nov 2, 2021

I didn't move it, see "copying" above. ;)
Anyway, I don't understand why it didn't work before or does now, but... it does. 😅 Playback and timing, with a nerve02.txt file created:

GameTics: 17428
Level Tics: 17428
Level Time: 497
FPS: 35

Looks like these are the tics/time until level end, rather than the total length of the demo, as I stopped recording a second into the next level. So my stats are 17445 / 498.43s. But that's fine, I understand your choice of where to wrap up the timing and write out the file.

So thanks for your work on this, this issue can be closed. 👍

@Xymph
Copy link
Author

Xymph commented Nov 2, 2021

Btw, if I were to make one tiny suggestion: make the file more readable in Notepad by using DOS newlines (\r\n).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants