I've got a skill that does a set amount of damage to a player when used. The amount it does is defined in an Int Value named Damage. The player also has a stat called SkillDamage, that increases with each level. The base damage of the skill (the value of Damage) is added to the SkillDamage level of the player via a Local Script. But the change does not occur until the player resets. Is there anything that I can do to fix this? Maybe a type of loop with set conditions or an event?
Script that adds damage:
local Player = game.Players.LocalPlayer script.Parent.Value = script.Parent.Value + Player.Levelss.SkillDamage.Value
Instead of using an event, I simply made it so that each time the button for the attack is pressed it copies the Damage Value to the correct script to do the damage, but each time the copy's value is added to the skill damage value, so that it will update on it's own.
Your problem is that this is in a local script, and if FE is on then it won't work. Either way, changing stats from the client side is not recommended as it is easily hacked.