home *** CD-ROM | disk | FTP | other *** search
/ Qu-ake / Qu-ake.iso / qu_ke / patches / 012 / DEMOCAM.TXT < prev    next >
Encoding:
Text File  |  1996-10-17  |  9.8 KB  |  212 lines

  1.  
  2.  
  3.                   DemoCam v0.8
  4.                        by
  5.                    Harlequin
  6.               (dtebben@alumni.caltech.edu)
  7.  
  8.  
  9. Operating Systems Supported
  10. ---------------------------
  11. Definitely DOS/Win95, probably Linux (can't think why not).
  12.  
  13.  
  14. How It Works
  15. ------------
  16. DemoCam is a patch for QuakeC that allows you to play back demos from
  17. a different viewpoint than you recorded them with.  For example, you
  18. can record a demo in the first person as normal, then convert it to
  19. play back from a chase camera located above & behind your character.
  20.  
  21. The bad news is that of the 3 playback modes I originally intended to
  22. support, only the chase cam works well.  See Known Bugs, below.
  23.  
  24.  
  25. How To Use It
  26. -------------
  27. First you need to compile the mod using QCC.  Get a version suitable
  28. for your OS from ftp.cdrom.com or http://www.stomped.com.  After you
  29. install QCC, copy all the files from V101QC (a subdir of QCC) into a
  30. new, empty subdir named "democam" off of your Quake directory.  Now
  31. unzip democam.zip into the democam subdirectory, answering "yes" to
  32. any queries about overwriting files.  Run QCC in that directory and
  33. it will generate a file called progs.dat.
  34.  
  35. Now start up Quake with the command-line argument "-game democam" and
  36. start recording a demo (syntax is "record <demoname> <mapname>").
  37. At some point during the demo, issue the command "impulse 16" from the
  38. console, or bind impulse 16 to a key and press it.  You'll notice that
  39. you character's weaponmodel (the weapon at the bottom of the screen)
  40. has vanished.  Run around a while, finish recording by typing "stop" at
  41. the console, and quit from the game.  Here comes the tricky part.
  42.  
  43. Fire up your favorite text editor/word processor/file viewer (Win95's
  44. Wordpad works fine), and load the .dem file you just recorded.  It
  45. will largely be a bunch of meaningless junk, but search for a part
  46. that reads "alias disconnect".  There should be two of them almost in
  47. a row, looking something like this:
  48.  
  49. ****A*    alias disconnect      ******    alias disconnect
  50.  
  51. There may be some carriage returns, etc. in there.  "*" are all the same
  52. character, but may appear different depending on your editor; they're
  53. not important.  What is important is the "A".  It may or may not be an
  54. A, it may not even be a standard ASCII printable (in which case you'll
  55. have to copy and paste it).  Whatever it is, it will always be the
  56. next-to-last character in a string of otherwise identical ones.  What
  57. you have to do is replace the "alias disconnect" bits with this:
  58.  
  59. ****A*    alias disconnect      ****A*    alias disconnect
  60.  
  61. Note that you are changing ONLY ONE CHARACTER, the next-to-last non-
  62. space letter before the second "alias disconnect".  Replace it with
  63. whatever the corresponding character in front of the first "alias
  64. disconnect" is, in this case "A".  Assuming that you only pressed
  65. impulse 16 once, you will only have to make this one alteration in the
  66. file.
  67.  
  68. The demo is now ready for viewing.  Go back into Quake and run it
  69. with "playdemo <demoname>".  If you did everything right, your view
  70. will have switched to a chase camera and stayed there until the end
  71. of the demo.
  72.  
  73. If all this isn't clear, don't despair.  I included two demos in the
  74. .zip that show how it should be done.  Their names are "1stper.dem",
  75. a normal demo in the first person, and "3rdper.dem", which is played
  76. from a chase cam.  The only difference between these two files is one
  77. byte.  Examine them a little and you'll see how to do it.  If all
  78. else fails, email me.
  79.  
  80. I strongly suggest backing up your demos before altering them.
  81.  
  82.  
  83. Impulse Commands & Other Docs
  84. -----------------------------
  85. You can use the following impulse commands in DemoCam:
  86.  
  87. -- impulse 15: toggle show/hide weaponmodels while recording
  88. -- impulse 16: start a demo chase cam on yourself
  89. -- impulse 17: start the Top Dog Chase Cam (see Known Bugs)
  90. -- impulse 18: start the Intermission Cam (see Known Bugs)
  91. -- impulse 19: stop your current chase cam from recording
  92. -- impulse 20: toggle your view between your character and your
  93.                currently active Demo Cam
  94.  
  95. Of these 6, only impulses 15 and 20 have any effect on the game as
  96. it is being played.  The rest only affect the playback of the demo.
  97. The weaponmodel toggle is so that they don't show up in the demo.
  98. Personally I don't mind having it not there in the game, but if you
  99. really feel you need it you can turn it on.  (I play with crosshairs
  100. and use them for aiming anyway).  For a really clean look when playing
  101. demos, max out the screen size and turn off the crosshairs.
  102.  
  103. It's possible to activate multiple cameras in succession in a single
  104. demo.  Every time you activate a camera or use impulse 20 to switch
  105. *back from* (not *to*) your demo camera view during the game, two more
  106. "alias disconnect" markers will be inserted into the .dem file and you
  107. will have to make the appropriate changes for the demo to turn out
  108. properly (see How To Use It, above).
  109.  
  110. The model I used for the camera is a bubble, like those that spawn
  111. when you drown.  There is no "null" model in Quake, so it had to be
  112. something.  If you want you can change the model to "null.spr", a
  113. blank model file that I got from Eli's Kuaqe2 mod; just be aware that
  114. anyone who doesn't have the file won't be able to play the demo.  You
  115. have to uncomment two lines and recompile to do this: one at the
  116. beginning of weapons.qc (in the precache functions), and one in
  117. democam.qc.  Both should be fairly obvious.
  118.  
  119. Why "alias disconnect"?  Well, it's one of two console commands I
  120. know of that does absolutely nothing, and doesn't interfere with the
  121. user's config in any way.  (The other is "alias quit").
  122.  
  123. If you want to, you can delete the centerprinted messages from the
  124. demo.  Just be sure to get rid of the message text *only*.  I suggest
  125. you replace it with spaces rather than actually removing it and thus
  126. changing the size of the file; you never know what might happen.
  127.  
  128.  
  129. Known Bugs
  130. ----------
  131. -- Unfortunately, it is not possible (AFAIK) for anyone other than the
  132. server to record a demo in Quake.  This means that you can only record
  133. a demo if you are running a listen server or playing single-player.
  134. Maybe this will be fixed in QuakeWorld (maybe it'll bring world peace
  135. too :-) ).
  136.  
  137. -- There may be some places on levels where cameras don't work right
  138. (all the SetViewPort network command stuff is a little wonky).  The only
  139. place I know of is the single-player start room of e4m7, but there could
  140. be others.  Be careful, and back up your demos!
  141.  
  142. -- It is not possible for DemoCam recordings to persist between levels.
  143. If not turned off, the demo will simply record a blank screen for all
  144. levels past the first.  Therefore I have set the mod to automatically
  145. stop recording when the level changes.
  146.  
  147. -- In coding mods, there are two brick walls that I have run into time
  148. and time again.
  149.      1) If a client's viewport gets too far away from the client,
  150.     the viewport hangs (i.e. stops updating).  This is seemingly
  151.     determined by some property of the level, because I have played
  152.     on homebrewed maps where it is not a problem.  On id's levels
  153.     it is chronic.
  154.      2) The viewport facing is always determined by the client's
  155.     facing.  I suspect there is a way around this, because during
  156.     the intermission the client's view is frozen in place (of course
  157.     he is also paralyzed).  The problem is that you can't be facing
  158.     one way and "looking" another, which is bad news if your camera
  159.     is facing a different direction.
  160.  
  161.      If anyone figures out a way around either of these, *please* tell
  162.      me!  I've seen the 1st one circumvented by creating a "doppleganger"
  163.      of the client that moves and takes damage while the "real" client
  164.      is off being something else, e.g. a guided missile.  This is
  165.      unworkable in DemoCam because both the camera and player need to
  166.      have updating displays.
  167.     
  168. -- The Top Dog Chase Cam was originally meant to be a chase camera that
  169. would follow whoever had the highest current frag count.  This would be
  170. great if it worked, but it falls foul of the two problems listed above.
  171. If the camera is too far away from its owner, the view never updates;
  172. also, the camera angle is determined by the owner's facing, which creates
  173. weird, frustrating, and unwatchable demos.
  174.  
  175. -- Likewise the bugs kill the Intermission Cam, which would have been
  176. a camera that warped around to the most active intermission sites to
  177. observe deathmatches in progress.  You can still use it with impulse 18.
  178. Note that it can only be activated if there is a player in line-of-sight
  179. with an intermission spot.  This prevents the view from screwing up, as
  180. it occasionally will if there are no players around when it switches.
  181.  
  182. So the upshot is that the only thing you can really do with this mod
  183. (at present) is convert first-person demos to a third-person chase cam.
  184. Hopefully in future versions some of these bugs will be fixed, or
  185. someone will come up with a cooler implementation.  I think it's an idea
  186. with potential, and I'm releasing it so others can improve on it.
  187.  
  188.  
  189. Copyright and Distribution Information
  190. --------------------------------------
  191. This program is free software; you can redistribute it and/or modify it
  192. under the terms of the GNU General Public License as published by the Free
  193. Software Foundation; either version 2 of the License, or (at your option)
  194. any later version.
  195.  
  196. This program is distributed in the hope that it will be useful, but
  197. WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
  198. or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  199. for more details.
  200.  
  201. For a copy of the GNU General Public License, write to the Free Software
  202. Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  203.  
  204.  
  205. Credits
  206. -------
  207. id Software, for...well, you know why :-).
  208.  
  209. Eli (apathas@mailhost.primenet.com) for the chasecam tracking code from
  210. his Kuaqe2 mod.
  211.  
  212.