Getting the error: ServerScriptService.BunnyHandler.MainBunny:28: invalid argument #1 to 'pairs' (table expected, got nil)

Click the image to see it in better quality

Ok, so what exactly are you trying to do. Change the Icon and title correct? Is that all? (I mean in the SetProperties Function).

Yes that is it! only change the icon and the title

Ok, so you see here

Module:SetProperties(FoundBunnyUI.Icon.Image, BunnyID, BunnyName)

Change it to:

Module:SetProperties(FoundBunnyUI, BunnyID, BunnyName)
ServerScriptService.BunnyHandler.MainBunny:36: attempt to index nil with 'Rarity'

this is erroring

Now all you have to do to make this extremely simple is to replace this:

to this:

function Module:SetProperties(parent, propertiesTable, name)
	local title = parent:FindFirstChild("Title")
	local icon = parent:FindFirstChild("Icon")
	if title then
		title.Text = propertiesTable.Display.Title.Text 
	end
	if icon then 
		icon.Image = propertiesTable.Icon
	end
end

Unable to assign property Image. Content expected, got nil New error :frowning:

ok just remove the icon chunk for now to see if the visible part works.

YEs it does, Should i add a debouce?

I mean does it flicker when you touch it?

No the bunny doesnt flicker but if I am there for too long it spams errors

Unable to assign property Image. Content expected, got nil this will keep on spamming once I stop stepping on it

for which line of code does it give the error?

FoundBunnyUI.Icon.Image = Module:SetProperties(FoundBunnyUI, BunnyID, BunnyName)

Oh, just replace it with:

Module:SetProperties(FoundBunnyUI, BunnyID, BunnyName)

You can also add this back if you want.

IT WORKS! Now one more thing, How do I change the text color to the rarity the bunny is

Actually i dont need that THANKS SO MUCH

function Module:SetProperties(parent, propertiesTable, name)
	local title = parent:FindFirstChild("Title")
	local icon = parent:FindFirstChild("Icon")
	if title then
		title.Text = propertiesTable.Display.Title.Text 
		title.Text.TextColor3 = propertiesTable.Display.Title.TextColor3
	end
	if icon then 
		icon.Image = propertiesTable.Icon
	end
end

There you go.

Wait there is another error…

FireClient: player argument must be a Player object