You can write your topic however you want, but you need to answer these questions:
-
What do you want to achieve?
I would like to have it where the models can spawn at multiple places, eg: if the first place is taken, it spawns at the second, etc.
^ The one on the right is the one the models spawn at currently, however I want to make it where I can add more places where models can spawn. The one on the left does not work, and thats what I want to work. -
What is the issue?
I cannot seem to wrap my head around how to do this at the moment in time. -
What solutions have you tried so far?
So I looked around on the forum, and couldn’t find anything of any use to myself.
After that, you should include more details if you have any. Try to make your topic as descriptive as possible, so that it’s easier for people to help you!
Spawning Model:
local SS = game:GetService("ServerStorage")
local Cloneables = SS.Cloneables
local tc_Train = Cloneables.Train
local RS = game:GetService("ReplicatedStorage")
local REs = RS.REs
local rE_Spawn = REs.SpawnTrain
local spawnPart = game.Workspace.SpawnPart
local function CloneTrain(plr)
local train = tc_Train:Clone()
train.Name = plr.Name.."'s Train"
train.Owner.Value = plr
train:SetPrimaryPartCFrame(spawnPart.CFrame)
train.Parent = game.Workspace
end
rE_Spawn.OnServerEvent:Connect(function(plr, msg)
print("Will clone a train for: "..plr.Name..", and the message is: "..msg..".")
CloneTrain(plr)
end)
Text Button:
local RS = game:GetService("ReplicatedStorage")
local REs = RS.REs
local rE_Spawn = REs.SpawnTrain
script.Parent.MouseButton1Click:Connect(function()
rE_Spawn:FireServer("Train")
end)
Other Images: