Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- game.Players.LocalPlayer.CharacterAdded:wait()
- local rebirthinng = false
- script.Parent.Parent.Click.Frame.Frame2.Rebirth.MouseButton1Click:connect(function()
- if rebirthinng == false then
- local stats = game.Players.LocalPlayer:WaitForChild('All').Data
- local rebirthneed = stats.Rebirth.Value*10+10
- rebirthinng = true
- repeat
- wait(0.01)
- if rebirthneed <= stats.Level.Value then
- stats.EXP.Value = 0
- stats.Rebirth.Value = stats.Rebirth.Value + 1
- stats.Level.Value = stats.Level.Value - rebirthneed
- end
- until rebirthneed > stats.Level.Value
- rebirthinng = false
- end
- end)
- while wait(0.1) do
- local stats = game.Players.LocalPlayer:WaitForChild('All').Data
- local x = stats.Level.Value
- local need = math.ceil((x^2)*(x^2/4)+20)
- local crazypercent = stats.EXP.Value/need
- local fixp1 = crazypercent*100
- local textie2 = ''
- local able2 = true
- for i = 1, #tostring(fixp1) do
- if able2 == true then
- local check = string.sub(fixp1,i,i)
- if check ~= '.' and able2 == true then
- textie2 = string.sub(tostring(fixp1),1,i)
- else
- able2 = false
- end
- end
- end
- script.Parent.Parent.Click.Frame.Frame.RebirthLevelEXP.Text = 'Rebirth: '..stats.Rebirth.Value..'|Level: '..stats.Level.Value..'|XP: '..textie2..'%'
- script.Parent.Parent.Click.Frame.Frame.RebirthLevelEXP.Frame.Size = UDim2.new(crazypercent,0,1,0)
- local rebirthneed = stats.Rebirth.Value*10+10
- local crazypercentage = stats.Level.Value/rebirthneed
- local fixp2 = crazypercentage*100
- local able = true
- local textie = ''
- for i = 1, #tostring(fixp2) do
- if able == true then
- local check = string.sub(fixp2,i,i)
- if check ~= '.' and able == true then
- textie = string.sub(tostring(fixp2),1,i)
- else
- able = false
- end
- end
- end
- script.Parent.Parent.Click.Frame.Frame2.Rebirth.Frame.Size = UDim2.new(crazypercentage,0,1,0)
- script.Parent.Parent.Click.Frame.Frame2.Rebirth.Text = 'Rebirth: '..textie..'%'
- if need <= stats.EXP.Value then
- stats.Level.Value = stats.Level.Value + 1
- stats.EXP.Value = stats.EXP.Value - need
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement