It seems crossbow bolts already respect hitboxes
(see CCrossbowBolt::PhysicsSolidMaskForEntity)



Kind regards,
Saul Rennison


On 4 July 2013 19:17, Saul Rennison <saul.renni...@gmail.com> wrote:

> If the crossbow projectile is an entity, you need to override a specific
> VPhysics function to tell it to respect hitboxes when doing collision
> detection. I can get this method override for you shortly.
>
>
>
> Kind regards,
> Saul Rennison
>
>
> On 4 July 2013 19:12, Tobias Baumann <m...@tobiasbaumann.net> wrote:
>
>> **
>>  Hi Ben,
>>
>>  I did but I looked into it again and adjusted its size which provided me
>> with the following result:
>>
>>  http://i.imgur.com/ffA9ZE7.jpg
>>
>>  The big box is the bounding box with ViewVector values. The little boxes
>> are the hitboxes visible with sv_showhitboxes 1. Now why are they ignored
>> and all hit-detection only happens on the bounding box? I did some testing
>> and found out that this only happens with the Crossbow or my own weapon
>> script which is a mixture of the crossbow and grenade code. So in other
>> words the crossbow bolt uses the boundingbox for hit detection while other
>> weapons use the hitboxes. Which makes sense since the other weapons don't
>> actually fire a physical projectile but instead use raytracing. At least
>> thats what I'm assuming. So long story short I'm left with two questions:
>>
>>  How do I tell the crossbow bolt to use hitboxes and not boundingboxes
>> for hit detection?
>>
>>  And how can I set individual ViewVectors for each player and is that
>> even possible with the engine? (What I noticed is that the hardcoded
>> vectors are uniform for everyone).
>>
>>  In case you're wondering: This is for the Suicide Survival mod.
>>  The weapon script is a physical book you throw, hence the crossbow bolt
>> code.
>>  The individual ViewVectors are needed because I wan't to use different
>> kind of prop models for the suiciders and the problem with this was that
>> they get position in the ground by half their size (due to the origin being
>> at 0,0,0 and the model not having any bones I'm assuming).
>>
>>  I hope this makes things a bit clearer :)
>>
>>  Thanks for any advice/help,
>>  Tobias
>>
>>
>>
>>
>> "Ben K." <amo...@online.de> hat am 3. Juli 2013 um 15:53 geschrieben:
>>
>>  You probably haven't adjusted the bounding box. Check out your game
>> rules and look for "ViewVectors".
>>
>> Ben
>>
>> Tobias <m...@tobiasbaumann.net> <m...@tobiasbaumann.net> wrote:
>>
>>  Already try that and it only shows the local hitboxes for me. I mean it
>> displays the proper hitboxes the same way they're displayed in the
>> modelviewer. However these are totally ignored for actual hit detection
>> when I fire on the player. :(
>>
>>  Check this screenshot: http://i.imgur.com/KGJ1Kys.jpg
>>
>>  Thats with "sv_showhitboxes 1". If I fire on the model with another
>> client the bullets go right trough the model until about half the vertical
>> size of it. Or in other words if I fire at the base/lower part I get hits
>> and everything above is ignored. Since the model is pretty large/high I'm
>> guessing that there might be some maximum height value for the hitbox? Or
>> for the collision box? A standard playermodel reaches until about the
>> middle of the cactus.
>>
>>  Best regards,
>>  Tobias
>>
>>
>>   _______________________________________________
>> To unsubscribe, edit your list preferences, or view the list archives,
>> please visit:
>> https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders
>>
>>
>> _______________________________________________
>> To unsubscribe, edit your list preferences, or view the list archives,
>> please visit:
>> https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders
>>
>>
>>
>
_______________________________________________
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
https://list.valvesoftware.com/cgi-bin/mailman/listinfo/hlcoders

Reply via email to