Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Increase damage
#1
I put self.bonusdamange = 100; for survivors

Then under
CodeCallback_PlayerDamage(eInflictor, eAttacker, iDamage, iDFlags, sMeansOfDeath, sWeapon, vPoint, vDir, sHitLoc, timeOffset)
I put this -> iDamage = eAttacker.bonusdamage * iDamage / 100;

Now when they jump off a cliff, they don't die.

Could you please help?
Reply

#2
Use

Level.OnPlayerDamage = ::FunctionName;

then create a function:

FunctionName(eInflictor, eAttacker, iDamage, iDFlags, sMeansOfDeath, sWeapon, vPoint, vDir, sHitLoc, timeOffset)
{
return eAttacker.damagebonus * iDamage / 100
}
(08-10-2011, 12:58)Pozzuh Wrote:
Se7en Wrote:Stealed, from cod4 mod ...
look who's talking

[Release] Old School Mod v2.2
[Release] Scroll menu

Reply

#3
Wouldn't it be the same?
Reply

#4
(04-06-2012, 21:44)Lemon Wrote: Wouldn't it be the same?

Yes, but then you wouldn't have to edit an existing file which means you can play normal gametypes aswell.

and bysides that, the code looks legit so it should work fine so there's not really a problem... are you sure its that part of the code and not something else?
(08-10-2011, 12:58)Pozzuh Wrote:
Se7en Wrote:Stealed, from cod4 mod ...
look who's talking

[Release] Old School Mod v2.2
[Release] Scroll menu

Reply

#5
Hmm, I may use it another mod.

When i remove that line, everything works perfect.
Reply

#6
(04-06-2012, 21:48)Lemon Wrote: Hmm, I may use it another mod.

When i remove that line, everything works perfect.

Hmm weird .. maybe use a float number for the bonus ?

like

self.damagebonus = 0.5;

iDamage = iDamage * eAttacker.damagebonus

?

shouldn't make a difference .. but hey who knows
(08-10-2011, 12:58)Pozzuh Wrote:
Se7en Wrote:Stealed, from cod4 mod ...
look who's talking

[Release] Old School Mod v2.2
[Release] Scroll menu

Reply

#7
if mod.falling or something like that , ive seen it before one sec
..............


Code:
(sMeansOfDeath == "MOD_TRIGGER_HURT" || sMeansOfDeath == "MOD_FALLING")

works great Smile
Reply

#8
With falling the attacker is the player itsself so when you have a bonus of lets say 50 the damage will be 50% of the actual damage therefor you wont die unless you jump from something really high
(08-10-2011, 12:58)Pozzuh Wrote:
Se7en Wrote:Stealed, from cod4 mod ...
look who's talking

[Release] Old School Mod v2.2
[Release] Scroll menu

Reply

#9
You start with 100 bonus. I'll try it when I get home.
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  [Release] CS addon for MW2(Sounds,show damage) Fl0w_.JACKDAN 1 4,693 09-29-2013, 19:46
Last Post: Nekochan
Question Help Team DAMAGE offhand E-losev 0 2,428 09-17-2013, 12:03
Last Post: E-losev
Question Help damage [HARD] Tony. 2 2,662 05-16-2013, 19:42
Last Post: Nekochan
  guys like increase the damage from falls? SaviouR9966 7 4,210 01-26-2013, 13:42
Last Post: Pozzuh
  incease Damage for GUID only islamsaab 8 4,216 11-13-2012, 10:00
Last Post: islamsaab
  Health and damage and custom comments mbakerinnv 1 2,014 11-01-2012, 15:09
Last Post: d0h!
  Help Disable fall damage Puffiamo 5 4,813 10-23-2012, 14:50
Last Post: Puffiamo
  Damage table surtek 3 3,466 09-18-2012, 08:30
Last Post: aosma8
  [Request] <- Duh! HP Increase/Speed Increase DidUknowiPwn 2 1,982 05-07-2012, 06:36
Last Post: DidUknowiPwn
  [Request] Damage to zombie [Z00MBY] Alex 0 1,806 04-12-2012, 06:53
Last Post: [Z00MBY] Alex

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.