It’s model
The value of Player Bricks here is showing 0.
So if multiplied by 0.1 it will stay 0.
Did you update it on player added or something?
Yes! I wrote u my script before. But i use NumberValue should i change it to IntValue? Script again:
local MoneyLabel = script.Parent
local Value = workspace.Factory.PlayerMoney
Value.Changed:Connect(function()
MoneyLabel.Text = Value.Value
end)
Oh wait i maybe understood someth wrong in ur message, explain more pls
I meant when you are in-game what is the value of the player bricks?
Now they are for each player, so everyone see it, not local player, should i make it with local player now?
Each 0.8 seconds brickValue get + 1
ive never know storing value inside model is a thing…what i would do is put the value inside a folder/aka leaderstat and get the value from the localplayer
Uhm, I don’t understood that sorry
Btw i don’t think if i make a folder for values will help
here check this out,its called leaderstat
Hmm jk i only understood, idk how do i make money value and brick value for one player, btw i know about leaderstats
But i use UI to display player stats
can you provide a picture of your scripts?
leader stat is made for one player…just make two leaderstats and you’ll be fine getting the value
Factory script:
while true do
wait(0.8)
script.Parent.Position = Vector3.new(42.434, 10.85, -334.54)
local PlrBricks = script.Parent.Parent.PlayerBricks
PlrBricks.Value = PlrBricks.Value + 1
end
MoneyUI script:
local MoneyLabel = script.Parent
local Value = workspace.Factory.PlayerMoney
Value.Changed:Connect(function()
MoneyLabel.Text = Value.Value
end)
BrickUI script:
local MoneyLabel = script.Parent
local Value = workspace.Factory.PlayerBricks
Value.Changed:Connect(function()
MoneyLabel.Text = Value.Value
end)
Proximity script:
local Proximity = script.Parent
local MoneyValue = workspace.Factory.PlayerMoney
local BrickValue = workspace.Factory.PlayerBricks
Proximity.Triggered:Connect(function()
MoneyValue.Value = BrickValue.Value * 0.1
print(MoneyValue.Value) --> just to check
BrickValue.Value = 0
end)
I mean for UI not for leaderstats
its easy, do
local bricks = game.Players.LocalPlayer:WaitForChild("leaderstats"):WaitForChild("Brick")
script.Parent.Text = "Brick "..cash.Value
script.Parent.Text = cash.Value.."brick"
function changed()
script.Parent.Text = cash.Value.."%"
end
cash.Changed:connect(changed)
Bruh even if i use value in leaderstats this won’t change anyth, script won’t work still
well for that just x1 for the value…i have no idea why this dragged for so long