View previous topic :: View next topic |
Author |
Message |
Baker

Joined: 14 Mar 2006 Posts: 1538
|
Posted: Mon Nov 17, 2008 1:43 am Post subject: Weapon in hand (vwep?) with DarkPlaces? How? |
|
|
I saw a mod screenshot posted here a few months ago that showed a Quake guy wielding a key as a weapon.
I don't know the name of the mod or if it is open source or if there is source code somewhere in the bowels of this forum explaining the technique.
Does anyone either
1. know how this is done
2. know the url of a thread where info was posted on this in the past
3. Or know the source of a mod that does this.
It is my understanding that Deathmatch Essentials mod cheated and the weapons are part of the player model, so you couldn't have the player wield just anything as a weapon.
In particular, I think it would be cool to have different single player bad guys with different weapons. |
|
Back to top |
|
 |
MauveBib

Joined: 04 Nov 2004 Posts: 602
|
Posted: Mon Nov 17, 2008 2:47 am Post subject: |
|
|
There are three ways it can be done:
Firstly, by modelling and animating the guns directly onto the player model, having one player model for each weapon. As you guessed, this is how it's usually done in most VWEP mods.
Secondly by having the guns in seperate model files, with matching animation frames to the player, and superimposing one on top of the other by having an entity that follows the player around and matches frames. This only works for a 3rd person view, or an engine that supports DP_SV_NODRAWTOCLIENT or similar, else the player will see the weapons floating around in front of him in 1st person view. This is how Prydon Gate does it.
Thirdly is via MD3 tagging, which is obviously only available for engines that support MD3 models. This is probably the best method if available, because the weapon models don't each need to be animated to match frames, the tagging takes care of it. _________________ Apathy Now! |
|
Back to top |
|
 |
Baker

Joined: 14 Mar 2006 Posts: 1538
|
Posted: Mon Nov 17, 2008 3:47 am Post subject: |
|
|
MauveBib wrote: | Secondly by having the guns in seperate model files, with matching animation frames to the player, and superimposing one on top of the other by having an entity that follows the player around and matches frames. This only works for a 3rd person view, or an engine that supports DP_SV_NODRAWTOCLIENT or similar, else the player will see the weapons floating around in front of him in 1st person view. This is how Prydon Gate does it.
Thirdly is via MD3 tagging, which is obviously only available for engines that support MD3 models. This is probably the best method if available, because the weapon models don't each need to be animated to match frames, the tagging takes care of it. |
FrikaC released the Prydon source a while back so I should be able to take a look at that and see how it's done.
I knew MD3 supports tagging, sometime I'll need to dig through the Nexuiz source and learn how MD3 works in QuakeC.
Thanks for your help. If I achieve anything of this, I'll write up a tutorial from what I do. |
|
Back to top |
|
 |
Spirit

Joined: 20 Nov 2004 Posts: 476
|
Posted: Mon Nov 17, 2008 8:51 am Post subject: Re: Weapon in hand (vwep?) with DarkPlaces? How? |
|
|
Baker wrote: | 2. know the url of a thread where info was posted on this in the past | I think it was at http://qexpo.tastyspleen.net/booth.php?id=49&page=268
Something at QExpo, that I remember for sure. _________________ Quake Maps |
|
Back to top |
|
 |
Baker

Joined: 14 Mar 2006 Posts: 1538
|
Posted: Mon Nov 17, 2008 8:59 am Post subject: Re: Weapon in hand (vwep?) with DarkPlaces? How? |
|
|
Yeah. That'd be it. |
|
Back to top |
|
 |
leileilol

Joined: 15 Oct 2004 Posts: 1321
|
Posted: Mon Nov 17, 2008 11:57 am Post subject: |
|
|
it's a mod i made in 2007 and never released it.
Also, I lost it.
Forever.
was a good qc exercise though |
|
Back to top |
|
 |
MauveBib

Joined: 04 Nov 2004 Posts: 602
|
Posted: Mon Nov 17, 2008 1:00 pm Post subject: |
|
|
Just thought of a 4th way: the locations and angles for the model carried for each frame get hardcoded into the qc. Downside is that it's horribly time consuming, especially for models with lots of frames. On the upside, once it's coded it'll allow anything to be carried. _________________ Apathy Now! |
|
Back to top |
|
 |
|