ywisis
|
  |
| Joined: 07 Dec 2014 |
| Total Posts: 1481 |
|
|
| 24 Mar 2017 05:15 PM |
It's very hard to understand when there are limited guides.
Thanks |
|
|
| Report Abuse |
|
|
ywisis
|
  |
| Joined: 07 Dec 2014 |
| Total Posts: 1481 |
|
| |
|
JoshRBX
|
  |
| Joined: 19 May 2012 |
| Total Posts: 8778 |
|
|
| 24 Mar 2017 05:22 PM |
wiki.roblox.com/index.php?title=FilteringEnabled
wiki.roblox.com/index.php?title=Remote_Events_and_Functions
|
|
|
| Report Abuse |
|
|
ywisis
|
  |
| Joined: 07 Dec 2014 |
| Total Posts: 1481 |
|
| |
|
Bit_blox
|
  |
| Joined: 28 Aug 2016 |
| Total Posts: 974 |
|
|
| 24 Mar 2017 05:37 PM |
if you want to change something on the server from the client, in a localscript, put
--event script.Parent.RemoteEvent:FireServer(PlrClient)
in a regular script, put
script.Parent.RemoteEvent.OnClientEvent:connect(function() --code end
- Hello world - |
|
|
| Report Abuse |
|
|
Wrathsong
|
  |
| Joined: 05 Jul 2012 |
| Total Posts: 22393 |
|
|
| 24 Mar 2017 05:42 PM |
| YT links get censored else I'd link you to my FE tutorials..you can access it from my profile Ever wanted to learn how to script? Check out my ####### channel: ########################### Want to see me code in action? Follow me on ####### #################### |
|
|
| Report Abuse |
|
|
ywisis
|
  |
| Joined: 07 Dec 2014 |
| Total Posts: 1481 |
|
|
| 24 Mar 2017 05:42 PM |
script.Parent.ChangeGui.OnServerEvent:connect(function(player) local num1 = 0 local num2 = 0 local num3 = 0 local num4 = 0 while wait(0.1) do if player.TeamColor == BrickColor.new("Electric blue") then num1 = num1 + v.leaderstats.kills.Value v.PlayerGui.ScreenGui.blue.Text = num1 num3 = num1 num1 = 0 if num3 == 50 then v.PlayerGui.ScreenGui.message.Visible = true end end end while wait(0.1) do for i, v in pairs(game.Players:GetChildren()) do if v.TeamColor == BrickColor.new("Electric blue") then num1 = num1 + v.leaderstats.kills.Value v.PlayerGui.ScreenGui.blue.Text = num1 num3 = num1 num1 = 0 if num3 == 50 then v.PlayerGui.ScreenGui.message.Visible = true v.PlayerGui.ScreenGui.message.Text = "Blue team has won!" end else if v.TeamColor == BrickColor.new("Really red") then num2 = num2+ v.leaderstats.kills.Value v.PlayerGui.ScreenGui.red.Text = num2 num4 = num2 num2 = 0 if num4 == 50 then v.PlayerGui.ScreenGui.message.Visible = true v.PlayerGui.ScreenGui.message.Text = "Red team has won!" end end end end end end)
|
|
|
| Report Abuse |
|
|
ywisis
|
  |
| Joined: 07 Dec 2014 |
| Total Posts: 1481 |
|
|
| 24 Mar 2017 05:44 PM |
| The message gui does not become visible nor does it show up on the message. |
|
|
| Report Abuse |
|
|
Bit_blox
|
  |
| Joined: 28 Aug 2016 |
| Total Posts: 974 |
|
|
| 24 Mar 2017 05:58 PM |
because when you defined player in OnServerEvent its not actually the player and you are trying to us the defined variable for what its not meant for
- Hello world - |
|
|
| Report Abuse |
|
|
Soybeen
|
  |
| Joined: 17 Feb 2010 |
| Total Posts: 21462 |
|
|
| 24 Mar 2017 06:00 PM |
| There is a lot wrong with that script. For starters, half of it will never run because it will just loop forever in your first loop |
|
|
| Report Abuse |
|
|
nohubris
|
  |
| Joined: 20 Nov 2015 |
| Total Posts: 126 |
|
|
| 24 Mar 2017 06:18 PM |
| Pretty easy, simple format : Server :: Remote Event / Remote Function --> Individual User Client :: Script the regular way :) (NOTE: Only shows up for the client player not the server) Say you want to put someone on a team 1. Put a RemoteEvent into Replicated Storage 2. #### # ############ in SSS 3. Make a LocalScript in StarterGui ServerScript: #code RS=game:GetService("ReplicatedStorage") #code Event=Rs:WaitForChild("RemoteEvent") #code Event:OnServerFired:connect(function() #code print('e') #code end) LocalScript: #code RS=game:GetService("ReplicatedStorage") #code Event=Rs:WaitForChild("RemoteEvent") #code script.Parent.Button.MouseButton1Click:connect(function() #code Event:FireServer() #code end) |
|
|
| Report Abuse |
|
|
nohubris
|
  |
| Joined: 20 Nov 2015 |
| Total Posts: 126 |
|
|
| 24 Mar 2017 06:19 PM |
That post is unreadable because of roblox lol.
|
|
|
| Report Abuse |
|
|