so for the past half hour iv been trying to change the imgid on a imagelabel but it changes the imgid when it sets it and nothing shows up. i can change it manualy and it shows it but wheni try to do it through a script it changes the image id and doesent work. ill leave my script below to see if im doing it wrong or something.
line 23-28 is where im trying to change it
--vars go here
local playerinvs = game.ReplicatedStorage.PlayerInvs
local playerinv = game.ReplicatedStorage.PlayerInvs
--find out when the player joins..
game.Players.PlayerAdded:Connect(function(p)
local playerinvfolder = Instance.new("Folder")
playerinvfolder.Name = p.Name.."sInv"
playerinvfolder.Parent = playerinv
for i=1, 9 do
local a = Instance.new("Folder",playerinvfolder)
a.Name = "Slot"..i
local b = Instance.new("BoolValue",a)
b.Name = "IsFull"
b.Value = false
a.ChildAdded:Connect(function(item) -- surprised this works but this will tell me when somone picks up something
-- saved me about 20 lines of code right here
wait(0.5)
local nameid = a.ItemName.Value
local pictureid = a.ItemName.PID.Value
print(pictureid)
local slot = p.PlayerGui.InvGui.Frame:FindFirstChild(i)
slot.Image = pictureid
print(slot.Image)
end)
end
end)
--make a for loop and create 12 diffrent folders for each slot
--make sure its easy to add more to later on

2 comments
What do both print statement print out?
they both print out the changed numberid