[CODE] playdemo 0.0.6.3, easily play back Urban Terror demos

Everything technical and nerdy stuff here plz !

[CODE] playdemo 0.0.6.3, easily play back Urban Terror demos

Postby Pirat » 06.08.11

(This page will be continuously edited upon each release)

This is a simple script for easily playing back Urban Terror demos on Linux.

Not thoroughly tested, but seems to work. =)

ADVANTAGES:
  • No need to rename file names due to Urban Terror case
    sensitivity bug.
  • Very easy selection of last <n> demos.
  • Very easy selection of demos downloaded to arbitrary
    directory..

NEEDS:
  • GNU/Linux incl. bash.

KNOWN LIMITATIONS: See list "TODOs" in the script.

DOWNLOAD: See attachment. Send PM for older versions.

INSTALLATION and INVOCATION
  • download and save as "playdemo.gz"
  • gunzip playdemo.gz
  • chmod a+rx playdemo
  • ./playdemo -h

SUPPORT: There is no guaranteed support of any kind, but if you have
problems, questions or suggestions, you can reply to this
post and hope for someone answering -- after reading the following:
  • playdemo -h


ChangeLog:
0.0.6.3
  • Fix: When multiple demos were specified, only maps for
    one of the demos were linked.

0.0.6.2
  • Fix: fs_basebath was not set, so it was always the latest client version
    that was used to play the demo.
  • Fix: UrT always reads the directory where the executable resides in
    (symlink does not help), so now the executable is an actual copy
    instead of a link. If you want the old behavior due to mass storage
    space constraints, use "--link-exe".

0.0.6.1
  • Add: Installed UrT versions are auto-detected now.
    Supported versions are 4.1 and 4.1.1.

0.0.6
  • Add: New flags '--urtversion=<desired UrT version number>' and
    '-u <desired UrT version number>'. Currently, only "4.1" and
    "4.1.1" are supported. May be needed if you want to watch a demo
    that was taken on a map where the server's version of the map
    differs from the client's version of the map, e.g. (IIRC) on 4.1.1,
    the following maps changed: ut4_ramelle, ut4_swim, ut4_uptown.
    You need to set this to the server version. Default is UrT 4.1.
    NOTE: With 'dm_68' installed, this switch is usually not needed,
    as the used UrT version gets auto-detected then.
  • New: Make use of the program 'dm_68', if installed, to link only the
    the map used in the demo, which makes UrT fire up *much* faster.
    dm_68 can be found here:
    http://skuller-vidnoe.narod.ru/downloads/dm_68.zip
    (You need an older version of GCC or alternatively patch it,
    see
    post34852.html#p34852
    )
    Needed if 'dm_68' cannot detect the map used, or if more than
    one (non-builtin) map is used in the demo.
  • Add: New flags '--all-maps' and '-a' to link *all* available maps, not
    only the one detected by dm_68.
  • New: If 'dm_68' is installed, the UrT version that was used on the server
    where the demo was taken is auto-detected, so you usually do not have
    to use '-u'.

0.0.5.2
- Chg: Bound "toggle r_shownormals" to MOUSE2, too.

0.0.5.1
- Chg: Improved Urban Terror binary search paths.

0.0.5
- Chg: Will search for Urban Terror binary automatically, if $URT is not set.

0.0.4
- Add: Select the last <n> demos to be played via "-<n>" option.
- Chg: More robustness.
- Chg: yes/no prompt for each demo.
- Chg: Print key / mouse bindings.
Attachments
playdemo-0.0.6.3.gz
****** LATEST VERSION ******
(6.38 KiB) Downloaded 1725 times
Last edited by Pirat on 06.16.11, edited 4 times in total.
Pirat
Godlike
 
Posts: 1447
Joined: 03.29.10
-----tdm:  
nick: Pirat
skill: 507.365
kills: 402
deaths: 636
ratio: 0.63

Re: [CODE] playdemo 0.0.4, easily play back Urban Terror demos

Postby draik » 06.08.11

Pirat started a new project yepi!!.
I think i'll test it tomorrow :)
User avatar
draik
Godlike
 
Posts: 181
Joined: 05.15.10
-----tdm:  
nick: draik
skill: 719.364
kills: 5
deaths: 14
ratio: 0.35

Re: [CODE] playdemo 0.0.4, easily play back Urban Terror demos

Postby PingoSuSE » 06.10.11

tried it now, but it's not playing any demo :( .... Here's what I get in console

Code: Select all
pingo@dhcppc0:~/UrbanTerror$ ./playdemo-0.0.4 -2                                                   
No demo(s) specified, looking for last demo(s) taken in
  '/home/pingo/.q3a/q3ut4/demos' ...                                                               

DEMOLIST:                                                                                           
/home/pingo/.q3a/q3ut4/demos/2011_6_9_18_41_56__4Pingo_SRB__ut4_subway_TDM.dm_68
/home/pingo/.q3a/q3ut4/demos/2011_6_9_18_42_21__4Pingo_SRB__ut4_subway_TDM.dm_68

{ Using tmpdir /tmp/playdemo-0.0.4-1000-hBXMZM8d }

The following key / mouse bindings are in effect:

  numpad 8:       toggle r_shownormals
  numpad 4/5/6/+: timescale 0.3 / 1 / 2 / 3
  mousewheel:     timescale 0.1 - 100
  numpad 1/2:     video / stopvideo
  numpad 0:       quit


