-- these numbers are how long it takes to switch. the numbers are in 1.4 seconds(IE: 6 = 1 1/2 seconds)

switch1 = 1
switch2 = 1
switch3 = 1
switch4 = 1
switch5 = 1
switch6 = 1


script.Parent.Parent.Character.Humanoid.WalkSpeed = start
while true do
x = script.Parent.Parent.Character.Torso.Position
wait(.25)
if script.Parent.Parent.PlayerGui.Bars.Charging.Value == false then
x = (script.Parent.Parent.Character.Torso.Position - x).Magnitude
if x < 1 then
script.Parent.Parent.Character.Humanoid.WalkSpeed = start
up1 = 0
up2 = 0
up3 = 0
up4 = 0
print("To normal")
end
if x >= 3 then
ch = math.random(1, 5)
if ch == 1 then
script.Parent.Parent.Data.Agility.AXP.Value = script.Parent.Parent.Data.Agility.AXP.Value + 50
end
if script.Parent.Parent.Character.Humanoid.WalkSpeed == start then
up1 = up1 + 1
if up1 == switch1 then
script.Parent.Parent.Character.Humanoid.WalkSpeed = stage1
up1 = 0
print("Speed Up")
end
end


if script.Parent.Parent.Character.Humanoid.WalkSpeed == stage1 then
up2 = up2 + 1
if up2 == switch2 then
script.Parent.Parent.Character.Humanoid.WalkSpeed = stage2
up2 = 0
print("Speed Up")
end
end


if script.Parent.Parent.Character.Humanoid.WalkSpeed == stage2 then
up3 = up3 + 1
if up3 == switch3 then
script.Parent.Parent.Character.Humanoid.WalkSpeed = stage3
up3 = 0
print("Speed Up")
end
end


if script.Parent.Parent.Character.Humanoid.WalkSpeed == stage3 then
up4 = up4 + 1
if up4 == switch4 then
script.Parent.Parent.Character.Humanoid.WalkSpeed = stage4
up4 = 0
print("Speed Up")
end
end


if script.Parent.Parent.Character.Humanoid.WalkSpeed == stage4 then
up5 = up5 + 1
if up5 == switch5 then
script.Parent.Parent.Character.Humanoid.WalkSpeed = stage5
up5 = 0
print("Speed Up")
end
end

if script.Parent.Parent.Character.Humanoid.WalkSpeed == stage5 then
up6 = up6 + 1
if up6 == switch6 then
script.Parent.Parent.Character.Humanoid.WalkSpeed = stage6
cha = math.random(1, 3)
if cha == 1 then
script.Parent.Parent.Data.Agility.AXP.Value = script.Parent.Parent.Data.Agility.AXP.Value + 16
else
script.Parent.Parent.Data.Agility.AXP.Value = script.Parent.Parent.Data.Agility.AXP.Value + 5
end
up6 = 0
print("Speed Up")
end
end
end
end
end

