How do i make mission progress bar

Hello, title says everything, but there is more details

  1. What do you want to achieve? Keep it simple and clear!
    I wanna make mission progress bar

  2. What is the issue? Include screenshots / videos if possible!
    Issue is: i can’t make for each click bar get +10%.



  3. What solutions have you tried so far? Did you look for solutions on the Developer Hub?
    I didn’t find anything on dev hub or youtube, only how to make loading bar
    Here is my code

local MissionsGUI = script.Parent
local Bar = MissionsGUI.Bar
local Filler = Bar.BarImage.Filler
local BarImage = Bar.BarImage
local Percentage = Bar.Percent
local ClickMenu = MissionsGUI.Mission1.Clicker
if MissionsGUI.Enabled == true then
	ClickMenu.MouseButton1Click:Connect(function()
		
for i = 1, 10 do
	wait(0.04)
	Percentage.Text = i.."%"
	
	local formula = i/100
	
	Filler:TweenSize(UDim2.new(formula, 0, 1, 0), Enum.EasingDirection.Out, Enum.EasingStyle.Linear, 0.1, true)
	
	end
		end)
		end

Alright so, for mission progression; you have to go into each task that needs to be done and then add 10 to a value that just constantly adds until it reaches 100%. I recommend using a system that follows the idea of this.

local BarImage = Bar.BarImage
BarImage.Size = BarImage.Size + --what ever percentage you want.
1 Like

Hmmm amma test that, thanks (30 letters)

Seems it works, but i lose every single animation, what can i do to not lose them?


Rule of the DevForum

One of the most important rules on the developer forum, use the edit button. Roblox does not want people to spam replies on the forums. If you’re replying to different people, it’s fine but if you can put it into one; it’s better to be safe than sorry.

I would need a gif, video or a way to look in-game to try and help. I’m down to give any form of help needed.


1 Like

Hmm amma record a vid to u give me a second

1 Like

Here it is my problem with mission progress - YouTube

1 Like

Alright so, somewhere in your code; you are simply moving to to 10 percent when you need to get it’s current position, then add 10 to its position.

hmm even if i detect i need to write that thing atleast 10 times, so i need to loop it somehow

send the current source code please

local MissionsGUI = script.Parent
local Bar = MissionsGUI.Bar
local Filler = Bar.BarImage.Filler
local BarImage = Bar.BarImage
local Percentage = Bar.Percent
local ClickMenu = MissionsGUI.Mission1.Clicker
if MissionsGUI.Enabled == true then
	ClickMenu.MouseButton1Click:Connect(function()
		
for i = 1, 10 do
	wait(0.04)
	Percentage.Text = i.."%"
	
	local formula = i/100
	
	Filler:TweenSize(UDim2.new(formula, 0, 1, 0), Enum.EasingDirection.Out, Enum.EasingStyle.Linear, 0.1, true)
	
	end
		end)
end

your number is stuck with 1,10 bruh you set for i = 1,10 so it will forever be 1,10%
do

local MissionsGUI = script.Parent
local Bar = MissionsGUI.Bar
local Filler = Bar.BarImage.Filler
local BarImage = Bar.BarImage
local clicks = 0
local Percentage = Bar.Percent
local ClickMenu = MissionsGUI.Mission1.Clicker
if MissionsGUI.Enabled == true then

ClickMenu.MouseButton1Click:Connect(function()

for i = 1 + (10*clicks),(10*(clicks+1)) do
wait(0.04)
	Percentage.Text = i.."%"
	
	local formula = i/100
	
	Filler:TweenSize(UDim2.new(formula, 0, 1, 0), Enum.EasingDirection.Out, Enum.EasingStyle.Linear, 0.1, true)
	
end

clicks += 1
if click >= 10 then
-- MISSION ACCOMPLISHED
end
end)
end

The problem is that you are not totalling up the clicks.
Try this code:

local MissionsGUI = script.Parent
local Bar = MissionsGUI.Bar
local Filler = Bar.BarImage.Filler
local BarImage = Bar.BarImage
local Percentage = Bar.Percent
local ClickMenu = MissionsGUI.Mission1.Clicker
local Clicks = 0
ClickMenu.MouseButton1Click:Connect(function()
	if MissionsGUI.Enabled == true then
		if Clicks.Value < 10 then
			Clicks += 1
			Filler:TweenSize(UDim2.new((Clicks/10), 0, 1, 0), Enum.EasingDirection.Out, Enum.EasingStyle.Linear, 0.1, true)
		else
			print("YOU CLICKED 10 TIMES!")
		end
	end
end)

u meant Clicks.Value <10 not > 10 lool

EASY! (this might make more sense in my head than me explaing it)
Make a number value. each time player completes a mission the number value goes UP and when it goes UP the mission bar goes UP. Lemme give you an example:

If the numbervalue.value = 1 then the bar will go up by one no matter what mission was completed.
if the numbervalue.value = 2 then the bar will also then go up bu 2 no matter the mission completed.

Hope this helps. If you are confused you can ask.

edited it, thanks for checking lol