DEMO: /home/pingo/.q3a/q3ut4/demos/2011_6_9_18_41_56__4Pingo_SRB__ut4_subway_TDM.dm_68
Watch this demo? [Yn]y
DEMO: /home/pingo/.q3a/q3ut4/demos/2011_6_9_18_42_21__4Pingo_SRB__ut4_subway_TDM.dm_68
Watch this demo? [Yn]pingo@dhcppc0:~/UrbanTerror$


I've run it with/without started game but neither way plays demo. Am I doing something wrong?
Image
User avatar
PingoSuSE
Ingame Mod
 
Posts: 537
Joined: 02.23.09
Location: kn03xh
-----tdm:  
nick: pingo
skill: 544.684
kills: 495
deaths: 461
ratio: 1.07

Re: [CODE] playdemo 0.0.4, easily play back Urban Terror demos

Postby Pirat » 06.10.11

PingoSuSE wrote:tried it now, but it's not playing any demo :( .... Here's what I get in console

Code: Select all
pingo@dhcppc0:~/UrbanTerror$ ./playdemo-0.0.4 -2                                                   
[...]
DEMO: /home/pingo/.q3a/q3ut4/demos/2011_6_9_18_41_56__4Pingo_SRB__ut4_subway_TDM.dm_68
Watch this demo? [Yn]y
DEMO: /home/pingo/.q3a/q3ut4/demos/2011_6_9_18_42_21__4Pingo_SRB__ut4_subway_TDM.dm_68
Watch this demo? [Yn]pingo@dhcppc0:~/UrbanTerror$


I've run it with/without started game but neither way plays demo. Am I doing something wrong?

Yyyyno. :-}

I forgot to mention that it needs adaption of the first occurence of the
variable "URT" in the script (line 28). The variable should contain
the name of the Urban Terror binary, including the full path.

The next version will search in a few paths automatically, promised.
:-}

Thanks for the report!


--
Posted using postdemo 0.0.9.12
Pirat
Godlike
 
Posts: 1447
Joined: 03.29.10
-----tdm:  
nick: Pirat
skill: 507.365
kills: 402
deaths: 636
ratio: 0.63

Re: [CODE] playdemo 0.0.4, easily play back Urban Terror demos

Postby PingoSuSE » 06.10.11

yay .... it works when I've changed line 28 :mrgreen: :D
Image
User avatar
PingoSuSE
Ingame Mod
 
Posts: 537
Joined: 02.23.09
Location: kn03xh
-----tdm:  
nick: pingo
skill: 544.684
kills: 495
deaths: 461
ratio: 1.07

Re: [CODE] playdemo 0.0.4, easily play back Urban Terror demos

Postby Pirat » 06.10.11

PingoSuSE wrote:yay .... it works when I've changed line 28 :mrgreen: :D

Yayyyyy! 8-)

If you want, you can test version 0.0.5 which I just uploaded, and
tell me where your Urban Terror binary resides, then I can
amend the search path, if necessary.

--
Posted using postdemo 0.0.9.12
Pirat
Godlike
 
Posts: 1447
Joined: 03.29.10
-----tdm:  
nick: Pirat
skill: 507.365
kills: 402
deaths: 636
ratio: 0.63

Re: [CODE] playdemo 0.0.5, easily play back Urban Terror demos

Postby PingoSuSE » 06.10.11

Well, it looked everywhere but my home directory :lol: .... after path change, it works OK ;)
Image
User avatar
PingoSuSE
Ingame Mod
 
Posts: 537
Joined: 02.23.09
Location: kn03xh
-----tdm:  
nick: pingo
skill: 544.684
kills: 495
deaths: 461
ratio: 1.07

Re: [CODE] playdemo 0.0.5, easily play back Urban Terror demos

Postby Pirat » 06.10.11

PingoSuSE wrote:Well, it looked everywhere but my home directory
:lol: .... after path change, it works OK ;)

w0000t?!

Can you give me the path to your binary (if it doesn't have a component
that is too personal :-)? Maybe it's something common ...

--
Posted using postdemo 0.0.9.12
Pirat
Godlike
 
Posts: 1447
Joined: 03.29.10
-----tdm:  
nick: Pirat
skill: 507.365
kills: 402
deaths: 636
ratio: 0.63

Re: [CODE] playdemo 0.0.5, easily play back Urban Terror demos

Postby PingoSuSE » 06.11.11

I have URT installed in
/home/pingo/UrbanTerror .... there resides my binary :)

What do you think about adding extra line between 208-216 like
Code: Select all
/home/*/*/ioUrbanTerror.i386 \

so it looks whole home folder for binary :?:
Image
User avatar
PingoSuSE
Ingame Mod
 
Posts: 537
Joined: 02.23.09
Location: kn03xh
-----tdm:  
nick: pingo
skill: 544.684
kills: 495
deaths: 461
ratio: 1.07

Re: [CODE] playdemo 0.0.5, easily play back Urban Terror demos

Postby wurst » 06.11.11

dont u fear the suse!
Image
User avatar
wurst
Godlike
 
Posts: 4648
Joined: 07.15.08
Location: Behind U
-----tdm:  
nick: [dswp]GewitterOma
skill: 1122.83
kills: 25960
deaths: 19847
ratio: 1.30
-----bomb:  
nick: [dswp]GewitterOma
skill: 812.172
kills: 3885
deaths: 3541
ratio: 1.09

Next

Who is online

Users browsing this forum: No registered users and 9 guests

Misc