@@ -250,11 +250,11 @@ def preAssign(self, attributeName, value):
250250
251251 def increase (self , attributeName , increase , position = "pre" , skill = None ):
252252 """Increase value of given attribute by given number"""
253- # Increases applied before multiplications and after them are
254- # written in separate maps
255253 if skill :
256254 increase *= self .__handleSkill (skill )
257255
256+ # Increases applied before multiplications and after them are
257+ # written in separate maps
258258 if position == "pre" :
259259 tbl = self .__preIncreases
260260 elif position == "post" :
@@ -269,11 +269,11 @@ def increase(self, attributeName, increase, position="pre", skill=None):
269269
270270 def multiply (self , attributeName , multiplier , stackingPenalties = False , penaltyGroup = "default" , skill = None ):
271271 """Multiply value of given attribute by given factor"""
272- # If we're asked to do stacking penalized multiplication, append values
273- # to per penalty group lists
274272 if skill :
275273 multiplier *= self .__handleSkill (skill )
276274
275+ # If we're asked to do stacking penalized multiplication, append values
276+ # to per penalty group lists
277277 if stackingPenalties :
278278 if not attributeName in self .__penalizedMultipliers :
279279 self .__penalizedMultipliers [attributeName ] = {}
@@ -291,9 +291,10 @@ def multiply(self, attributeName, multiplier, stackingPenalties=False, penaltyGr
291291
292292 def boost (self , attributeName , boostFactor , skill = None , * args , ** kwargs ):
293293 """Boost value by some percentage"""
294- # We just transform percentage boost into multiplication factor
295294 if skill :
296295 boostFactor *= self .__handleSkill (skill )
296+
297+ # We just transform percentage boost into multiplication factor
297298 self .multiply (attributeName , 1 + boostFactor / 100.0 , * args , ** kwargs )
298299
299300 def force (self , attributeName , value ):
0 commit comments