Part = Instance.new("Part") Part.Size = Vector3.new(1,3,3) Part.BrickColor = BrickColor.new(23) Part.Transparency = .3 Part.Reflectance = .3 Part.Parent = game.Lighting Part.Name = "Trail" s = Instance.new("Script") s.Parent = game.Lighting.Trail s.Source = [[ wait(2) script.Parent:Destroy() ]]
As far as I know, you can't edit a script's source with a normal Script or LocalScript. That's probably the problem. :P
Just a side note, you should use ServerStorage instead of Lighting for storing items. They're more or less the same thing, except ServerStorage is official
Also, you could probably make the separate delete script beforehand, make it Disabled = true, place it into ServerStorage and THEN clone it into the trail. Then, when you want it to, make Disabled = false, so that it doesn't delete itself while in ServerStorage.
Read this http://wiki.roblox.com/index.php?title=ProtectedString
And also just use this instead of having to insert an entirely new script.
game.Debris:AddItem(game.Lighting.Trail, 2)