From what I've seen, you're trying to get the players character model:
for i, player in pairs (game.Players:GetChildren()) do
local character = player.Character
torso = character:FindFirstChild("Torso") or character:FindFirstChild("UpperTorso")
end)
I'm not sure what you're trying to do exactly as your question is very vague. The script I just made will loop through the players, get each and every one of their torso's, and then you can apply the changes you want(I'm assuming that's why you want this) -- Anyways my guess of your intentions may be off, but you got an error for searching "player" under workspace. The name "Player" won't be under workspace, look for the player under the players folder and then link it to their character.
4 comments
@Percil Thanks! That is exactly the solution I am searching for!! This is a Regular script inside of a model. The model is a NPC and I am trying to assign the "Torso" or "UpperTorso" 's Vector3 to the target. I can target any other "part" in the workspace but not the player.
So in that case you have to decide who the "target" is. For example, is it the player closest to the model?
Ahhhhh!!! Yes, sir/ma'am that is exactly right! It should be the player closest to the model!! Do you have time to post a script or a link to a situation that does that?
Loop through all the players, then use http://wiki.roblox.com/index.php?title=API:Class/Player/DistanceFromCharacter that to find which one is the closest.