• TTT Tripmine killer
    4 replies, posted
When a player is killed by a tripmine the log says "<something/world> killed <playersname>". I was wondering if there was a way to change it so that they were killed by the person who placed the tripmine. I was thinking maybe if you set the tripmine's owner on spawn that might work. So is there any easy way to do it without modifying core files?
You can easily just check inside the molotov's fire file and see how it's done. [lua] flame:SetDamageParent(dmgowner) flame:SetOwner(dmgowner) [/lua]
That's assuming it uses the same fire, which I find unlikely for a tripmine More likely it's using util.BlastDamage, which means you should just set the second argument to the damage owner, like the c4 does [lua]util.BlastDamage(self, dmgowner, pos, r_outer, self:GetDmg())[/lua]
[QUOTE=my_hat_stinks;40564758]That's assuming it uses the same fire, which I find unlikely for a tripmine More likely it's using util.BlastDamage, which means you should just set the second argument to the damage owner, like the c4 does [lua]util.BlastDamage(self, dmgowner, pos, r_outer, self:GetDmg())[/lua][/QUOTE] I was using it as a reference, not by him using the fire entity itself. I was referring that he could set the damage parent and the owner of the tripmine to whoever planted it and it would act the same as the fire entity by taking whoever it dealt damage to and TTT would know who the owner was.
I'm currently using the hl2 tripmine, so I think I'm going to do what I didn't want to and just write a lua tripmine. This does also mean that I can fix it killing other traitors though.
Sorry, you need to Log In to post a reply to this thread.