You can write your topic however you want, but you need to answer these questions:
-
What do you want to achieve? Keep it simple and clear!
I want to make it so that the images actually appear instead of not appearing. -
What is the issue? Include screenshots / videos if possible!
The images do not appear. -
What solutions have you tried so far? Did you look for solutions on the Developer Hub?
I have tried putting “http://www.roblox.com/asset/?id=” or “rbxassetid://” before the number id but both solutions don’t work
It is ImageLabels by the way.
This is my code.
local fen = "rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR"
local gui = script.Parent
local stuff = string.split(fen, "/")
local ids = {
["p"] = "http://www.roblox.com/asset/?id=8056505376",
["q"] = "http://www.roblox.com/asset/?id=8056511102",
["n"] = "http://www.roblox.com/asset/?id=8056513312",
["b"] = "http://www.roblox.com/asset/?id=8056516498",
["r"] = "http://www.roblox.com/asset/?id=8056512250",
["k"] = "http://www.roblox.com/asset/?id=8056509776"
}
for i = 1,8,1 do
local value = stuff[i]
local addNumber = 0 + ((i - 1) * 8)
local numberToHit = nil
for i = 1,8,1 do
if numberToHit then
if numberToHit >= i then
break
end
end
local number = i + addNumber
local piece = string.sub(value, i, i)
local pieceLowered = string.lower(piece)
if ids[pieceLowered] then
print(ids[pieceLowered])
gui[tostring(number)].Image = ids[pieceLowered]
if string.upper(piece) == piece then
gui[tostring(number)].ImageColor3 = Color3.fromRGB(0, 0, 0)
else
gui[tostring(number)].ImageColor3 = Color3.fromRGB(255, 255, 255)
end
else
numberToHit = tonumber(piece)
end
end
end