|
| 05 Oct 2017 05:08 PM |
| how would i do this? fireclient does not show me much examples so im sort of confused. |
|
|
| Report Abuse |
|
|
Kekulator
|
  |
| Joined: 20 Jul 2011 |
| Total Posts: 1833 |
|
|
| 05 Oct 2017 05:12 PM |
I’m unsure if you can send instances through events etc
I can tell how to use it tho,
FireClient(ToPlayer, Arg1, Arg2)
You need to set the 1st argument the player you want to send to, rest is variables. |
|
|
| Report Abuse |
|
|
ChiefDays
|
  |
| Joined: 26 Sep 2016 |
| Total Posts: 502 |
|
|
| 05 Oct 2017 05:18 PM |
They are called arguments.
The instance must be replicated to the client first before being sent to the Client.
Something like this: Server:
local Inst = Instance.new'Part'; Inst.Parent = game.ReplicatedStorage;
RemoteEvent:FireClient(Client, Inst);
Client:
RemoteEvent.OnClientEvent:Connect(function(Argument1) print(Argument1); end);
-Game Developer, Official QA Tester, RBXDev Member. |
|
|
| Report Abuse |
|
|
|
| 05 Oct 2017 05:19 PM |
If the object isn't visible to the LocalScript you're sending it to, you can't send it. This is only true of Instances (Stuff you can see in the Explorer window like BasePlate and Workspace). functions and metatables can't be sent at all. If you don't know what a metatable is, don't worry about it anyways.
|
|
|
| Report Abuse |
|
|
|
| 05 Oct 2017 05:25 PM |
@chiefof
would i be able to do this with NPCs? with humanoids? |
|
|
| Report Abuse |
|
|
chimmihc
|
  |
| Joined: 01 Sep 2014 |
| Total Posts: 17143 |
|
|
| 05 Oct 2017 06:13 PM |
There is no way to replicate things to specific clients.
The best idea is to just store it in ReplicatedStorage where it can be accessed directly. |
|
|
| Report Abuse |
|
|
|
| 05 Oct 2017 06:25 PM |
| humanoids for some reason dont work when cloned to the client, i was wondering if it could be on the server then replicated to client. |
|
|
| Report Abuse |
|
|
|
| 05 Oct 2017 07:47 PM |
| This is why FE is annoying. |
|
|
| Report Abuse |
|
|