Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

Why is this function that starts at Line 14 not registering?

local part = Instance.new("Part",workspace)
part.Name = "Bruh"
part.Anchored = true
part.BrickColor = BrickColor.new("Really red")

function say_hello()
	print("Hey there")
end

if part.Name == "Bruh" then
	say_hello()
end

function test_Anchored()
	if part.Anchored == true then
		print("This part is Anchored")
	end
	
	local part = Instance.new("Part",workspace)
part.Name = "Test"
part.Anchored = true
part.BrickColor = BrickColor.new("Dark stone grey")
part.Size = Vector3.new(4,4,4)

1 answer

✓ Accepted answer

You forgot to close the function

local part = Instance.new("Part",workspace)
part.Name = "Bruh"
part.Anchored = true
part.BrickColor = BrickColor.new("Really red")

function say_hello()
    print("Hey there")
end

if part.Name == "Bruh" then
    say_hello()
end

function test_Anchored()
    if part.Anchored == true then
        print("This part is Anchored")
    end
end; -- You forgot this end.

    local part = Instance.new("Part",workspace)
part.Name = "Test"
part.Anchored = true
part.BrickColor = BrickColor.new("Dark stone grey")
part.Size = Vector3.new(4,4,4)

Hope this is what was wrong and that this helps, if it does, please accept this answer.

This discussion is preserved as it was. New answers, comments, and votes are closed.