EMAN381
|
  |
| Joined: 27 Nov 2007 |
| Total Posts: 4300 |
|
|
| 08 Nov 2011 09:20 AM |
function onAdded(object) local player = game.Players:playerFromCharacter(object) if player ~= nil then local owner = player:findFirstChild("e_man") local spawn = script.Parent.Spawn if owner ~= nil then object.Torso.CFrame = object.Torso.CFrame + Vector3.new(0,3,0) wait() object.Torso.CFrame = spawn.CFrame + Vector3.new(0,3,0) end end end
game.Workspace.ChildAdded:connect(onAdded)
--The parent property is inside the spawn, and when I was testing it, it was in game.Workspace and now that I moved it, it's not working nor is there any output error. |
|
|
| Report Abuse |
|
|
|
| 08 Nov 2011 09:25 AM |
game.Players.Playeradded:connect(function(p) if p.Name == "eman381" then p.Character.Torso.CFrame = game.Workspace["YOURSPAWNNAME"].CFrame + Vector3.new(0,5,0) end end)
|
|
|
| Report Abuse |
|
|
EMAN381
|
  |
| Joined: 27 Nov 2007 |
| Total Posts: 4300 |
|
|
| 08 Nov 2011 09:29 AM |
| Well actually I need it as a value, and it's whenever a player spawns, not when he enters the game. |
|
|
| Report Abuse |
|
|
EMAN381
|
  |
| Joined: 27 Nov 2007 |
| Total Posts: 4300 |
|
|
| 08 Nov 2011 09:32 AM |
NEVERMIND! I fixed it now.
I made it script.Parent.Spawn instead of script.Parent.
Well thank you for helping, though! |
|
|
| Report Abuse |
|
|