Send code i wil fix ithi im having and error that it doesnt show the entity damage.
View attachment 2200
Waiting for an Reply.
Thanks you.![]()
__title__ = 'DamageShow'
__author__ = 'MrNunoPT'
__version__ = '0.1'
import clr
clr.AddReferenceByPartialName("Fougerite")
import Fougerite
class DamageShow:
def On_PlayerHurt(self, HurtEvent):
if HurtEvent.Attacker is None: return
if HurtEvent.AttackerIsPlayer and HurtEvent.VictimIsPlayer:
HurtEvent.Attacker.Notice("Seu Oponente: " + HurtEvent.Victim.Name + " Vida: " + str(HurtEvent.Victim.Health))
def On_NPCHurt(self, HurtEvent):
if HurtEvent.AttackerIsPlayer:
HurtEvent.Attacker.Notice("Vida Restante: " + str(HurtEvent.Victim.Health))
def On_EntityHurt(self, HurtEvent):
Server.Broadcast(HurtEvent.GetTakeDamage().health + " hp")
Read my last mesaagePython:__title__ = 'DamageShow' __author__ = 'MrNunoPT' __version__ = '0.1' import clr clr.AddReferenceByPartialName("Fougerite") import Fougerite class DamageShow: def On_PlayerHurt(self, HurtEvent): if HurtEvent.Attacker is None: return if HurtEvent.AttackerIsPlayer and HurtEvent.VictimIsPlayer: HurtEvent.Attacker.Notice("Seu Oponente: " + HurtEvent.Victim.Name + " Vida: " + str(HurtEvent.Victim.Health)) def On_NPCHurt(self, HurtEvent): if HurtEvent.AttackerIsPlayer: HurtEvent.Attacker.Notice("Vida Restante: " + str(HurtEvent.Victim.Health)) def On_EntityHurt(self, HurtEvent): Server.Broadcast(HurtEvent.GetTakeDamage().health + " hp")
let me try this one but when i change it on my code it didnt work__title__ = 'DamageShow'
__author__ = 'MrNunoPT'
__version__ = '0.1'
import clr
clr.AddReferenceByPartialName("Fougerite")
import Fougerite
class DamageShow:
def On_PlayerHurt(self, HurtEvent):
if HurtEvent.Attacker is None: return
if HurtEvent.AttackerIsPlayer and HurtEvent.VictimIsPlayer:
HurtEvent.Attacker.Notice("Seu Oponente: " + HurtEvent.Victim.Name + " Vida: " + str(HurtEvent.Victim.Health))
def On_NPCHurt(self, HurtEvent):
if HurtEvent.AttackerIsPlayer:
HurtEvent.Attacker.Notice("Vida Restante: " + str(HurtEvent.Victim.Health))
def On_EntityHurt(self, HurtEvent):
HurtEvent.Victim.Notice(HurtEvent.GetTakeDamage().health + " hp")
Try Player.Noticelet me try this one but when i change it on my code it didnt work
Just remove that entity lineNop it didnt work
[IronPython] Error in plugin DamageShow:
Traceback (most recent call last):
File "<string>", line 22, in On_EntityHurt
AttributeError: 'Entity' object has no attribute 'Notice'
Is it the plugin or it is impssible o do?Just remove that entity line
Idk i'm on phone all the time so i cant do muchNot what i really wanted but...
View attachment 2203
Atleast its something xd
that works but its not the entitie health remainingPython:def On_EntityHurt(self, HurtEvent): HurtEvent.Attacker.Notice(str(HurtEvent.DamageAmount) + " hp")
Maybe that event isnt available...
Uh...hi im having and error that it doesnt show the entity damage.
View attachment 2200
Waiting for an Reply.
Thanks you.![]()
Uh...
HurtEvent.GetTakeDamage().health
There is no GetTakeDamage method in that.
There is HurtEvent.DamageAmount though.
But your answer: HurtEvent.Entity.Health
![]()
i am using this plugins.it works..
but i get error in console!
what i must do?
Uh...
HurtEvent.GetTakeDamage().health
There is no GetTakeDamage method in that.
There is HurtEvent.DamageAmount though.
But your answer: HurtEvent.Entity.Health
class DamageShow:
def On_EntityHurt(self, HurtEvent):
HurtEvent.Attacker.Notice(str(HurtEvent.Entity.Health ) + " HP")
LOLAccording to the image you posted there is.