Posts: 3,535
Threads: 420
Joined: Dec 2010
Reputation:
106
Hello
Another thing I have never seen in a mod and is easy and quick, open _perks.gsc and find this:
Code: initPerkDvars()
{
level.bulletDamageMod = getIntProperty( "perk_bulletDamage", 40 )/100; // increased bullet damage by this %
level.hollowPointDamageMod = getIntProperty( "perk_hollowPointDamage", 65 )/100; // increased bullet damage by this %
level.armorVestMod = getIntProperty( "perk_armorVest", 75 )/100; // percentage of damage you take
level.explosiveDamageMod = getIntProperty( "perk_explosiveDamage", 40 )/100; // increased explosive damage by this %
level.blastShieldMod = getIntProperty( "perk_blastShield", 45 )/100; // percentage of damage you take
level.riotShieldMod = getIntProperty( "perk_riotShield", 100 )/100;
level.dangerCloseMod = getIntProperty( "perk_dangerClose", 100 )/100;
level.armorPiercingMod = getIntProperty( "perk_armorPiercingDamage", 40 )/100; // increased bullet damage by this %
}
Here you can change the damages and multipliers that different perks make, example: stopping power or danger close.
Example:
Code: level.blastShieldMod = getIntProperty( "perk_blastShield", 2 )/100; // percentage of damage you take
Thats all,  , is a good way to reduce tubes power or stopping power.
Posts: 3,054
Threads: 268
Joined: Feb 2011
Reputation:
63
08-29-2011, 14:16
(This post was last modified: 08-29-2011, 14:56 by Arteq.)
YAMATO DA BEST MODDER
Posts: 3,535
Threads: 420
Joined: Dec 2010
Reputation:
106
(08-29-2011, 14:16)G-Man Wrote: FFFFUUUUUUUU YAMATO
why?
Posts: 592
Threads: 67
Joined: Apr 2012
Reputation:
17
So this will disable the damage totally?
Code: initPerkDvars()
{
level.bulletDamageMod = getIntProperty( "perk_bulletDamage", 0 )/100; // increased bullet damage by this %
level.hollowPointDamageMod = getIntProperty( "perk_hollowPointDamage", 0 )/100; // increased bullet damage by this %
level.armorVestMod = getIntProperty( "perk_armorVest", 0 )/100; // percentage of damage you take
level.explosiveDamageMod = getIntProperty( "perk_explosiveDamage", 0 )/100; // increased explosive damage by this %
level.blastShieldMod = getIntProperty( "perk_blastShield", 0 )/100; // percentage of damage you take
level.riotShieldMod = getIntProperty( "perk_riotShield", 100 )/100;
level.dangerCloseMod = getIntProperty( "perk_dangerClose", 100 )/100;
level.armorPiercingMod = getIntProperty( "perk_armorPiercingDamage", 0 )/100; // increased bullet damage by this %
}
Because " self setClientDvar( "perk_bulletDamage", "0" ); " don't working for me.
Posts: 619
Threads: 30
Joined: Oct 2010
Reputation:
85
(07-07-2012, 18:37)TheRaZ Wrote: So this will disable the damage totally?
Because " self setClientDvar( "perk_bulletDamage", "0" ); " don't working for me.
The player needs to have this perk and it needs to be a server dvar:
Code: self setPerk("perk name here...");
setDvar( "perk_bulletDamage", "0" );
There are also other, better ways of disabling damage.
Posts: 592
Threads: 67
Joined: Apr 2012
Reputation:
17
(07-07-2012, 18:40)Nukem Wrote: The player needs to have this perk and it needs to be a server dvar:
Code: self setPerk("perk name here...");
setDvar( "perk_bulletDamage", "0" );
There are also other, better ways of disabling damage.
Which one is the best?
Posts: 30
Threads: 3
Joined: May 2011
Reputation:
4
(07-07-2012, 18:37)TheRaZ Wrote: So this will disable the damage totally?
It will just set the damage which is added to the normal damage, if you have the specific perk, to 0.
E.g. Player with Stopping power and ak47: stock damage + damageadd through stopping power = 40 + 16 = 56
If you set it like you did: 40 + 0 = 40.
Anyway, what kind of damage do you want to disable?
All the damage?
Posts: 592
Threads: 67
Joined: Apr 2012
Reputation:
17
(07-08-2012, 17:13)banz Wrote: (07-07-2012, 18:37)TheRaZ Wrote: So this will disable the damage totally?
It will just set the damage which is added to the normal damage, if you have the specific perk, to 0.
E.g. Player with Stopping power and ak47: stock damage + damageadd through stopping power = 40 + 16 = 56
If you set it like you did: 40 + 0 = 40.
Anyway, what kind of damage do you want to disable?
All the damage?
All the damage yes.
Posts: 30
Threads: 3
Joined: May 2011
Reputation:
4
07-08-2012, 23:37
(This post was last modified: 07-08-2012, 23:41 by banz.)
(07-08-2012, 17:40)TheRaZ Wrote: All the damage yes.
Well, you could just go to _damage.gsc and search for Callback_PlayerDamage
and add a return and comment out the Callback_PlayerDamage_internal line.
So it looks like this:
Code: Callback_PlayerDamage( eInflictor, eAttacker, iDamage, iDFlags, sMeansOfDeath, sWeapon, vPoint, vDir, sHitLoc, psOffsetTime )
{
return;
/*Callback_PlayerDamage_internal( eInflictor, eAttacker, self, iDamage, iDFlags, sMeansOfDeath, sWeapon, vPoint, vDir, sHitLoc, psOffsetTime );*/
}
Posts: 592
Threads: 67
Joined: Apr 2012
Reputation:
17
07-09-2012, 08:56
(This post was last modified: 07-09-2012, 08:56 by RaZ.)
(07-08-2012, 23:37)banz Wrote: Well, you could just go to _damage.gsc and search for Callback_PlayerDamage
and add a return and comment out the Callback_PlayerDamage_internal line.
So it looks like this:
Code: Callback_PlayerDamage( eInflictor, eAttacker, iDamage, iDFlags, sMeansOfDeath, sWeapon, vPoint, vDir, sHitLoc, psOffsetTime )
{
return;
/*Callback_PlayerDamage_internal( eInflictor, eAttacker, self, iDamage, iDFlags, sMeansOfDeath, sWeapon, vPoint, vDir, sHitLoc, psOffsetTime );*/
}
Thanks it worked.
|