Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

FPSC Classic Scripts / Universal Character Melee Script

Author
Message
Pride
16
Years of Service
User Offline
Joined: 22nd Dec 2007
Location: Eastern USA
Posted: 21st Mar 2009 19:54 Edited at: 23rd Mar 2009 03:06
I have constructed a script that allows any character rigged with the default FPSC skeleton to "punch" the player. It works wonderfully. Video attached 4mb.

I am also working on a script that allows the character to hold a melee weapon and attack the player correctly, though as of now, it does not work.

VIDEO

EDIT: I stand corrected, some melee weapons work correctly, although EAI's pipe wrench is the only one that seemed to work.
EDIT2: For melee weapons to work, the weapontype field in the gunspec.txt of the weapon must be at 0.


"March 1st 2009, 12:49pm, a 3 year struggle with cancer ends..."

Attachments

Login to view attachments
Pride
16
Years of Service
User Offline
Joined: 22nd Dec 2007
Location: Eastern USA
Posted: 21st Mar 2009 19:57 Edited at: 24th Mar 2009 02:05
Code on this page for your benefit


And...
SCRIPT


"March 1st 2009, 12:49pm, a 3 year struggle with cancer ends..."

Attachments

Login to view attachments
The Fps Creator rocks!
16
Years of Service
User Offline
Joined: 24th Oct 2008
Location: Sneaking down your chimney.
Posted: 22nd Mar 2009 01:40 Edited at: 22nd Mar 2009 01:43
EDIT: I just saw vid

I can't texture. I'm not an artist.
meteorite
18
Years of Service
User Offline
Joined: 19th Nov 2006
Location: The Capital Wasteland
Posted: 22nd Mar 2009 04:47
Good thoughts, and an excellent contribution, thanks much for this Pride

"I can't imagine what this place would have been like if I hadn't found you here." - BJ Hunnicutt
The Fps Creator rocks!
16
Years of Service
User Offline
Joined: 24th Oct 2008
Location: Sneaking down your chimney.
Posted: 22nd Mar 2009 18:18
I just tested it. It's good! But you just used the grenade animation. But it is still good!

I can't texture. I'm not an artist.
Errant AI
18
Years of Service
User Offline
Joined: 24th Aug 2006
Location:
Posted: 22nd Mar 2009 18:28 Edited at: 22nd Mar 2009 18:30
Quote: "EDIT: I stand corrected, some melee weapons work correctly, although EAI's pipe wrench is the only one that seemed to work."


Which other weapons have you tried and what didn't work? All of my melee weapons have generally the same model positioning but working/not working may be dependent on the weapontype setting in gunspec which dictates animation poses to some degree.

I'm DLing the vid now...

Anyways, this sounds great. I've been hoping someone could come up with a generic weapon holding melee which uses that throw animation.
Pride
16
Years of Service
User Offline
Joined: 22nd Dec 2007
Location: Eastern USA
Posted: 23rd Mar 2009 03:04 Edited at: 23rd Mar 2009 03:07
Gotcha EAI!!!

The weapon type must be 0 for a melee weapon to work. Beast, thanks for the info EAI, never saw that in the gunspec file...

EDIT: What effect will changing the weapontype have on the weapon.


"March 1st 2009, 12:49pm, a 3 year struggle with cancer ends..."
Pride
16
Years of Service
User Offline
Joined: 22nd Dec 2007
Location: Eastern USA
Posted: 23rd Mar 2009 03:41
Another video showing that fights with several characters does not cause any lag because of the simplicity of the script.


"March 1st 2009, 12:49pm, a 3 year struggle with cancer ends..."

Attachments

Login to view attachments
Errant AI
18
Years of Service
User Offline
Joined: 24th Aug 2006
Location:
Posted: 23rd Mar 2009 17:08
Quote: "What effect will changing the weapontype have on the weapon."


AFIK, the weapontype only dictates which weapon holding poses/animations are used by NPCs.

0 = grenade

The other anim sets are for pistol, shouldered rifle, shooting from the hip, over-the-shoulder launchers and another for the minigun pose.

I'll be sure to set all melee weapons to weapontype zero from this point on. Will the script in the #2 post work with weapons? Once, I've tested, I'd like to link to this post if that's cool with you.
Pride
16
Years of Service
User Offline
Joined: 22nd Dec 2007
Location: Eastern USA
Posted: 23rd Mar 2009 23:24
Yes, you may link the post and yes, the script will work woth weapons.

If you look closely at the second video, a thug is holding a combat knife.

Thanks for the education EAI!


"March 1st 2009, 12:49pm, a 3 year struggle with cancer ends..."
SamHH
17
Years of Service
User Offline
Joined: 9th Dec 2006
Location: Vermont
Posted: 24th Mar 2009 15:07
TGC already did this... Just download one of the free melee characters, they use the stock throw animation.


Pride
16
Years of Service
User Offline
Joined: 22nd Dec 2007
Location: Eastern USA
Posted: 25th Mar 2009 03:06
The TGC store models use the default script, which does not work for default characters. This script works for any character.


"March 1st 2009, 12:49pm, a 3 year struggle with cancer ends..."
Wraith Staff
17
Years of Service
User Offline
Joined: 3rd Apr 2007
Location: Hamilton, OH
Posted: 25th Mar 2009 09:15
Do any of you think it may be possible to integrate this into multiplayer? IE Katana, Wrench or something of the sort as a weapon in arena games... I'll give it a few tests myself, but I want to know what you guys think...



Play Harder!
daarboven
16
Years of Service
User Offline
Joined: 20th Dec 2007
Location: right over there, see?
Posted: 25th Mar 2009 14:04
I know the dumb zombie script that lies around here somewhere also uses the throw animation, as I used it for some of the standard characters successfully. You can even improve the look of it if you shorten the range of the throw animation in the characters FPE (backup prior to this!!!) so the "ring pull" isn't played and he beats you instantly!

I am Jacks complete lack of surprise.
Pride
16
Years of Service
User Offline
Joined: 22nd Dec 2007
Location: Eastern USA
Posted: 25th Mar 2009 16:34 Edited at: 25th Mar 2009 16:35
I think the ring pull is more real. Like the charging-back of a fist before pounding it on one's nose

Your idea also seems pretty plausible Daarboven...I may experiment with it


"March 1st 2009, 12:49pm, a 3 year struggle with cancer ends..."
Wraith Staff
17
Years of Service
User Offline
Joined: 3rd Apr 2007
Location: Hamilton, OH
Posted: 10th Apr 2009 06:12
BUMP... Any word on my idea, no real luck on my end...



Play Harder!

Login to post a reply

Server time is: 2024-11-24 23:28:58
Your offset time is: 2024-11-24 23:28:58