#multiplayer

1 messages ยท Page 649 of 1

fading birch
#

AWS EC2 and Gamelift have free tiers

#

but if you're just testing with a handful of friends, just host the server on your own machine.

pallid mesa
#

use EOS!! ๐Ÿ˜

azure hollow
#

you can use hamachi too

pallid mesa
#

hahahahha

fading birch
pallid mesa
#

yeah I know nitrado/aws is your friend

fading birch
#

having worked with AWS Gamelift and EC2 scaled in a released game, go with PlayFAB

smoky plinth
true stream
#

what is a micro instance

#

sorry the ignorance

fading birch
#

it's just a less powerful server

#

their naming conventions are a bit weird

true stream
#

what limits are there for hosting on my own PC?

#

CPU? Ram?

fading birch
#

yup

#

servers are much more lightweight than running a game

dark edge
#

What's the Properยฎ way to pass data to server on join? I have a struct representing the joining players character and loadout. What's the best event to hook into so the server can spawn the dude for me correctly?

#

Using Stock Steam sessions

fading birch
#

that depends on how that data is being retrieved. Trust the client with nothing. The server should be fetching the clients loadout/character once they have joined the server and pass that to them.

chrome bay
#

Once you've joined, send the data via RPC

#

Server validates it, then applies

#

In our case we think of it more as a request than a demand

dark edge
#

Its a coop roguelike so I'd like to at least make it slightly difficult to scum

random bone
#

What conditions cause a remote function call to not be executed when reliable execution is turned off? Is it only packet loss? I have a function I'm calling that is failing to be called 95% of the time, even when I'm running with clients locally and network emulation turned off.

chrome bay
#

Could be that there just isn't enough room left to send it, might be the case if you already have a lot of properties or RPC's

#

If they don't fit into the unreliable buffer that network frame, they get dropped

meager spade
#

also i would up the max rpcs

#

by default engine sets it super low

#

[SystemSettings] net.MaxRPCPerNetUpdate=5 by default its 2

#

iirc fortnite sets it to 10

chrome bay
#

Is that per-actor?

#

That is low...

vague fractal
#

Hey, i'm having a FCharacterDefaultStats struct as property which contains stuff like; CurrentHealth, MaxHealth, HealthRegRate(Same for stamina and mana), but it also contains the IsDeath state.

Does it make sense to separate the IsDeath boolean out of this struct when i want to have an OnRep method for the IsDeath changes ?
I kinda think if i'd let it stay how it is atm i'd increase the send packages by a lot since the OnRep would be also called for each single taken stamina when sprinting e.g.

#

Maybe my concern doesn't even make sense here since i still don't really understand this whole system.

vague fractal
meager spade
#

Well rpcs cost game time on the server

random bone
#

Huh, okay. Is there a way to debug whether it's being dropped via that route?

#

I'll look at that setting too. That does sound very low.

vague fractal
random bone
random bone
#

I don't see MaxRPCPerNetUpdate in my ini file and I don't see anywhere on the net really mentioning it within the context of unreal engine

meager spade
#

You need to add it and the best documentation is the source files :)

random bone
#

Yeah, setting it from my console to a high value (like 10) directly doesn't seem to fix the issue. I do see the stat of "saturated connections" going up when I have too many clients, but oddly enough, it doesn't seem to correlate with the issue arising. I seem to have the issue when the connections are saturated as well as when they aren't.

#

Yeah I don't see that line being logged. Hrm.

#

Man, nothing at all about that RPC even with full global verbose logging turned on. Also, I tried disabling a fairly frequent multicast I'm firing that would be sending far more frequently than the RPC I'm calling. The RPC still is being dropped for some reason.

random bone
#

Something more subtle is going on. If I call the RPC from a keypress it works fine. Blah. This makes no sense!

#

The only thing that seems to differ is where I'm kicking off the function call that ends up calling the RPC. When it's unreliable, it's from my projectile. When it's reliable, it's on my player. Even if I put it in a function on my player though and have the projectile call that, that doesn't seem to fix it.

#

Maybe because my projectile has a lower net priority? Would that cause the RPCs to be dropped even though they're being called for a high-priority actor? Edit: Raising the priority to be the same as the player didn't do anything.

random bone
#

Looks like upgrading to 4.26.3 fixed it.

random bone
#

Thank you for coming to my TED talk

shadow hatch
#

is there any way to convey a vector of a players camera if the camera is an actor that only exists clientside

#

im working on a beam / laser type of feature and it works just fine clientside since it follows the camera or where the character looks but other clients wont see the change

wide portal
#

I also have some camera-angle-dependent features and I'm not using an actual camera actor, so I have a replicated UPROPERTY which holds the camera angle, and I update this via RPC from CalcCamera. Not sure if this is the best way or not, though.

random bone
#

I have to replicate the actual direction the player controller is looking too for animation purposes. I think I do an unreliable multicast to do it.

plucky sigil
#

does onrep get called for all clients ? or just the owning clients ? if so, how can i have onrep triggered for all clients ?

fading birch
#

it depends on what the onrep is being called on

#

if you have an OnRep on say a player controller, only the owning client and the server will get that update

#

but if you have an OnRep on the playerstate, each client has a copy of the playerstate, so they'll all get the update

plucky sigil
#

What about ActorComponent

#

And from what you're saying, its only achievable if its moved into the PlayerState ?

fading birch
#

nono

#

the player state was just an example

#

each client has a local copy of other client's player state

#

for replication purposes

#

If you're spawning the actor in the world from the server, then all clients will have that actor with it's components

#

assuming the component replicates as well

#

so an OnRep would update them all at once

plucky sigil
#

But would the OnRep function be called on every client

fading birch
#

the server calls the OnRep

#

which is what updates the variables on each client

plucky sigil
#

lets say i want to display a ui on top of the player
depending on the health of the player
seen by all players
the health is a replicated variable
so i shouldn't put the displaying of the ui inside the onrep ?

fading birch
#

no

#

UI is strictly client side only, well it should be

#

if you want to use health, you can either store that in a component, the player state, or a gameplay ability tag (if using the Gameplay Ability System)

#

The server should control the damage/healing the health receives on that actor

#

if you're using a function like SetHealth(float inHealth);
it would look loosely like this:

