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

[L4D & L4D2] Weapon Damage Mod


Post New Thread Reply   
 
Thread Tools Display Modes
dirka_dirka
Veteran Member
Join Date: Nov 2009
Old 02-20-2010 , 10:50   Re: [L4D & L4D2] Weapon Damage Mod
Reply With Quote #21

doesnt:
SetEventInt(event,"dmg_health", altereddamage);
change dmg_health... so when you do this:
new health = eventhealth + dmg_health - altereddamage;
your not actually doing anything (adding and subtracting the same value)?

you should be setting the dmg_health after the calculations are done.

also..
if you change the if (health > 1) to if (health < 1), you can partially fix cases that would cause to much damage. change this:
PHP Code:
        {
            
altereddamage RoundToNearest(dmg_health multiplierWeapon);

            
SetEventInt(event,"dmg_health"altereddamage); // for correct stats.
        
            
if (eventhealth 1// dont bother if the player dies
            
{
                new 
health eventhealth dmg_health altereddamage;
                
// health calculation: first revert damage done by adding dmg_health, then subtract the changed damage
                
                
if (health 1)
                {
                    
SetEntityHealth(clienthealth);
                    
                    
DebugPrintToAll("Changed weapon %s damage used by %N on %N, was %i, is now %i, oldhealth %i, newhealth %i"weaponnameattackerclientdmg_healthaltereddamageeventhealthhealth);
                }
            }
        } 
to this:
PHP Code:
        {
            
altereddamage RoundToNearest(dmg_health multiplierWeapon);

            if (
eventhealth 1// dont bother if the player dies
            
{
                new 
health eventhealth dmg_health altereddamage;
                
// health calculation: first revert damage done by adding dmg_health, then subtract the changed damage
                
                
if (health 1)
                {
                    
// adjust the damage done so theres 1 health left
                    
altereddamage += health 1;
                    
health 1;
                }
                
SetEntityHealth(clienthealth);
                
                
DebugPrintToAll("Changed weapon %s damage used by %N on Tank %N, was %i, is now %i, oldhealth %i, newhealth %i"weaponnameattackerclientdmg_healthaltereddamageeventhealthhealth);
            }

            
SetEventInt(event,"dmg_health"altereddamage); // for correct stats.
        

..fixes both points.
dirka_dirka is offline
AtomicStryker
Veteran Member
Join Date: Apr 2009
Location: Teutonia!!
Old 02-20-2010 , 11:09   Re: [L4D & L4D2] Weapon Damage Mod
Reply With Quote #22

"altereddamage" is calculated before changing the event value.

Its not "the same" as dmg_health, at no point.


You have a point with the event Int - Im changing it regardless of changing the actual damage.
AtomicStryker is offline
Gixxer
Member
Join Date: Nov 2009
Old 02-20-2010 , 21:38   Re: [L4D & L4D2] Weapon Damage Mod
Reply With Quote #23

Then what multiplier do I set the AWP at to kill a Charger in 2 hits? It seems whatever I set it to, the AWP always takes at least 3 shots to kill. 2.0, 3.0, 4.0, etc.
Gixxer is offline
Gixxer
Member
Join Date: Nov 2009
Old 02-20-2010 , 22:53   Re: [L4D & L4D2] Weapon Damage Mod
Reply With Quote #24

Also, just wondering how he could do it but you couldn't?

https://forums.alliedmods.net/showthread.php?t=114296
Gixxer is offline
dirka_dirka
Veteran Member
Join Date: Nov 2009
Old 02-20-2010 , 23:41   Re: [L4D & L4D2] Weapon Damage Mod
Reply With Quote #25

gixxer did you try the new version? if you set the damage high enough, it should only take 2 shots to kill a charger (anything higher then 300 damage).
dirka_dirka is offline
Gixxer
Member
Join Date: Nov 2009
Old 02-21-2010 , 00:02   Re: [L4D & L4D2] Weapon Damage Mod
Reply With Quote #26

Yes I did, I got the Charger to go down in 2 shots, but now the Jockey takes 3...
Gixxer is offline
AtomicStryker
Veteran Member
Join Date: Apr 2009
Location: Teutonia!!
Old 02-21-2010 , 04:36   Re: [L4D & L4D2] Weapon Damage Mod
Reply With Quote #27

Quote:
Originally Posted by AtomicStryker View Post
Not without screwing the games Kill detection (it wouldnt score as your kill).
Thats what Crimson does. Also, his modded damage doesnt apply to witches.
AtomicStryker is offline
Gixxer
Member
Join Date: Nov 2009
Old 02-21-2010 , 19:43   Re: [L4D & L4D2] Weapon Damage Mod
Reply With Quote #28

Big deal, does anyone even pay attention to that? Not anyone I know, as long as it shows who killed who it's alright with me and his mod does that just fine. I applaud your work on this and I'm using your mod for all other guns except for AWP/Scout but I feel that your mod would be more successful and appealing if it used that method of damage delivery.

I also like how his damage scales equally, set AWP to do 600, it does 600 to everyone, while your method makes it scale funny. I set the AWP to mimic 600 DMG and to the tank it does 2300 DMG, then starts to scales almost in halves. While that would be fine if it was 1 v 1 but completely unfair on a 4 v 1 encounter because the burst damage is ridiculous taking 1/3 of the tanks health away with 1 bullet.

Just my 2 cents on the matter.
Gixxer is offline
dirka_dirka
Veteran Member
Join Date: Nov 2009
Old 02-21-2010 , 21:42   Re: [L4D & L4D2] Weapon Damage Mod
Reply With Quote #29

gixxer, your using 2 mods to tweak the damage of a weapon, of course your going to get funny results.

the weapon unlock mod also adjusts how much damage that gun does. your results will vary depending on which one runs first.
dirka_dirka is offline
Gixxer
Member
Join Date: Nov 2009
Old 02-22-2010 , 21:46   Re: [L4D & L4D2] Weapon Damage Mod
Reply With Quote #30

Quote:
Originally Posted by dirka_dirka View Post
gixxer, your using 2 mods to tweak the damage of a weapon, of course your going to get funny results.

the weapon unlock mod also adjusts how much damage that gun does. your results will vary depending on which one runs first.
Nope, I only used the Weapon Damage Mod while running into my issues. I only started combining them after I was told nothing could be done about it.
Gixxer is offline
Reply


Thread Tools
Display Modes

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 00:55.


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