Melee Combat Code?

  • Thread starter Thread starter JediPhreaK
  • Start date Start date
J

JediPhreaK

Guest
I keep hearing negative things about the melee Code for Half-Life 2, and I was wondering if someone could explain this a little more clearly as to why everyone is so negative about it?

I'm trying to do some research for MOD's who will want to use Melee Weapons, like Swordfighting etc.

Maybe if the Melee Code is so bad it should become a Community project to have an open Source Melee Mod that others could base Melee type MODs around?

Anyways I would just like to hear what some actualy HL2 Coders have to say about the "melee" code.
 
I think it's due to the fact that, as soon as you press the button, it instantly strikes, and that there's only one attack, and melee degenerates into a dash-forward strike dash-back type thing.

-Angry Lawyer
 
So its more or less the fact that its not immediately customizable, and was not built to be capable of more then a simple swing?
 
Something like that.
All Source does for Melee attacks is fire a really short-ranged bullet.

-Angry Lawyer
 
Dark Messiah of Might and Magic seems to have some pretty awesome melee attacks. That's on the Source engine, but I don't know if a mod could do something like that, I'm not a coder. I would really like to see an improved melee mod because the melee attacks in Sin: Episodes and DoD: S are a bit unreliable.
 
The guys in Might and Magic have gone and rewritten the melee code.

As long as you've got the skills to make it from scratch, melee is definately viable.

-Angry Lawyer
 
Just because it's on the source engine doesen't mean they're basing their code upon Half-Life 2.
 
So you guys are basically saying that making a melee based mod for HL2 is impossible, or is it just harder? I'm working on a personal project (join? :P ) that is only melee combat, but the control system for it is different from what most titles have tried.
 
So you guys are basically saying that making a melee based mod for HL2 is impossible, or is it just harder? I'm working on a personal project (join? :P ) that is only melee combat, but the control system for it is different from what most titles have tried.

I think you would have to ignore what they have for melee weapons and start from scratch and design your own melee weapon system.

Lucky for me, all melee in my game will be of the short-range bullet type :)
 
You don't HAVE TO make a copy of one of Valve's old guns like the crowbar, you know.

A good example of a melee weapon is the shovel in SMod, not that you can get your hands on their code though.
 
Can you fill me in on how the Shovel works differently from the crowbar?

I suspect it's a swing-hit or a swing-miss kinda thing isn't it?
 
There is no such thing as a "melee system" in source. How a melee attack feels is weapon implementation-dependent. It's easy to make your own melee code that behaves completely different from the Source one; the SDK allows that very easily. If someone wanted to invest a little time in it, you could easily make a better melee than the default crowbar one [the crowbar one is copied most of the time, which is why everyone gets the same bad impression of melee attacks in different games] [no I haven't written a custom melee attack for Off L yet, but it'll happen someday].
 
Back
Top