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 » Scripters
Home Search
 

Re: Appear for all players?

Previous Thread :: Next Thread 
sal212 is not online. sal212
Joined: 11 Apr 2010
Total Posts: 2929
20 Oct 2015 08:22 PM
wait(6.8)
game.Workspace.ScreenGui:Clone().Parent = game.Players.LocalPlayer.PlayerGui

How would this appear for all players and work? It works in studio, but not ingame (Its in a normal script even though it includes LocalPlayer because local script wouldnt work.) So whats an alternative way for doing this and work?
Report Abuse
bosswalrus is not online. bosswalrus
Joined: 04 Jan 2013
Total Posts: 5430
20 Oct 2015 08:23 PM
You should probably store ScreenGui in ReplicatedStorage.
Report Abuse
sal212 is not online. sal212
Joined: 11 Apr 2010
Total Posts: 2929
20 Oct 2015 08:25 PM
Fixed, I think.

game.Players.PlayerAdded:connect(function(player)
wait(6.8)
game.Workspace.ScreenGui:Clone().Parent = player.PlayerGui
end)
Report Abuse
bosswalrus is not online. bosswalrus
Joined: 04 Jan 2013
Total Posts: 5430
20 Oct 2015 08:27 PM
You should use ReplicatedStorage
Report Abuse
TheFurryFish is online. TheFurryFish
Joined: 08 Jun 2011
Total Posts: 3433
20 Oct 2015 08:27 PM
or put it in startergui, then add a wait in the localscript
Report Abuse
sal212 is not online. sal212
Joined: 11 Apr 2010
Total Posts: 2929
20 Oct 2015 08:27 PM
Doesnt work?

game.Players.PlayerAdded:connect(function(player)
wait(6.8)
game.ReplicatedStorage.ScreenGui:Clone().Parent = player.PlayerGui
end)
Report Abuse
TheFurryFish is online. TheFurryFish
Joined: 08 Jun 2011
Total Posts: 3433
20 Oct 2015 08:28 PM
you can't fire playeradded from a localscript, do this
Report Abuse
sal212 is not online. sal212
Joined: 11 Apr 2010
Total Posts: 2929
20 Oct 2015 08:29 PM
Its not a local script
Report Abuse
TheFurryFish is online. TheFurryFish
Joined: 08 Jun 2011
Total Posts: 3433
20 Oct 2015 08:29 PM
whoops forgot to put what to do

but are you familiar with RemoteEvents?
Report Abuse
sal212 is not online. sal212
Joined: 11 Apr 2010
Total Posts: 2929
20 Oct 2015 08:29 PM
Nope
Report Abuse
TheFurryFish is online. TheFurryFish
Joined: 08 Jun 2011
Total Posts: 3433
20 Oct 2015 08:32 PM
well, here's a little tutorial since you want something to appear for everyone

*in a server script
local RemoteEvent = Instance.new('RemoteEvent',game.ReplicatedStorage)
RemoteEvent.Name = ('Event')

RemoteEvent:FireAllClients() -- This will send out a connection to all players ingame

*in a local script
local RemoteEvent = game.ReplicatedStorage:WaitForChild('Event')

Event.OnClientEvent:connect(function()
-- do stuff
end)
Report Abuse
sal212 is not online. sal212
Joined: 11 Apr 2010
Total Posts: 2929
20 Oct 2015 08:33 PM
Why isnt this script working also?

function Click()
local camera = workspace.CurrentCamera
camera.CameraSubject = game.Players.LocalPlayer
end

script.Parent.MouseButton1Click:connect(Click)

Its in a local script.
Report Abuse
sal212 is not online. sal212
Joined: 11 Apr 2010
Total Posts: 2929
20 Oct 2015 08:34 PM
I think its because I have another script that circles around an object for my intro...
Report Abuse
bosswalrus is not online. bosswalrus
Joined: 04 Jan 2013
Total Posts: 5430
20 Oct 2015 08:34 PM
becuase CameraSubject takes a model, part or humanoid.
http://wiki.roblox.com/index.php?title=CameraSubject
Report Abuse
sal212 is not online. sal212
Joined: 11 Apr 2010
Total Posts: 2929
20 Oct 2015 08:36 PM
Still not working, ?

function Click()
local camera = workspace.CurrentCamera
camera.CurrentCamera.CameraSubject = game.Players.LocalPlayer.Character.Humanoid
end

script.Parent.MouseButton1Click:connect(Click)
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • 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