letris
|
  |
| Joined: 17 Dec 2012 |
| Total Posts: 572 |
|
|
| 01 Nov 2017 07:12 PM |
| how would i make the #### ## a gui appear the same for each player from a local script? ex: --local script script.Parent.Text = game.Players.LocalPlayer.Name how would i get this to display on all guis in players? -much to learn, you still have |
|
|
| Report Abuse |
|
|
rly_gud
|
  |
| Joined: 15 Jun 2014 |
| Total Posts: 220 |
|
|
| 01 Nov 2017 07:13 PM |
| i would use a serverevent that fires to all clients |
|
|
| Report Abuse |
|
|
letris
|
  |
| Joined: 17 Dec 2012 |
| Total Posts: 572 |
|
|
| 01 Nov 2017 07:16 PM |
true... i didnt even think about that
-much to learn, you still have
|
|
|
| Report Abuse |
|
|
letris
|
  |
| Joined: 17 Dec 2012 |
| Total Posts: 572 |
|
|
| 01 Nov 2017 07:33 PM |
thing is its very complicated because the gui is a leaderboard that shows the top players, and im not exactly sure how i would get it to work with only a serverevent
-much to learn, you still have
|
|
|
| Report Abuse |
|
|
INOOBE_YT
|
  |
| Joined: 08 Feb 2014 |
| Total Posts: 5067 |
|
| |
|
|
| 01 Nov 2017 08:37 PM |
use an event that Fire to all clients and in a *LocalScript* inside the *StarterPlayerScripts* you can make a function that does something when the event is fired to the client
ɱǿƲƨƹ_ƤǿƗɒϯѳҽ |
|
|
| Report Abuse |
|
|
|
| 01 Nov 2017 08:54 PM |
| You should do your best to avoid using remote events though, as that can cause extreme lag for players with not so advanced computers. Simply create an update function like using an onchanged property, that affects each client individually at the same time instead of the server as a whole. |
|
|
| Report Abuse |
|
|
|
| 01 Nov 2017 09:11 PM |
@Above me, :FireAllClients is the easiest way to do this. Unless you run on a 4x4 potato, it won't lag.
|
|
|
| Report Abuse |
|
|
Anu_Ea
|
  |
| Joined: 06 Jul 2017 |
| Total Posts: 33 |
|
|
| 01 Nov 2017 10:05 PM |
Just a note If you're attempting to do something like a server-wide synced timer don't consistently FireAllClients()
its not efficient.
instead have a value in ReplicatedStorage and have a script detect changes in that value. |
|
|
| Report Abuse |
|
|
TaaRt
|
  |
| Joined: 26 Apr 2009 |
| Total Posts: 5039 |
|
|
| 01 Nov 2017 10:13 PM |
| Aren't both .Changed and .OnClientEvent RBXScriptSignal objects with the delay of the server data traversal to the client between it? |
|
|
| Report Abuse |
|
|
Anu_Ea
|
  |
| Joined: 06 Jul 2017 |
| Total Posts: 33 |
|
|
| 01 Nov 2017 10:40 PM |
yeah but wouldnt it be easier than doing
for i = 60,1,-1 do thing:FireAllClients() end
(Assuming that's what someone would do.)
instead just have the client listen to a change.
idk. im stupid. |
|
|
| Report Abuse |
|
|
Kareem35
|
  |
| Joined: 08 Feb 2014 |
| Total Posts: 162 |
|
|
| 02 Nov 2017 12:23 AM |
You could have the server clone and parent the GUI to PlayerGui when the player joins (game.Players.PlayerAdded), thus allowing the server to manage each GUI (loop through players & apply the change)
However, if you NEED to use a localscript use RemoteEvents/RemoteFunctions.
|
|
|
| Report Abuse |
|
|