There’s both a code sample issue and an unclear reference that may be confusing for newer developers.
Page:
Issue
local Humanoid = route.to.humanoid --should probably have a comment here for new developers that wouldn't know what this means
Humanoid:GetPropertyChangedSignal("FloorMaterial"):Connect(function()
print("New value for FloorMaterial: " .. Humanoid.FloorMaterial) --this line is the issue
end)
Error: Attempt to concatenate string with EnumItem
Fix
local Humanoid = route.to.humanoid --reference a character's humanoid here
hum:GetPropertyChangedSignal("FloorMaterial"):Connect(function()
print("New value for FloorMaterial: " .. tostring(hum.FloorMaterial))
end)
Convert the FloorMaterial enum to a string.