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: Works in test but not online....

Previous Thread :: Next Thread 
legokendall is not online. legokendall
Joined: 07 Aug 2010
Total Posts: 667
25 Jun 2014 09:15 PM
This script works fine in test mode but doesn't work on a server... Help?
If you dont understand what this script is supposed leave a reply asking and I'll tell you but I'm to lazy to explain it hear...



script.Parent.CanCollide = false
wait (2)


debounce = false
script.Parent.CanCollide = true
script.Parent.Touched:connect(function(hit)
if hit.Parent:FindFirstChild("Humanoid") and hit.Parent:FindFirstChild("Head") and debounce == false then
if not hit.Parent.Head:FindFirstChild("Upgrade") then
debounce = true
local lol = script.Parent:Clone()
lol.Parent = game.Players.LocalPlayer.PlayerGui.ScreenGui.Chest
wait(0.1)
hit.Parent.Humanoid.MaxHealth = 150
script.Parent.Sound:Play()
local bob = script.Upgrade:Clone()
bob.Icon.Visible = true
bob.Parent = hit.Parent.Humanoid.Parent.Head
script.Parent.CanCollide = false
script.Parent.Transparency = 1
game.Players.LocalPlayer.PlayerGui.ScreenGui.Chest.Image = ("http://www.roblox.com/asset/?id=162826925")


else


wait(math.random(100,10000))
debounce = false
script.Parent.Transparency = 0
script.Parent.CanCollide = true

end
end
end)
Report Abuse
legokendall is not online. legokendall
Joined: 07 Aug 2010
Total Posts: 667
25 Jun 2014 09:32 PM
BUMP
Report Abuse
DigitalVeer is not online. DigitalVeer
Joined: 23 Jun 2009
Total Posts: 4182
25 Jun 2014 09:33 PM
That's because in Test Solo, scripts are ran locally, allowing even Server-Sided scripts to use LocalPlayer.
However, in a regular server, this is not the case.
You're gonna have to fix how you reference the player.
Report Abuse
legokendall is not online. legokendall
Joined: 07 Aug 2010
Total Posts: 667
25 Jun 2014 09:43 PM
Can you help me with the fix?
Report Abuse
legokendall is not online. legokendall
Joined: 07 Aug 2010
Total Posts: 667
25 Jun 2014 09:44 PM
bump :/
Report Abuse
legokendall is not online. legokendall
Joined: 07 Aug 2010
Total Posts: 667
25 Jun 2014 09:47 PM
\: bump
Report Abuse
legokendall is not online. legokendall
Joined: 07 Aug 2010
Total Posts: 667
25 Jun 2014 10:06 PM
HoLyBuMp
Report Abuse
legokendall is not online. legokendall
Joined: 07 Aug 2010
Total Posts: 667
25 Jun 2014 10:09 PM
PLEASE I NEED HELP SO BUMPBS
Report Abuse
legokendall is not online. legokendall
Joined: 07 Aug 2010
Total Posts: 667
25 Jun 2014 10:13 PM
e_E
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