#multiplayer

1 messages · Page 318 of 1

gaunt kestrel
#

Setting up another RPC and having it run on the client makes it work, but the animations arent the same :/

worn nymph
wintry cove
#

Anyone an idea what can cause this?

#

Randomly I was unable to connect over steam anymore and I've thrown quite a bit of potential fixes at it but none seem to work. I assume that this warning is the reason as to why looking for sessions on internet on a steam-connected game stopped working

#

It only comes up in a packaged game, not if i launch it with a bat file

loud wolf
#

anyone who knows why i dont find any steam sessions using when i find sessions using steam online subsystem?

wintry cove
#

@loud wolf you launch the game via bat/packaged or doing in-engine? Anywho, if you launch the game does it say you're in steam game Spacewar(or your game)?

loud wolf
#

i tested it both in packaged game and play(standalone) game. yes, if i launch it i see the steam notif in the bottomright, and in my steam client it says im in Spacewar. I am able to host a session. But the other machine cannot find it.

I'm also testing if I can find my own session, but still no sessions are found.

wintry cove
#

Engine version?

#

Also can you check if you have the same warning as I have above? We might have the same issue

loud wolf
#

4.15. Sure i'll look at it

#

@wintry cove have you looked into your DefaultEngine.ini and see if DefaultPlatformService is set to Steam?

wintry cove
#

Yeah it is

#

It worked perfectly fine before

loud wolf
#

maybe try adding the game in steam client and launch it there?

wintry cove
#

Hmm can try

#

Okay

#

Found solution

loud wolf
#

it worked?

wintry cove
#

not that directly

loud wolf
#

can you share it here once you're done? 😃

wintry cove
#

do you have c++ in the project?

loud wolf
#

yes.

wintry cove
#

did you setup the build file?

loud wolf
#

yup.

chrome bay
#

The most obvious question is, is the IP address right?

#

And have you tried connecting to a LAN IP?

loud wolf
#

yes. enabling LAN works fine. i was able to host and find my sessions.

chrome bay
#

kk what about an ip in the same regionas you?

loud wolf
#

im testing on machines both in the same network

twin juniper
#

@loud wolf i have the same issue

#

It's the fact that Epic won't update the engine

#

(is what everyone tells me)

worn nymph
#

@chrome bay you made a chat system can you help me with my problem?

chrome bay
#

possibly

chrome bay
#

IIRC, Date Time Variables don't have any UPROPERTY values, so they won't replicate. let me check

#

Yeah, the Date Time won't send because interally, it's a uint64

#

so the only way to get around it is to send a uint64 and rebuild the datetime struct on the other end

#

But that requires C++

#

The solution in Blueprint is to send the extra string data, but that makes the chat messages more expensive

#

alternatively, you can break the date time first, send all the int32's accross the network and then re-make a DateTime struct on the other side

#

again, more expensive than C++

#

In my game I use local date and time anyway. Computer clocks aren't garaunteed to be the same and you'll get wierdness with people in different timezones

#

Also worth noting, PC ID won't make any sense to clients - they only have one player controller

#

You're better off sending the Player State, and getting rid of SenderName, MessageTime and PC ID. SenderName you can get from Player State, PC ID won't be useful, and DateTime can be constructed client-side

worn nymph
#

Oh so it is replication issue . What if I break the date time structure and use it to set the variables before I send it then it should work? My chat system us using interface so the player controller I'd gets stored into an array and this array gets added to the list of interface listeners it's not used for the message and the sender name I get from the playerstate already I just have a function setting the variable before I create the message structure

chrome bay
#

It will work doing it that way yeah, but it's expensive to do so

#

Sending strings over the network is not cheap

#

Something to be aware of in future

twin juniper
#

if anyone finds out how to get a dedicated server

#

to be public

#

please tell me

hushed garnet
#

@twin juniper dedicated server? public using steam?

hushed garnet
#

i have tried this @chrome bay and i still cant host a dedicated without the steam client being present! I have all the API .dlls ect, yet nothing i try works

chrome bay
#

Honestly no idea, unfortunately those who have solved it appear to not want to share the solution

twin juniper
#

Yea

hushed garnet
#

its a shame really as in general, the UE4 comminty is great !

twin juniper
#

idk

#

@chrome bay @hushed garnet yea my server only shows up on the LAN tab of the server list

#

it doesnt show up becuase i dont have it on right now but normally it would show up right there

chrome bay
#

Just checking, you are building a dedicated server binary too right? Not trying to run a game server etc?

#

I.e. using source version of engine?

twin juniper
#

yea

#

"Development Server"

hushed garnet
#

yeah, my server just chucks out the, could not initialize steam api

twin juniper
#

sooo

hushed garnet
#

......lol

twin juniper
#

is this pull request really the ONLY way to get steam to show my server on master server list?

hushed garnet
#

i just got the dedicated server working without the steam client open....but can still only run one instance of the server ! I really need to be able to host multi dedicated servers on one machine

jolly siren
#

no you don't need that to get steam dedicated server working ootb

twin juniper
#

yo

#

EREBEL u need to help me man

jolly siren
#

lol

#

it works out of the box

twin juniper
#

=..=

#

mine only shows up on LAN

#

lol

jolly siren
#

is your session lan only? are you using presence?

#

@hushed garnet you have to use a different port and queryport for multiple instances

hushed garnet
#

i changed the port using -PORT=6666 on the command line?

#

when i start the second server it spits back the cant initialize steam api - maybe because a steam server/client is already running

jolly siren
#

you need a different QueryPort too

#

port=7781?QueryPort=27016

#

for example^

#

you can run multiple servers on the same box. but you can't test your game on the same server you need to use a different box for connecting

hushed garnet
#

ok going to give this a quick try

jolly siren
#

and you need to port forward the new ports obviously

hushed garnet
#

yeah 2secs just trying it now

jolly siren
#

np

#

@twin juniper are you port forwarding the port and queryport?

#

@twin juniper are you port forwarding the port and queryport?

#

what does your FindSessions call look like?

twin juniper
#

uhm

#

it finds the session

#

on my local machine

jolly siren
#

make sure you pass false for both bIsLAN and bIsPresence for the FindSessions call

twin juniper
#

but i dont think its working on my friends pc (he lives literally right down the street)

jolly siren
#

you have to port forward and make sure you are passing the right stuff to FindSessions

twin juniper
#

well what happens

#

i have it loading into my server browser

#

and when u click the server browser

#

nothing happens

#

(The button calls JOinSession() with a session search result gathered from FIndSessions())

jolly siren
#

mhm and what does JoinSession return?

twin juniper
#

uh

#

nothing

#

I dont remmeber

#

:l

jolly siren
#

lol

twin juniper
#

but have u actually tried it

#

at another location

#

besides locally?

jolly siren
#

duh

twin juniper
#

like a library, school..etc

jolly siren
#

I host 5v5 games daily

#

with people across my state

twin juniper
#

completely vanilla UE4?

#

or are there modifications

jolly siren
#

yes

twin juniper
#

