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: Holo command script isn't working

Previous Thread :: Next Thread 
brickzombie is not online. brickzombie
Joined: 18 Jan 2012
Total Posts: 260
03 Feb 2014 08:26 PM
It isn't working now. Is it because roblox can only run so many scripts? I've check every thing else I can't find out whats wrong. PLEASE HELP.

game.Players.ChildAdded:connect(function(player)
player.Chatted:connect(function(chat)
if player.Name == "brickzombie" then
if string.lower(chat) == "load obby1" then
if not game.Workspace:FindFirstChild("Obby1") then
game.ServerStorage["Obby1"]:Clone().Parent = game.Workspace
end
elseif string.lower(chat) == "end obby1" then
if game.Workspace:FindFirstChild("Obby1") then
game.Workspace["Obby1"]:Remove()
end
end
end
end)
end)--This script was created by brickzombie
Report Abuse
domorox17 is not online. domorox17
Joined: 06 Mar 2012
Total Posts: 1710
03 Feb 2014 08:27 PM
One thing is use PlayerAdded not childadded.
Report Abuse
brickzombie is not online. brickzombie
Joined: 18 Jan 2012
Total Posts: 260
03 Feb 2014 08:31 PM
So just change all the childadded to PlayerAdded?
Report Abuse
DiamondBladee is not online. DiamondBladee
Joined: 24 Feb 2013
Total Posts: 3527
03 Feb 2014 08:32 PM
function NOODLES(player)
if player.Name == "brickzombie" then
player.Chatted:connect(function(chat)
if chat:lower() == "load obby1" then
if not game.Workspace:FindFirstChild("Obby1") then
game:GetService("ServerStorage"):FindFirstChild("Obby1"):clone().Parent = game.Workspace
end
elseif chat:lower() == "end obby1" then
while game.Workspace:FindFirstChild("Obby1") do
game.Workspace:FindFirstChild("Obby1"):remove()
end
end
end)
end
end)
game.Players.PlayerAdded:connect(NOODLES)
for i,v in pairs (game.Players:GetPlayers()) do
NOODLES(v)
end
Report Abuse
brickzombie is not online. brickzombie
Joined: 18 Jan 2012
Total Posts: 260
03 Feb 2014 08:40 PM
Still doesn't work!
Report Abuse
brickzombie is not online. brickzombie
Joined: 18 Jan 2012
Total Posts: 260
03 Feb 2014 09:09 PM
Lol the problem was that I named the script the same thing as the model. *facepalm*
Thanks for the help!
Report Abuse
HumanXerxes is not online. HumanXerxes
Joined: 17 Apr 2011
Total Posts: 1351
03 Feb 2014 09:26 PM
Also, I would put the "if player.Name=="brickzombie" then" outside the Chatted event. Otherwise, it would connect to every player that enters for no purpose.
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