I need help making something. Basically, I just need a new part to spawn in specific coordinates in the air. I want it to be duplicate. So a part falls from the sky and the a different one and so on. That’s all. I’m not a scripter so if anyone can at least guide me, it would be greatly appreciated.
for i = 1, 50 do
local part = Instance.new("Part")
part.Position = Vector3.new(x, y, z)
part.Parent = workspace
end
Change 50 for the desired number of parts, change x, y and z to the desired x, y and z co-ordinates the parts should fall from.
I’m sort of a bad scripter, so take my advice lastly.
I use CFrames. For spawning parts like this, I usually have a part in the spot I want it to be spawned at.
``Local PartSpawn = game:GetService(“Workspace”)
Local PartThing = game:GetService(“ServerStorage”)LePart:Clone() – LePart is the name of the Part.
PartThing.Parent = game:GetService(“Workspace”)
PartThing.CFrame = PartSpawn.CFrame.``
This is honestly one way of doing it, albeit a slower way but it’s what I use regarding CFrames and specific areas that will be used more than once.
Amazing! How would I make it so that you are able to set an amount using a UI? So basically you can click the UI and that amount of parts would fall? For instance, if you click a UI that says 1k, 1k parts would fall?
If it works I can pay 50 robux cause i really need this system!
while true do
local Part = Instance.new(“Part”)
Part.Parent = game.Workspace
Part.Position = Vector3.new(CoordinatesHere)
wait(5) --time between parts spawning
end
This will let you modify other properties of the part.
There’s so many ways to do this
(If you really need someone to tell you this then put a script in workspace and paste this inside of the script)