to the engine

jolly siren
#

no

#

ootb ue4

#

c++ implementation for sessions

#

I don't use bp for anything important

#

gl to you

twin juniper
#

lol

#

no i just want to know

#

u did do this

hushed garnet
#

you legend ! multiple servers on one machine all working 😛

twin juniper
#

with vanilla UE4 tho

jolly siren
#

yes

twin juniper
#

ok

hushed garnet
#

p.s im using bps to host the sessions and its working just fine

jolly siren
#

@hushed garnet awesome, congrats man

twin juniper
#

Heh

#

Ok

#

@jolly siren so what ports do i need opened?

#

also

#

when i JoinSession()

#

basically what happens

#

is it doesnt change the map

#

lol

#

like nothing happens

#

to should start => Main Menu => OnCLickServer() => Load "World" map

jolly siren
#

whatever you are using for port and queryport. by default it is 7777 and 27015

#

right, so debug the travel url

#

and see what it looks like

#

I know I have to call ClientTravel manually in OnJoinSessionComplete. But I'm not sure how the BP stuff works.

twin juniper
#

Oh

#

so maybe thats why lol

#

How do u have multiple servers on one server? @jolly siren

jolly siren
#

I just explained that to Parabellum-Ka0s

#

run multiple instances of the server exe

#

use different port and queryport for each

#

port forward new ports

#

done

twin juniper
#

oh

#

lol

#

thats what i thought

#

@jolly siren Important: If you have a server and a client behind the same router, the client cannot connect to the server through the server browser. In fact the server may not be visible in the server browser of the client. The client must connect to the server using the server's internal IP address.

#

do you know if this may be why i cant connect

#

lol

#

i have the server hosted on my laptop

#

(on a diff steam acc)

jolly siren
#

on a vm?

#

that statement isn't true

twin juniper
#

it was just on my laptop

#

lol

#

and then i have my desktop

#

as the client

#

it shows up in the server browser but when i click my server

#

nothing happens

jolly siren
#

that will work fine. I join my sessions all the time

twin juniper
#

lol

#

heh

#

idk :L

jolly siren
#

that's why you use c++

#

so you can see wtf is going on

#

is a ClientTravel being called?

#

that is what moves you to the new map

twin juniper
#

im not sure

#

im using the AdvancedSessionsPlugin

#

and i havent looked at all of the code he has yet

jolly siren
#

might want to do that lol

#

I don't use plugins

twin juniper
#

I didnt

#

but then im like

#

"Why reinvent the wheel"

jolly siren
#

look for the ClientTravel call in his join session stuff

#

debug it

#

and see what the string looks like

#

it should be steam.13094890238409283094

#

something like that

twin juniper
#

mhm

#

ill check

#

honestly tho

#

i use to want to always do everything from scratch

#

until i learned that... if ur spending more time devloping something which u could just use an already existant solution then whats the point

#

lol

#

like u arent devloping anything new

jolly siren
#

so you can figure out what's going wrong when things break lol

twin juniper
#

well i already know how it works tbh

jolly siren
#

why are you asking what's wrong then? 😛

twin juniper
#

im already using the default JoinSessions() btw

#

in bps

jolly siren
#

okay, the default c++ function doesn't call ClientTravel for you at least. But would have to dig into the bp code

twin juniper
#

hm

#

thats really lame

#

lol

#

Do you know about this?

jolly siren
#

what about it?

#

yeah I used that for a while

#

but it's only needed for security. I stopped using it because it's never going to be merged

twin juniper
#

does it actually do anything tho

#

do i need this to get the server to show up?

#

Like what does it exactly do ? @jolly siren

jolly siren
#

no you don't need it

#

i already told you that I'm using out of the box ue4

#

Like I said the PR is for security. It adds steam authentication. Which is a way to make sure the user who started your game owns the game.

twin juniper
#

lol ok

jolly siren
#

it's for anti-piracy

twin juniper
#

hmm

#

so like

#

where do u create the session

#

in your C++ file?

#

are u doing it in RegisterServer() => GameSession.cpp?

jolly siren
#

yes

twin juniper
#

IF so, could you show me yours

jolly siren
#

i already told you where to start and it's not there

#

confirm that clienttravel is being called

#

figure out what the url looks like

twin juniper
#

is this fine

#

lol

twin juniper
#

@jolly siren

jolly siren
#

sorry man, I told you where to start. I have to get to my work.

twin juniper
#

i mean its a yes or no answer but ok

twin juniper
#

Do you need a Steam App ID to host a dedi server (or can 480 work fine)

wise bridge
#

Evening one and all, Dunno if anyone could help me see where I am going wrong? I have this... apparently it should be working... I just need to know if this is correct I can start debugging elsewheres 😄

thin stratus
#

Well the Switch Has Authority isn't really needed on GameMode

#

The ServerRPC neither

#

It's a class that only exists on the Server anyway

#

I don't know about your PlayerStart array

#

is that actually filled when the first player conencts?

#

@wise bridge

jolly siren
#

@twin juniper 480 works fine

twin juniper
#

@jolly siren do you know what OVERFLOW 651 means?

#

gameplay tags overflow 651

jolly siren
#

sounds like your session settings are overflowing

twin juniper
#

i mean

#

im just setting it up default

#

lol

jolly siren
#

it's easy to debug

#

look at OnlineSessionAsyncServerSteam.cpp

#

it logs things with UE_LOG_ONLINE verbose

#

turn on logging

#

read to see why the warning is coming

high lotus
#

you might have glitches with 480 because there are so many other games testing on 480

jolly siren
#

highly doubt that

twin juniper
#

yea

#

@jolly siren im about to test this with my friend, i need 7777 port forwarded, anything else?

jolly siren
#

dude I already answered that

#

7777 and 27015

twin juniper
#

ok so

#

my friend has it showing up lol

loud wolf
#

hello, why do I see my server on LAN tab of Steam Server Browser even though i set bIsLANMatch to false?

loud wolf
#

Update: so I tested the sample shooter game of Epic, I was able to host, find, and join sessions using steam but I'm wondering why I cannot see it on Steam's Server browser

thin stratus
#

@loud wolf You mean that old Server Browser thing from back in the time where only Counter Strike and HL was a thing o nsteam?

#

I haven't even used that for the past 5 years or so

#

Isn't it enough to have the Sessions in your game's own ServerList?

slim holly
#

Playerstate persists until session ends, right?

#

ah, I see it doesn't unless you copy it manually

tranquil yoke
#

How do I replicate a decal?

#

Am I required to multicast or can I replicate it simply by running it on the server?

loud wolf
#

@thin stratus i just tested it to see if I can use it for testing.

#

I may have to start from scratch. I downloaded and tested the sample shooter game, and I can find my own sessions on steam. My mind's so cluttered right now so i'm gonna take a break 😐

tranquil yoke
#

Is anyone here good with replication? I want some advice on an approach

proud hemlock
#

Is it possible to replicate a variable on demand?

tranquil yoke
#

What do you mean?

#

You can do an RPC to update the variable so yes I guess?