YourActorComponent::SetHealth(float inHealth)
{
  Health = inHealth;
  OnRep_Health();
  // OPTIONAL HERE
  ForceNetUpdate();
}```
#

you can use ForceNetUpdate() to force a variable to replicate so clients have the most up to date info about that

plucky sigil
#

I assume thats a server rpc

#

sorry

#
YourActorComponent::SetHealth(float inHealth)
{
    if (!GetOwner()->HasAuthority())
    {
        SetHealth_Server(inHealth);
        return;
    }

    Health = inHealth;
    OnRep_Health();
    // OPTIONAL HERE
    ForceNetUpdate();
}

YourActorComponent::SetHealth_Server(float inHealth)
{
    SetHealth();
}
#

something like that ?

fading birch
#

no need to use an RPC

plucky sigil
#
YourActorComponent::SetHealth(float inHealth)
{
    if (!GetOwner()->HasAuthority())
    {
        SetHealth_Server(inHealth);
        return;
    }

    Health = inHealth;
    OnRep_Health();
    // OPTIONAL HERE
    ForceNetUpdate();
}

YourActorComponent::SetHealth_Server(float inHealth)
{
    SetHealth();
}

void OnRep_Health()
{
    // Do UI stuff here
}
fading birch
#

you can check role actually

#

1s let me double check some code I have

#

because I have that exact scenario I believe

plucky sigil
#

thanks

fading birch
#

so technically

#

you don't even need to do UI stuff there at all

#

you can just directly hook into the your health variable

#

or broadcast a delegate

plucky sigil
#

how so ?

fading birch
#

in the OnRep

plucky sigil
#

and will it be visible to all clients

fading birch
#

yes, OnRep causes the variable to be updated on all instances of that variable.

plucky sigil
#

i dont particularly understand the part where you said broadcast a delegate

#

server side or client side

#

i assume client side inside the on_rep

fading birch
#

just do it inside the on_rep

#

but you don't need to broadcast the delegate at all

#

if you're talking about health changing

#

there's no need

#

and the example I have, is for a server call unfortauntely

#

so wouldn't work here

plucky sigil
#

ive been doing it like you said

#

but for some reason it doesnt want to work

#

qq

fading birch
#

Show code please.

wet dock
#

Can anyone explain these network settings? My goal is to have my server allow 1mbps per connection with each connected client for a total of 15mbps (15 clients). What values would I need to set these at?

pure elm
#

Hi guys! So I was following this tutorial by Dev Addict: https://youtu.be/EDNF2DNLhPc , and I ran into a couple of issues. At the first test, right after setting up the "Join" button, it doesn't work. I mean, I create a session, then launch another instance of the game, click Join... And nothing happens. After some debugging, I found out that it does not find any sessions at the Find Advanced Sessions node. Any ideas as to how I can fix it? Thanks.

Check out my Unreal Engine 4 courses:

โ–บSouls-Like Action RPG with Multiplayer: https://devaddict.teachable.com/p/souls-like-action-rpg-game-with-multiplayer
โ–บMultiplayer First Person Shooter with Dedicated Servers: https://devaddict.teachable.com/p/multiplayer-fps-inspired-by-cs-go
โ–บMultiplayer Top-Down Dungeon...

โ–ถ Play video
fading birch
#

Are you testing in pie?@pure elm

#

Steam only works in standalone

#

And you need 2 pcs and 2 steam accounts.

#

It's annoying.

pure elm
#

Yeah I've been testing in standalone

#

And at the first test I haven't got steam setup yet

#

Just UE and Advanced Sessions

fading birch
#

Ah ok. So you're just testing with the null system?

pure elm
#

Yep

fading birch
#

You're sure the session is bring created?

pure elm
#

Yep

#

Rechecked it with strings, it is

fading birch
#

And find sessions is returning 0?

#

Interesting.

pure elm
#

Yes

fading birch
#

I've not worked with the advanced sessions stuff in a good long while unfortunately.

#

Is your project c++?

pure elm
#

No

#

I'm using BPs

fading birch
#

Alrighty

#

What session settings are you using when creating it. Can you show me?

pure elm
#

Err

#

I can

#

But rn I'm in a bus

#

I may be able in about 3 hours

#

Can I DM you?

fading birch
#

I'll be asleep lol. 11pm here.

#

Generally people ask for help at their desk lol

pure elm
#

Oh

fading birch
#

But I would check to make sure your session is being advertised.

#

And that it's joinable in progress.

#

That should sort out the find session issue

pure elm
#

Hmmm

#

I'll try to check

#

Thanks!

fading birch
#

Np. Feel free to ask follow up questions in here later. Others will help.

pearl moon
#

Anybody know of any guides or tutorials on how to set up sending/receiving json files over a network between two separate UE projects/games? (Using a client game and a separate server game project for security)

thin stratus
#

@fading birch I just noticed something

#
    // Use newer RPCs and RPC parameter serialization that allow variable length data without changing engine APIs.
    static int32 NetUsePackedMovementRPCs = 1;
    FAutoConsoleVariableRef CVarNetUsePackedMovementRPCs(
        TEXT("p.NetUsePackedMovementRPCs"),
        NetUsePackedMovementRPCs,
        TEXT("Whether to use newer movement RPC parameter packed serialization. If disabled, old deprecated movement RPCs will be used instead.\n")
        TEXT("0: Disable, 1: Enable"),
        ECVF_Default);
#

That's in the CMC

#

There is a "packed" version of the Server Move RPC

#

That sends a struct that can be extended

#

Which allows doing what I asked about in a nice and clean way, without having to adjust the API

#

And apparently that is on by default

#

That would also allow for passing over way more flags

thin stratus
#

You can literally tell UE4 to strip Server data from Client builds :<

#

But okay, whatever you want to do there would be done via some simple socket logic

#

check how to listen for incoming stuff on a socket and how to send, that should give some tutorial results

slender rivet
#

Running into replication issues and wondering if anyone has experience with it to suggest a workaround

#

I have a "container" actor component that can contain items. Simple array of a struct, {name, amount} style. Defaults to an empty array. Component set to replicate and the array replicating with an OnRep callback.

So I make a level instance, drop in a chest actor, add the component and fill with item entries. Start a server and modify the inventory. Start a client and join and everything works as expected - OnRep callback triggered on the client and the client updates it's inventory to match the server. I debug print both inventories and client always matches server. Tested various things like this and all working great.

However, one thing is not working. If I start the server - inventory full of things from level instance load - and then empty the inventory completely, and then join a client, the Server doesn't tell the client that the inventory is empty and the client never triggers an OnRep. If I ask the server to print what's in the container, it's correct - empty. If I ask the client, it shows that the container on the client-side is incorrectly full of items from the level instance.

#

The only way I've managed to get this to work is if the server empties the container while the client is connected. eg. Start a server - inventory full of level instance load things - Start a client and join. Then empty the container. In that situation the client receives the replication, triggers OnRep and both inventories match.

thin stratus
#

That sounds an awful lot like an Engine bug

#

@slender rivet Can you try something for me

#

Does your Chest have the Component on it already in its Blueprint?

#

Or are you adding it afterwards onto it?

slender rivet
#

I've tried both. Having a blueprint with the component already in it, and having a generic replicating 'chest' actor that has no existing component

#

Wondering if it's an engine bug where the engine is mistakenly thinking 'That replicating variable has been set to constructor default. Don't sync' and ignoring the fact that the client will be using the level instance array.

thin stratus
#

It is

#

I mean

#

At least that's what I had and thati s reported and backlogged

#

An easier example is this:

  • Blueprint with a RepNotify Boolean set to false
  • Blueprint placed into World, where Boolean is changed to true on the Instance
  • Server sets boolean to false before Client joins
  • Client joins and has boolean still true
#

Something like that

#

It compares to the archetype, not sure why and also not every time. A delay fixes it but delays are of course shit

slender rivet
#

Sounds like it's a case of waiting for it to be fixed then and doing some horrible workaround for now

thin stratus
#

You can probably wait a long time

#

You can test if this is the case by adding the component to the class

#

And adding 1 entry to it

slender rivet
#

Thinking I could have inventory default to some kind of weird value like [{name: "Empty", amount: 0}]

thin stratus
#

Then placing it into the world

#

And then filling it

#

And if the clearing of the server then works, then it probably compared the empty vs the archetype that had one entry

thin stratus
slender rivet
#

๐Ÿ˜„ doh. I take it this bug will apply to anything that has a replicating property set back to constructor default

pearl moon
#

thank you for the tips though! i'll start searching around tomorrow

thin stratus
#

The only restriction is that it requires c++ as far as I know

#

Not sure you can strip BP code

#

But simple wrapping your code in a server only macro should be enough

slender rivet
thin stratus
#

Not sure, ForceNetUpdate didn't help iirc

slender rivet
#

What a weird, annoying bug.

thin stratus
#

Yeah it is :D

pearl moon
#

perhaps I'm dealing with a completely separate issue

thin stratus
#

Ah right

#

Sorry

#

Totally forgot about the Dedicated Server needing a custom build

abstract pond
#

was wondering if anyone could help - i have this blueprint on an blueprint actor for on overlap - however when i overlap using the server player the rotation of the client player isnt being changed even though its fired when debugging

thin stratus
#

Uff, GetAllActors of Class two times? :D

abstract pond
#

when i go through using the client player it works as intended

#

yeah one for the player the other for where i want to teleport them to

thin stratus
#

Set the Players Control Rotation too

#

Maybe that resolves it already

#

Don#t really see wht's going on in your image. I would suggest you clean it up and send an easier to read one

#

Also 99% of the time, GetAllActorsOfClass is not required and just bad coding

#

If you need references to actors, there are usually other ways

abstract pond
thin stratus
#

There are multiple problems

#

The Overlap is called on all Players

#

That's for starters already something you need to take into account

#

It's not only running on the server or stuff like that

#

The first GetAllActorsOfClass is confusing. Don't you want to teleport the Overlapping Vehicle?

#

The other thing is

#

GetAllActorsOfclass does not guarantee you to be always in the same order

#

Index 0 is not always the same actor

#

Neither is Index 1 when you use it for RacePositions

#

You should have a manager that has the references and has them in order

#

Don't overuse this node

abstract pond
thin stratus
#

But you are only getting the first entry

#

If you want all, you'd need to loop over the array

#

Ah you use Index 0 and 1

abstract pond
#

right now im working with 2 vehicles and its working with both - it teleports just doesnt set the rotation for the client player

#

the teleport works fine

#

its teleporting to the right place and everything

#

just the rotation only sets on the client player when the client player goes through it themselves

#

if the server player goes through and triggers the overlap then the rotation of the client player isnt set

thin stratus
#

Right, okay, just keep in midn the code really should be improved.
Try setting the ControlRotation

#

Make sure that if you set the control rotation, that you check if the controller is valid before accessing it

#

Can someone refresh my mind on NetSerialize for a simple float?

#

Trying to look through examples, but most of them try to pack the float into a byte, which I don't need atm

thin stratus
#

Any errors when you stop playing?

abstract pond
#

both rotations are set correctly if the client player triggers it but when the server player triggers it the client player rotation isnt set

#

no errors

#

i've tried adding a delay also to see

#

and the delay is getting fired through

#

and the rotation just doesnt get changed

#

but the teleport still happens

thin stratus
#

Not sure atm, sorry. I only had issues with ControlRotation overriding the Actor rotation and stuff like that

ancient bramble
#

Hey, i have already setup a dedicated server with a 6 player(3v3) gamemode.
Since we are using the open <ip-address>command to connect to the server using an ip address which is recieved from the matchmaking service, Is it possible to have multiple matches running on the same server?
is it possible to isolate the 7th player into another match in the same server?
since its not feasible to have a server for every single match is this a good way to have clients connect to the server or is there a better way to do the same?

chrome bay
#

you essentially just run multiple instances of the game server .exe on one box, and assign them to different ports

pearl moon
#

that's good to know, i'll have to set up a pool of ports on the server firewall for multiple instances then

ancient bramble
#

like suppose a huge amount of people join

chrome bay
#

Everyone connected to the Server communicates on one port

#

E.g. you don't have 100 ports all assigned to each player

#

It's one port for all traffic

pearl moon
#

think of ports as the key to a door, you're basically just giving all your players a key to that one door (server) they are going to connect to...you can have multiple doors (servers) on different ports, so they have their own key for each ... if that makes any sense ๐Ÿ˜›

zinc owl
#

I think we will not came into the solution about above this question?

thin stratus
#

You mean the Ports stuff?

#

You can't run multiple matches on the same DedicatedServer.
You need to launch multiple DedicatedServers, one per Match.
These can run on one and the same physical (or cloud) server by using different ports.

#

That's basically the answer

zinc owl
thin stratus
#

Pretty sure before you run into the limits of ports, you'll run into the limits of hardware

#

You'll need multiple physical (cloud) servers

#

One is not enough

#

Not even with unlimited ports

ancient bramble
#

so is there any other way to connect to a headless server?

zinc owl
thin stratus
#

Not really

#

As in, there is not really another way

zinc owl
true stream
#

My projectile still moves even when I don't put SetReplicatedMovement to true, only SetReplicates.

#

should that work that way?, apparently in the guide I'm following the guy says that if I don't set it to true, it wont move, but it does.

#

maybe a different engine version made it that way, no idea.

thin stratus
#

Depends. If you are "firing" the projectile on every player, it will move

#

The Replicated Movement is to sync the location and rotation from server to clients

true stream
#

a bit confused there

#

the action of firing makes it move and maybe rotate, so...

#

just following the Tom Looman guide, that's why I was curious.

#

I was expecting to see the projectile spawn in place and not moving.

dark edge
true stream
#

so in which case should I use replicateMovement?

thin stratus
#

To keep things in sync

#

I can tell the Projectile to move on the client and on the server.
And if I cross my fingers strong enough, they might fly the same direction and distance :D
Replicating Movement updates the location and rotation (smoothly) if needed.
At least on projectiles, normal actors aren't smoothed

#

There is also an Interpolated Component on the ProjectMoveComp which you can set

#

usually the mesh you want to move smoothly, while the root collision is instantly moved on correction

dark edge
true stream
#

ok I think the reason why it moves without setting that to true, might be because of how the projectile gets spawned?:

#

that's on constructor

chrome bay
#

The initial location rotation and velocity is always sent even if replicated movement is false

#

So if the server initialises the velocity, that's also the velocity the client will have when it receives the actor.

#

See UPackageMapClient::SerializeNewActor

true stream
#

SetReplicates(true) is executed after projectile initialization

chrome bay
#

Also shouldn't call SetReplicates in the contructor, just use bReplicates = true

true stream
#

does that make any difference?

chrome bay
#

Doesn't matter

#

That doesn't set the actors' velocity anywhere anyway, but the projectile movement component does

true stream
#

alright

#

I'm reading eXi guide about networking, didn't finish it yet, I guess at some point it will talk about what makes sense to replicate and what not.

pure elm
#

Hi guys! So I was following this tutorial by Dev Addict: https://youtu.be/EDNF2DNLhPc , and I ran into a couple of issues. At the first test, right after setting up the "Join" button, it doesn't work. I mean, I create a session, then launch another instance of the game, click Join... And nothing happens. After some debugging, I found out that it does not find any sessions at the Find Advanced Sessions node. Any ideas as to how I can fix it? Thanks.

Check out my Unreal Engine 4 courses:

โ–บSouls-Like Action RPG with Multiplayer: https://devaddict.teachable.com/p/souls-like-action-rpg-game-with-multiplayer
โ–บMultiplayer First Person Shooter with Dedicated Servers: https://devaddict.teachable.com/p/multiplayer-fps-inspired-by-cs-go
โ–บMultiplayer Top-Down Dungeon...

โ–ถ Play video
pure elm
#

pls help

#

Ive spent three weeks on this project

fading birch
#

@pure elm we need code.

#

Also tagging here won't work and is a good way to get banned.

#

See rule 2

pure elm
#

Why instead of making a rule they didnt just disable it?

twilit radish
#

It is disabled, doesn't mean you should attempt to mass ping people. If someone has the time to help or by chance knows the answer they may help you out, but just trying to ping people isn't the solution. Same is said in the rules.

fading birch
#

we also still need code or can't help you

#

@thin stratus proper channel this time, my bad

pure elm
#

@fading birch OK, gonna repost tommorow, with samples of code

meager spade
#

@pure elm you need to run the game on two seperate PC's

#

else steam will never find any sessions

fading birch
#

they're not using steam yet, just null

meager spade
#

ioh

#

so still fighting my issue here ๐Ÿ˜„

#

think its related to updating session settings

#

nope, i have the most simple of setups and sometimes it works, sometime is does not

true stream
#

is there like a rule of thumb on what should happen on the server and what on the client?

dark edge
shadow hatch
#

optimisation question: if im doing a laser beam spell thats basically an actor that ticks every frame in order to update its location and rotation, would it be better to have a collision component that updates its size / length every frame or use a box / line trace every frame?

dark edge
#

So for a super basic shooter, I'm the servers eyes, everyone is just a bunch of capsules sliding around and line tracing at each other. The sever doesn't care about particles or sound or other polish, it just cares about the actual game model itself.

shadow hatch
#

the box trace or collision component would be used to damage viable actors

dark edge
#

@shadow hatch depends on if it's meant to have thickness or not. Either is fine. Traces are dummy cheap

shadow hatch
#

oh what do you mean by thickness? like the size of the trace box?

dark edge
#

Yeah.

#

I hadn't thought of a box trace but any approach is fine.

shadow hatch
#

oh nah it should be relatively small

#

well im modding for a game where aiming is not easy, youre mostly stuck in third person with over the shoulder camera plus the beam is not laser-thin

#

a line trace would probably be too frustrating

dark edge
#

Ya a box trace should be good

shadow hatch
#

thank you

true stream
#

anyone knows if there is a way to get like a networking diagram of sorts?

#

to know what gets replicated and where

kind ember
#

Does anyone know if Chaos vehicle have client side prediction instead of waiting for server round trip like Apex vehicle?

eternal canyon
#

as Epic has said they don't do prediction on vehicles im pretty sure

kind ember
#

Ok thxs Em,
Yea I have a feeling so

eternal canyon
#

Have clients predict behavior of client owned actors based on player inputs; simulate this behavior before receiving confirmation from the server (and correcting if necessary). We use this model for Pawn movement and Weapon handling, but not for Vehicles, as the complexity of saving and replaying the physics simulation outweighs the benefit of reduced latency for vehicles handling, where typical internet response latencies arenโ€™t that different from typical real world vehicle control response latencies.

dark edge
true stream
#

I'm reading it, probably didn't reach that part yet.

dark edge
kind ember
dark edge
kind ember
#

Goal

true stream
#

if you were to make an RTS-ish game, the units (let say ships) would be vehicles or normal pawns?

dark edge
#

Also if you figure out a nice way to do a very rigidly coupled drivetrain and tire model, hit me up

dark edge
#

Usually RTS games have very simple individual unit mechanics

true stream
#

great.

true stream
#

probably explained somewhere, or obvious.
When you call UFUNCTION(Server, etc), you are telling the server to run a RPC, then comeback to the client, and execute whatever you have in your function.

#

when you call UFUNCTION(Client...) what does it do?

fading birch
#

Server means to run the function only on the server

#

Client means to run the function on the owning client

#

NetMulticast means to run the function on the server, then to all clients.

true stream
#

right, but what is the difference between just plain UFUNCION() and UFUNTION(Client...)

#

don't functions by default run it only on client?

#

I have that feeling that I'm missing something critical to understand how it works ๐Ÿ™‚

dark edge
true stream
#

ok, in the example I have the teacher uses ServerFire, that I call it on Fire() in my client code, which then runs on ServerFier_Implementation()

#

so it's the server RPC'ing the client, I assume.

#

seems like Server and Client do the same thing, at least for my example

sand tangle
#

Hi, I could need some help replicating my current Enum value. Enum used as Transition Rules between different AnimBP States.

Character.h:

//AnimBP States.
UENUM(BlueprintType)
enum class EPawnStance : uint8
{
    Stand            UMETA(DisplayName = "Stand"),
    Crouch            UMETA(DisplayName = "Crouch"),
    Prone            UMETA(DisplayName = "Prone")
};

AnimInstance:

// Animation Stance States
bIsStanding = PlayerCharacter->CurrentPawnStance == EPawnStance::Stand;
bIsCrouching = PlayerCharacter->CurrentPawnStance == EPawnStance::Crouch;
bIsProning = PlayerCharacter->CurrentPawnStance == EPawnStance::Prone;

I tried this, but it's obviously wrong ๐Ÿ™‚

//The current stance of the player character
UPROPERTY(VisibleAnywhere, ReplicatedUsing = OnRep_PawnStance)
EPawnStance CurrentPawnStance;
UFUNCTION()
void OnRep_PawnStance(EPawnStance NewStance);
void AShooterProjectCharacter::OnRep_PawnStance(EPawnStance NewStance)
{
    CurrentPawnStance = NewStance;
}
#

Is there anyone who can be so kind and explain to me? ๐Ÿ™‚

boreal geyser
#

Hey yall so currently I have this bug in my game where clients can't move from the game to the main menu. I have a simple check for if one player has 3 kills, then an event will be run on the server to destroy the session. All that happens is the server moves to the menu but the clients just reload the level(offline, of course).

#

I'm using blueprints btw

#

Any ideas what's going on here?

dull lance
boreal geyser
dull lance
#

No, they're not

#

OpenLevel disconnects everyone

#

hence the behavior that you're experiencing

#

Check the docs on Steamless Travel/server/client travel.

boreal geyser
#

Alright thanks! will do

dull lance
#

@hollow eagle sorry for the tag, moving from #cpp

"Then I guess I have a different question: Do you happen to know when do Player states get their names assigned? I'm getting (on the server) PlayerName == "" for connected clients when running from MyPlayerState::BeginPlay"

If I run the function that updates things (it's a replicated struct, where I'm doing) cpp SetBaseInformationFromPlayerState(APlayerState* InPlayerState) { if (IsValid(InPlayerState)) { PlayerID = InPlayerState->GetPlayerName(); } }

and then running from BeginPlay if Authority cpp PlayerStateStruct.SetBaseInformationFromPlayerState(this);

the server gets a populated name, but the clients get an empty string

hollow eagle
#

That I don't know.

dull lance
#

I see. Thanks for answering though ๐Ÿ˜Š

twin juniper
#

Any way I could make login via Web3?

twin juniper
#

Can we set events as virtual ? So it can be overrided

fading birch
twin juniper
fading birch
#

oh

#

same answer

#

however you can to do it a bit differently

twin juniper
#

RPC call a function and this function is virtual ?

fading birch
#

for example:

UFUNCTION(Client, Reliable)
void Foo();
virtual void Foo_Implementation();```
twin juniper
#

Mmh

#

Thx!

steel fox
#

It's ok to limit player input to avoid spamming a button that calls a RPC(like to once every 0.1s) or it's going to make players experience worse?

rocky night
#

HI! I wonde rhow can i set more than one postprocess effect for one Player. At the moment i can bind only one to the camera or use them as unbound, but unbount creates wrong postprocess effects

chrome bay
#

Then whatever processes that input determines at what rate it should be sent

fast arrow
#

Hello, if i make a call to a delegate from the client, will the server react to it? for example. i got delegate OnPCSetUpFinished, i trigger it when the client finished it's initialisation. So will the server react to it or i should make RPC like Server_InitFinised and trigger a delegate there?

#

This is the call on client side. So server wont hear it right?)

kindred widget
#

Like Lorash said, only RPCs will talk to another machine. Delegates will only run on the machine they're bound in. ReplicatedProperties and RPCs are the only two things that will function across network.

fast arrow
#

RPC it is) got it. Thx

strong sail
#

Im running a dedicated server but I am wanting to spawn stuff in by passing a command to the server externally is this possible?

thin stratus
#

Basically RCON stuff?

#

Pretty sure that's somehow possible, but not without some extra code?

#

Maybe UT has something for that

strong sail
#

Yeah basically

#

Can't find any documentation on it

solar stirrup
#

Hey! Is there an in-built method of checking if a replication notification is the initial one?

#

In C++

#

I guess the quick and dirty way would be a flag that I set to true after the first rep notify, but I was wondering if there was a cleaner way

winged badger
#

there is a PostNetInit functiont hat runs after first round of replication(callbacks) @solar stirrup

solar stirrup
#

Awesome, I'll use that to check. Thanks!

winged badger
#

use that to do whatever you want done only during initial replication round

#

then you don't need to check anything

fading birch
#

I recently upgrade a project from 4.25 -> 4.26 and i'm noticing that my dedicated server is calling PostLogin on it's own, with 0 players connected to it.

#

that doesn't seem like it should be happening at all

astral agate
#

When I open 2 windows in editor (number of players > 1), collision for some objects (trace hit under cursor) stops working for both windows. There is no replication and these objects are created locally for each window, and net mode is Play Offline. How is that possible?

rocky stag
#

anybody can help me ?

boreal geyser
#

Heyo can session names be set in blueprints or is that still a c++ only thing? (I don't plan to use the advanced session plugin)

half jewel
# steel fox It's ok to limit player input to avoid spamming a button that calls a RPC(like t...

theres an internal rpc limit per Nettick(?) and of course there is the per player bandwidth limit.
so if its an expensive rpc, then you need to limit it so the player doesn't use up all of their bandwidth.

keep the player experience good and just mark the rpc as unreliable if the rpc is small.

and rpc on tick is a big no no no matter how you dress it.
a player spamming an input for rpc is ok.

#

now if your rpc is spawning actors or doing expensive work on the server well... might want to have a limiter on that ๐Ÿ˜…

steel fox
#

Ty @half jewel

fading birch
#

so C++ is the only way unless you use the Advanced Sessions plugin

young bluff
#

I'm using Advanced Sessions plugin for creating dedicated server session but I'm unable to display my server in Internet Tab under Servers in Steam. It's visible under LAN and works on local network but I'm unable to connect between different networks.

Is it even possible to make this with this plugin or I need to fix code for that or maybe there is plugin I can buy that actually works? ๐Ÿ˜ญ

fading birch
#

how are you testing it?

#

2 pcs 2 steam accounts?

#

in stand alone mode?

#

does the steam UI popup when you launch the game?

true stream
#

what would be difference between marking something as "Client" on the RPC and using ReplicatedUsing to execute functions only on clients

#

seems similar, not sure when should I use one or the other, and why both exist

thin stratus
#

Reminder: Session and OnlineSubsystem related questions belong into #online-subsystems.
Please redirect users whenever you can. Cheers! PE_PandaSippysip

thin stratus
#

RPC will only be executed for whoever is relevant at that time. So not for hotjoiners or peeps that are far away.

#

So if you want to update a state of your actor this is less ideal

#

A RepNotify function gets executed when the client receives the replicated variable. That can be minutes after you set the variable, ensuring they get the change and call the function.

#

(In BPs the Server also calls the OnRep function cause BPs are janky)

#

An example would be a barrel that explodes.
The explosion sound and vfx are only interesting for whoever is relevant at the time of explosion. I don't need the explosion effects when i join 30 minutes later. So this can be an RPC.
However the change from intact to broken barrel mesh is a change of state. I want to see the broken barrel when i join 30 min later. So this should be an OnRep (e.g. A boolean called bExploded)

#

So you mean they selected a class beforehand?

#

Generally the GameMode class has the functions you want to override

#

E.g. SpawnDefaultPawnForPlayer or something along that line of wording

true stream
#

I see, I guess there are a few concepts I still need to wrap my head around to fully understand how to develop properly. Thanks.

rocky stag
#

@thin stratus Thanks i found that .

dark edge
# thin stratus Generally the GameMode class has the functions you want to override

Do you know what the GameMode centric way to do this would be?

  1. Start up game. You have no default pawn. PlayerController sets view target to a static camera and plays a little intro camera action.
  2. Pawn parameters are selected or you resume a saved game, either way, we now have info to spawn your pawn.
  3. ? Spawn pawn somehow? Could just spawn actor and possess but that feels hacky.
#

I'm thinking something like restart player might be the ticket , do I override Choose Pawn Class for Player to use the info from character creation / resuming game?

thin stratus
#

For 1. I would use the PlayerCameraManager in combination with the GameState to get some self-registering camera actor or similar.
2. Here I would make sure the info is set on the PlayerController and then call RestartPlayer for 3. While overriding the GetDefaultPawnForPlayer function where you get the playercontroller to grab the previously saved info from, which will then make sure another restart will respawn with the same info.

true stream
#

Following this guide, and the guy says all the time: "because this code runs only on the server", but I have no idea why, or how he knows that.

#

any tips on how to know that ๐Ÿ˜›

thin stratus
#

Depends on where he is coding

#

If he's in the GameMode then it's because the GameMode only exists on thr Server

#

You should read my compendium that's pinned to this channel

true stream
#

in this case it was a AI class

#

yes I've read the compendium already.

rocky stag
#

@thin stratus Sir I didn't know you wrote that compendium . that mini book was amazing and really helped me to understand UE4 network system . ๐Ÿ˜ƒ

true stream
#

should make his name bigger and emmisive fonts.

fading birch
#

I recently upgraded a project from 4.25 -> 4.26 and i'm noticing that my dedicated server is calling PostLogin on it's own, with 0 players connected to it.
that doesn't seem like it should be happening at all

thin stratus
#

Breakpoint it and follow the callstack upwards

fading birch
#

that was my plan later on, was just curious if something changed

fading birch
#

now it's not happening at all ????

young bluff
fading birch
dense orchid
#

i have a question does multi usher work properly or is it difficult to get it to work cause I am really new to unreal and i have been trying to find ways to work with a friend of mine on unreal engine 4

fading birch
#

@dense orchid can you clarify what you mean.

dense orchid
#

My question was how can I collaborate with someone in unreal engine and share stuff with

#

The tutorial videos I find don't really help me out much or confuses me

tall pine
#

@meager spade : sorry to bother, but I see you have experience with RestartPlayerAtPlayerStart.
In my gamemode, I call RestartPlayer() but my player doesn't get reset to the starting position. He just stays where he is.

I don't override any of the RestartPlayer or RestartPlayerAtPlayerStart.
Just wonder if you run into this problem.

fading birch
#

@dense orchid version control mainly. If you're both going to be working on the game, as in through UE4, you'll need to use version control. If they're just going to be a tester, then you'll need to send them the packaged binary of your game. You can also purchase a steam app id ($100, 30 day turn around) and upload it to steam for testing purposes. You'll just give them a steam key, which you'll request through steam works and that's that.

#

Alternatively, since you're already using version control, you can just give them access to that, or a facet of it and put your packaged game there

dense orchid
#

Is there any in-depth tutorial videos for version control @fading birch

fading birch
#

there's an entire channel

#

with a good video as the top pin

dense orchid
#

Ok thank You @fading birch

heavy marlin
#

Anyone know how I might replicate the same property with different values per client?

#

I was going to just duplicate the actor for each connected client but that's a bit heavy handed

#

The use case is time dependent property values where each client can specify their own time

meager spade
#

you would likely want a struct

#

with say PlayerState and Time in it

#

put this in a replicated array

#

or i think you can use the FUniqueNetId

#

tho personally playerstate would be easier, tho i am not sure why you just don't have this "time" value on the playerstate

#

as there is a unique one per player..

#

@heavy marlin

heavy marlin
#

Alright thankyou

#

It's multiple values that are time dependent btw

#

And yeah it would make sense to put it in PlayerState or PlayerController, and maybe as a map keyed by actor id or some thing that ties it back

#

And use ffastarrayserializer

upbeat estuary
#

I have a (I think) pretty stupid question: Is it possible to run a game as a client without connecting to any server?

fading birch
#

yes

#

it's what you do before you connect to a server

upbeat estuary
#

wouldn't this be more of a local server then though?

#

in terms of authority

thin stratus
#

The Game does not count as Client without being connected to a Server

upbeat estuary
#

(I'm not even sure if my initial question makes sense, I'm slightly lost atm still)

thin stratus
#

You have 4 things you can be as a Game

#

Standalone -> Basically Singleplayer, nothing networked
DedicatedServer -> Headless Server that has no rendered version of the game
ListenServer -> A Player that hosts and acts as Server while also being able to play
Client -> A Player that connects to either a Listen or Dedicated Server

upbeat estuary
#

Okay, and I assume there isn't any straightforward or easy way to "fake" being a client, without actually connecting to an existing server? (aka executing all logic etc as if it were a client, while no server really exist).

thin stratus
#

I don't think so.

#

The only reason I would see is if you want to do some unit testing

twin juniper
#

A client is more like a window to the whole thing. Or that's how I think of it.

thin stratus
#

Well we are not talking about a Game Client aka the Game itself.

upbeat estuary
#

My use case is a bit convoluted, I'm using nDisplay's clustered rendering and am trying to fake the nodes as clients somehow, while only the master node is a real client

thin stratus
#

Hm

#

The only concept that UE4 has for that is Splitscreen Gaming

upbeat estuary
#

it kind of works if the master is the server too, and the nodes run as standalone - that way they execute the same-ish logic

thin stratus
#

And that is limited to 4 players by default and I doubt it can be applied here

#

Yeah a ListenServer and Standalone are sort of the same

#

Just that the ListenServer accepts connections

#

And probably does some magic under the hood

upbeat estuary
#

exactly, so what works for me atm is that I run the master as listen server, and the clients as standalone

fading birch
#

those still aren't clients

upbeat estuary
#

then I manually forward events that arrive on the master via nDisplay sync to the "clients"

#

yep

fading birch
#

standalone = you are the authority

#

client = server is

thin stratus
#

Then why not start them all as Standalone

#

And do the communication with sockets

#

There are probably some Plugins that allow easier creation and communication via Sockets

#

We used that in the past to communicate between UE4 and non-UE4 application

#

Like Scalemodels

#

Or UE4 PC Project and slimmed down UE4 Tabled Project

upbeat estuary
#

Hmmm that could work, but would require a lot of custom stuff

#

which I probably can't get around anyway

thin stratus
#

I'm not an nDisplay knowing person, so maybe there is an easy solution

upbeat estuary
#

so basically nDisplay starts an instance of unreal on all nodes and on the master, and syncs those via sockets (render barriers etc)

thin stratus
#

I just asked my co-worker

#

The project she worked on in the past has them just as standalone

#

And nDisplay sends the events to communicate

#

That's "all"

upbeat estuary
#

Yep

#

So what I'm trying to do now is connect that to a regular multiplayer "server"

#

so basically have a listen or dedicated server running somewhere else

#

then connect the nDisplay cluster "master" to said server

#

but then the nDisplay master is in client mode, and the nDisplay nodes are in standalone mode

#

which makes syncing a nightmare

thin stratus
#

Why do you need the extra layer though

#

Why can't the master node do what your extra server is supposed to do

#

There is probably a reason, but for me it sounds more like overcomplicating it

hollow eagle
upbeat estuary
#

Yeah that would be one option, but then when you'd have two clusters and a few regular Unreal instances this becomes a bit of an issue I think

hollow eagle
#

I don't see why running other nodes as standalone would cause problems if they get events from the master/client anyway

#

Is it that you're using HasAuthority checks? You can work around that by checking the net mode yourself.

#

Or add something to a config that you use to bypass authority checks

upbeat estuary
hollow eagle
#

I don't think you're going to be able to achieve that, faking being a client sounds worse than just writing a new HasAuthority function

thin stratus
#

I would say it's not even possible to fake that

upbeat estuary
#

Yeah it seems to be that way, that was kind of expected ๐Ÿ˜„

thin stratus
#

Too much underlying stuff going on

upbeat estuary
#

Thanks a lot tho, figured I'd ask here before I try ๐Ÿ™‚

#

My Unreal multiplayer experience is unfortunately not that great yet so as always with unreal there's so much stuff that's possible somehow if you just know about it

thin stratus
#

That's fair

#

But that goes for all sorts of frameworks hehe

upbeat estuary
#

yeah

thin stratus
upbeat estuary
#

oh wow this is really cool

thin stratus
#

Not sure what exactly my co-worker did on it, think some of the iPad stuff

#

And nervously sweating whenever the presenter touched the iPad

upbeat estuary
#

hehehe

#

that's a great visualization

thin stratus
#

Yeah it bit further into the video you can see the actual project on the wall screens, where the location is reflected into the table

upbeat estuary
#

oh my god setting that up sounds like an absolute nightmare

thin stratus
#

Haha, probably

upbeat estuary
#

okay so master node as listen server works-ish almost out of the box

fast arrow
#

Hello again) What Actor do you use to handle replication for UWorldSubsystem. It is a UObject so there must be someone in the wold to handle replication of it's fields.

chrome bay
#

Just spawn an actor and use it as a proxy

fast arrow
#

But should it be replicated as well?

thin stratus
#

I'm not doing replication work in that Subsystem

#

Would also not make any sense for the problem this was solving

#

The GameState replicates and tells the WOrldSubsystem on BeginPlay that it's available

#

There is no need for additional replication

fast arrow
#

Oh god i got it. I did everything wrong XD I broadcast delegate OnRep_Notify but i should just make a setter and broadcast it there)

#

Thank you)

thin stratus
#

Yeah

#

:P

errant silo
#

hi, i haven't touched ue in a few years now, i've been looking into it recently but i got a lot of confused information on the state of multiplayer in ue: some people say origin point shifting now somehow supports multiplayer? and ue5 is doing away with that and should support 'very large worlds'? any of that holds any truth?

chrome bay
#

Well, supported and usable are two different things when it comes to origin shifting. It does work, but it only really solves visual issues on the client. You can't move the Servers' origin. UE5 apparently supports double-precision worlds, but I don't know if that's complete yet and it also means double the cost.

errant silo
normal girder
#

we already said that it s not a good idea to make a multiplayer game now ^^

#

and we already answer for this issu

#

and, in french.....

chrome bay
#

It's not a good idea to make anything serious in UE5 right now. Epic say it's not production ready.

thin stratus
#

I wouldn't put any energy in doing so. You'll have an even harder time if users use it and don't encounter issues

errant silo
#

just out of curiosity and i ain't sure if this is offtopic - are there decent books on game multiplayer that cover more than the bare basics? it's the one part of game development that i don't think anyone can just "wing it"

wide portal
#

Anyone know the best way to detect on a client when a pawn gets unpossessed?

pearl moon
#

And yet "winging it" is exactly what im doing. Feels like a ticking timebomb at this point, but at least I'll learn what not to do!

vague fractal
#

Does it make any sense to have replicated variables in a UUserWidget ?
Same as RPC's.
I think it's a no, but since you can still override the GetLifetimeReplicatedProps method inside of the UUserWidget i'm not sure anymore

#

Alright, so it's just a thing you shouldn't use, or ?

chrome bay
#

can't replicate them

#

so noop

vague fractal
#

Will note that for the future ๐Ÿ‘

manic terrace
#

I am having quite some hard time spawning stuff in multiplayer. I don't know whether to make them happen only on the server and then replicate down to the clients or spawning in them all instances. I am currently spawning a gun on the start of my game and I am not sure how to handle it. Any advice?

chrome bay
#

If it's a gun, should almost certainly be spawned on the Server then replicated.

#

Spawning in Multiplayer is almost always server-side

#

For anything that affects collision or has some general gameplay behaviour

manic terrace
#

I am spawning on it on my character class. So I should just if(HasAuthority()) { SpawnTheGun }?

#

should I spawn it in another class maybe?

chrome bay
#

Seems fine

manic terrace
#

When executing some functions I have on the gun I it saying the gun has no owning connection. I am setting it's owner to be the character but doesn't seem to work. I do it like this: ```void AUnrealMultiplayerCharacter::SpawnGun()
{

if(StartingGunClass && HasAuthority())
{
    UKismetSystemLibrary::PrintString(GetWorld(), "TEST", true);
    CurrentGun = GetWorld()->SpawnActor<AGunBase>(StartingGunClass, GetActorLocation(), GetActorRotation());
    if(CurrentGun)
    {
        CurrentGun->AttachToComponent(Mesh1P, FAttachmentTransformRules::SnapToTargetIncludingScale,
            "WeaponPoint");
        CurrentGun->SetOwner(this);
        CurrentGun->GunMesh->SetOnlyOwnerSee(true);

        if(TP_GunMesh)
        {
            TP_GunMesh->SetSkeletalMesh(CurrentGun->GunMesh->SkeletalMesh);    
        }        
    }        
}

}```

chrome bay
#

The character would need to be possessed and therefore "owned" by the player controller too

manic terrace
#

I do it on begin play. I it throws the warning only on the client. Maybe when I am spawning the gun the controller hasn't possesed the character?

chrome bay
#

Yeah that's certainly possible

manic terrace
#

Tried setting on tick but no luck (just for testing) LogNet: Warning: UNetDriver::ProcessRemoteFunction: No owning connection for actor BP_TraceAssaultRifle_C_1. Function Server_EndFire will not be processed.

#

Still getting this warning

true stream
#

is it OK to think of the GameState as a way to communicate GameMode things to clients?

vague fractal
#

I'm kinda afraid of the use of Multicast RPC's, but i think in my case i should use it. But i wanna go safe and ask first.
My use/case would be basically just to spawn some death particles, that's totally a case for Multicast's, or ?

dark edge
#

Like you don't need the multicast play a sound and then multicast play particles and then destroy actor and then multicast some other thing, just have a sort of death state that something goes into or a multicast death RPC and locally trigger all the visuals and other decorations

vague fractal
dark edge
vague fractal
#

As in OnRep will call the destroy mesh and such

dark edge
#

I prefer death being in on rep of some sort of variable, probably an enum or a boolean

vague fractal
#

But if i'd use the OnRep to also spawn the particles it might get called 10 minutes later once you are relevant for it. That seems kinda wrong to me

vivid seal
#

hey guys, im trying to figure out the best way to do fast-firing abilities, like automatic weapons or channeled spells that tick multiple times a second. Currently I have things setup to just multicast every tick of an ability (or every shot from a weapon), but this comes with 2 downsides. 1. is that im multicasting a LOT. 2. is that i dont have a way to skip the owner when multicasting, and while i can filter the event by NetRole (if Autonomous Proxy, don't play the effects), its still sending the message in the first place when the owner has already done prediction for effects in most cases.

I was considering trying to set up some kind of on-rep variable for any given cast that updates every tick or an ability (I believe this is similar to how ShooterGame does its burst counter?), that can just trigger the effects in the onrep, and skip owner on the replication condition, but I have trouble figuring out how to deal with relevancy. If someone comes into relevance I don't want them triggering effects from a cast that ended a while ago.

chrome bay
#

You can guard it by checking the time

#

That's how we do it in HLL

vivid seal
#

im literally reading that right now lol

chrome bay
#

For rapid-fire, we setup a timer to repeat the effect, and use looping FX where possible. It fixes the "stacatto" like FX you get otherwise since you can't rely on a steady stream of rep updates.

vivid seal
#

yeah i've built my ability system a certain way and then decided later on i wanted weapons to be included in the same system, but weapon fire rates are much faster than what I had planned for ability tick rates, so i'm kinda trying to rebuild parts of it to account for this

#

normally I have a "simulatedtick" function that fires with the tick number (the tick of the ability cast, not like a game tick), and can change effects based on what number tick it is, but for fast firing stuff I'm considering just doing only an initial tick and an on-cancel tick that just start and stop a looping effect

chrome bay
#

yeah that's sensible enough

vivid seal
#

so after reading that post, my question is how would you change your approach to handle if you DID care about what number shots in a given burst happened? like if you wanted to know if the burst was 4 shots or 6 shots. Since you're never resetting the counter, you'd need to keep track of which shots started/ended a burst I think

#

and to add on to that, in my case, I want to know how the burst ended, since I'm trying to repurpose this for a cast bar type situation, which can either complete all ticks, be cancelled early, be interrupted, etc. I was considering some kind of FastArray setup, where the array just contains every completed cast (up to a maximum) represented as a struct that details how many ticks have occurred, whether the cast is still active or not, how the cast ended, and the ability that the cast was actually casting. I'm not sure if that's going to cause weird issues replicating multiple cast structs at once tho

chrome bay
#

You could use an enum or a gameplay tag to denote how the last burst ended

vivid seal
#

hmm, like inside the burst info struct have the counter and bisfiring like you have but also have some info about the previous burst? that could be interesting

chrome bay
#

Possibly yeah. Abilities get complicated though, this one works okay for basic pea-shooter weapons but maybe not so well for more complex stuff

vivid seal
#

yeah, the more I try to fit weapons and abilities in the same system the more I feel I'm having to compromise to get both working

#

but there's so much overlap in how they work prediction-wise that I don't really want to have to write a new component for weapons that does 90% of the same stuff

#

alright well thank you for your time, gotta go to work

vague fractal
#

Does it make sense to have replicated logic in UAnimNotify/UAnimNotifyState's ?
Or is it the same as with UUserWidget's where you shouldn't use it ?

#

Just found the answer here xD

fading birch
#

@chrome bay side bar you're a HLL dev?

#

BTW dev says hi

#

Big fan

meager spade
#

really need to play HLL

fading birch
#

It's quite good.

#

Sorry for the OT

vague fractal
# meager spade really need to play HLL

Hey uhm, since your post told me to make this kind of call from the owning actor, should i do something like this then ?

void UAnimNotifyState_MeleeHitCheck::NotifyEnd(USkeletalMeshComponent *MeshComp, UAnimSequenceBase *Animation)
{
  Super::NotifyEnd(MeshComp, Animation);

  for(AEnemyBase* Enemy : M_AlreadyHit)
  {
    if(IsValid(Enemy))
    {
      if(ACharacterBase* Owner = Cast<ACharacterBase>(MeshComp->GetOwner()))
      {
        Owner->DealDamageTo(Enemy); // <---
      }
    }
  }
  M_AlreadyHit.Empty();
}
#

This kind of workflows always confuses me so hard

meager spade
#

hmm i tend to handle stuff outside of the notifies

#

and have the notifies call a function on the enemy, as notifies are CDO (can not store states)

vague fractal
meager spade
#

M_AlreadyHit.Empty(); is in the state

#

which is not allowed

vague fractal
#

Yeah, that line is probably useless anyways since i'm calling it on NotifyEnd

meager spade
#

err i meant M_AlreadyHit wont persist

#

hard to explain ๐Ÿคท

vague fractal
#

Even more when it comes to my brain ๐Ÿ˜น

fading birch
#

Generally you use a notify to trigger logic on the owner. In this case you want the notify to trigger on a melee hit, so you would call a function in the owner to run the check you're trying to do on your character.

#

Ie, notify ends, run a trace to get enemies hit.

meager spade
#

what i am saying isd

vague fractal
#

I'm currently doing this trace in the Tick of this Notify

meager spade
#

if you are tracing on notify tick

#

you can not store that in M_AlreadyHit

fading birch
#

^

meager spade
#

as the notify is CDO

fading birch
#

Actually I think you can store it just fine. I don't see why not.

vague fractal
#

So should i pass the hit enemies in my tick directly to my character which handles the already hit logic ?

fading birch
#

I've done similar things in the past

#

The notify is just a weird place to do it

meager spade
#

its CDO, it does not maintain state

fading birch
#

It doesn't need to

meager spade
#

it does if M_Hits is a member

fading birch
#

Array created on notify start, populated on tick, emptied on end.

#

It persists through that

meager spade
#

CDO should be read only

#

you should not mutate stuff

fading birch
#

At least in BP versions of notifies I've used.

meager spade
#

those are const

vague fractal
meager spade
#

all BP exposed are const, cause they should be

fading birch
#

I would just do the logic on your character in the first place.

meager spade
#
     * We don't instance UAnimNotify objects along with the animations they belong to, but
     * we still need a way to see which world this UAnimNotify is currently operating on.
     * So this retrieves a contextual world pointer, from the triggering animation/mesh.  
     * ```
fading birch
#

And call that from your notify

#

@meager spade also BPs can ignore const btw

#

They'll do some shady shit under the hood.

vague fractal
fading birch
vague fractal
#

Alright, in that case i'm not even in need of my Notify's anymore

meager spade
#

i use the notifies to turn on/off the trace

vague fractal
#

Was probably a tutorial for a singleplayer game i've followed since the trace was also made inside of the NotifyTick

meager spade
#

and notify when the melee is finished

vague fractal
# meager spade i use the notifies to turn on/off the trace

So basically just like

void UAnimNotifyState_MeleeHitCheck::NotifyEnd(USkeletalMeshComponent *MeshComp, UAnimSequenceBase *Animation)
{
  Super::NotifyEnd(MeshComp, Animation);
  if(ACharacterBase* Owner = Cast<ACharacterBase>(MeshComp->GetOwner()))
  {
    Owner->SetShouldTrace_LeftHand(false);
  }
}

Or similar ?

meager spade
#

yh

fading birch
#

Yeah something like that

vague fractal
#

Alrighty, hope i get it to work, thanks for the help ^^

gray zinc
#

This might be a dumb question but I'm trying to check overlaps with OverlapMultiByChannel and I want it to ignore an actor. In the server it works, in the client the autonomous proxy actor doesn't get ignored.

Does this problem ring any bells?

wise bridge
#

Hello everyone, I'm just trying to change the value of a variable. It's replicated, a character cast to the game state that the triggered action has happend, the game state set this boolean to false for a defined character. It works very well when the client is this defined character, but not when it's the server, the variable still have the same value. My event is replicated on the server, this is the value I get on my specific character

wise bridge
#

GS action :

#

(and 173 is a child of the base character, which contain the function on the first screen)

gray zinc
#
const FCollisionResponseParams Response;
const FCollisionQueryParams QueryParams(TEXT("LadderEntranceOverlap"),false, Character);
TArray<FOverlapResult> CenterHits;
bool Close = GetWorld()->OverlapMultiByChannel(MovingHits,CharacterLocation,Character->GetActorQuat(), ECollisionChannel::ECC_Pawn,CharacterCapsule->GetCollisionShape(),QueryParams, Response);

something like this, however I discovered that under separate processes works correctly, and in one process works wrong I wish I was able to know why and how to fix it, two processes works slow -_-

queen pine
#

For some reason i cant get my server rpc to run on the client. I'm running the rpc from the player character too.

#

I've done this before and havent had issues

bronze summit
#

I have a replicated UObject (I had it correctly setup and it was working). I recently changed it to using a struct instead of a FDataTableRowHandle. But now it doesn't seem to be replicating anymore (not calling OnRep). In the image above is the code used to change structs. Anyone has an idea for potential fix?

#

Rep in the component

dark edge
#

Of course nothing runs on the client, that's a Client -> Server RPC

#

That should be reliable too btw

queen pine
kindred widget
#

Most things are going to end up portable to UE5. Not worth the headache of finding out what doesn't work just to try and use it right now. If you intend to use UE5, it's probably better just to stay on 4.26 or so for now and design your baser systems, and then spend some time fixing stuff after an engine upgrade.

dark edge
peak sentinel
#

Can we use OnReps with Push Model?

meager spade
#

ofc

#

its only to reduce server time in comparing props that need to be replicated

pearl moon
#

So I think I'm having an issue with unreal's game mode functionality. I tried to play in editor using a client / server setup, and started getting random crashes due to exception violations. They appear to be happening when trying to GetAuthGameMode() i'm guessing from the client instance that is running. Does this basically mean I need to change my code so that client's never try to call functions from Game Mode? Or are clients still supposed to be able to call Game Mode, just at the server's Game Mode and not their own?

#

(i.e. RPC's)

hollow eagle
#

Gamemodes only exist on the server.

pearl moon
#

ok thanks, yeah I figured that much out so far ๐Ÿ˜›

#

so, if I wanted to call a function on the server's game mode class, from a client, i'll have to do some kind of RPC it looks like

hollow eagle
#

Not on the gamemode. You can't call an RPC on an object that doesn't exist.

#

You also can't call an RPC on an object that you don't own (for clients)

pearl moon
#

ok, scratch that idea then

hollow eagle
#

The most common method for telling the server to do something is to use an RPC on the player controller or another actor that the player owns.

#

The server RPC can then do whatever it wants on the server.

pearl moon
#

ok cool, in my case it would be a pawn controlled by the player, so that should be simple enough

fading birch
#

@pearl moon it's also very good practice to check your pointers and don't expect them to be valid. In blueprint, you can do this with an IsValid call, in C++ you can do if(pointerhere) or if(IsValid(pointerhere)

pearl moon
#

So I believe what I can do, is do an RPC from the client's gameinstance, which should be executed on the server's gameinstance? The server game instance would then call whatever function needed from game mode, returning the values or info needed to the client.

thin stratus
#

GameInstances aren't replicated

#

@pearl moon

fading birch
#

@pearl moon use the player controller

#

It exists only on the owning client and the server.

thin stratus
#

Based on your previous conversations here you should read the pinned compendium first

#

Lots of this is basic knowledge you can read up on

fading birch
#

If you need something to go to all clients, use the player state or game state.

#

Also that

pearl moon
#

I, should check pins on channels more often then! Thanks lol...and yeah I haven't touched game or player state classes at all yet.

twin juniper
#

Is there a way to create Multiplayer Games for mobile?

#

Creating Games with Multiplayer Steam Subsystem is easyโ€ฆ.but for mobile, i dont have any idea

tranquil eagle
#

Hello! I'm trying to implement a jump action for a toy multiplayer RPG game. Basically there are several characters and every player can select them and make them do things (move to point, jump to point, use items, etc.). I made it possible to move using navmesh by making characters possessed by an AI Controller and when you click somewhere on navmesh, the Player Controller just tells the AI one to AAIController::MoveToLocation to the hit result.

But regarding the jump โ€“ do you think my idea for how to make it sounds okay-ish?

  1. Player Controller uses a Jump() method on the selected character which implements ICanJump interface (so that it doesn't depend on a particular actor class) and does a server RPC
  2. Server RPC calls a Multicast_Jump() RPC on the character to make everyone else do the jump also

The Jump would then just lerp the character along a spline to the destination point, but every client would do this on their own. I think this would work but I'm not sure how to make the player that initiated the jump ignore multicast RPC from server. I wanted to make him issue the jump immediately so that they don't have to wait for the server response, to make the jump feel immediate. Does this sound ok? Sorry if this is a noob question

#

On a side note, if you use AI Controller possessed characters like I do, I guess you don't have client movement prediction from CMC, right? Because they are unowned or server-owned actors? It's very hard to wrap my head around the best practices and there is a lot of stuff going on with replication :/

half jewel
#

pawns exist on the client, therfor the clients copy of the cmc will do local prediction just fine

vague fractal
#

How bad is it to call an Server RPC for tracing inside of the Tick method ?
Would only be called if the tracing is actually needed aka player is attacking with a melee weapon

meager fable
#

that depends on how many inputs and what kind it has, why can't you keep the trace on the client?

vague fractal
#

why can't you keep the trace on the client?
Maybe i'm just taking the "Never trust the client" too seriously here ๐Ÿ˜…

thin stratus
#

You can just tell the Server ONCE that you start attacking.

#

Server can then do the Trace on their own

#

And it's not bad-bad to call one, but you 100% can't make it reliable.

#

On Tick only ever unreliable RPCs

#

While the RPC to start attacking can be a reliable one, since that should only happen once (every other time)

vague fractal
#

Would this here look any right then ? (Where i only set ShouldMeleeTrace via an Server RPC)

void UCombatSystemComponent::TickComponent(float DeltaTime, ELevelTick TickType, FActorComponentTickFunction* ThisTickFunction)
{
  Super::TickComponent(DeltaTime, TickType, ThisTickFunction);
  if(ShouldMeleeTrace)
  {
    //Do the tracing
  }
}
#

Also not even sure if i should use some authority guards in this place ๐Ÿ˜“

half jewel
#

i see, you need tick so you can trace the arcs of the melee weapon when swinging

vague fractal
#

Yeah, that's my case

thin stratus
#

Is that an animation driven one?

#

You could maybe also just use an AnimNotifyState

#

And trigger the Animation

#

AnimNotifyStates have Tick

vague fractal
#

The animation is used to set ShouldMeleeTrace with NotifyBegin/NotifyEnd

half jewel
#

whatever is playing the animation will call the rpc to start tracing on the server

thin stratus
#

Or you just trigger an AnimMontage via the RPC

#

And have an AnimNotify State with the correct length in that montage

vague fractal
thin stratus
#

You should trigger the Animation with the RPC

#

Not other way round

vague fractal
# thin stratus AnimNotifyStates have Tick

My first version has used the AnimNotifyStates Tick to trace.
But i've used too much replicated logic in it since i've stored the hit enemies inside of it.
Would it be fine to have the whole tracing inside of this Tick where i only pass the hit enemies to the owning character which will handle the logic such as Was already hit, Deal damage to it

thin stratus
#

Otherwise, why even needing an RPC?

#

You can just get the owner of the mesh in the AnimNotifyState

vague fractal
thin stratus
#

Why so many RPCs

#

There should only be 1 RPC needed for this whole thing

#

And it's the keypress of the player

#

"I want to Attack"

#

That's all

#

The only other thing you might need is a Multicast to tell Simulated Clients to play the Montage as well

#

UE4 even keeps those synced

vague fractal
thin stratus
#

Yes

#

No offense but Multiplayer is really hard

vague fractal
#

Yeah, i feel that daily atm ๐Ÿ˜“

thin stratus
#

And I can fully understand that one can't find this out without getting some answers every now and then

#

But ultimately, I would start with this setup:

#

On Key Press, call "TryAttack"

#

In there, check if you can attack

#

If so, tell the Server via ServerTryAttack, but continue with your attack by playing the Montage locally.

#

The Server should just call TryAttack too then

#

Also playing the Montage, and maybe executing the Multicast

#

In the Multicast you need to make sure to filter Server and owning client (IsLocallyControlled in the Character would be true for that one), because they already played the montage.

#

And then play the Montage in that again

#

You can then have effects added to the AnimMontage, as well as Sounds.

#

And also your AnimNotifyState "AttackWindow" or so

#

In there you can get the Owner of the Mesh (I think you get the mesh as an input)

#

Cast it to your Character and tell your character to trace

#

Most likely grabbing a socket location + rotation for the actual trace location and direction at the given point in time

#

That will execute on everyone, so no need for further RPCs

#

Just limit the actual damage dealing to authority

#

Rest, like hit blood or sounds etc. can just be executed

vague fractal
#

Alright, i'll try to study your words and to apply it to my project.
Thanks for the help ๐Ÿ™

vague fractal
#

Oh sorry, you just said it in the next sentence

thin stratus
#

Yeah I usually do that and then filter specific logic in the TryAttack with HasAuthority or similar

#
// Server and Owning Client (who pressed the key)
void TryAttack()
{
  if (!CanAttack())
    return;

  if (HasAuthority())
  {
    MulticastOnAttack();
  }

  if (!HasAuthority() && IsLocallyControlled())
  {
    ServerTryAttack();
  }

  PlayMontage(...);
}

// Server Only
void ServerTryAttack()
{
  TryAttack();
}

// Everyone, but Owning Client (pressed key) and Server excluded
void MulticastOnAttack()
{
  if (HasAuthority() || IsLocallyControlled())
    return;

  PlayMontage(...);
}
#

Just keep in mind that:

  1. This is "one" way of doing it, doesn't need to be the best way for all and especially your situation.
  2. "HasAuthority()" does not mean that it's always the Server. In this scenario it does, but a locally Spawned Actor (that is not replicated) should have ROLE_Authority, which would not mean Server.
  3. The above is pseudo code. :P UE4++/C++ looks different
vague fractal
#

Alrighty, will also study that.

But there is another question related to you.
Are you available for private(paid) multiplayer tutoring ?

thin stratus
#

Yeah, let's talk via DM though

vague fractal
#

Alrighty

red salmon
#

If a session dies (server is closed or you lost connection to it) how do I reset the client back to the main menu? (Its my first time trying to make a multiplayer game so I am pretty stupid when it comes to all of this)

meager spade
#

It should automatically do that

#

the netdriver will shutdown and call into the game instance to move the player, though its best to override that kinda stuff and handle it yourself

red salmon
#

I dont understand how the game will make clients leave a session and move them to the menu

fading birch
#

@red salmon if the client loses connection to the server, the clientopens up the default starting map. You can override it to go to your main menu map if that's not your default starting map

red salmon
#

Ok then it must be a problem with how I had done the leave server button.

wise bridge
#

Hello everyone, I'm just trying to change the value of a variable. It's replicated, a character cast to the game state that the triggered action has happend, the game state set this boolean to false for a defined character. It works very well when the client is this defined character, but not when it's the server, the variable still have the same value. My event is replicated on the server, this is the value I get on my specific character

#

This is the trigger action :

#

And this is my game state action

#

173 is a child of the base character, which contain the function on the first screen

fading birch
#

@wise bridge is that bool replicated using OnRep?

#

err Rep Notify in bps

#

it could be that the client is printing it before they get the updated value by replication

wise bridge
#

No just replicated

#

It's working for the client

fading birch
#

where is your print?

wise bridge
#

Just not for the client-server

#

In 173 there

fading birch
#

it never becomes true for the client?

wise bridge
#

It's perfectly working

#

But for the client

#

If the client server is 173, it's not working, he got it on true all the time

fading birch
#

what do you mean by client server?

wise bridge
#

(and I want it to became false)

#

The host

fading birch
#

ah ok

wise bridge
#

I'm not in dedicated server

fading birch
#

put a breakpoint here:

#

and check what the and is outputting

#

it seems like the server is never getting the call

fading birch
#

humor me

wise bridge
#

I just put what I wanted in the screen, but the OK is printing

#

Give me a second

#

When the client is 173 :

vague fractal
#

I think i've got a terrible bug here, or just me being an idiot.
As shown in the video the client trace is correct, but the server tracing seems to have the enemy at a different location.

The weirdest part is that it's only happening when i play as client only, but when i play as server/client + another client it will trace just fine. Any ideas here ? ๐Ÿ˜ฐ

fading birch
#

put a breakpoint on it like i suggested

#

and see what the and is outputting

wise bridge
#

When the server is 173

#

(I remove the execute on server, my client couldn't reach the GS, but that change nothing)

fading birch
vague fractal
fading birch
#

what could be happening is that your gamestate is coming out null, so it's spitting garbage data as your actor location

wise bridge
#

Or do anything

fading birch
#

how are you getting the enemy location?

#

GetActorLocation?

wise bridge
fading birch
#

sorry not you

#

xD

wise bridge
#

Oh mb xD

fading birch
#

that was for @vague fractal

vague fractal
fading birch
#

@wise bridge put a breakpoint on the branch node, and see what the bool output of your and says.

wise bridge
fading birch
#

yes, that's fine

#

you just mouse over the red line

wise bridge
#

I almost never use it, can you explain more? I click on it? I'm using the button on top but I can't do anything with that

fading birch
#

nono

#

the red line going into condition

#

if you mouse over it, a tooltip will popup with it's value

#

alternatively, put a print string before it

wise bridge
fading birch
#

with the value of that

#

there's your answer

#

it's not getting triggered

wise bridge
#

??

#

That's normal bro

#

Because I'm not looking at it

fading birch
#

ohxD

#

i see

#

yeah use the print string then

wise bridge
#

xD

fading birch
#

i misunderstood your dilemna

#

@vague fractal any luck?

vague fractal
fading birch
#

you can print out the start/end locations

#

and just compare them

vague fractal
#

Alright

wise bridge
#

When the server look the client (I don't check if it's scp173 for now, so that's normal that the client is calling)

#

When the client is looking the server

#

Everything works all the way to the variable, I see it with my print

fading birch
#

what if they see each other?

wise bridge
#

Change nothing, there's only one 173

#

Can't be true

fading birch
#

oh ok

wise bridge
#

My point is that the value of can move is false on the GS, but not on the character when the client see the server

#

Beside this it works well

fading birch
#

173 is an actor correct?

#

why not just do this logic from 173

vague fractal
wise bridge
#

If 173 can say hey I can move that suck

fading birch
#

you're using listen servers

#

gl with that

wise bridge
#

I will change on dedicated

#

Worse on listen?

fading birch
#

yes

wise bridge
#

Might be

fading birch
#

clients are the authority with listen servers

#

so, if they're the host, it's easier to cheat

wise bridge
#

Well only the host

#

Yeah, but I'm not doing anymatchmaking

#

For now

#

Only server community based, so it's don't change a lot

#

If someone cheat, he will be alone

fading birch
#

so let me see if I understand correctly

#

You have an actor, which determines if the player can/can't move if it's in their view

#

correct?

wise bridge
#

Yes

fading birch
#

I would just have the actor manage all of this

wise bridge
#

Well, as I said I will remake this in the future if I do that so no

vague fractal
#

@fading birch Actually, now when i look closer at all those outputs, the server start/end location will never change.
And since i'm getting those locations based on my "AttackAnimation" i'm getting the feeling that it's cuz the server in the background wont play the animations

peak sentinel
#

Can we somehow replicate subsystems?

fading birch
#

can you give an example?

vague fractal
fading birch
#

@vague fractal if you're executing an action, that needs to be replicated to all clients, calling it from the server is a good spot to do your trace. You should be doing your trace on the server anyways

fading birch
#

you said you were only testing using Play as Client in PIE

vague fractal
fading birch
#

that launches a server in the background for you

#

ah

#

yeah, that doesn't play super nice in PIE

#

because both clients are listen servers

vague fractal
#

Really ?
I always see that only 1 client is the server while the other one is just a client

fading birch
#

you can open the map you're in by typing open MAPNAME?listen on one client

#

and then open 127.0.0.1 on your other client

#

oh, maybe they fixed that issue then

vague fractal
#

Like i mean this names here

fading birch
#

ah yeah

#

that's the same thing then

#

so, your play as client with both = dedicated server

#

play as listen server = listen server

#

on dedicated servers, it's headless and runs in the background and only executes logic of the game server side

#

listen servers do the same thing, but the hosting client is also the authority and a client at the same time

#

if you program your game correctly, you can swap them in and out interchangeably

vague fractal
#

I've totally no idea how to handle this situation then.
Cuz if i can't use my animation to trace i'm lost ๐Ÿ˜ฐ

fading birch
#

how are you kicking off the animation in the first place?

#

just execute that function on the server

#

and have it RPC to your client

#

think of the client as the cosmetic tool for your game

#

and your server as the actual logic host

vague fractal
fading birch
#

ah then you can just execute the trace then and there

#

you can us anim notifies too

#

to execute an event when a certain point is reached in your animation

#

to run code on your server too

#

ie your trace

vague fractal
tacit sage
#

Hi, I am struggling with actor's replication. I want to spawn actor on server and pass some data to use in BeginPlay on clients.

I have following code:


    //Server
    AMyActor* NewMyActor = GetWorld()->SpawnActorDeferred<AMyActor>( MyActorClass, MyActorTransform );
    NewMyActor->Data = "Some data";
    UGameplayStatics::FinishSpawningActor( NewMyActor, NewMyActor->GetTransform() );
    
    //Client+Server
    AMyActor::BeginPlay()
    {
        Super::BeginPlay();
        print(Data);
    }

On both clients and server actor is created and BeginPlay called, but only on Server I get proper string data, while on clients string is empty. Do you have any tips how can pass such data during initialization?
I have checked RPCs but that sucks as Actors may not be replicated on client and rpc call disappear :/

fading birch
#

where are you spawning the actor?

#

is the data replicated on the actor?

tacit sage
#

in game mode, Data is UPROPERTY( Replicated )

fading birch
#

just use your notify begin to kick the trace off on the server, have the server use it's locations as they're 100% correct and boom.

fading birch
#

pointless to replicate anything there

tacit sage
#

Yes I know, I am creating actors for whole world

#

and actors are replicated fine

fading birch
#

so you're spawning them in gamemode

#

and the data on your actor itself is replicated

tacit sage
#

actors yes, data not really

fading birch
#

???

#

it either is or isn't

#

there isn't a not really

wise bridge
tacit sage
#

data not, data is default, not changed to values which i set up during spawning

fading birch
#

you can, but having that behavior tied to the actor that is the cause of it makes more sense

fading birch
tacit sage
fading birch
#

you said you're not replicating your data at all

tacit sage
#

I want to, I gave property Replicated, and I want to pass data during actor's spawning, not after

fading birch
#

yes, that's fine

#

you can just mark it as UPROPERTY(Replicated)

tacit sage
#

I have already

fading birch
#

just set it up in the rep props in cpp

tacit sage
fading birch
#

Happens to all of us

tacit sage
#

ye... imo should be warning there, or even it should be done underhood

#

tbh c++ api of ue sucks - metaprograming on enums, enormous number of macros, nonconst functions which could be, lack of constructors, lack of constexpr

fading birch
vague fractal
tacit sage
fading birch
#

in your NotifyBegin cast to your character or w/e the actor that's executing the animation, call an RPC on the server to execute the trace. In the RPC get the location there.

fading birch
vague fractal
fading birch
#

no, you can just trace every time the notify is hit

tacit sage
#

if it is done by default :p thanks anyway. Sorry for aggression but that kind of things trigger so much...

fading birch
#

i understand

vague fractal
fading birch
#

then move your notify

#

if you trace multiple times during the animation, then you'll fire the logic multiple times, which i'm not sure you want