Text does not update when AssetID changes

EDIT: The update print works, but it just doesn’t update the text.

Mixed together some scripts to make a sort of music identifier, if you get what I’m saying. Trying to making something like what Tower Of Hell has, that little sound thingy at the bottom right corner.

Tried it, worked for the first sound, but never for all of them.
Checked the text itself, didn’t change.
Visually didn’t change either.

SCRIPT:

local Sound = game.Workspace:WaitForChild("Sound")
local id = Sound.SoundId:match("%d+")
local Asset = game:GetService("MarketplaceService"):GetProductInfo(id)

local frame = script.Parent.Frame
local text = frame.TextLabel

while wait() do
	text.Text = "Song Playing: " .. Asset.Name.. " - " ..Asset.Creator.Name
	print("update")
end

Help! :sob:

Try putting the Sound, ID, and Asset variable declarations into the while loop before updating the text.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.