wintry cove
#

Anyone remember where and how to open the replication analyzer?

#

I.e. the program the engine has that can see how much and how long it taks for actors and variables to replicate

#

I remember using it, but can'r recall where it's located

worn nymph
#

@wintry cove no sorry but if you do find it I'll be interested in where it is so I can look that sounds usefull . Thanks :-p

jolly siren
wintry cove
#

hanks!

#

Thanks, hanks!*

jolly siren
#

lol

#

no prob

worn nymph
#

The documentation is a little confusing so I need to build the engine editor as debug and then use the console commands to capture the profile ?

wintry cove
#

I don't recall needing to do that

jolly siren
#

you use the console command to capture the file

#

you open the file with

#

/Engine/Binaries/DotNET/NetworkProfiler.exe

slim holly
#

Question: can I force reconnect on all clients?

#

without changing map

jolly siren
#

what do you mean?

slim holly
#

I mean, trigger EventPostLogin on everyone

#

without map travel

jolly siren
#

without travelling at all? or just without changing maps?

#

and why? what are you trying to do?

slim holly
#

trigger new UI generation + variable reset

#

cuz otherwise I need to manually reset all the playerstates and controllers

jolly siren
#

that's the normal flow. to use PS::Reset and PC::PostSeamlessTravel

#

if you are using seamless travel

#

if you don't use seamless than you don't have to worry about persisting, but it has it's own issues

#

beyond that you could call PostLogin yourself if you don't want to use travel at all

slim holly
#

There seems to be reset function

#

calls reset on all actors except gamemode and controllers

#

so reset+manual recall on UI generation

jolly siren
#

makes sense

slim holly
#

restart game might work

#

Im getting debug messages from player logging in

#

but again, it's same as opening level

slim holly
#

blargh

#

also there seems to be a new experimental feature in project settings

#

called Download Maps on the fly

uncut pivot
#

Sick

jolly siren
#

RestartGame travels under the covers

#

either seamless or not depending on your settings

twin juniper
#

ended up getting my server to work

#

lol

#

it was not connecting because

#

GetOwningPlayerPawn() -> Get Controller -> Cast to PlayerController

#

doesnt work

#

on widgets

#

lol

#

so i just used GetPlayerController(0)

slim holly
#

because owning player is controller

twin juniper
#

heh

slim holly
#

or should be

#

you can leave it undefined when creating widget

#

yay, manual fake login works

hushed garnet
#

wonder if anyone can help? I am running a linux dedicated server, all working, but it doesnt seem to read a custom string in the DefaultGame.ini file like windows does? both .ini files are setup the same, just the linux doesnt pick it up?

twin juniper
#

Hey guys so when I load my dedicated server I have it spawning in a bunch of Actors that I serialized to json. However, in my PostLogin() function I have it setup so that the player will possess one of those actors based on their unqiue steam ID. However, this only seems to work when the player disconnects, and logged back into the server. If the server itself crashes (or I reboot it) the player doesn't possess the proper pawn.

tranquil yoke
#

@hushed garnet hey man, I have never used a dedicated server but this is just my random guess..
Can you check the file encoding of the .ini file? That may be causing problems.
It could also be the line endings.

#

@twin juniper Mind me asking why you're evne serialising it to JSON?

#

I have a wild question to everyone..
If the host shuts down his game, the connected clients will leave the game but they will still be locked to the session.
Is there any event like .. "EventOnSessionEnd" or smth?

jolly siren
#

do you not want to destroy the session?

twin juniper
#

@tranquil yoke because I plan to turn it into a MongoDB server later on

#

@jolly siren im not trying to destroy the server. I want to keep it running (Think about like ARK or Rust) you logout, then your character is replaced with a lootable character, then u logback in and that lootable actor is destroyed and replaced with your real character

jolly siren
#

I was talking to Simple

tranquil yoke
#

oh

#

hahah I also thought you were talking to Bdoom :d

twin juniper
#

use @tranquil yoke

jolly siren
#

mhm

tranquil yoke
#

Basically my problem is:
If the host leaves, the clients disconnects.
But the client cannot resume and join games as normally because they're already in a session.
Now if I were to press ESC I would destroy the session cause of a binding i have. But I want it to be done automatically

#

So basically I want to detect if the host leaves the game

hushed garnet
#

@tranquil yoke im not sure of the encoding, its always been standard

[ServerDetails]
Name=Blabla

Is all im adding to the defaultgame.ini

tranquil yoke
#

yeah but if the file is saved using a windows text encoding standard, it might give issues to Linux systems

hushed garnet
#

errr....not sure tbh, unreal build tool spits its out, but to be honest i have deleted on the linux machine and created a new one with nano and it still doesnt pick it up

twin juniper
#

@tranquil yoke its because you are using matchmaking

#

if u are using sessions like that

tranquil yoke
#

yeah that's why I was wondering if there's a solution to it

twin juniper
#

its like the server crashes

#

are u trying to do matchmaking?

#

or a dedicated server

#

or what

tranquil yoke
#

In my case I was just using create session and join session

#

sort of like matchmaking

#

anyways I have to get going home, already 9 pm 😛

#

I'll work on it on monday

#

thanks

twin juniper
#

ok

thorn merlin
#

theres get owning player - which can be casted

#

oh no i replied to a super old thing

rocky meadow
#

aight, im slowly going crazy

#

i have made PlayerController

#

which spawns actors which are handling camera positions

#

i want to run on dedicated servers therefore all my clients are listen

#

to position the camera i need the clients palyerController

#

is there any trick to get the current local playerController, i searched my ass of and nothing is working

brittle sinew
#

So you only need to get the PlayerController references locally?

#

I feel a bit dirty using it (and recommending it), but there's UGameplayStatics::GetPlayerController

#

Though if you have a way to plant a reference on the actors directly, I would do that

rocky meadow
#

i fergott to mention im within blueprints

#

i coould use a c++ script in the bp tho, but is there no clean way to get the current player controller??? I cant actually belive that somehow

brittle sinew
#

Well the method is the same in BP

#

It's the one that takes an index

#

I shy away from using it in MP as if you use it on the server you don't really always know whose PC you're getting, but on a client, it only has its own

rocky meadow
#

yeah so getPlayerController with the default 0 should work right?

brittle sinew
#

On clients, yes

rocky meadow
#

well it doesnt

brittle sinew
#

What issue are you running into?

rocky meadow
#

which basically means that player controller returns null

#

i just thought i can use self

#

because im actually within a player controller bp class

#

but aint working either

brittle sinew
#

The error mentions PlayerCharacter... do you have a reference to the pawn at hand?

#

And I'm not quite sure what you mean by the last couple lines...what isn't working about it?

rocky meadow
#

the input for the function is the the player controller from the first screenshot

#

since i'm within a PlayerController BP self should be the reference to the current player controller which is spawned right?

brittle sinew
#

AFAIK ID != index

#

Additionally, you have other characters on the client, so that risks getting other characters

#

If you're on the PC, why not just run Get pawn?

