• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

Player must deal +33% dmg to monster

Erexo

Kage
Premium User
Joined
Mar 27, 2010
Messages
743
Solutions
5
Reaction score
200
Location
Pr0land
GitHub
Erexo
Hello,
someone can explain me how to create creaturescript, that work when monster `X` die, and player deal more than 33% damage to that monster.
Currently im using script, that only player who lastHit recive something. Idk how to change this.

Code:
function onKill(cid, target, lastHit)
   if isMonster(target) and getCreatureName(target):lower() == 'x' then
    if lastHit then
      --code
    end
    end
   return true
end
 
You need to code a function like: getDamageMap in 1.0 or getDamageRatio which should exist in sources but not as a lua function.
 
Back
Top