Raised This Month: $51 Target: $400
 12% 

Realistic Bullet: Real-Life Bullet physics to CS - FINAL VERSION


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
VoivoDpl
Junior Member
Join Date: Apr 2017
Old 09-14-2018 , 15:45   Re: Bullet Speed Management
Reply With Quote #11

Quote:
Originally Posted by EFFx View Post
Yeah, when I reload the thread I thought about that way...

Lemme ask you a question, how would you suggest to manage the damage when the bullet gets through a wall? Like damage / times_that_the_bullet_gets_through_the_wall?
To do this accurately one must know:
Weapon base damage, Texture(type of a wall), ammo type penetration(this can be researched on youtube since there are tons of movies about ammo penetration), distance.


For example you hit wall with texture duct_XXX. So you've hit a ventilation shaft. We are gonna ignore thickness to real life comparison cause vent on cs_assault is simplified for editing(and it's quite thick). We can even do multiple wallshots since awp ammo could propably penetrate like 10 or more thin vent metal plates.

Let's simplify walls, group them into two groups where one only checks if the bullet reached max penetration length and the other checks penetration length, give them damage reduction points:

This is DR per penetration, piercing ammo type divides this by 2, also we must add max penetration(8 or 16 game units/inches):
wooden door 20
metal door 35
metal plate 45
ventilation 15

This is DR per inch of penetration, piercing ammo type divides this by 2:
concrete wall 7-15(i'm not sure, but I think we should pick a number from this range)
wooden wall 7-15
dirt 7-15

impenetrable:
metal wall
thick metal door
everything else

Distance:
lets say normal ammo distance check looks like this:
Code:
damage *= (3000.0 - distance) / 3000.0
piercing:
damage *= (6000.0 - distance) / 6000.0
shotgun:
damage *= (1500.0 - distance) / 1500.0
example:
AK47 through wooden door, distance 1000u:
Code:
36 * 0.84 - (20 / 2) = ~ 20 damage
(weapon base damage * distance modifier - (damage reduction from penetration / 2 because ammo is piercing)
example2:
AK47 through 3 units thick concrete wall, distance 2000u:
Code:
36 * 0.66 - ( (15 / 2) * 3) = 1.26 damage
(bullet HP * distance modifier - ((damage reduction from penetration / 2 because ammo is piercing) * 3 inches)
When fired bullet starts with it's base weapon damage as HP number and with each penetration the bullets HP decreases. When it reaches 0 it's removed from the game.
Texture names and wall types should be listed in a config file, also the plugin should support debug mode where it displays texture name on screen where the player is aiming.

Phew...

Last edited by VoivoDpl; 09-14-2018 at 15:46.
VoivoDpl is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 10:15.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode