How would you recreate a light switch and light in Blueprints?
Newbie here, thank you for your patience.
I've watched the official Blueprint tutorials covering enabling/disabling/handling input, having blueprints communicate to each other via custom events and event dispatchers, and networking (variable and function replication).
I've tried to combine it all to make a [conceptually] simple light switch blueprint and lamp blueprint that communicate to each other (light switch sends a boolean to lamp light that sets visiblility), and also works in a client/server multiplayer environment.
The light switch and lamp work fine in single-player, but multiplayer is only halfway working - The server can switch the light on and off just fine, and it even shows in the client, but the client doesn't want to switch on that lamp.
My blueprints are extremely messy from inserting Print nodes all over to try and figure out where the breakdown is, so forgive me for leaving those out for now; I will post them tomorrow after work, and after I've cleaned them up to be more viewable/readable.
Here are some screenshots of the behavior I've got working so far:
[Server Toggles Light On - Replicated to Client Succesfully]
If I try to use the Client to toggle that light switch, nothing happens.
So, what would you do to get a Client to communicate properly to the Server, telling it "I am toggling this light switch's boolean, so you need to change the boolean in that lamp to match, which would turn on that light source"
I'm probably way over-thinking this, and/or I'm missing a proper setting of Run on Server/Run on Owning Client/Multicast.
How would you go about making an interactable light switch blueprint and lamp blueprint work as expected and sync across server and clients?
Thanks in advance!
asked Jun 04 '14 at 05:49 AM in Blueprint Scripting
You was right. I found the solution here: https://answers.unrealengine.com/questions/74932/blueprint-rpc-for-non-owner.html
Now it works fine. =D Thank you very much.
answered Apr 07 '15 at 11:16 PM
Without seeing your blueprint setups, it's a little difficult to help pinpoint what may be going on--if you wanted to dig in a little more yourself more before posting your blueprint screenshots, take a look at this post from the forums: https://forums.unrealengine.com/showthread.php?2956-New-Blueprint-Networking-Tutorial-Videos-Posted
That has a list of blueprint networking tutorials that may offer some insight into your issue. We don't have the maps he's using the in the tutorials available publicly just yet, so if you are still having trouble getting this working just reply back with your blueprint screenshots and we'll be glad to take a look with you.
answered Jun 04 '14 at 11:46 PM
Steve Allison STAFF
Hello i also have the same problem. Since no one have posted the solution i want to reopen this cuestion. Thank you very much.
answered Apr 06 '15 at 10:11 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here