generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Need help really quick, please someone help

Previous Thread :: Next Thread 
builderman1171 is not online. builderman1171
Joined: 27 Mar 2010
Total Posts: 1595
25 Aug 2011 03:00 PM
I have a team teleport script;

play = game.Players:GetChildren()

for i = 1,#play do
if play[i].TeamColor == teams[team1].TeamColor then
char = play[i].Character
if char ~= nil then
torso = char:findFirstChild("Torso")
if torso ~= nil then
torso.CFrame = game.Workspace[BlueGameTele].CFrame
elseif play[i].TeamColor == teams[team2].TeamColor then
char = play[i].Character
if char ~= nil then
torso = char:findFirstChild("Torso") -----------------------------------HERE IS 113
if torso ~= nil then
torso.CFrame = game.Workspace[RedGameTele].CFrame
end
end
end
end
end
end


and I get in out this:

Players.Player.PlayerGui.GameGui.Script:113: bad argument #2 to '?' (string expected, got userdata)

Line 113, is where I put a line of -'s
Report Abuse
TrollHappy is not online. TrollHappy
Joined: 05 Nov 2010
Total Posts: 112
25 Aug 2011 03:02 PM
noo.. i think it has to do with

torso.CFrame = game.Workspace[BlueGameTele].CFrame

try chagning that to

torso.CFrame = game.Workspace["BlueGameTele"].CFrame


same with other team
Report Abuse
builderman1171 is not online. builderman1171
Joined: 27 Mar 2010
Total Posts: 1595
25 Aug 2011 03:04 PM
BlueGameTele is a variable e.g:

BlueGameTele = game.Workspace.BlueGameTele

It has something with line 113, where torso I guess is not found or astring is needed...
Report Abuse
builderman1171 is not online. builderman1171
Joined: 27 Mar 2010
Total Posts: 1595
25 Aug 2011 03:06 PM
bawmp
Report Abuse
TrollHappy is not online. TrollHappy
Joined: 05 Nov 2010
Total Posts: 112
25 Aug 2011 03:07 PM
well.. you tagged the torso part twice..
Report Abuse
builderman1171 is not online. builderman1171
Joined: 27 Mar 2010
Total Posts: 1595
25 Aug 2011 03:16 PM
bump
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image