Announcement

Collapse
No announcement yet.

Change player model QuakeC

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Change player model QuakeC

    I'm trying to change the player model, to the model of the knight. Is this even possible and if so, in the quakec src how would one go about doing this? Is it just as simple as changing a string somewhere or does it actually involve modding the model/animations?

  • #2
    there's some self.modelindex = player_modelindex; (vs eyes/invis model) hack somewhere in client.qc that makes changing models really messy.

    note that if you call setmodel (instead of faffing around with modelindexes), then you WILL need to call setsize (almost immediately) afterwards to ensure the player didn't change sizes and bug out.

    and once you've actually changed the model, you'll need to do something about the hardcoded frame numbers that are shoved throughout all of the various 'state' functions in player.qc.
    the '$frame f1,f2,f3' thing at the top of the file defines $f1 $f2 $f3 with increasing values. the qcc interprets them as constants and are exactly equivelent to any float immediate (eg: 5.0). this means that if you do change a model, you will need to either make full duplicates of every single function, or the whole animation thing much more explicitly.
    Some Game Thing

    Comment


    • #3
      The following mod, RQP+ (a variant of RuneQuake) you can play as a monster (Vore, Shambler, maybe Ogre too --- maybe more than that). Mr. Burns is a fan of this mod and hosts it from time to time I think so he's probably rather fresh on how everything works.

      The QuakeC source code is in the download.

      http://www.quakeone.com/q1files/down...ot-8-27-03.exe

      /Yeah, .exe not .zip --- but that is how the author packaged it.

      So that may help you.
      Quakeone.com - Being exactly one-half good and one-half evil has advantages. When a portal opens to the antimatter universe, my opposite is just me with a goatee.

      So while you guys all have to fight your anti-matter counterparts, me and my evil twin will be drinking a beer laughing at you guys ...

      Comment


      • #4
        I already have the quakec src all setup on my computer. I'm gonna take spikes direction and play around with it. Hopefully I can get it to work we shall see, I'll post some screens if I figure it out. Thanks guys.

        Comment


        • #5
          you should be able to find the setmodel() for the player entity (in client.qc) and change it to "knight.mdl", but you'll have to change the .frame values used in player.qc.

          For example, I looked in knight.qc to see that the stand1() animation uses frames 0 through 8. player.qc's stand1() animation is only one function, but it iterates through frames 12 through 16 (or 17 through 28 if holding axe). Thus, the 12 here should be 0, and the 5 should be 9. (9 will be the number it flips to zero.) [The knight doesn't have a gun-holding animation, so you won't need the 'else' statement for not holding the axe.]

          Follow through changing run1() in a similar manner. For death and attack animations, you'll have to do it number by number, and sometimes add/remove functions to handle more or less animation frames.

          Comment


          • #6
            if you're trying to make it the default model. just change it to the knights model in qc, then redo all the animation qc and setup weapons in qc that match the knights model and animations.

            Comment


            • #7
              the weapon view models aren't gonna match so you might want to add a chasecam so you can view yourself in third person.
              SuperDuper Quake 3.0

              Comment

              Working...
              X