Disable CFReptuation by default

Reputation currently doesn't have a very noticable in-game impact, but
currently causes a pretty big performance hit when killing a lot of
monsters.
master^2
Kevin Zheng 2024-03-19 11:11:43 -07:00
parent 8a10e01301
commit 9838c555ed
1 changed files with 9 additions and 4 deletions

View File

@ -10,8 +10,13 @@ def get_killer(hitter):
def is_player(op):
return op.Type == Crossfire.Type.PLAYER
killer = get_killer(Crossfire.WhoIsActivator())
victim = Crossfire.WhoAmI()
def on_kill():
killer = get_killer(Crossfire.WhoIsActivator())
victim = Crossfire.WhoAmI()
if is_player(killer):
CFReputation.record_kill(victim.Race, victim.Map.Region.Name, killer.Name)
if is_player(killer):
CFReputation.record_kill(victim.Race, victim.Map.Region.Name, killer.Name)
# disabled by default, doesn't currently have a big in-game impact and has a
# pretty significant performance hit
#on_kill()