How to increase an attribute by % of itself?

drentekdrentek Member, PRO Posts: 25
edited November -1 in Working with GS (Mac)
Hi all,

was wondering how I go about increasing an attribute (e.g. height) by 20% every 3 seconds.
Currently I am doing:

self.height= self.height+ 0.2 ,

Obviously doing it wrong. Is there a page where I can learn the expression editor better as I am struggling on how to phrase commands in a way it understands.

Ta

Comments

  • LiquidGameworksLiquidGameworks Anchorage, AKMember, Sous Chef Posts: 956
    You're almost there. self.height = self.height * 1.20

    Alternatively self.height=self.height + (.20*self.height)

    This should do it. This will increase your self.height by 20% every time it is activated. Good luck!
  • drentekdrentek Member, PRO Posts: 25
    Thanks Liquid :)
Sign In or Register to comment.