Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
1

startScript re-entrancy has exceeded 3?

Asked by 8 years ago

I'm making an eye that is supposed to pulsate, however, I keep getting this error. It's really weird, as I've never seen it before.

Script;

local eye=script.Parent:Clone()
eye.Parent=workspace["Wisdom Fate Gauntlet"]
spawn(function()while wait() do
    eye.Transparency = 1
    eye.eyeMesh.Scale = Vector3.new(0.35, 0.35, 0.35)
    wait(1)
    eye.Transparency = 0
    for i = 1,10 do
        wait()
        eye.eyeMesh.Scale = eye.eyeMesh.Scale + Vector3.new(0.01, 0.01, 0.01)
        eye.Transparency = eye.Transparency + 0.1
    end
end
end)

I've read upon it and they say it has something with too many clones, but there's no loop or anything causing too many..?

1 answer

Log in to vote
1
Answered by
XAXA 1569 Moderation Voter
8 years ago
local eye=script.Parent:Clone()

This tells me that this script is a child of of the thing being cloned. This means, that whenever script.Parent is cloned, the same script is run again, which then clones script.Parent... etc. This goes on forever.

Either move the script outside of the thing you're cloning or disable the script right after cloning.

0
Never accepted this answer even though it worked. Woops. SimplyRekt 413 — 8y
Ad

Answer this question