Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Sword not upgrading?

Asked by 8 years ago

Hi I am testing lots of scripts and I was scripting an upgrade button for my sword. It doesn't work and the output says "LungeDamage is not a valid member of Configurations". Can you help?

function ontouched()
    game.StarterPack.ClassicSword.Configurations.LungeDamage = 100
    print('Sword upgraded!')
end
script.Parent.MouseButton1Down:connect(ontouched)

1 answer

Log in to vote
0
Answered by 8 years ago

Assuming LungeDamage is a value, you'll need to add .Value after the LungeDamage part.

    game.StarterPack.ClassicSword.Configurations.LungeDamage.Value = 100
Ad

Answer this question