10.10.2016, 13:52
The problem was that I was subtracting an integer from a float using -= so the damage was like 100000000 for some reason. I could fix it by subtracting a float from amount instead of an integer. (like 15.0 and 10.0 instead of 15 and 10).