So this script won't work and idk why. It prints everything, but it doesn't add to the IntValue. It's suppose to add 'number of chickens multiplied by(*) 0.25' to the 'money value' but it doesnt. What am I doing wrong??
Works! :D New Script:
while true do local waitTime = script.Parent.WaitTime.Value local money = script.Parent.Parent.Money local chickens = script.Parent.Parent.Chickens print('1') wait(waitTime) print('2') money.Value = money.Value + (chickens.Value*0.25) end
Well, it seems to me like neither money
nor chickens
is ever updated in this script, which means it will remain the default value forever. Just move all of the variables into the loop and it should work fine. Just make sure to declare your variables before you use them.