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
 

How do i make it where it updates to ALL players in-game?

Previous Thread :: Next Thread 
Rackm is not online. Rackm
Joined: 07 Jan 2014
Total Posts: 718
03 Jul 2014 07:52 PM
local p = script.Parent.Parent.TextBox1
local s = script.Parent.Parent.TextLabel
local shout = game.StarterGui["Shout Gui ~NintendoZERG"]

function shout()
if p.Text ~= "Shout" then

s.Text = script.Parent.Parent.Parent.Parent.Character.Name.. " says: "..p.Text
shout.TextLabel.Text = script.Parent.Parent.Parent.Parent.Character.Name.. " says: "..p.Text

end
end

script.Parent.MouseButton1Down:connect(shout)


(since it is a shout i want it to update the text to all players.)
Report Abuse
Rackm is not online. Rackm
Joined: 07 Jan 2014
Total Posts: 718
03 Jul 2014 07:58 PM
...
Report Abuse
Rackm is not online. Rackm
Joined: 07 Jan 2014
Total Posts: 718
03 Jul 2014 08:09 PM
bump
Report Abuse
Rackm is not online. Rackm
Joined: 07 Jan 2014
Total Posts: 718
03 Jul 2014 08:17 PM
....
Report Abuse
Rackm is not online. Rackm
Joined: 07 Jan 2014
Total Posts: 718
03 Jul 2014 08:26 PM
......
Report Abuse
Rackm is not online. Rackm
Joined: 07 Jan 2014
Total Posts: 718
03 Jul 2014 08:32 PM
bump
Report Abuse
Rackm is not online. Rackm
Joined: 07 Jan 2014
Total Posts: 718
04 Jul 2014 01:43 PM
...
Report Abuse
badfitz99 is not online. badfitz99
Joined: 01 May 2010
Total Posts: 5854
04 Jul 2014 01:44 PM
Do you know how to do an in pairs loop?
Report Abuse
Rackm is not online. Rackm
Joined: 07 Jan 2014
Total Posts: 718
04 Jul 2014 01:44 PM
No not really
Report Abuse
badfitz99 is not online. badfitz99
Joined: 01 May 2010
Total Posts: 5854
04 Jul 2014 01:45 PM
Then I suggest learning it. Use peasfactory's tutorial on YT
Report Abuse
VirtualPrince is not online. VirtualPrince
Joined: 17 Oct 2013
Total Posts: 7386
04 Jul 2014 01:49 PM
local players = game.Players:GetChildren()

for i = 1,#players do
local gui = example:Clone()
gui.Parent = players[i].PlayerGui
end
Report Abuse
Rackm is not online. Rackm
Joined: 07 Jan 2014
Total Posts: 718
04 Jul 2014 01:52 PM
Seeing an example of one,

Why would i need that function? I want to make it where it updates everyone's GUI with the shout. No replace it or add a new one of it...
Report Abuse
VirtualPrince is not online. VirtualPrince
Joined: 17 Oct 2013
Total Posts: 7386
04 Jul 2014 01:54 PM
I'm not giving you the script, I gave you a large example.
Report Abuse
Rackm is not online. Rackm
Joined: 07 Jan 2014
Total Posts: 718
04 Jul 2014 01:55 PM
I know thats what i said, example.


I didn't try to use it. I said why do i need to use it. I don't get it.
Report Abuse
Rackm is not online. Rackm
Joined: 07 Jan 2014
Total Posts: 718
04 Jul 2014 01:59 PM
Wait i am starting to get it.
Report Abuse
Rackm is not online. Rackm
Joined: 07 Jan 2014
Total Posts: 718
04 Jul 2014 02:04 PM
Could this work?

local p = script.Parent.Parent.TextBox1
local s = script.Parent.Parent.TextLabel
local shout = game.StarterGui["Shout Gui ~NintendoZERG"]

function shout()
    
    if p.Text ~= "Shout" then
        
        local players = game.Players:GetChildren()
        
        for i = 1,#players do
            local update = players[i].PlayerGui["Shout Gui ~NintendoZERG"].TextLabel
            update.Text = script.Parent.Parent.Parent.Parent.Character.Name.. " says: "..p.Text
        end
        
        s.Text = script.Parent.Parent.Parent.Parent.Character.Name.. " says: "..p.Text
        shout.TextLabel.Text = script.Parent.Parent.Parent.Parent.Character.Name.. " says: "..p.Text

    end
    
end

script.Parent.MouseButton1Down:connect(shout)


(has nobody to test it with so i am asking)
Report Abuse
VirtualPrince is not online. VirtualPrince
Joined: 17 Oct 2013
Total Posts: 7386
04 Jul 2014 02:05 PM
"[i].PlayerGui["Shout Gui ~NintendoZERG"].TextLa"

I don't even understand what you're trying to do here

PlayerGui:findFirstChild'Shout Gui ~NintendoZERG'.TextLabel
Report Abuse
FauxHawke is not online. FauxHawke
Joined: 08 Jun 2012
Total Posts: 2190
04 Jul 2014 02:05 PM
Remove the quotations around shout
Report Abuse
Rackm is not online. Rackm
Joined: 07 Jan 2014
Total Posts: 718
04 Jul 2014 02:06 PM
Thats the name of the GUI. It works fine with that because it updates my own gui by using that.
Report Abuse
Rackm is not online. Rackm
Joined: 07 Jan 2014
Total Posts: 718
04 Jul 2014 02:13 PM
I am getting an error...
15:12:21.914 - Players.Player1.PlayerGui.Shout.TextButton.Script:20: attempt to index upvalue 'shout' (a function value)


Line 20: shout.Text = script.Parent.Parent.Parent.Parent.Character.Name.. " says: "..p.Text
Report Abuse
Rackm is not online. Rackm
Joined: 07 Jan 2014
Total Posts: 718
04 Jul 2014 02:15 PM
woops small mistake nvm.

i already have a function named shout
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