#

Rather than using these static iterator methods

rocky meadow
#

I'll try that

#

give me a sec

#

basically this is my problem

#

i created a camera actor assigned it to a variable and want to set it active for the current player controller

#

the pawn/actor is not helping me there

brittle sinew
#

I don't understand why you were getting the character then

rocky meadow
#

for some other stuff, i setup two main variables

#

PlayerController

#

PlayerCharacter

#

and i use them troughout my player controller bp

#

if i run it on the server everything works out fine

#

if i run it on a listen server, he cant get the controller nor the character, therefore not caluclation the positions correctly, and not setting the camera active

brittle sinew
#

If you're on the PC, no need to get it, just use self. If that's not working, the issue is something else

#

And you say it works on the server but not a listen server, what do you mean?

rocky meadow
#

if my machiene hosts a game (being the server)

#

self is the right player controller

#

if i connect as a client to the server (listen client) it aint working

brittle sinew
#

Client != listen server...in this situation your machine is the listen server

#

Where are you calling these methods originally, however? That's probably the core of the issue

rocky meadow
#

this is within my PC bp

brittle sinew
#

Why are you getting the controller within the controller? I don't understand hahahaha

#

Same with the character, just use get pawn

#

I'm still not clear on what the issue is however, all I'm hearing is it "aint working"

rocky meadow
#

haha ^^ i just use those two functions a setters

#

so i have to adjsut anything i do it at this player

#

rather than thruout the whole blueprint

#

within the get PlayerController i use self

#

and in my get character i get the pawn

#

and the problem is this

brittle sinew
#

I mean, I guess? I would just use self and the get pawn when you need it, so the variable has no chance of turning stale

rocky meadow
#

as server/host

#

as client

#

and this happens because the camera doesent get set to active for the clients player controller

brittle sinew
#

Okay, well do your best to debug why the call isn't working

#

If you get a specific error, great

#

If not, it's probably something in your flow

rocky meadow
#

i gues i have a very specific error

#

but i dont get why the PC is none/null if i use self

brittle sinew
#

Confused, your PC is called Player Controller but the error is CharacterController

#

Additionally, you're not using self, you're using a variable you set to self earlier in the graph

rocky meadow
#

my bp is called characterController but it has the playerController as parent

brittle sinew
#

Well you're throwing so much at me man, haha.

rocky meadow
#

yeah i know xD sorry for that

#

i had like the whole class layed out perfectly

#

and then i hit the dedicated server button

brittle sinew
#

Your issue is in set world location, look at the error

#

Not the set blend

rocky meadow
#

i have 30 of those errors

#

all saying i cannot acces from none

#

and it all referes back to the palyerController or its pawn

#

therfor the palyerController is none

#

well, i think i'll sleep over this

#

maybe it's a flow flaw or some misconecption of myself

#

anyways thx for the help, appriciated

fossil silo
#

hey guys, I am having a little trouble w/ some replication stuff...I am trying to store a variable on each clients PlayerState and show that variable above them in a widget their characters have.

somehow each of the players see their own info above the other characters.

#

This is the node that gets the text shown above each characters head

#

I am thinking GetowningPlayer is getting the actual playercontroller from the client you are on, even in each of his instances of other characters

#

ahh, maybe thats because each client only has his own playercontroller

twin juniper
#

Hey guys, if a dedicated server crashes, I am unable to reconnect when I restart the server I have to also reboot the client (even though it finds the session) is there a way to destroy my clients session?

fossil spoke
#

@fossil silo Clients only have their own PlayerController, this is why PlayerState exists, to be able to share information across clients. All Clients has access to all PlayerStates for all other Clients.

fossil silo
#

thanks @fossil spoke ! I noticed that shortly after I asked...just finished adjusting to store reference to playerstate instead of controller and its working 😃

thin stratus
#

@twin juniper You probably didn't destroy the client's session

twin juniper
#

@thin stratus do i have to do this on the server? or on the client?

#

who is destroying the session

hollow pond
#

Hey guys. If as a server I do an Apply Radial Damage to clients, do I process the damage in the client? Or do I ask the server to proccess my damage with an RPC inside the Event Radial Damage?

#

I'm thinking that if the code to proccess the damage was inside the client it could be tempered.

brittle sinew
#

I believe apply damage is a server-only function, so if you're calling it from the server (where you have to), it'll be processed on the server

#

From there, if your health is replicated, it'll make it down to the client

hollow pond
#

hm.. I see, so the event On Damage would only be played inside server-side?

#

Or do clients receive that event as well?

brittle sinew
#

When you say "apply damage to clients", I think you're misunderstanding the client-server system a little bit. Yes, the clients own the pawn, but there's a server version of the pawn, and the damage call occurs on that server version

#

The client version doesn't receive the event directly, no. But it can get the effects of it replicated down via replicated variables

hollow pond
#

Yeah, you're right. I knew I was getting something wrong

#

Thanks @brittle sinew

brittle sinew
#

👍

#

If you want to tell the client when something happens though, you can call a client RPC within that function, that would work fine

hollow pond
#

But in that case, the client could change how the function works and do a custom code when it receives the RPC, right?

brittle sinew
#

Well, you wouldn't let the client handle the damage itself.

#

It would mostly be just a notifier of something happening

hollow pond
#

yeah, that makes sense

brittle sinew
#

You could also use the OnRep of the health variable, either way

hollow pond
#

Logically I wouldn't want the server to handle everything, like notifications and stuff like that

#

So it does make sense to do something like that

#

Thanks again!

twin juniper
#

Is there a way to replicate InstancedStaticMeshComponent() when i remove an instance on the server, if a new player connects its not "Relavant" to the new player

twin juniper
#

I'm curious how deep does breplicates work on an actor? Does it also replicate its components?

twin juniper
#

Pretty sure i just discovered something some people may not know

#

you cannot Possess() a pawn that the client does not own

#

UE_LOG(LogPlayerController, Warning, TEXT("Trying to possess %s without network authority! Request will be ignored."), *GetNameSafe(PawnToPossess));

#

^ Someone else may need this in the future, so i posted it lol

thin stratus
#

Not true

#

The call comes up with you call Possess on the Client

#

It's a ServerOnly function

south flare
#

Ive got a question with streaming volumes on multiplayer

#

i am using client side level streaming

#

and the actors that are loaded in the first time on a client do not have their beginplays called

#

but the second time the same player steps into the streaming volume and streams the level from the network, it works fine

#

anyone seen this or know about this?

twin juniper
#

@thin stratus yea?

uncut pivot
#

when implementing a vaulting system its best to put it into char movement comp for prediction yes?

jolly berry
#

would this be the correct way to handle firing for a client->server?

#

cause obviously the client wants immediate feedback, but it also needs to replicate to the server

#

or is this gonna make it spawn twice?

thin stratus
#

If the homing actor is replicated then yes, it would spawn twice for the client

#

@jolly berry

sharp pagoda
#

@jolly berry It looks like you're trying to use a multicast here? For this case, I would recommend a structure like this: Input Fire -> Server Fire -> Client Fire (Multicast) Then in Client Fire (Multicast), you want to implement all of your shooting mechanics. Because of how RPCs work, this will work if called from the authority and remote.

thin stratus
#

He is telling the Server to Shoot, which spawns the homing missle

#

And at the same time he tells the Client the same to prevent lag

#

Which is a good idea, but not if the missle gets spawned replicated

#

So yeah, he should probably set the missle to NON replicated

#

Then have the Server call a Multicast

#

In that multicast he should filter the owning client

sharp pagoda
#

Exi, using what I said will cause initial fire lag on the client, but if you were shooting some projectile that can be predicted, you should have seemless prediction. Pros and cons to both.

thin stratus
#

Well, you should just spawn the missle non replicated

#

And let the server deal with the actual explosion dmg

#

while all clients spawn one through a multicast to simulate the rocket

#

Though filtering the owning client so he can spawn the rocket directly instead of waiting for the multicast

sharp pagoda
#

Exi why wouldn't you want the missle replicated?

thin stratus
#

Because then it gets spawned on all clients, which results in the owning client to have 2

#

Initial fire lag is shit

#

The rocket is only visual anyway

#

And technically should not behave differently when fed with the same velocity

#

If he doesn't care about initial fire lag, then he only needs the server RPC

#

and no Multicast or owning client call

native axle
#

@wary willow Spent this weekend trying to setup SpatialOS. Got the demo working with...a few issues, nothing too bad though. A few unexplained crashes, but the main problem is I tried to change something, compiled and everything broke. Probably need to re-setup the project which takes about an hour. Would suggest waiting before trying it out cause the documentation is not quite there yet. I might give it another shot next weekend and actually try to change something but we'll see.

full axle
#

Any idea how can I achieve proximity-based voice chat?

slim holly
#

I assume quantized vectors don't behave well when put into structure?

twin juniper
#

@native axle Thanks for the info, I played around with the unity integration but I saw that the unreal sdk was lacking some core features

junior tree
#

newbie question: how do you fake latency in play in editor?

thin stratus
#

There are some console commands you need to enter

#

on server and client iirc

#

A quick google should give them to you. Don't have them at hand either

junior tree
#

thanks a bunch!

#

I remember there is a rama video demonstrating replicated physics where he uses that console command

slim holly
#

net pktlag

#

and

#

net pktloss

#

( I did make notes during multiplayer stream )

junior tree
#

T H A N K S

jolly berry
#

how do I filter the owning client in blueprint?

#

for a multicast call

#

@thin stratus

#

cause what u said is exactly what I wanna do haha

thin stratus
#

Well what did you set the owner of the weapon to

#

As i assume that code snippet is in the weapon?

#

Usually the owner is the PlayerController

#

And that things as a function called "IsLocalPlayerController"

jolly berry
#

should I just pass in the player controller to the multicast and check to make sure im not calling fire again if it's on the same client?

#

by using that is local

junior tree
#

So, I have to ask this: I often prototype multiplayer games. I start with the thirdpersoncharacter from unreal and customize it according to the needs, since it already has basic movement functions with prediction.
I test my protos in LAN with 4+ computers connected to the same router.
Now what I often see is that the game behaves as if there is almost no prediction at all: the updates are not so frequent, the latency seems bad, the characters warp around and sometimes the net just crashes. This also happens if I just build the third person character right away.
I can reproduce the behavior in editor by adding packet loss on client (30%+). Packet loss from server does not seem to bother the client, and adding ping is fine aswell.
Still, the builds are barely playable because of this!
What am I doing wrong? Is this not a proper workflow to test multiplayer games? The router is decent but nothing special. Maybe it's all router's fault?

jolly berry
#

we did it!

slim holly
#

@junior tree look into update rates, they default at 100 which is very rare in mp games

junior tree
#

update rate you mean an engine setting or a character component settting...?

#

sorry for the question, just need to know where to find it

slim holly
#

iirc it's in the class defaults...maybe?

#

try tuning it down for character and controller

junior tree
#

thank you!

#

so actually lowering the update rate could help decrease the update time and thus grant more stable updates...?

#

I noticed I can go as low as 10 without losing much in smoothness. Thanks a bunch!

thin stratus
#

@jolly berry that's not a good solution

#

PlayerController only exists on server and owning client

#

Passing it via a multicast will result in accessed none on everyone else

#

Make sure to use "is valid" on it before accessing it

twin juniper
#

Anyone know why the number of players on the server doesnt work right?

#

always returns 0

jolly berry
#

@thin stratus Yeah I added the isValid node earlier today. Had that problem earlier.

jolly berry
#

oh i see

#

yeah I also made it so that if the controller isn't valid it just fires then during the multicast

ebon coral
#

is there an upper limit to the number of human players in an UE4 based game?

#

or is it not just based on resources available?

worn nymph
#

Anyone know best solution for doing a number of players online widget . Do I just set an integer equal to the length of the playerArray in the game state ? Or is there a better way thanks ?

void canopy
#

Hey Devs! I'm stuck in a situation. I have a question to be asked from Client 1 to Client 2. I've successfully coded message passing functionality in c++ in player controller c++. From here I'm passing id to the character and which is passing id to the 3d widget added in its heirarchy. I can see while debugging blueprint that its should update the value as I call the function. But its not actually changing the value. I'm clueless where to look for error. Any pointers please

#

After passing the id from client 1 pc to another client pc. I use blueprint to call UI Widget function which is in client 2 character bp.

#

While debugging I can see its calling the correct function. But the values aren't updating in the game

loud wolf
#

I'm fairly new to UE4 and I just realized that Game Mode is Server-only.

slim holly
#

question: when using advanced sessions plugin, does "Allow Join via Presence" mean all clients in session will automatically join the new session created?

gaunt kestrel
#

can I use appID 480 for testing steam multiplayer?

slim holly
#

yes 480 is Spacewars and dedicated for testing

#

by valve

gaunt kestrel
#

Okay cool

#

Do I need to log into a different steam account?

slim holly
#

only one steam account per connecting client

#

-> can't run the game twice using single steam account

gaunt kestrel
#

Ahh

#

any reason you know why I cant create an advanced session in a packaged game?

#

ie do I have to set it to shipping?

slim holly
#

not really without seeing the code

#

build settings should not affect

#

except 4.13 engine version had bug where it only included steam files to developer builds

gaunt kestrel
slim holly
#

note; run your session management in GameInstance

#

not in UI

#

because latent actions and stuff

gaunt kestrel
#

That shouldnt affect me creating a session tho?

#

it just DOESNT create a session

slim holly
#

meddling with map loads can cut any execution short

#

because it destroys everything except gameinstance

gaunt kestrel
#

Maybe its not succeeding on the create session

#

I make a cast to GameInstance

slim holly
#

print string is your friend

gaunt kestrel
#

xD

#

Thanks

slim holly
#

also I would recommend trying to get it to work locally first before going to steam

gaunt kestrel
#

well it was working locally

#

