Yahn and I found a bug in the SDK when we were helping out the AirHL guys 
with their hitbox problems. In the GetHullBounds() functions in the client 
& game dll's, you'll see this code (slightly different on svr):
        switch ( hullnumber )
        {
        case 0:                         // Normal player
                mins = Vector(-16, -16, -36);
                maxs = Vector(16, 16, 36);
                iret = 1;
                break;
        case 1:                         // Crouched player
                mins = Vector(-16, -16, -18 );
                maxs = Vector(16, 16, 18 );
                iret = 1;
                break;
        case 2:                         // Point based hull
                mins = Vector( 0, 0, 0 );
                maxs = Vector( 0, 0, 0 );
                iret = 1;
                break;
        }
This isn't actually doing anything, because the Vector class doesn't have an
assignment operator for float *. If you've changed the hullsizes to your
custom
hulls, it's not having any effect. To fix it, change the code to something
like
this (or use Vector's CopyToArray()):
        switch ( hullnumber )
        {
        case 0:                         // Normal player
                mins[0] = mins[1] = -16;
                mins[2] = -36;
                maxs[0] = maxs[1] = 16;
                maxs[2] = 36;
                iret = 1;
                break;
        case 1:                         // Crouched player
                mins[0] = mins[1] = -16;
                mins[2] = -18;
                maxs[0] = maxs[1] = 16;
                maxs[2] = 18;
                iret = 1;
                break;
        case 2:                         // Point based hull
                mins[0] = mins[1] = mins[2] = 0;
                maxs = Vector( 0, 0, 0 );
                iret = 1;
                break;
        }
So if it looks like your hitboxes aren't quite working, its probably
because they're not. Note that if you're not changing any hullsizes, this
bug isn't affecting you (the engine'll just be using default hulls), so 
you don't need to fix it.


-----Original Message-----
From: Neale Roberts [mailto:[EMAIL PROTECTED]]
Sent: Sunday, December 16, 2001 11:33 PM
To: [EMAIL PROTECTED]
Subject: Re: [hlcoders] Hull3?


We certainly have hitbox issues with hull 3. The player type that uses hull
3 cannot duck, so that problem is eliminated. However, the hitboxes only
appear to cover about 80% of the model size. They *appear* as normal if you
do a r_drawentities 3, but the top, bottom and side 10% don't register any
hits. Very bizarre.

----- Original Message -----
From: "Matthew Lewis" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, December 17, 2001 4:03 AM
Subject: [hlcoders] Hull3?


> There are still issues with the hit boxes left over from the previous
> release. Basically, the hit boxes don't work very well with crouched
> players. What I've found is that it's impossible to head shot a player
while
> he's crouched. You have to aim for the center of his chest to score a hit.
> Anything above that won't score a hit of any type. I'm not sure if this is
a
> hull issue or not. If I understand the process correctly, I think the
engine
> checks for a hit on the player's hull before narrowing down to the
> individual hit box. If the hull doesn't register a hit, then the hit boxes
> never come into play. This leads me to believe a crouched player's hull is
> messed up somewhere, but I can't figure it out. It's very annoying, cuz a
> lot of players want to snipe at each other and they're usually crouched.
> Then I have to listen to "Hey WTF?!?! I hit him in the head!" Chances are
> they did. But the engine won't acknowledge it. I'd be curious if someome
> found a way around this little problem.
>
> _______________________________________________
> To unsubscribe, edit your list preferences, or view the list archives,
please visit:
> http://list.valvesoftware.com/mailman/listinfo/hlcoders
>
>

_______________________________________________
To unsubscribe, edit your list preferences, or view the list archives,
please visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders
_______________________________________________
To unsubscribe, edit your list preferences, or view the list archives, please visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders

Reply via email to