2 Followers of Valkyrie don't get any praying spells, because Valkyrie hates magic.
3 Instead, they gain experience by combat bravery; and the way they prove that is
4 by bringing the flesh of dead enemies as a sacrifice in Her altar.
6 Of course, the script only activates for followers of Valkyrie, and only runs for
7 sacrifices of type FLESH.
9 Then, it can handle each in two ways:
11 - Ideally, all items will have Exp stored. In this case, you'll get 1/5 of that
12 Exp, with a bonus if it's a head or heart.
14 - Otherwise, we'll use the Level and resistances to estimate how hard it was to
15 kill the monster. In fact, I'm not at all certain the algorithm used to
16 estimate is reasonable at all for higher levels... but then again, I'm not
17 sure it's still necessary either, so feel free to remove it :-)
23 pl.Write(
'Valkyrie accepts your %s sacrifice!' % description)
27 altar = Crossfire.WhoAmI()
28 pl = Crossfire.WhoIsActivator()
29 praying = pl.CheckArchInventory(
'skill_praying')
30 if praying
and praying.Title ==
'Valkyrie':
36 pl.Write(
'Valkyrie scorns your stolen sacrifice!')
38 if obj.Type & 0xffff == Crossfire.Type.FLESH:
42 if obj.Level < praying.Level / 2:
44 pl.Write(
'Valkyrie grudgingly accepts your pathetic sacrifice!')
46 pl.Write(
'Valkyrie scorns your pathetic sacrifice!')
47 elif obj.Level < praying.Level:
50 elif obj.Level < praying.Level * 1.5:
53 elif obj.Level < praying.Level * 2:
56 elif obj.Level < praying.Level * 5:
64 if obj.Name.endswith(
'head')
or obj.Name.endswith(
'heart'):
69 value = obj.Exp / 5 * part_factor
76 res += obj.GetResist(at)
78 value =
max(res, 10) * level_factor * part_factor
84 pl.AddExp(
int(value),
'praying')