Search in

Sort by:

Everything C++ Programming

Current Space

Question Status:

All Questions With Answer With Accepted Answer

Quick results

Search help

Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both.
Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.

You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with
each other. Examples

Issues with proper replication

0

Hey everyone,

I'll try my best to ask this question properly, but due to my extreme lack of understanding about C++ based networking in UE4, it might seem convoluted.

I'm creating a networked FPS for my final project in college with another student. We're hitting a roadblock at the basic process of shooting an enemy, and decreasing their health, replicating that value throughout whoever needs to know about it.

The problem is, we (and even some other groups also using UE4 for their final project) can't figure out exactly how we're expected to go from a hit event on the players local computer, to properly propagating that information around. Even with the current documentation and examples, we're at a loss.

Hopefully some benevolent individual can come along and explain, as though we're idiots, what we're do do (in C++) to get this type of behaviour, and maybe explain how and why that is as well.

I'm currently on a skype call with a few of my buddies, and we still can't seem to wrap our heads around this concept. Especially since we're testing Role == Role_Authority and both instances of the game are ROLE_Authority. How else can we check if it's the server? We're looking at the Shooter Example but none of it is really documented so we still can't really make sense of it. We've been at this for weeks, and everyone just keeps sending us and everyone else to the shooter example.

Unfortunately, we need a bit more clarification since we can't get it to work at all, let alone a little.

You can run a single client /server instance in editor to test basic replication. Try that locally to test your code. You should clearly be able to see the RPC calls moving between the client and server while debugging. I can't think of anything that would ever cause two instances of a game to both have Role_Authority.