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
 

Help!, whats wrong with my script!

Previous Thread :: Next Thread 
coolcardriver1 is not online. coolcardriver1
Joined: 08 Apr 2011
Total Posts: 121
04 Aug 2014 08:17 PM
local group = {
["coolcardriver1"] = true;
["dannyneal1122"] = true;
}

game.Players.PlayerAdded:connect(function(player)
if group[player.Name] then
player.Chatted:connect(function(msg)
if msg == "hi"
then for i,v in pairs do
game.Lighting.Tardis:clone()
game.Lighting.Travel:clone()
Tardis.Parent = game.Workspace
Travel.Parent = game.Workspace
end
end
end)
end
end)

so basically, idk whats wrong
help plz
Report Abuse
KnightmareXD is not online. KnightmareXD
Joined: 14 Jul 2009
Total Posts: 11189
04 Aug 2014 08:20 PM
You don't need that for loop. Just parent the items like this:

game.Lighting.Tardis:Clone().Parent = Workspace
game.Lighting.Travel:Clone().Parent = Workspace
Report Abuse
coolcardriver1 is not online. coolcardriver1
Joined: 08 Apr 2011
Total Posts: 121
04 Aug 2014 08:32 PM
Didn't work.
local group = {
["coolcardriver1"] = true;
["dannyneal1122"] = true;
}

game.Players.PlayerAdded:connect(function(player)
if group[player.Name] then
player.Chatted:connect(function(msg)
if msg == "hi"
then for i,v in pairs do
game.Lighting.Tardis:Clone().Parent = game.Workspace
game.Lighting.Travel:Clone().Parent = game.Workspace
end
end
end)
end
end)
Report Abuse
KnightmareXD is not online. KnightmareXD
Joined: 14 Jul 2009
Total Posts: 11189
04 Aug 2014 08:34 PM
Again, I don't think you need the loop/


local group = {
["coolcardriver1"] = true;
["dannyneal1122"] = true;
}

game.Players.PlayerAdded:connect(function(player)
if group[player.Name] then
player.Chatted:connect(function(msg)
if msg == "hi"then
game.Lighting.Tardis:Clone().Parent = game.Workspace
game.Lighting.Travel:Clone().Parent = game.Workspace
end
end)
end
end)
Report Abuse
KEVEKEV77 is not online. KEVEKEV77
Joined: 12 Mar 2009
Total Posts: 6961
04 Aug 2014 08:37 PM
for i,v in pairs(TABLEHERE) do
Report Abuse
coolcardriver1 is not online. coolcardriver1
Joined: 08 Apr 2011
Total Posts: 121
04 Aug 2014 08:39 PM
ye, it worked but how do I remove the lag from it, like only I feel it
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