Update sword of Souls python code to reflect movement of handling exp scaling to caller in r21461
git-svn-id: svn://svn.code.sf.net/p/crossfire/code/maps/trunk@21462 282e977c-c81d-0410-88c4-b93c2d0d6712master
parent
2d7a1b6376
commit
f254fc82a0
|
@ -22,8 +22,9 @@ if killer.Owner is None and killer.Type == Crossfire.Type.PLAYER:
|
|||
old_level = weap.ItemPower
|
||||
old_xp = weap.TotalExp
|
||||
# Add experience to the weapon (though we only care about the total_exp field)
|
||||
# As the weapon gets stronger, it takes a larger share of the exp
|
||||
weap.AddExp((victim.Exp * (1.0 + weap.ItemPower / 115.0)) // 1)
|
||||
# As the weapon gets stronger, it takes a larger share of the exp,
|
||||
# with a baseline of half at level 0, and taking all of it at level 115.
|
||||
weap.AddExp((victim.Exp * (1.0 + weap.ItemPower / 115.0)) // 2)
|
||||
|
||||
# Determine the change in XP
|
||||
delta_exp = weap.TotalExp - old_xp
|
||||
|
|
Loading…
Reference in New Issue