Tempust85 Posted September 8, 2013 Posted September 8, 2013 Ok so I've been trying to stop the auto third person for melee from happening in OpenJK, and I have this: Now how do I set different third person settings (range, etc) for just melee and not have it affect when the player goes into third person via "cg_thirdperson"?
Onysfx Posted September 8, 2013 Posted September 8, 2013 Darn, I feel like I have the answer on the tip of my tongue, even though I know nothing about this stuff...wish I knew the answer to this.
Tempust85 Posted September 8, 2013 Author Posted September 8, 2013 Hmmm, a better way might be to get an .md3 to load for melee's first person...
Circa Posted September 8, 2013 Posted September 8, 2013 You can look how the author of this mod did it. It's not exactly the perfect solution but it works. It's not a coding solution unfortunately.
Tempust85 Posted September 8, 2013 Author Posted September 8, 2013 I managed to allow first person for melee while removing the player model and slotting in an md3 view model. However it doesn't fire any animations like the other weapons. :\
eezstreet Posted September 8, 2013 Posted September 8, 2013 Try looking at MapTorsoAnimToWeaponFrame (I think is what it's called?) in cg_weapons.c[pp]. You'll need to add cases for the melee anims (not sure what those are right off the top of my head)
Tempust85 Posted September 9, 2013 Author Posted September 9, 2013 Found it, was MapTorsoToWeaponFrame Thanks eez, that did the trick. Now plays two viewmodel animations that match up to the player model anims. Circa likes this
eezstreet Posted September 9, 2013 Posted September 9, 2013 Could you provide a video? I'm curious of how this turned out.
Tempust85 Posted September 9, 2013 Author Posted September 9, 2013 https://www.youtube.com/watch?v=deHCQq3yEYQ Things I did: - removed the auto third person switch for WP_MELEE- removed ammo count for WP_MELEE- added BOTH_MELEE1, BOTH_MELEE2 & BOTH_STAND6 to "MapTorsoToWeaponFrame" in cg_weapons.cpp- changed anim length & anim starts for BOTH_MELEE1 & BOTH_MELEE2 (to match up to the player animations) to work with a 36 frame MD3 file The hit effect shows in the middle around the crosshair, which works. Each arm is seperated, so I have: fists.md3fists_barrel.md3 Then of course, the animation: fists_hand.md3 Stoiss, Circa, Archangel35757 and 2 others like this
eezstreet Posted September 9, 2013 Posted September 9, 2013 Excellent, most excellent. Tempust85, Stoiss and therfiles like this
Tempust85 Posted September 9, 2013 Author Posted September 9, 2013 Works great for DF2, but would need something else for multiple player models like JKA.
Circa Posted September 9, 2013 Posted September 9, 2013 Works great for DF2, but would need something else for multiple player models like JKA. Right, but it would work for JK2 as well. Tempust85 likes this
Merek Posted September 15, 2013 Posted September 15, 2013 use JA++ then hit p to toggle between first and third person.
Tempust85 Posted September 15, 2013 Author Posted September 15, 2013 I'd rather full access to the code which is why I went the OpenJK route.
Circa Posted September 15, 2013 Posted September 15, 2013 use JA++ then hit p to toggle between first and third person.This is for SP and for melee. First person melee doesn't exist anywhere else as far as I know.
Archangel35757 Posted October 8, 2013 Posted October 8, 2013 Awesome work DT... you're becoming quite the coder. Now you just need to spice things up by adding in more punching styles-- rather than just left or right hooks. Would like to see you add:Left and right straight jabs. Allow the punches to be thrown while doing the left or right torso dodge move. Add some lower body straight kicks Add some lower body roundhouse kicks to opponents knee joints. etc., etc., etc.
Tempust85 Posted October 8, 2013 Author Posted October 8, 2013 Most of the edits I've done is a mix of luck and some help from others telling me what to search for lol. I highly doubt I could do those on the list, even though they would be cool.
Jango40 Posted October 8, 2013 Posted October 8, 2013 https://www.youtube.com/watch?v=deHCQq3yEYQ Things I did: - removed the auto third person switch for WP_MELEE- removed ammo count for WP_MELEE- added BOTH_MELEE1, BOTH_MELEE2 & BOTH_STAND6 to "MapTorsoToWeaponFrame" in cg_weapons.cpp- changed anim length & anim starts for BOTH_MELEE1 & BOTH_MELEE2 (to match up to the player animations) to work with a 36 frame MD3 file The hit effect shows in the middle around the crosshair, which works. Each arm is seperated, so I have: fists.md3fists_barrel.md3 Then of course, the animation: fists_hand.md3Just me or do Kyle's hand have awesome quality?
Tempust85 Posted October 8, 2013 Author Posted October 8, 2013 Pretty crap quality IMO, need to be redone but that all depends on the player model being finished.
Archangel35757 Posted October 8, 2013 Posted October 8, 2013 The hands do look a little arthritic... but that can be easily fixed.
Tempust85 Posted October 8, 2013 Author Posted October 8, 2013 Yeah, that's the old mesh and crappy hand weights. Next version will look better lol.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now