I could connect to my second player

slim holly
#

question is more of "did it really connect" or was it just PIE helping you out

gaunt kestrel
#

but when i packaged it I couldn't create the session, no matter if I hotkey it or just the UMG

slim holly
#

did you check the log?

#

yourpackagedgame.exe -log

#

it should show any issues

gaunt kestrel
#

I will check after i try out this packaged build

slim holly
#

it also occured to me, did you see the session in server browser?

gaunt kestrel
#

Oh you mean if I create the session and then look for myself?

#

I can see the session when I play in editor

#

let me check if I can see it in packaged

slim holly
#

how would you know the session creation failed if you didn't look for it?

gaunt kestrel
#

It should have opened up a new level with the listen option

#

and it didnt

#

?

slim holly
#

are you even seeing the steam overlay in your packaged game?

gaunt kestrel
#

Yeah I'm seeing the overlay for Spacewar right now

slim holly
#

then steam should be enabled

#

so that's not the issue

gaunt kestrel
#

okay so its not that

slim holly
#

check the log

#

that's your best guess

gaunt kestrel
#

[2017.04.10-08.31.00:957][984]LogBlueprintUserMessages: [FPSVive_PawnCharacter_C_0] CreatingSession [2017.04.10-08.31.00:957][984]LogNetVersion: GetLocalNetworkVersion: CL: 3299760, ProjectName: vrexppluginexample, ProjectVersion: 1.0.0.0, EngineNetworkVersion: 2, GameNetworkVersion: 0, NetworkChecksum: 928417868 [2017.04.10-08.31.10:988][743]LogOnline:Warning: Async task 'FOnlineAsyncTaskSteamCreateLobby bWasSuccessful: 0 LobbyId: 0 LobbyType: 2 Result: '3' k_EResultNoConnection (no connection)' failed in 10.030624 seconds [2017.04.10-08.31.10:990][743]LogBlueprintUserMessages: [FPSVive_PawnCharacter_C_0] failedToCreateSession

#

Dont know if thats helpful or nah

slim holly
#

try basic session then

gaunt kestrel
#

on it!

#

gotta wait for the package everytime tho

slim holly
#

that's why I said make sure it works locally first

gaunt kestrel
#

define locally because I may be mis understanding.

And create basic session gave me essentially the same logs

slim holly
#

PIE

#

or play in editor

gaunt kestrel
#

it 100% works PIE

#

doesnt matter if I create basic or create advanced

slim holly
#

ok then, Open 2 players in editor play, create session in one and join with the other

#

if that works, then the issue is with steam

gaunt kestrel
#

It must be steam then

#

do I need the Steam APIs installed?

#

wait no I already have the overlay, so that should e it right?

slim holly
#

yup

gaunt kestrel
#

Well I'll check back in tomorrow

#

hopefully Spacewars servers are just down

slim holly
#

no it's not down

gaunt kestrel
#

D:

#

What dp

#

do*

thin stratus
#

Is there a way to stop a Client from Moving if input is handled via "AddMovementInput"?

#

Some bool I can set on the Server? Otherwise I add my own Movement logic -.-

twin juniper
#

@thin stratus if u dont want the player to move... why dont u do it on the client? why does the server need to stop the movement of a client?

#

lol

thin stratus
#

You ever heard of cheating?

#

If that check happens on the client, he just changes the boolean or what ever to false

#

And can move again

#

Multiplayer is authorative

#

Might just set the MaxWalkSpeed to 0 -.-

twin juniper
#

yeah

#

idk ive always thought about it like this, what is the actual reality of the amount of hackers u will have

#

like, is ur game going to make them money

#

loll

#

(No offense)

thin stratus
#

Doesn't matter, I'm working for clients

twin juniper
#

ohh

thin stratus
#

And the amount of hackers is huge

#

e.g. GTA5 there is not a single lobby without one

#

Cause they don't do their checks on the server

twin juniper
#

yeah but those arent hackers, those are script kiddies

#

lol

thin stratus
#

They can spawn objects, teleport you, spawn money, etc

#

Well I called them cheater

#

To begin with

twin juniper
#

xD

#

No, you're right

rare cloud
#

it's too easy to cheat on GTA online

#

I tried some stuff few time ago

#

I have something like 2 billion on my bank account and no ban actually

#

that's pretty bad for an AAA game

thin stratus
#

Money is actually the thing they ban in waves

#

But yeah

#

I don't get why there even is a way to spawn such stuff

#

That is actively implemented

twin juniper
#

^

#

LOL

thin stratus
#

Client tells the Server to do stuff

#

they don't check it

#

they just ask for cheaters

rare cloud
#

I hope next GTA use SpatialOS 😛

thin stratus
#

Well I still don't know how to properly disable movement for my clients

#

-.-

twin juniper
#

hey so

#

in your AddMovementInput

#

couldnt you just create a replicated boolean

#

and say

#

if(bCanMove) { AddMovementInput(); }

#

like that? lol

thin stratus
#

AddMovementInput happens on the client

twin juniper
#

oh

#

RIP

#

i do know that

#

MaxWalkSpeed on Charmovementcomponent

#

is replicated

#

because just yesterday i was messing with it

#

and it wouldnt let me change it without doing a server RPC

thin stratus
#

It's not afaik

#
/** The maximum ground speed when walking. Also determines maximum lateral speed when falling. */
    UPROPERTY(Category="Character Movement: Walking", EditAnywhere, BlueprintReadWrite, meta=(ClampMin="0", UIMin="0"))
    float MaxWalkSpeed;
twin juniper
#

idk why it wouldnt make a change unless i did that then

#

lol

#

likke when i set it to 5,000 is didnt do shit unless it was inside of a server rpc

#

:l

thin stratus
#

WEll yeah

#

cause the Client and the Server start fighting about the speed

#

You try to move fast as a client

#

But the Server is stopping you by updating the location

twin juniper
#

lol

thin stratus
#

If you move 5000 units on the client and the server only moves you 600

#

You get the Server location

#

obviously

twin juniper
#

yah

#

but

#

why not set it to 0

#

on yours?

#

and do it that way

thin stratus
#

That's one way, but I would still like to have it kill the input

twin juniper
#

yea

#

set movement speed before addmovement is called? then check movement if it is 0 or not?

#

lol

thin stratus
#

The whole net stuff happens in the C++ charactermovement component

#

I have no entrance point

#

It calls AddMovementInput on client and handles the rest

#

Alright got it

#

Seems like "Disable Movement" stops it also on the Client

#

I searched for "SetMovementEnabled", hence I didn't find the function

#

gg

twin juniper
#

oh

twin juniper
#

OnRep functions are called on the local client right?

#

So I cant do OnRep=OnPlayerDied, remove my player from an array of players

#

if that array is replicated

#

because it wont be a server function

full axle
#

Is there a way to expose the voice chat input from the player to blueprints?

slim holly
#

@thin stratus why not transfer movement input to server side directly, then do the check?

#

it's not gonna cause any more latency anyway

worn nymph
#

is it possible to cast to the game mode >? i ve tried everything . im trying to access the function get num of players but everything i try fails the cast?

brittle sinew
#

Yes, you can, and definitely might need to

#

Are you trying to access it on the client? It only exists on the server

worn nymph
#

@brittle sinew well thats the thin how do i access it . i am trying to get the value from the gamemode and then send it to a variable in the gamestate which is bound to my widget , this all worked but for testing i was doing it on tick event in gamemmode which i dont want instead i want to be able to call the custom event to only run when i want it to

twin juniper
#

Has anyone noticed that this funciton is broken?

int32 UFindSessionsCallbackProxy::GetCurrentPlayers(const FBlueprintSessionResult& Result)
{
    return Result.OnlineResult.Session.SessionSettings.NumPublicConnections - Result.OnlineResult.Session.NumOpenPublicConnections;
}
brittle sinew
#

You would want to do all the updating on the server, and just access the variable from the GameState on the client

twin juniper
#

inside of the engine

worn nymph
#

which works in the game state instead but just seems silly having to do it yourself when they have a function there already

#

the pproblem is how to call the event on the gamemode when i cant cast to it

brittle sinew
#

From the client, you can't

#

So you'll have to find a way to get the info at the server level and pass it to the client

worn nymph
#

so i either have to have the event on tick or just not use it at all

#

so may as well just use the player array in the gamstate

brittle sinew
#

Well, if you're updating it in the GM, you could just update it when you change it rather than tick

#

But yeah, if the default player array works that's fine

worn nymph
#

oh wait

#

can i repnotify itself

#

then just get it to change the variable in gamestate

brittle sinew
#

I don't think that works only on the server

worn nymph
#

cant any way it has to have an in execution

#

just seems stupid why have a really usefull function that you cant even call from anywhere

brittle sinew
#

Well, that's your choice by putting it on the GameMode

worn nymph
#

i didnt put it there its a built in function of the gamemode

brittle sinew
#

Oh, I thought it was a custom one

worn nymph
#

nope

#

if i do this inside gamemode it works perfectly but just didnt want to call it on tick

#

lol forgot to hook up the values but you get what i mean

brittle sinew
#

You could try to just change it on login/logout

worn nymph
#

wonder if i can use a blueprint interface

#

but then its more effort

#

may as welljust use the gamestate player array

#

lol

twin juniper
#

so yeah tho

#

anyone know that this is broken and how to fix it? ```cpp
int32 UFindSessionsCallbackProxy::GetCurrentPlayers(const FBlueprintSessionResult& Result)
{
return Result.OnlineResult.Session.SessionSettings.NumPublicConnections - Result.OnlineResult.Session.NumOpenPublicConnections;
}

#

its inside of the engine steam subsystem

#

I was thinking i could manually edit the session information

#

and add a new connection via PostLogin() and remove one on Logout()

#

but how would i access the session info

#

lol

worn nymph
#

@brittle sinew omg forgot about login and logout yeah that works lol .

#

thanks

twin juniper
#

lol.

gaunt kestrel
#

@slim holly It's working today xD

#

I don't know why

wise bridge
#

Anyone around who might be able to help before I headdesk myself into an early grave? xD

gaunt kestrel
#

xD

#

hi

#

I can try

wise bridge
#

In short: Host a session, host joins level fine, client can join the session, spawns in at one of the locations correctly, doesnt possess the spawned pawn, spawned pawn exsists on the server and is being registered as auth through this snippet of janky ass BP 😛 For reference, this picture is inside my pawn BP

#

@gaunt kestrel You would be a god amoung men in my eyes xD

gaunt kestrel
#

You probable want to handle possession within the Controller for your pawn. That way you don't net to get the player character index.

#

Can you show me what youre using to possess the pawn?

wise bridge
#

Sure 😃

#

So thats fired off from the game mode BP like so..

gaunt kestrel
#

Make sure your player reference is Replicated.

wise bridge
#

okay

gaunt kestrel
#

In your pawn there is an event called "On Possession" which you could use to help debug

#

Can I see where you're setting your player reference?

wise bridge
#

Im not seeing the on possession event in my pawn 😮

gaunt kestrel
#

Let me open up my editor so I can help you

wise bridge
#

Cheers dude 😃

#

Oh wait is the on possession event called "event possessed"? XD If so I found it lol 😛

thin stratus
#

Whyyyyyyyyyy the delay

#

slaps

wise bridge
#

lmfao Eek

thin stratus
#

Also why the ServerRPC

#

You are on the Server anyway

wise bridge
#

Because the internet told me so 😄

thin stratus
#

slaps²

#

GameMode exists only on the Server

#

If you access a class while working in it, e.g. the passed PlayerController, you will still remain on the server side of things

twin juniper
#

^

thin stratus
#

And please never ever use a delay in multiplayer related things

#

It has a reason why something wasn't ready yet

#

And if that was caused by replication lag, then someone with higher ping will still fail the delay

wise bridge
#

Okay 😃

gaunt kestrel
wise bridge
#

I shall adjust and see what she does! 😄

#

So possess doesnt need a target nessecerily?

#

God damn I suck at spelling xD

worn nymph
#

@thin stratus And please never ever use a delay in multiplayer related things
It has a reason why something wasn't ready yet
And if that was caused by replication lag, then someone with higher ping will still fail the delay i agree in his use case but in some cases you have to use a delay otherwise things dont work for example here i am sending a welcome message to the clients http://image.prntscr.com/image/a2f69491edaa4dbaa395699422123f44.png and it wont work at all without the delay

thin stratus
#

Not really. Then you just did it wrong

#

I don't have a single delay in my network code

worn nymph
#

how is that code wrong

#

when widget is constructed do soomething

#

but never works unless a delay

#

i was stuck debugging it for hours

#

only way that code executes is with delay

#

i think the reason in my case i need delay is because

wise bridge
#

@gaunt kestrel Testing now 😛

worn nymph
#

the name variable it is trying to acess is loaded in from the database, so without the delay it means sometimes the event fires and the variable doesnt exist because it hasnt been loaded yet

wise bridge
#

@thin stratus I got rid of the delays.... Sorry boss xD

twin juniper
#

@thin stratus I mean whats wrong with the delays though

#

like...

#

all its going to do is stop them

#

from moving forward right?

#

its basically like

#

Thread.Sleep(long miliseconds)

brittle sinew
#

@worn nymph the general opinion is that you should use event callbacks rather than just delaying a flat amount

thin stratus
#

Let's say you try to access a pointer, like the PlayerState directly

#

Now you notice "wait, the PlayerState isn't spawned yet. Let's add a delay of 2 seconds"

#

Now it solves the issue

#

but now someone has a small lag that takes 3 seconds

twin juniper
#

yea

worn nymph
#

oh i see so when data is loaded call the custom event send message rather than using on event construct

twin juniper
#

i understand that

#

but...

worn nymph
#

that makes sense

twin juniper
#

its not really game changing

#

lol

#

no pun intended

thin stratus
#

So, not sending the Player the Data at the start of the game is not gamechanging?

gaunt kestrel
#

Omg yes! Steam multiplayer works with appID 480!!

thin stratus
#

"Hey, sadly you can't have your name displayed, cause sending the data got caught by a lag and I used a too small delay."

twin juniper
#

wont it be sent

#

just delayed?

#

lol

#

like... make the delay 1 second every time

thin stratus
#

No, cause the call happens after 2 seconds and the PlayerState is still null

twin juniper
#

if u have 900 milisecond delay

#

i dont even want u on my game

#

im sorry

#

like i dont play games if i get any more than 90 ping

thin stratus
#

:P Well then work with delays

twin juniper
#

lol

#

i understand what ur getting at tho

worn nymph
#

there you go fixed it lol thanks now i just call this function once i know data is loaded :-p

gaunt kestrel
#

@wise bridge hows it looking?

brittle sinew
#

@worn nymph 😄

twin juniper
#

basically if u set the delay to 2 seconds for example, but their ping is 3,000 (for whatever ungodly reason) the data would be initialized to null because the 2 second delay didnt catch someone who would have 3,000 ping it would only stop a 2,000 ping delay

#

thats what ur saying right?

#

lol

#

I mean idk who is going to have 1,000 ping tho

#

1,000 milisecond delay

#

like if ur ping is that high why are u even playing lol

wise bridge
#

@gaunt kestrel I took the delays out and it causes my Vive bool to not get set in time so just moved the check into off of begin play into the spawn event so about to test again 😛

brittle sinew
#

Not only will it save time in the 99% (arbitrary) of cases where it loads faster than 0.5s, but it prevents failure in the case it takes longer @worn nymph

rocky meadow
#

i worked out a system for myself which basically maces mp straight forward, and im looking for some suggestions

#

does someone mind if i post some blueprints ? 😄

twin juniper
#

Like when I play on a server located in Japan (im east coast USA) I only get like 300 ping. So that's 300 milisecond delay

#

Lol

#

idk how u could get anymore of a 1 second delay

wise bridge
#

be my friend who has 2mb broadband and downloads peak at 150kb/s

#

😛

brittle sinew
#

Even if it doesn't seem probable, it shouldn't be designed in a way that would break if it does occur

wise bridge
#

If hes lucky lol

twin juniper
#

I mean ping isn't based on download speed

worn nymph
#

@brittle sinew @thin stratus yeah it makes sense now my brain was just being dumb all that time i spent trying to figure it out and the answer was simple. for some reason i was thinking the error was caused by the widget taking a certain amount of time to run through construction process and somehow event was firing bfore it had finised

twin juniper
#

lol

#

Ping is based on latency

#

its based on how long it takes for the data to travel

#

not the speed of the data

#

hard to explain lol

#

latency != download speed

#

u could have a 10 ms response time and still have 10 mbps download speed

#

lol

brittle sinew
#

Once you get past a certain threshold, yes

#

But at really low speeds, your ping will be affected

twin juniper
#

ping is location based

brittle sinew
#

Since the packets take a non-negligible time to be uploaded

twin juniper
#

lol

#

like the closer u are to the server

#

the better ur ping

#

which is why i get like 1 ms in my house

#

and my friend down the street gets like 10ms

brittle sinew
#

Yes, but packets have size

#

You can't ignore that

twin juniper
#

mhm

brittle sinew
#

At decent speeds, the upload time is negligible versus the speed it takes to travel

#

At lower speeds, it's not

twin juniper
#

yeah

wise bridge
#

@gaunt kestrel Still doing the same thing 😮

rocky meadow
wise bridge
#

I'm going to try not specifying a target on the possess xD

gaunt kestrel
#

you can only do that if you're handling the possession within your player controller

wise bridge
#

I am 😃 its in a custom player controller

#

why im passing the reference in the first place..... is questionable! 😛

gaunt kestrel
#

@wise bridge I had this weird bug where my second player wasnt possessing the pawn.

All I did to fix it is migrate over my pawns to a new project

#

seemed like a engine bug

wise bridge
#

Hmm

#

I'm not sold on it being that... However try all possibilities! 😛

rocky meadow
#

quick questin, the default character replication resets the rotation of the skeletal mesh everytime i apply some movement input

#

does anyone know a way around that

#

?

wise bridge
#

@gaunt kestrel Is it possible that I am creating the session incorrectly?

#

I'm doing it out of my custom player controller BP

gaunt kestrel
#

Can you join the session and see both players?

#

yeah you want to make your session in your GameInstance typicallly

#

at least I think right @thin stratus

wise bridge
#

You can... I believe... on the server, the pawn appears, the client can see the servers HMD moving around

#

I am using the get player controller for the Create session and Find session nodes I also just realised I was using the player reference you said for me to replicate as the player controller for the Join Session node

#

that could be self surely as its in the player controller BP?

twin juniper
#

is there a BPs node for detecting server crashes?

gaunt kestrel
#

You should have it cast to GameInstance (or a custom game instance) and have the session creation and find and join nodes in there

#

thats just whats typically done

#

but it doesnt sound like what your problem is

wise bridge
#

Indeed 😄

gaunt kestrel
#

have you tried testing it without VR? Just Play In Editor

wise bridge
#

I have not no, I package it out (only takes 2 mins) and just test it for realsies xD

gaunt kestrel
#

PIE is good for testing this kind of stuff cause you can see what is flowing where

wise bridge
#

Interestingly, when the client joins, I can see the controller and HMD on the floor and when I shake the HMD around the headset moves in a really wierd way lol

#

server cant see it moving

#

client can see the server moving headset just fine

gaunt kestrel
#

Just have it so if they don't have a headset it spawns a non VR pawn. Then you just play (nonVR) preview

thin stratus
#

Well you can create the session everywhere

#

I usually end up using GameInstance in BPs

wise bridge
#

Is that for debugging purposes? I dont have a use for nonVR pawns as not planning on using nonVR 😃

thin stratus
#

and GameSession class in C++

#

Replication for VR is not properly working or needs some random things

#

Like I was able to control the hands of another player

#

why ever

#

Never really tried more after that

wise bridge
#

The work around to that is using the get position and ori of tracked devices (something to that end atleast)

#

rather than using the motion controller component

#

as thats not working for VR MP at all (and still is not to my knowledge)

#

So just updating the mesh componnent that way... rather than it being a child of motion controller 😃

rocky meadow
#

okay 😄 i searched every checkbox, cant find where the controller resets the mesh position

#

could it be that the default replication has a higher priority than my own implementation?

#

if so, that sucks

wise bridge
#

Im actually beginning to think its a problem with something in my Pawn @gaunt kestrel

twin juniper
#

Seriously tho

#

if GetCurrentPlayers()

#

always returns 0

#

does that mean u can have unlimited players

#

because its broken

#

lul

#

if my max players is set to 10

#

u could go to like 100000

wise bridge
#

I was able to rotate using the snap turning we have on the character... so its taking input from my controller.

#

It wouldnt be because the character im spawning in, is a child BP?