Inside3D!
     

V Weap Animations in Quake

 
Post new topic   Reply to topic    Inside3d Forums Forum Index -> QuakeC Programming
View previous topic :: View next topic  
Author Message
Snarboo



Joined: 07 Mar 2007
Posts: 2

PostPosted: Wed Mar 07, 2007 8:08 am    Post subject: V Weap Animations in Quake Reply with quote

I've been playing around with perQuake and wanted to make a similar mod, but I'm not sure how view weapon animations are handled in Quake. In perQuake, the weapons have a bunch of new animations and doodads. For instance, a weapon will play an animation(cock the weapon, insert a magazine etc) when the corresponding impulse key is pressed. I want to copy ths, and I've read through the weapons and player QC in the clean 1.06 Progs and sort of understand how animations work in Quake, but I'm still confused. I've studied the weapon models in perQuake as well and they seem to have multiple frames(reload, fire, etc) like monsters, so I'm wondering if I should create a new QC file with $frame definitions?

Edit: I think I'm starting to figure this out now, but I'll keep this post open in case I need more help. Sorry about that. :/
Back to top
View user's profile Send private message
leileilol



Joined: 15 Oct 2004
Posts: 1321

PostPosted: Wed Mar 07, 2007 7:02 pm    Post subject: Reply with quote

defined player.qc's player_shot, player_rock etc... frames that set a self.weaponframe = blah. For smoother animation, toss in a self.nextthink = time + 0.03; or some other smaller than 0.1 number
_________________
Back to top
View user's profile Send private message
RenegadeC



Joined: 15 Oct 2004
Posts: 370
Location: The freezing hell; Canada

PostPosted: Wed Mar 07, 2007 8:15 pm    Post subject: Reply with quote

You can also run self.weaponframe in playerprethink(); so that weapon frames do not rely on player animations. This is how I got the reloading shotgun frames in my Starship Troopers mod without the player "ice skating" around. Playerprethink runs every frame, so you'll have to define a new float in order to keep track of how fast the animation should play.
Back to top
View user's profile Send private message AIM Address MSN Messenger
Snarboo



Joined: 07 Mar 2007
Posts: 2

PostPosted: Thu Mar 08, 2007 5:45 am    Post subject: Reply with quote

Thanks, that helps! I was thinking along those same lines after studying the .qc files more.
Back to top
View user's profile Send private message
Urre



Joined: 05 Nov 2004
Posts: 1073
Location: Sweden

PostPosted: Thu Mar 15, 2007 10:05 am    Post subject: Reply with quote

The ice-skating and related problems baffled me for a good while when I was starting out. The fact that playermodel animations and viewmodel animations are tied in some cases, but in other cases not, is some seriously bad design by id. It should be either or Razz
_________________
Look out for Twigboy
Back to top
View user's profile Send private message Visit poster's website
Sajt



Joined: 16 Oct 2004
Posts: 1026

PostPosted: Thu Mar 15, 2007 3:33 pm    Post subject: Reply with quote

I don't think so... Unless they had multi-part animations in their model format, or run+shoot animations, it makes perfect sense to me Smile
_________________
F. A. Špork, an enlightened nobleman and a great patron of art, had a stately Baroque spa complex built on the banks of the River Labe.
Back to top
View user's profile Send private message
Urre



Joined: 05 Nov 2004
Posts: 1073
Location: Sweden

PostPosted: Fri Mar 16, 2007 3:41 pm    Post subject: Reply with quote

Sajt: consistency > weirdness!
_________________
Look out for Twigboy
Back to top
View user's profile Send private message Visit poster's website
Sajt



Joined: 16 Oct 2004
Posts: 1026

PostPosted: Sat Mar 17, 2007 3:37 am    Post subject: Reply with quote

If you're talking about how the nailgun animation frames are what shoot the bullets, I agree with you...
_________________
F. A. Špork, an enlightened nobleman and a great patron of art, had a stately Baroque spa complex built on the banks of the River Labe.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Inside3d Forums Forum Index -> QuakeC Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2004 phpBB Group