#multiplayer

1 messages ยท Page 302 of 1

thin stratus
#

@thorn merlin

#

@chrome bay Yo, does UE4 include the GooglePlay Multiplayer Session stuff?

thorn merlin
#

yea, you'd have to make your own nosql data base and query it etc i assume, im looking into that next year

thin stratus
#

Found a thread in which james said that hosting etc works with just the session nodes

thorn merlin
#

i think as of 4.13 android can do LAN session stuff but theres no google play integration

#

if there is id love to no, I'm currently making my own custom nat punch system right now

thin stratus
#

GooglePlay has a MasterServer for their users, or?

thorn merlin
#

i dont think so

thin stratus
#

I mean, is that a thing or not. Because if yes, then it only needs to be connected to the UE4 subsystem

#

hm

thorn merlin
#

i think most unity games use raknet or whatever

#

hence why i suggest someone makes a hosted service, could make a lot of biz off us ue4 devs

thin stratus
#

Stores participant and room state information on the Google Play games services servers during the lifecycle of the real-time multiplayer game.

#

That sounds like they have a master server for your rooms

thorn merlin
#

could you link me please?

thin stratus
#

Well it's the link that Tyler shared iirc

thorn merlin
#

reimplementing the wheel as usual

thin stratus
#

Their sessions are called "Rooms" as far as i understood

#

but have no time to further dig into it

thorn merlin
#

I'm already at the finish line with my custom solution, if anyone gets this google play way figured out I'd love to know how they do it

wary willow
#

You can use GameSparks @vivid siren

#

And use their GooglePlay authentication

#

Which also provide achievements and such

thorn merlin
#

oooh game sparks

#

has anyone gotten this going yet?

#

"GameSparks is essentially the authority in the equation. You have to communicate with it directly to make things happen. The Unreal replication and session features do not work with Unreal."

#

that sounds really bad

modern fable
#

dahell

wary willow
#

I am using GameSparks in one of my projects and I find it fantastic

#

It does what you need of it

#

And much much more

thorn merlin
#

@wary willow is that true you can't use unreal replication with it?

wary willow
#

@thorn merlin you should try something before following gossip

#

๐Ÿ˜‰

#

To answer your question a bit more directly, it does not replace OOS'

#

As we use it on Steam

vivid siren
#

So, I can successfully host a listen server on my pc and have players who downloaded the app via Google Play Store connect to the listen server and play with each other

#

but the thing is, I need a pc to host this listen server, and then that's only 1 session that the android clients may join

#

What would you guys say is the easiest way to scale this up?

loud sage
#

Is it OK to replicate my gamemode variables to my gamestate? I want to be able to display stuff like max players etc to the user. But ofc the gamemode is server-only ๐Ÿ˜„

regal relic
#

Yes.

loud sage
#

ty ๐Ÿ˜„

thin stratus
#

@loud sage Yeah, you can, on beginplay of the GameState, query all the data from the GameMode (Switch Has Authority !)

#

@vivid siren Hm, the ideal way would be not having the need of a PC to host a session

#

Are you doing that on LAN?

#

And what are you using now?

#

You should look into a way where your ListenServer on the Phone can register his Server at some master server

#

and where the clients can request the server list from that

loud sage
#

Wait you dont even need an execute on server event in the gamestate? ๐Ÿ˜ฎ

regal relic
#

@vivid siren If your in need of an easy master server plugin for ue4, This one has worked perfectly for my needs.

#
vivid siren
#

@thin stratus I have it working online, I used port forwarding on my home pc and then my friends could connect with "open [my ip]" and then I would do the same to have both of our androids connected

#

the listen server is on my pc while the androids are all clients

#

i have no clue how to get a server list though, theres no online subsystem that i know of for me to use

#

or in other words, i just have no clue what i'm doing, lmao

#

@regal relic how does this work? if i implement this, and someone with my app searches for a game, it will give them a list of everyone who is hosting?

#

it would make my day if you said "anyone who hosts a listen server has their IP automatically entered into the master server's list for all other clients to choose from"

#

but i'm assuming it's going to be more complicated than that ๐Ÿ˜ฆ i cant look into right now, it's 5:26 am so i have to head to bed

#

i'll check it out in the morning though, thanks!

thorn merlin
#

@wary willow I don't have time to grok every technology marketed to me, I relay on the opinion of people I respect, hence I validated that claim with you - I don't understand the "OOS" statement, but it sounds like it doesn't provide the same level of service steam does (I am interested in multiplayer browser AND NAT)

#

@vivid siren my solution i sent you basically handles your next step, it uses http so the server broadcasts to a web application, which stores its ip on a list to offer to clients when they want a server browser - then they essentially use the "open ip" command to join

thin stratus
#

Well the Plugin is a Master Server, yeah

#

It simply connects to the Server and checks if the GameID etc matches afaik

#

And for the Clients, it simply retrieves the IPs etc

#

No idea how solid that plugin is

#

if there are things in it that could be done better

#

but it's a solid start for android i guess

#

Would need you to host that server somethere though

#

But then again, no costs for subsystems like Steam

thorn merlin
#

i think I'll play around with it, it does seem worth checking out

subtle wolf
#

Hello everyone, i'm new to Unreal Engine 4

#

I want to learn how to use UE4 with WebSocket. Is here any solutions?

thorn merlin
#

@subtle wolf you mean send messages to a http server with unreal engine? there are multiple ways you can do this

#

@subtle wolf there are blueprint only plugins you can buy on the marketplace, or if you are comfortable with c++ you can just use the fhttp interface to send messages yourself

subtle wolf
#

I mean build connection with WebSocket server

thorn merlin
#

I am trying to make a nat punch through system for unreal, do I need to send punch messages from both tcp AND udp? I'm using the examples you can find on forums and answer hub and it doesnt quite seem to be working - I have all the master server bits done, I just can't seem to open the connection for the join command

thin stratus
#

You can probably use any C++ WebSocket tutorial

#

And apply that to UE4

subtle wolf
#

Okay... i had an plan, make client connect to websocket server, and make one client to be master client(calc physic for every NPC)

thin stratus
#

Exposing that to Blueprints is a different story but that's just utility

subtle wolf
#

Buy i don't know how to get start

#

I can simply use NodeJS to build an WebSocket server in minutes.

thin stratus
#

Hm, you want to replace the default network system of UE4?

subtle wolf
#

I use C++ on this.

thin stratus
#

Well, nice, but that doesn't answer my question :D

#

So normally, you have a Server (Dedicated or Listen Server) and he has the authority

#

So he defines what the physics do

#

and replicates that to the clients

subtle wolf
#

yes

#

I think replace default network&mutilplayer system is hard

thin stratus
#

Yeah, also not really necesarry

#

depending on what you want to achieve with it

#

So what is your plan with the socket system?

#

I don't see yet how this would make any difference to the authority version

subtle wolf
#

Use NodeJS with available websocket package could up-speed server development

#

and this server use for persist data

#

but here get an question

#

How to implement NPC movement & AI

#

WebSocket server could only do some simple validate

thin stratus
#

Uff, that goes beyond my knowledge. I stick to what I have in most of the times :D

subtle wolf
#

Okay...

thorn merlin
#

reasking my question - has anyone used sockets in unreal engine to punch through NAT? could use some help, my master server is sending the information to my clients, just not sure if im doing the correct work on my client to punch to the other client

thorn merlin
#

fyi will pay if someone can help me with this NAT punch solution I'm trying to build on android - I need this working ASAP - please contact me directly if need be

thin stratus
#

If I would know how to properly do this, I would have told you already hehe

thorn merlin
#

โค thanks man

thorn merlin
#

@subtle wolf I know little about it, but I think the html5 version of unreal uses websocket, and I've just stumbled across UWebSocketConnection in my own adventures in unreal source code

subtle wolf
#

So, can it use in native client(Like mac or win)?

#

Unreal Engine 4 Networking over Websockets Plugin

Provides websocket transport layer for unreal engine 4.
Uses libwebsockets for the server side and client side for non HTML5 clients.
HTML5 clients use emscripten's sockets abstraction.

#

Ok i got it, thx @thorn merlin

thorn merlin
#

wish i could be of more help

jolly siren
#

I have a TimeRemaining variable which is the amount of time left in the match. I want to play audio on the client when there is 30 seconds left. Would you guys use an OnRep for that or just check to see the value of TimeRemaining? in tick or something I'm not sure how much overhead OnRep has.

#

I guess it's a balance between server and client cpu load

cloud ledge
#

Why not just do a replicated function/RPC and call it for all clients once

#

E.g. move all of the logic to server

jolly siren
#

Yeah that's an option. I normally keep as much load of the network as possible tho

humble birch
#

Hey guys, someone as an idea of how I could make the authentification work for Azure with Unreal, I can make call to Azure, but I'm not able to make the auth (with C++) part

brittle sinew
#

Honestly I would put that on just the client personally, you can set a timer for it when the round starts, and it eliminates the need for a reliable RPC to guarantee it occurring

#

Assuming you have a static-type timer where you're not adding time in the middle of it ๐Ÿ˜›

thorn merlin
#

Is it possible to open bound tcp sockets in general with unreal? or even a bound tcp socket on one thats already in use? port 7777?

vivid siren
#

@regal relic Hey you here?

#

I was wondering..
If a player on pc wants to host, they open a map as a listen server and others can connect, but the host HAS to have port 7777 forwarded for others to join as clients

#

Does this master server plugin handle that? so if an android user wants to host a game, they dont need to worry about ports or anything, right?

regal relic
#

@vivid siren When the server/dedicated server initializes its connection with the master server, The ip address, and port number are given to the master server by the server/dedicated server.

#

Personnally i put all the all master server logic in my GameInstance, But i dont do a listed server style setup, My servers are all dedicated. But it should'nt be a problem to do listen servers as well.

#

IE client servers.

brittle slate
#

anybody know how to replicate anim montages? it doesnt seem to be working

regal relic
#

Wish i get tell ya Bren, But i have'nt played alot of anim, or montages for that matter much in replication.. Are you using a replicated custom event for the trigger though?

brittle slate
#

yes i am. haha its weird

regal relic
#

What kind of replication are you using?

brittle slate
#

server to client

regal relic
#

So, Run on owning client?

#

Try the multicast function.

brittle slate
#

using multicast

#

srry im not a blueprint guy by any means lmao

regal relic
#

No prob.. Hmm.. My guess is to set a break, and make sure its firing.

brittle slate
#

it is

vivid siren
#

@regal relic also, can you help me out here

brittle slate
#

says its playing but just not showing

vivid siren
#

my ip goes there, right? the example showed the default ip but idk if thats what i use or if use my actual one

regal relic
#

@vivid siren yes, either your internal IP for lan testing, or perhaps your external IP for WAN testing.

vivid siren
#

awesome thanks

#

i'll probably have a few more dumb questions soon if that's alright

regal relic
#

Dont forget for WAN testing you will need to port forward or whatever the ports you need open.

vivid siren
#

yup i have them opened, i used the default 8081 they had

regal relic
#

If i see, I answer. ๐Ÿ˜›

vivid siren
#

๐Ÿ˜„

regal relic
#

I dont pay attention all too often though. Multitasking happens.

vivid siren
#

that's alright, i can wait ๐Ÿ˜›

#

@regal relic is this variable supposed to be Master Server Functions Class?

#

This is worrying me, please don't say that the user has to know their own IP to host a server

regal relic
#

@vivid siren Yes the create class looks right.

vivid siren
#

Awesome

regal relic
#

You can leave the gamemode blank, Or just whatever... And your IP is obviously the IP to your new server .

vivid siren
#

so, for my master server then, if I host it on my own pc, i use my own ip in the Initialize node

#

and then i use the same ip in the Make ServerInformation?

#

Like, just hard-coded in there?

regal relic
#

You can hardcode it in for testing.

#

You could also make it variable pulled from elsewhere, An Ini or whatever.

vivid siren
#

@regal relic Sorry I still don't quite understand. Will the Ip in the Make ServerInformation always be my ip since I'm hosting the master server? Or will it have to change to other things when, say, someone tries registering a server on my master server

#

Because I don't know what or how I could ever fill that with anything other than my own IP

regal relic
#

Well in the future if for instance your making listen server (IE Client Servers) then you obviously want to get their WAN Ip and the port to forward address.

#

@vivid siren The bottom side to this system. Will be that you would need to probably set up port forwarding on each hosts individual router. A pretty major caveat for some.

vivid siren
#

I'm definitely not going to be able to do that @regal relic

#

So I don't think this plugin can help me then

#

I thought the purpose of the master server was to provide a link between people who want to play together?

#

Without having each person trying to host require to port forward

quiet vale
#

sorry to interrupt. just a little question

#

how to quite a Dedicated server from code?

#

i am using quite node from blueprint.
it is working fine on listens server and client build.
but nothing happening in Dedicated server build
any thoughts?

regal relic
#

@tribal oyster Quit? Are you talking about closing a dedicated server terminal? Try Ctrl-C

fossil spoke
#

Sounds like he wants to be able to shut one down through code

regal relic
#

@vivid siren the purpose of a master server is to give clients who only know one place to go (the master server) to get a list of available servers elsewhere. The clients need no such forwarding. They can connect without any setup necessary. However for the servers forwarding would be necessary without some kind of NAT punchthrough

#

@fossil spoke I dont think there is a way to actually call commands from a dedicated server terminal. One would need to work out creating a client which could log into the server, and have access to a pre-coded set of console commands, or something of the like.

vivid siren
#

@regal relic so if I wanted to let a user on my android app host a 2 player lobby for a game and have a second user join that lobby to play, what should I do?

regal relic
#

Well you could for instance have PC dedicated servers located somewhere waiting to host these such rooms.

#

I imagine a half decent dedicated server should be able to host quite a few dedicated server threads. If the rooms are just 2 people.

vivid siren
#

For a complete noob with dedicated servers, how long do you think it would take for me to learn and set that up? I have no clue about threading a server, but it sounds about right

regal relic
#

So your clients could connect, get a list of available (Rooms), Log into one, Which is effectively a dedicated server thread being hosted in the cloud somewhere.

vivid siren
#

Does it have to be on the cloud or could I have a dedicated PC to just hosting?

regal relic
#

It can anywhere you like.

#

Just depends on how many people your trying to support simulatenously, and what their going to be sending/transmitting in their sessions.

vivid siren
#

this is just a small project for an app prototype that maybe a dozen people at maximum would be using at the same time

#

it's not going to be a fully deployed game or anything

regal relic
#

by the time it becomes an issue, Im willing to bet you'll know how to solve it ๐Ÿ˜ƒ

vivid siren
#

@regal relic So just so I can try to imagine this: I'll have a dedicated server hosted on my PC, (a command prompt window, nothing else) and I will have this command prompt running several different "rooms" simultaneously (and separately) for others to join?

#

And then when someone wants to join a room, they will connect to my PC (through my IP which is hardcoded in) and then select which thread/room they would like to join?

regal relic
#

Pretty much.

#

Proper server environments have ways of extrapolating away the graphical undesireables, such as terminal windows and such. Lots of cloud frameworks for this sort of stuff when you wanna get serious.

#

It cloud setups for the most part you have VM's running server OS's, handling server threads like our OS handles services.

vivid siren
#

Interesting, alright, I will try to take this route then, thank you

quiet vale
#

hi sorry.i was taking with my CEO about it

#

our master server setup done and dedicated srver is hosted on aws

#

but problem is dedicated server keeps ruinning even when all the players quites

#

so what we did is counting player number and when player number is 0 then it will quite automatically

#

but quite node is not working on Dedicated server build

#

"@quiet vale Quit? Are you talking about closing a dedicated server terminal? Try Ctrl-C"

#

thats why ctrl+c is not an option

#

we are looking for an automated way instead of manually closing iy

#

it

#

we tried to use quite button in different places but none of them working

stiff wasp
#

I don't think you understand how dedicated servers work. They are not suppose "quit" when everyone leaves. One of the points of using a dedicated server is so it can run even if no one is currently connected. If you have to have shut down after someone leaves then use a listen server. @quiet vale

quiet vale
#

Okk

#

But our server gets created dynamically

#

On demand

#

Basically we want to save resources

#

I was pretty sure that there is a way to quite it out of the box

#

Otherwise i have to implement it myself

#

@stiff wasp are u sure there is no way to quite it from code ?

stiff wasp
#

There is

#

But i want you to ask yourself why you are using dedicated servers.

#

From what you are describing you don't need to

#

Shouldn't use dedicated servers unless you have to. They are not cheap

quiet vale
#

Company secret. Cant tell.

#

Just one clue "on demand server spawning"

stiff wasp
#

Heh.

#

Not sure what you are trying to spawn, but it does not matter. The point is, you shouldn't shut a server down just cause there are no players in it. You'll just end the current session and create a new one

#

Don't shut the whole server down

#

That would use more resources, not save any

quiet vale
#

Ok. Still i am interested on quite() method

stiff wasp
#

You doing this in C++ or blueprint?

#

Depending on your answer will change my answer.

wary willow
#

Not to derail this, but what's a quite() method?

#

Quit and Quite are two different words

stiff wasp
#

Yeah, I'm just assuming he is making a typo

vivid siren
#

It's pretty obvious it's a typo tbh

stiff wasp
#

^

#

Not sure if he is talking about EQuitPreference or destroying a session. He wants help but does not really give me the info to help him.

#

Welp I'm going to bed. Nighty night ๐Ÿ˜ด

quiet vale
#

Hi

#

Was busy wih something .

#

Thanks for all the info

stiff wasp
#

Dammit. I was literally closing discord

quiet vale
#

I am using c++ bp both

#

Whatever needed for work

stiff wasp
#

Is your session logic in bp or C++

quiet vale
#

I will look into the defination of EquitePreference

#

We are not using ue4's session syatem

#

System

#

We have built our external system

stiff wasp
#

Ahhh well that would have been nice to know before I wrote all that

quiet vale
#

Session syatem is too heavy for our simple task

#

Sorry

#

One man handiling so many things at once

#

@stiff wasp thank you so much .

#

I will dig into engine code

vivid siren
#

I'm grasping at straws with this whole multiplayer thing and it's really getting me stressed.
Can I just host a bunch of listen servers on my home pc and let players connect to those? Honestly I don't care I just need something that works

#

I have less than a week to develop this whole app and I don't want to start it until I know how to get it multiplayer

wary willow
#

Multiplayer is pretty hard concept just by itself, and then add the complexity that UE4 adds to it... @vivid siren

#

or any engine

#

If you are "hosting a bunch of listen servers", you are essentially doing dedicated servers, so you might as well do that instead

vivid siren
#

I don't know how to host a dedicated server though and everything I find online requires me to edit the engine's source code or something which I'm not comfortable doing at all

wary willow
#

There's a plugin

#

That fixes the dedicated server issue present if memory serves me correct

#

Pretty sure we were just talking about it a few days back

vivid siren
#

Where would I look for this plugin?

wary willow
#

Look at the past msgs

#

google

#

ยฏ_(ใƒ„)_/ยฏ

#

But pretty sure it was discussed

vivid siren
#

Is anyone here familiar with GameSparks?

wary willow
#

I use it

vivid siren
#

Would that solve my problem?
I just want to be able to have several 2-player rooms available for players to join

wary willow
#

Gamesparks is not an OSS

#

I don't get where everyone is getting this info from

#

Gamesparks is like PlayFab

#

Both just provide backend services

vivid siren
#

Oh, well I need something to handle the actual systems

wary willow
#

Quite a bit of awesome services though

#

Just use Steam

vivid siren
#

It's an app

wary willow
#

ยฏ_(ใƒ„)_/ยฏ

#

No idea then

#

I don't do mobile

vivid siren
#

So I caved in and decided I would try to do the whole nonsense with downloading and coding stuff for a dedicated server

#

but what do you know, the github for the ue4 repo is down

#

My entire weekend has been wasted on unreal engine to get nowhere because of terrible documentation and poor support for mobile games

atomic horizon
#

Github UE4 Repo is up for me.

vivid siren
#

Well I guess I'm just failing at using github then

atomic horizon
#

works

vivid siren
#

Turns out I messed up when linkin my github on my ue4 account

atomic horizon
#

applaus

vivid siren
#

Well, wish me luck I guess.
I'm about to learn about dedicated servers and hopefully I can get this unecessarily difficult project finished before the deadline

wary willow
#

@vivid siren how long have you used UE4 for?

vivid siren
#

about two years

wary willow
#

And how long have you been using Networking in UE4 for?

vivid siren
#

about 2 months

wary willow
#

When's your deadline?

vivid siren
#

this saturday

split plank
#

Hi I am using the official multiplayer on steam project from epic forums, anyone knows why when I use seamless travel on a project with steam why dont keep playerstates, gamemodes and characters selected when I switch from Arena01 to Arena02. When I go from Lobby to Arena01 or Arena02 it keeps the information (player selected and everything)รง

wary willow
#

@split plank define "official"

#

the BP MP series?

split plank
#

yes

#

that one

wary willow
#

I bet @thin stratus would love to answer this, but he's probably sleeping

#

I don't know anything about replication and seamless travel

split plank
#

thank you anyway I will try to ask him

wary willow
#

The Lobby to Arena though, that's probably because gameinstance hosted all those umgs

#

From Arena01 to Arena02, is that something you implemented?

#

Or was that part of the series?

split plank
#

yes

wary willow
#

I kind of stopped watching it because i wasn't learning anything

#

So

split plank
#

I wanted to switch maps after time is over

wary willow
#

If you are switching maps

split plank
#

I tried servertravel but dont move the clients

wary willow
#

You need somewhere to carry over the information

split plank
#

tested with some friends

#

when I use seamless travel they all move but it doesnt carry over the information

wary willow
#

Right

#

So, mainly GameMode, GameState and PlayerState are the major things to look out for. GI/PC can be used as well, but rarely. Unless in that MP BP, where all the UMG are getting called.

#

GameMode only exists on the Server

split plank
#

I wonder if there is a way to keep those things away from resetting

wary willow
#

I'm going over my notes;)

#

One sec

#

GameMode always resets when travelling

#

So, this is probably what you are experiencing

#

You need somewhere to keep that information persistend

#

persistent

#

Traveling to new level s*

#

This happens in SP also

#

Which is why we use Gi

#

GI for saving info from one level to another usually

split plank
#

mmm so load the gi information

wary willow
#

Hmm, probably not so easy

#

I don't think GI is replicated

#

GS is though

split plank
#

after the map load?

split plank
#

I tried to search for a tutorial on youtube but didnt find anything

wary willow
#

you should read this

#

Yeah

#

Looks like GameState is where you will want to keep your info

split plank
#

I will try to look into that thank you!

wary willow
#

No problem

#

@split plank

#

Go to page 79 on the link I just gave you

#

79-83 will give you what you want

#

Supposedly GameMode does persist

#

I'

#

I'll have to get used to that when dealing with networking

split plank
#

reading right now

#

didnt know servertravel disconnected clients from server then tried to reconnect

#

AGameMode::GetSeamlessTravelActorList' what is this?

wary willow
#

...

#

read ๐Ÿ˜‰

#

it tells you exactly what it is in the name

#

and if it doesn't the pdf does

split plank
#

isnt a blueprint right?

#

I have my gameplaygm (gamemode) and try to get that list

thin stratus
#

Cpp only afaik

#

@split plank Lobby to Arena keeps information as that is what you programmed after all. Thr series isn't that great though so I don't blame you if you didn't understand where and why that happened

#

Arena to Arena won't keep the information as you never programmed that

#

Seamless travel means it keeps everything alive that you specify during a map change

#

Including gamemode

#

So that's not useful for lobby to arena

#

And is only useful for arena to arena if you want to keep stats and the gamemode etc is the exact same

#

Means you can't use that if you go from team death match to capture the flag

#

A normal ServerTravel with seamless travel off should bring your clients with the server

#

I mean the same happens when you leave the lobby

#

You just need to make sure that all the data

#

That you stored and passed from lobby to arena is also stored for arena to arena

#

Otherwise you character etc won't get spawned as the information is missing on the new map

#

While it's true that you can use seamless travel to keep data alive (my network compendium has info about that in the PlayerState chapter) this will only work if you keep the gamemode and is most likely better supported in c++

#

So your task is to use normal ServerTravel and pass it the data you need

#

How you do this is up to you though :x

split plank
#

Hi Exi thank you for your reply if I want to use servertravel on steam my clients disconnect to main menu you have idea why? server travel fine and store everything

#

but clients seems to dc

thin stratus
#

I would need to see the logs of the server and the client

split plank
#

how can I enable those logs?

thin stratus
#

There should be a Saved/Logs folder if you have a development build

#

and of course if you just run it as standalone

split plank
#

ok thank you will test tonight

wise depot
#

or if you're launching from the editor, add -log as an argument to launch

#

or from a buil d(that isn't shipping) just run cmd or make a batch file with

Game.exe - log

proven jolt
#

Hi all, I'm pretty noob in these unreal things and my questions might sound a little simple, but... I'm trying to make a multiplayer test game with camera rig not being attached to any actor (kinda like in rts), but a camera that follow all pawns
I know that to force a player to look through that camera I need to SetViewTarget(camera rig actor) on PlayerController, therefore I tried these things already:

  • Placing CameraRig actor in the map, then finding that actor in PlayerController::BeginPlay(); I don't like that solution, because that camera rig actor should be transient, and placing such an actor in a map just doesnt seem right for me
  • Spawning CameraRig on PlayerController::BeginPlay() and setting it as view target; the issue with that solution I have is that I don't exactly know where that actor is being spawned (on a server? on a controllers client?) and whether it is being replicated; that actor, because it is a camera anyway, and I feel that it does not need to live anywhere on a server
    The questions I have are:
  • what is the proper, valid, epic way to do that kind of thing?
  • how (and when) to spawn client-only actor?
thin stratus
#

Hm

#

You are not possessing any Pawn, right?

#

You only want the View to change, or?

#

So spawning the Camera on BeginPlay is fine.
If you do that in the PlayerController, it's called on the Server Version of it and on the Client Version of it.

Each Client has one Controller Instance and the Server has all of them

#

That results i nthe Client getting one version and the Server getting one for each

#

You can limit that with an authority check before calling the code

#

Though I haven't used Cpp for network in a while so I would need to check what the command was

#

Then you would limit the spawn to Client

#

And make the Camera Actor not replicated

#

That SHOULD do what you want

#

@proven jolt

#

Ah ,here we go

#
if (Role == ROLE_Authority) ; // Will always mean server version.
if (Role == ROLE_AutonomousProxy) ; // Will always mean the client that 'owns' the actor.
if (Role == ROLE_SimulatedProxy) ; // Will always mean the client(s) that are just copying the actors data from the server.
#

So you would do it when Role != ROLE_Authority

proven jolt
#

actually I do possess the pawn, because each player has its pawn

#

one pawn per player I mean

thin stratus
#

Ok, then you might want to do the Set View after possessing

#

Cuase possessing might override the view target again

proven jolt
#

there's bAutoManageActiveCameraTarget that I think will prevent setting view after possessing, but I'll double check that

#

ok, i'll check that role and see what happens ๐Ÿ˜ƒ

vivid siren
#

Hey. I have two phones connecting with lan through the ue4 session nodes and whatnot but this only works on my home wifi. When I try on another wifi, they won't connect....

#

I have ue4 ports opened at home, but I don't think ports should be the issue since it's lan...

brittle sinew
#

What other wifi are you trying on?

vivid siren
#

My work's wifi

brittle sinew
#

Alright, there's a good chance they have something called AP isolation on

#

Where you can't see other devices on the network

#

Not guaranteeing that, but in work settings that's often on just for security reasons

vivid siren
#

That makes sense for this place. Is there a workaround?

#

Maybe Bluetooth?

brittle sinew
#

I haven't done anything with bluetooth, it might be possible but I haven't tried

#

Though it seems you might have to do it yourself if so

vivid siren
#

So you're saying the blueprint session node stuff won't work with Bluetooth?

brittle sinew
#

Judging by what I see on answerhub questions, no

vivid siren
#

Damn, I don't know what to do then

wary willow
#

6 days left @vivid siren ?

vivid siren
#

Yup...

wary willow
#

Not sure why you waited so long ๐Ÿ˜‰

brittle sinew
#

It might work if it tries to connect via sessions, maybe it would like go to the outside and back?

#

Not sure D:

wary willow
#

His work ports are probably not opened

brittle sinew
#

Though actually there would be nowhere else to go on P2P

wary willow
#

Not hard logic

#

Unless he gets access to them and forwards the ports, nothing is going to happen

brittle sinew
#

LAN doesn't need ports

#

But they might have AP iso on

wary willow
#

Even with discovery?

vivid siren
#

@wary willow I didn't wait, I started working on this asap

#

And I can't touch ports because this needs to work anywhere

wary willow
#

Well, it's not going to just "work" anywhere

#

Even hosting on steam requires some work on the player's part

brittle sinew
#

The amount of time you'll be running into AP isolation is pretty much 0 on home networks, but if you need it specifically in that setting I think you're pretty much out of luck

#

You can try to run something like nmap to see if that's the issue, if you see other devices then it's something else. But if you see no other devices, not much you can do :/

thorn merlin
#

this is what ive been rambling about recently - i was investigating the nat punch through technique

charred crane
#

I cannot get a SimpleMoveToActor node to work. Prints before and after it work and the event is called on server. Is there something else I'm missing?

brittle sinew
#

Do you have a navmesh in your level?

#

That's the biggest thing I see people forget ๐Ÿ˜›

charred crane
#

....it appears the navmesh i had in the level was broken or something...i added another in and it solved it.

drowsy zodiac
#

Is there an event called when a player leaves a session/game?

#

is it just end play?

#

a playerstate event that is

fossil spoke
#

@drowsy zodiac OnPostLogin and OnLogout are events on the Gamemode that notify of a connection/disconnection of a player controller.

drowsy zodiac
#

perfect, thank you

#

@fossil spoke Exactly what I needed.

fossil spoke
#

Good to hear mate.

dull river
#

i'm having a little trouble getting a locally networked game to run. i'm using 2 pcs which are connected by ethernet to the same network. i'm running the server using this command: ""C:\Program Files (x86)\Epic Games\4.13\Engine\Binaries\Win64\UE4Editor.exe" "Z:\Unreal Projects\base_vr 4.13\BASE_VR.uproject" Default?listen -game" and the client with this: "C:\Program Files (x86)\Epic Games\4.13\Engine\Binaries\Win64\UE4Editor.exe" "Z:\Unreal Projects\base_vr 4.13\BASE_VR.uproject" Default -game

#

the client cant seem to connect, it just sits there frozen

#

(timing out i assume)

#

any ideas?

thin stratus
#

Would need log files to know what's going on

#

How do you actually connect?

dull river
#

@thin stratus i'm using BP nodes create session and find session/join session

thin stratus
#

@dull river Normally you should Create the Session and then open a new Level with ?Listen

#

Maybe the order is wrong

#

Start the Server normally

#

and handle that in the menu

dull river
#

@thin stratus currently im just doing that on key presses

#

i can get 2 players to join the session now

#

though in one of my windows i seem to be a spectator

#

i can see both players (one of which moves if i press movement input buttons)

#

(that BP is in the character pawn)

thin stratus
#

That looks fine

#

The stuff about the spectator etc, i don't know, that's mostly your own code on the new map i guess ?

dull river
#

if i play it single player it works fine

#

im having an issue with my playerstart though, it doesnt put the right pawn in the map

#

it actually doesnt put a pawn in the map at all

brittle sinew
#

I know you were asking about OnPostLogin a couple days ago, are you overriding that?

#

@dull river

dull river
#

i think youre thinking of someone else

#

ive never even heard of onpostlogin before haha

brittle sinew
#

D"

#

Sorry haha

#

So I guess that wouldn't be the issue then, I'm not exactly sure why no pawn at all would be spawned if your defaults are correct. If you depossess after spawn, is there anything there?

dull river
brittle sinew
#

Is there a collision possibly happening preventing it from spawning?

#

Since you said the DefaultPawn worked

dull river
#

ahhhhhhhhhhhhhhhhh

#

that worked

#

thanks!

brittle sinew
#

๐Ÿ‘

vivid siren
#

Hey does anyone know about using google play's online subsystem? it supports realtime multiplayer but i dont know how to utilize it

dawn linden
#

Is it possible to get public leaderboard stats via BP (Steam and Oculus subsystems) ? From what I can tell, only player stats are supported.

wary willow
#

@dawn linden yes

#

So, there's two caveats to that of course

#

One, it's currently bugged, and needs a engine code fix

#

Two, you need to fix that little thing that Epic doesn't want to, to do it

#

But there's a PR somewhere, that again, Epic does not want to take

#

There are also other Leaderboard solutions available to you. Such as @crimson jetty 's Epic Leaderboard and GameSparks, and I am sure a few others.

#

TBH, I am surprised, no one's done a plugin to fix the issues and just sold it on Marketplace

#

(I use GameSparks for leaderboards) and find it pretty awesome myself

dawn linden
#

Thanks a lot, I'll look into those options.

thorn merlin
#

game browser and nat punch are needed big time for android - are there any big multiplayer unreal engine games on Ios? do they have this problem solved over there?

vivid siren
#

I still can't figure out how and there's absolutely nothing online about it

#

it says the user must be signed into the google api client

#

so I guess I need to implement that as well?

wary willow
#

@vivid siren 5 days left and you're still messing with this?

vivid siren
#

....i kind of have to. i have 5 days left.

wary willow
#

rofl... my point exactly

#

You need to cut your losses

#

take a step back and figure out what your MVP is

#

If you can't have realtime MP, then do async

#

aka turn-based

vivid siren
#

I have no clue how to do that either

wary willow
#

so...like...why again did you wait until the last week to learn MP?

vivid siren
#

I didn't. I started it as soon as I was told to.

wary willow
#

So, what exactly do you have done with your multiplayer setup ?

#

Are all your variables replicated properly?

vivid siren
#

Nothing. People give me a suggestion, I try it, and then I find out what they said is irrelevant and I cannot use it

wary willow
#

Um

vivid siren
#

Replication isn't the issue right now

#

I cannot connect two people at all

wary willow
#

So, is that a no?

#

What I am asking you, is what you have done

#

In regards to multiplayer

#

Anything?

vivid siren
#

There is nothing

#

I am using blank templates

#

I can easily make the game in 2-3 days for this prototype but the multiplayer is what I need to figure out first

wary willow
#

So, why not just follow the MP BP series and call it a day?

vivid siren
#

Because that doesn't help, I need this to work for android

wary willow
#

There isn't an OSS for android?

#

or goggleplay whatever

vivid siren
#

There's the google play subsystem, but I can't find any docs on how to implement it with ue4

wary willow
#

You mean other than enabling it in plugins?

#

And using the same damn thing as any other tutorial?

#

Since it's just an interface

vivid siren
#

There's a google play subsystem plugin??

wary willow
#

generic one at that

#

No idea...I asked you that

#

I don't dev mobile

vivid siren
#

There isn't one

wary willow
#

And yes there is

#

Anyway

vivid siren
#

Well shit

wary willow
#

Back to what I was talking about

#

All you need to do is use the same damn nodes that every other OSS uses

#

Since all it really is, is a generic interface that ties into whatever OSS you enable/put into your configs settings

vivid siren
#

But I need the plugin first for that

#

Where did you get it?

wary willow
#

And yes, it's a bit easier in C++

#

Just include the interface and ggwp

vivid siren
#

Feel free to laugh at me, but I have no clue what you mean by that

#

Oh, nevermind

#

@wary willow Okay so anyway, now that I have that plugin enabled, I can use the normal blueprint session nodes to join players?

#

Don't I have to do some kind of google sign-in thing or whatever?

#

I changed the OOS in the ini as well, then enabled the plugin, but I'd assume there's more to it than that

wary willow
#

Well

#

If I were you

#

I would just download and use gamesparks and use their authenticaion

#

But

#

If not, you can just use Advanced Sessions Plugin

#

But I don't have much experience with that

#

And once again, no idea about mobile dev

#

So no idea how hard it is to get authentication/player stuff with GooglePlay

#

But I don't see how much it could differ

vivid siren
#

Okay, I have both in my project

thorn merlin
#

its been a while since i've tried but i dont think the google play online plugin offers multiplayer functionality

#

trying to check github code right now but its crashing on me

vivid siren
#

:\

thorn merlin
#

oh, it works for leaderboards, yea

#

i thought this was for game browser etc

vivid siren
#

yes

#

i need actual multiplayer, not leaderboards or achievements

thorn merlin
#

nice thnx, unreal did update its google play services lib in 4.12 i think.. might be worth revisiting this

wary willow
#

No idea, probably not going to get done in a week though

vivid siren
#

yes I've read that, it doesn't explain how you would set it up

#

and neither does the video

wary willow
#

or 5 days

twin juniper
#

anyone know if i can just call IOnlineSession::Get() and then use the JoinSession function and just input the necessary variables

#

or do i have to setup the delegates too

vivid siren
#

@wary willow if all it took was the normal session nodes then i would have the entire app built with full multiplayer functionality and proper distribution on the app store within 2-3 days

#

hopefully @thorn merlin is right and they may have updated it, but even still, i won't know how to implement that anyway because surely there's some api required to be integrated for the authentication to work

#

i doubt google would just let me connect to them

thorn merlin
#

i was looking at the source code for the google play vs the steam online plugin - i didnt look for as long as i wanted but based on what i saw i dont see any session stuff

#

i'd love to be proven wrong but really i dont think you can do it out of the box, if anyone other than me has a multiplayer game on android game i wish someone would chime in and help out

wary willow
#

I think that's the problem @thorn merlin

#

Not many people have done one

#

Or would

#

๐Ÿ˜‰

#

Technically, documentation for just Steam was lacking

#

There were a few community tutorials though, which helped

thorn merlin
#

because I'm going to steam next I really wanted to keep my network replication uniform, other wise id be using gamespark like you

wary willow
#

Well, GameSparks has nothing to do with replication...

thorn merlin
#

thats my point

wary willow
#

Why are people still saying this ๐Ÿ˜ญ

#

Okay

thorn merlin
#

gamespark uses a different method of networking

wary willow
#

GS is just what I use for everything other than Connecting to players

#

I do use Achievements though, since that's easy to implement

thorn merlin
#

it looks like a good service, just too late in the game for me to use it

wary willow
#

The Leaderboards are bugged

#

And require a source code change

#

But that's documented

#

So, if you are on source, easy fix

#

Otherwise, you'll need GameSparks

#

or something similar to host your leaderboards

#

But I love GS because it's just so much MORE than Leaderboards

#

Like, you could essentially implement a prestige system

#

full inventory

thorn merlin
#

yea the cloud db and all that looks great, im holding my breath for a google firebase plugin tho

wary willow
#

great analytics

#

And custom ones as well

thorn merlin
#

who owns gamesparks btw?

wary willow
#

no idea

#

they do?

dull river
#

im trying to connect to a LAN game through BPs with one PC acting as a listen server and one as a client

#

my client cant find any sessions though

#

how do i get my client to be able to find the listen server?

thin stratus
#

Can you connect directly via IP?

elfin dagger
#

has anyone ever tried a setup like this?: within a LAN environment a few players start a game and automatically start a map as a listen server. then they look for other existing sessions and join them if they were created at an earlier time than their own, eventually all ending up in the same session. I have it working more or less but it qualifies as buggy at best. :/ @thin stratus maybe?

#

to add to the level of difficulty: needs to run on android and preferably with BP

thin stratus
#

So you want to automatically join all LAN Players together?

#

Wouldn't it be easier to say "Are there any Sessions available? NO? Then let me start one and wait."

#

And if "YES? Let's join it"

elfin dagger
#

yeah, that would work as well I suppose

thin stratus
#

And if you want to make it more bulletproof you go ahead and do "Hm, started a Session and I'm waiting for 2 minutes now, lemme check if someone else has a Session"

#

And then maybe join that

elfin dagger
#

as my brain feels like it has completely melted down by now, how would you about implementing it? store the create and find session events in the gameinstance and then run the checks from the player controller/game mode?

#

right now I'm constantly running into the issue that even though two sessions exist it would not always find any. or only after a substantial (and varying) amount of time

#

and a lot of these: "LogScriptCore:Warning: Script Msg: FindSessionsCallback - Invalid player state"

cinder talon
#

Yeah, GameInstance is a good place to put host/find session functions

#

What checks do you want to do?

elfin dagger
#

@cinder talon I mean basically from where to call those find/create session events/functions

cinder talon
#

I have a mainmenu widget and a HostGame button which calls the host function

elfin dagger
#

I've been running in circles with this for a while now and I just feel like I'm doing some really stupid miskate that I just can't see anymore. hence I'm starting to ask stupid questions to verify my level of insanity and maybe get some good pointers in the right direction ๐Ÿ˜‰

#

A menu is specifically not what I want to do here. that worked just fine for me in other projects but unfortunately is not feasible in this case.

cinder talon
#

I see

elfin dagger
#

it pretty much has to be a solution without any user interaction...

cinder talon
#

Level Blueprint's BeginPlay, Controller's BeginPlay

#

When exactly it should be called?

elfin dagger
#

right when you start the app

cinder talon
#

Hmm

#

Maybe an "InitialLevel" could help

elfin dagger
#

the user should not need to do anything but click the app icon. as soon as anybody else does the same in the same WLAN they need to end up together

cinder talon
#

The one that open's first has a timer that every 0.25 seconds checks if everything's ready and starts a game

#

Previously there should be a check for existing sessions

#

If none found -> host session

#

The second player does the same but should be able to find first session

#

*opens

thin stratus
#

Yeah, the first Level you open

#

Let it be "InitialLevel"

#

Put the call in the BeginPlay of the LevelBlueprint

#

And the actual function in the GameInstance

#

That InitialLevel also doesn't need any GameMode or so

#

You can also add a Widget through that function

cinder talon
#

Seems like it should do the trick ๐Ÿ˜„

#

I'm just thinkin about order of BeginPlay calls

thin stratus
#

So it would be:

  • Icon Pressed
  • App Starts
  • App opens "Initial Level"
  • LevelBlueprint of "Initial Level" calls "BeginPlay"
  • That calls a "Check for existing Sessions" in the GameInstance
    -- That is a simple FindSessions node that checks if the returned Array has a length > 0
  • Then, based on that, either Create a new Session or Join one.
cinder talon
#

I wonder if the widget will be added from Level's beginplay if the controller hasn't had his beginplay yet

thin stratus
#

Creating a new Session needs to have "OpenLevel" with the GamePlay Level" and "listen" as an option

#

Otherwise the joining etc will not work

#

OpenLevel node of course only if the CreateSession node succeeds

#

@cinder talon It should. Doing the same in my Lobby project of the Marketplace

cinder talon
#

Sweet

elfin dagger
#

sounds pretty much like what I tried a while ago except for doing it from the level BP. will give it a try, thanks guys

#

how would you then handle the case of two or more people doing it at roughly the same time and maybe ending up with multiple sessions as a result?

cinder talon
#

No way to stop people from launching at the same time so I'd do additional ingame check after a few seconds.

#

Something like "An existing session has been found. Join?"

elfin dagger
#

right now I'm storing the creation time of the session as an extra attribute and compare it, but it doesn't seem to work too well yet

#

i could probably just check every once in a while and if there is a session that has more players than the one you're currently in then join the other one

cinder talon
#

That could be a popup message on the right side of the screen with text showing the number of players and JOIN or DISMISS options

#

I guess it's up to you from this point

elfin dagger
#

it would definitely be a forced join in this case but yeah, once I'm at that point it should be easy enough... ๐Ÿ˜ƒ

cinder talon
#

Who cares about user experience? Force people to play together ๐Ÿ˜„

elfin dagger
#

sometimes it's the only way. ๐Ÿ˜‰ it's corporate clients for this project, so every button they need to click is one too many. they're not the usual computer savvy-gamer-type of people who want a choice ๐Ÿ˜‰

wise depot
#

yo, is it just me or do the Packet Simulation Settings not work anymore? (4.11.2)

elfin dagger
#

@cinder talon @thin stratus : magically seems to work at first glance. still need to iron out some things, but the basics look good so far, thanks guys!

cinder talon
#

You're welcome ;d

wise depot
#

also, anyone here work with the steam API?

#

when the host crashes, clients then just get "can't join a session, game in progress" or something along those lines when trying to join a new session

turbid stratus
#

there must be a timeout value somewhere? might also check if the crashed-host-session has 0 players, exclude 0 player ones from showing up in a list?

#

just random workaround ideas

knotty frost
#

When is the proper time to destroy a session, and where should it be done? I had it setup to Destroy the session on the exiting controller within a gamemode blueprint using Event OnLogout, but it seemed to destroy the session for the entire server rather than the exiting controller (it would no longer be found when searching for sessions).

thorn merlin
#

@knotty frost are you calling PlayerController::Logout?

#

@knotty frost i dont think you want to destroy the session, do you mean the player state?

knotty frost
#

I was using the gamemode event OnLogout, I'm trying to figure out where to end the session for a disconnecting player so that they can join other sessions

thorn merlin
#

ah, i typically do a log out, then return to my main menu, so perhaps the map change destroys it for me

thin stratus
#

@knotty frost I destroy a players session when he gets into the MainMenu

#

cause there he 100% does not need or want to have a session

#

And then I only need to do it at one point

heady delta
#

Hm, can anyone tell me why in shootergame, epic have it set up that when the state switches to firing, it runs the firing function on both client and server, but only seems to refire on the client (automatic) and then the client sends an RPC to the server after each following shot to tell it to use ammo etc

#

Im wondering why they don't just have the server refire as well

fresh saddle
#

@heady delta less for the server to process, I assume.

heady delta
#

@fresh saddle I would have thought the same, but it's just a function timer it has to run, the firing function get's called by the RPC the client sends after they run it anyway.. I'm going to take a stab in the dark and presume it might be so that when the client calls to stop firing, the server does not refire an extra shot because of latency.. that's the only reason I can think of

#

ยฏ_(ใƒ„)_/ยฏ

twin juniper
#

I am playing the same build on two computers, one loads the steam overlay, the second doesn't. I haven't had any issues with this computer before, and I did the usual restart/check for updated drivers etc. I can see the two accounts in their respective friends list, so I'm definitely online on both... I'm out of ideas

wary willow
#

@twin juniper Oh, check your steam settings

#

Make sure the one that's not playing overlay doesn't have it disabled

twin juniper
#

Well, not all good. But on the overlay settings part.

#

Wtf, steam now shows the purchase button for my game, something must be very wrong

wary willow
#

lol

#

just reinstall steam on that one

twin juniper
#

Yeah I logged in with this account on the other comp and I own it there

#

Apparently steam thinks I play my game so much that I have to buy it.

twin juniper
#

Reinstalling didn't work, I actually had to register a new key

dull river
#

i'm failing to find any sessions over LAN after creating one on another PC, any ideas why?

#

@thin stratus i saw you suggested connecting directly via IP, how would I do that through BPs?

thin stratus
#

It's more a debug step. I want to see if maybe your firewall or what not stops the whole fun

#

You do that either vis console (if you can still access it in your development build)

#

Or you use the "Execute Console Command" node

#

Host uses it to do "Open MapName?listen" (or uses the OpenLevel node) and client does "open IPADDRESS"

#

No session creation for this one

dull river
#

ive tried 'open ipaddress'

#

i get outdated client error

thin stratus
#

Client and Server don't have the same programm

fierce birch
#

hmmm

#

just read the latest replies on exi's thread

#

This will include more review on our end, but may also involve the community experts in one way or another.

#

wouldn't epic have any experts on that matter?

#

feels odd to try to get community to do that

#

I mean, they've designed it, they should know how it works

sly kernel
#

Can someone recommend docs/tutorials (relevant to current UE4) for Steamworks in BP ? Not looking for matchmaking or MP yet. Looking for achievements, leaderboards, player ID, Cloud, etc. Thanks

dull river
#

@thin stratus they're both running the same version of the vr editor

brittle sinew
#

I wouldn't be trusting a PIE instance to have the exact same files, if you need to test MP I would package.

#

Even separate from that, MP is somewhat shaky in PIE @JTLR

thin stratus
#

PIE is shit, yes, but you don't need to package

#

You might want to from time to time

#

But you can simply start the game as a standalone

#

Either from PIE or rightclick the Uproject file and hit "LaunchGame"

brittle sinew
#

I just meant to package since generated files might differ on each, not sure if it's necessary

sly kernel
#

So, can someone help with my question about Steamworks please ?

wary willow
#

@sly kernel no

#

TBH, If you are already on steamworks, all the documentation is already there ๐Ÿ˜ƒ

#

That's something that I can't fault Valve on

#

But you are also asking about different parts of Steamworks and for BP

#

And that's not going on happen

#

Only reliable thing that's accessible straight from BP is achievements

#

And there's already a tutorial on that

#

PlayerID should already be accessible though?

sly kernel
#

yeah, I found tutorial for Achievements via BP

#

but not Leaderboards

wary willow
#

nope

sly kernel
#

so, does it mean there is no way to do Leaderboards from BP ?

wary willow
#

Because Epic broke it and never fixed it

sly kernel
#

๐Ÿ˜ฆ

#

gee

wary willow
#

I mean you can

#

It's just not going to be a 100% bp only project

sly kernel
#

I see

wary willow
#

Also

#

Forget Steam Leaderboards

#

And use GameSparks

sly kernel
#

well, as much fun as it might sound, people on Steam want Leaderboards on Steam.. That's just how it works.

#

by people I mean players

#

for my old game we wanted to go non-Steam route for Leaderboards (since we used GPL engine we couldn't use Steamworks). Players rejected the idea.

wary willow
#

?

#

That's the dumbest thing I've ever heard so far

sly kernel
#

isn't there a way to make a plugin for Steamworks, so that project can remain BP project ? Or is it just easier to have BP + CPP project ?

wary willow
#

Well no , not the dumbest

sly kernel
#

that's something you can tell to gamers ๐Ÿ˜‰

wary willow
#

You are wasting your breath and fingers

sly kernel
#

and then see how your userbase shrinks significantly

wary willow
#

Okay

#

Then they don't play your game, next.

#

No one cares about Steam Leaderboards

#

They really don't

sly kernel
#

what makes you say that?

wary willow
#

Experience

#

Players will be content with any type of leaderboard implementation if it is inside the game.

sly kernel
#

I am curious, because I've been on Steam since 2011 with my game and while I don't care for Steamworks as a gamer, my experience says that a lot of people do.

#

you can't link inside-game leaderboard to anyone.. How will you brag about it to your buddies ?

#

and apparently it's a chore to open browser nowadays and look at leaderboards outside of Steam

#

I am not pulling this out of my ass, I am talking out of experience.

#

maybe I got "lucky" with my userbase, I don't know

#

anyhow, point about steamworks in BP is taken

fierce birch
#

well

#

I wouldn't want to mix another service for leaderboards only either

#

using steams would make a lot more sense :p

#

also

#

I care about leaderboards

#

not for global ones

#

but ones where I can try to beat my friends scores

#

I know some of my friends do that same too :p

#

@wary willow ^

#

and I mean in-game leaderboards

wary willow
#

?

#

You arne't making any sense either

#

I never once said I was against leaderboards

#

All I said, is that Steam Leaderboards themselves, as a service, is irrelevant

#

If you use another Leaderboards implementation

#

Your players will not know or care

fierce birch
#

and then you'd have to rely on yet another service which may go offline

wary willow
#

And if he can only do a BPonly project, or one with plugins, he's not going to get Steam Leaderboards, so he might as well go shopping

#

Nah

#

You don't know what you're talking about lol

fierce birch
#

I do

wary willow
#

If everyone had that same logic, nothing would ever get done

fierce birch
#

you don't just respect that opinion ๐Ÿ˜ƒ

wary willow
#

Everyone would be afraid to use new things

#

And that's a horrible way to dev

#

You're missing out on new and awesome shiny new toys

#

You didn't state an opinion though

#

That's my point

#

And you are not also taking into account his or her difficulties with the engine

fierce birch
#

my opinion is that it's better if you can keep minimal amount of external services that may go offline from time to time or altogether

#

that's just common sense

wary willow
#

If they cannot or will not want to make the engine change

#

They will have to ultilize a plugin

#

End of story

sly kernel
#

well, I am gathering info at this time

#

I am cross checking what my old game has (or should have had) and what UE4 already has working, and what will require to be added

#

so at the end of the day, if I have to do a small tweak to the engine before release, I might do that. It just depends. Maybe it would be wiser to hire someone ๐Ÿ˜‰ to make a plugin for missing Steamworks functionality, or a template C++ / BP project..

#

now that I think about it, I wonder what happens with plugins if I have to tweak and rebuild engine :/ Would I have to recompile plugins too ? (if they have source code available) Would plugins work with non-launcher build if UE4 ?

wary willow
#

Hire @thin stratus he is cheap and for hire @sly kernel

#

I heard he takes bananas as payments, cannot confirm though

thin stratus
#

Ha, don't say I'm cheap :D

knotty frost
#

@thin stratus I ended up destroying the session on leaving, on network error, and before attempting to create or join a new session, due to having trouble detecting a server host disconnecting. It seems dirty, but its working.

thin stratus
#

Hm weird

#

The thing is, when an Error appears

#

I send the Person back to the MainMenu anyway

#

So there they get their session destroyed

knotty frost
#

I had an issue where if the listen server host opened console, and ran disconnect, the gamemode's Event OnLogout wouldnt fire and detect the server leaving and cleanup/destroy that session

thin stratus
#

I destroy the session in the BeginPlay of the LevelBlueprint of the MainMenu

knotty frost
#

Destroying the session before attempting to join/start a new session is working, just not sure if that will cause problems later down the road

#

I was kind of bummed out there is no way to get the active session in Advanced Sessions / Epic's online library so I can't really use the OnFailure event to log any inconsistency

#

do people just store the session result they are joining in the game instance and reference it later? not sure how to go about it

#

since all the session functions take a PC the active session probably lives in there somewhere, just got to find it

thin stratus
#

Well there is a "GameSession" Class

#

That's where I do my stuff in C++

#

It's barely to none exposed to BPs

#

Though that's also a Server thing

proud wren
#

Anyone know if you can do client side prediction and the other things Blizzard talked about in their netcode video in unreal? Only thing i know how to do is stop cheating by running it on the server, wondering if there is a way to do some of the things they talked about.

#

@thin stratus @stiff wasp

thin stratus
#

Blizzard, if I got that correctly while playing Overwatch, does some checks and then decides who is correct and who not

#

Other then that, no idea

#

Simple example is the Roadhog hook. If Client A hits, but Client B was behind a wall on his screen (on Client As not yet cause of Replication delay), the Server favors Client As hit

#

I guess there is a simple threshold that is like "yeah that's still in the limits"

stiff wasp
#

@proud wren In simple terms, yes that is what they do. I should probably watch that video myself, as you are not the first person to ask me about it. You could do this in UE4 yes, it would take a bit of work, but its do-able. In my 1v1 arena game I am making, one thing I do is keep track of the delay between abilities. So an example would be with my character Floriaa vs Lucy. Floriaa has a lot of roots and stuns, and Lucy has a ability that makes her imune to roots and stuns. So lets say Floriaa throws her Gas Bomb (2 second stun + DoT) at the same time Lucy uses Overcharge Generator (her immunity). As of now the way the system works, it would ignore the stun. It always favors the DCD vs the OCD. Now, after the server compared the amount of time it took for those abilities to come in it might update this decision. I plan on changing this in the furture because right now on the Floriaa player's screen they would see the Lucy player get stunned for maybe 4-6 ms depending on the RTT then it drops as the server updates. This is rare, but it happens. So doing these kinds of predictions are very hard, and I am far from the greatest programmer. If I can do it, I know any networking dev could do it. Even Blizzard is not perfect, there are mistakes in their own system. So if you are thinking you could just make a fool proof system that would never get it wrong, than you may want to lower your goals. I was using simple terms there but I hope you get what I was going on about.

proud wren
#

Hmm, okay. Is this something I could do in blueprints? Or would I have to learn C++ for this? I am using the advanced sessions plugin is that helps.

stiff wasp
#

Heh, tbh you need to learn more about networking and programming as a whole before you try to do something like this. Not saying I am special cause I did it, I am not. Anyone could do it, but there is a lot you need to learn before you would be able to even start on it.

#

And no, you couldn't do something like this in BP only. There are multiplayer classes that are not even exposed to BPs.

knotty frost
#

mainly about update rates, but I think it has info on correction too

turbid stratus
#

as far as things like player controls go (things that you want to feel responsive), is it generally right to do the move on the client and then the server?

#

e.g. when my player presses "Block", in my playercontroller client copy I'll run the "Set IsBlocking" function on the pawn straight away, then use an RPC to run the same thing on server side

#

This seems to work well - I'm just wondering if that's how it's generally done

#

Now if I want to rotate my player to match their aim target, I plan on doing the same thing - on tick in the playercontroller client copy, interp smoothly from current rotation to desired rotation (to aim at target), then do the same thing on the server

#

I suppose I'm better off not replicating that kind of movement each tick though, and instead sending an updated rotation target every half second or so, and doing the rotation in the local copy

stiff wasp
#

Yes, do your movement on client then check with the server to make sure they can actually move. However never replicate something on tick

#

Show me a screen shot of the stuff you have on tick

turbid stratus
#

that's currently in the character, now I'm just fixing stuff up so it works properly in network

#

so I guess I'll just update the desired rotation periodically via controller, and leave that tick logic in the pawn

stiff wasp
#

Why are you not using an axis event for your rotation?

turbid stratus
#

you mean rotate in the input direction?

#

I have it auto-orient for normal walking around (which replicates by default thanks to the Character class), but I turn that off when aiming, because they "lock on" to a target and I need their rotation separate from their movement direction

#

(the screenshot is missing the IsAiming branch)

stiff wasp
#

Okay, so have a custom event that fires when you aim instead of having something on tick

turbid stratus
#

the aim target location is often changing every tick

stiff wasp
#

Uh huh. Alright, but you said it's when the player aims right?

#

Is when you fire that logic

turbid stratus
#

well, "while" they are aiming, keep smoothly tracking the target, i mean

stiff wasp
#

Okay. Well that did not talk matter right now. Main thing is you want to make sure you never have an RPC on tick. Very bad idea. But back to your main question. Rule of thumb: You want none gameplay changing actions to be client based, then ask the server if the action was correct.

turbid stratus
#

so if the server is like, "nuh uh" (you can't do that move you just did), they won't move on the server, so the client will get automatically corrected anyway?

stiff wasp
#

Pretty much. Unless the player is lagging really bad that usually won't happen in large enough amounts that you'd notice it

turbid stratus
#

thinks back to my days playing UT from NZ to Germany

stiff wasp
#

The main things out checks for is things like, is the player dead? Is there something another player did to prevent this player from moving?

#

Most of the time of nothing happens the server wing have anything to change.

turbid stratus
#

I'm quite glad that I'm attempting co-op rather than versus.. seems a little more forgiving

stiff wasp
#

Forgive the typos, can't edit your messages on the mobile app

#

Heh yeah. I guess, at least your don't have to worry about the other team calling hacks cause the player lagged out :P

turbid stratus
#

yea and in general, they seem less likely to want to cheat

stiff wasp
#

Well, when you are playing against AI, only person you are cheating is yourself

neon mango
#

hey guys trying to debug some hitching I'm getting while moving

#

I'm using the ShooterProject as a base and some aspect of the code I added just makes the game unplayable at anyting above 10ms

#

so I simulate lag and recorded with netprofile

#

I just don't know what to make of it

#

it all says 0 ms?

knotty frost
#

Anyone know how to get friend invites working these days? Does it still require custom C++ code?

stiff wasp
#

Yes unless you are using advanced sessions like a blueprint skrub

compact oyster
#

Only thing that bothers me is that visual studio is just slow with ue4

knotty frost
#

I use atom but not having linting can be annoying for some people

#

With alot of work you could get clang-linter to work with UE4 and atom though

#

@stiff wasp any idea on View Game Info?

carmine parcel
#

On a listen server multiplayer is there a way to run a function only on the clientside of the host ?

#

http://puu.sh/sJwdz/33ba5684fd.jpg I am trying to set clientside visibility of skeletal meshes like this and it works, however when this function runs on the host and hides something it hides for everyone in the server

thorn merlin
#

@carmine parcel you could check for a HUD instance + is authority boolean check

#

@carmine parcel or perhaps just is authority check

carmine parcel
#

@thorn merlin If I say execute only if you don't have authority, won't it never execute on the host ?

#

so it does the exact opposite of what I am trying to accomplish when I say do only if you don't have authority, and interestingly it does the correct thing when I bool check true for has authority but now it only works for the host since it is the only one with authority

thorn merlin
#

sorry I don't have the time to get into the mindspace to understand your issue, I'm simply saying there is authority checks, as well as checking if the hud exists, i think new nodes have been expanded to see if something is being controlled remotely or not

carmine parcel
#

Thanks I will check what I can do from there ๐Ÿ˜ƒ

thorn merlin
#

an additional tip tho the great Mr. Michael Noland told me this on twitter - if you don't care about the locations of your bones/animations - disabling the animations of your characters will save a lot of cpu on your server

#

also if this is something on your remote clients, you could play with your replicaiton ranges to have them not show up (if all of this is for performance)

carmine parcel
#

Thanks for the tips but this is a gameplay issue, I don't want online clients to see each other unless they are in a frontal cone of each other (it is a top down 3rd person game)

thorn merlin
#

mmm thats a interesting problem, keep in mind one day you'll have the problem of simply just hiding them will be hackable, maybe playing with replication types is the key

carmine parcel
#

Yes, I thought about hiding them on clientside being hackable but couldn't come up with a better approach

carmine parcel
#

@thorn merlin Just FYI, I solved it ๐Ÿ˜ƒ Made 2 skeletal mesh for the player characters, 1 only visible to owner and 1 not visible to owner and did the exact same thing I did for the mesh owners can't see.

thorn merlin
#

awesome!

#

wish i could have helped more thats a interesting problem

wise depot
#

Yooo

#

anyone here use steam for their multiplayer?

#

if so could you please try the find sessions node?

thin stratus
#

Depends on what setup you have

#

Without Source Changes, Steam might only work with Presence based Listen Hosts

#

@wise depot

flint hedge
#

How do I get materials changes to update from the server <---> client?

#

Or for instance a door moving to update? The force update node isn't working

thorn merlin
#

i typically use some kind of flag, like a replicated enum, or a client call with that enum as the param to indicate this should happen on a client

#

replicated vars work better tho with relevance etc if its like a door

flint hedge
#

right, so I got it to update on both screens, however I've lost the ability for the client to interact with things, how would I go about fixing that?

modern fable
#

what's going on there? can't really tell cz of the quality / what are you tryna do?

#

@flint hedge

flint hedge
#

Hey, I'm trying to allow the client to open the door and have the actions from the server and the client replicated to each other. Currently the server is the only thing that is allowed to open and touch things apparently, the client seems to lose the ability to interact with things.

#

Also if you click the picture it should make it bigger?

modern fable
#

dunno, prolly phone embedding issues

#

I guesd you have a RPC on the server that the client then calls?

flint hedge
#

Well I haven't been doing any coding in C++, I've been sticking entirely in blueprinting, am I required to code RPC's and the like to set up basic multiplayer interactivity?

flint hedge
#

Awesome! Thank you so much!

modern fable
#

woops sorry, had to go afk - but pretty much that ^

#

๐Ÿ˜›

flint hedge
#

Yea I'm newish to UE4 and entirely new to networking

modern fable
#

I learned networking basics by 'following' a video series iirc

#

that compendium is much better tho, whatever you like the most

stiff wasp
flint hedge
#

I'm doing Arch Viz and want to try to be able to program functionality to allow two or more people to be in the building at the same time in VR, all I really need is the ability to drop people in the same space and have them be able to interact with the things in the map and have those interactions replicated

nocturne hedge
#

learn about basic networking and replication

#

there are few good tutorials on youtube from epic

green topaz
#

Unreal networking is conspiring to melt my brain

#

all of a sudden my characters pawn is a simulated proxy instead of autonomous proxy on my client and I have no idea why ๐Ÿ˜ฆ

jolly siren
#

is there anyway to get a simulated character from a player state?

compact oyster
#

physics replication tho

#

Kappa

green topaz
#

ahhhh didn't call Super::GetLifetimeRepProps

green topaz
#

My pawn has a child actor component, is there a nice way to have the actor that is that child actor be ROLE_autonomous proxy on the pawn it belongs to when that pawn is role_autonomousproxy? Essentially on the pawn that belongs to the local player I want that pawn to call things on its children that call server functions that belong to them

#

to give a more concrete example Im making a VR game and i have child actors under the motion controller to represent hands, when the user pulls a trigger the pawn tells the hand "hey grab something if you can" and to do that logic the hand calls Server_DoGrab...

modern fable
#

not sure what role is what from the top of my head rn, but I can tell you the child actor component itself has to be set to replicate too

#

and well, created server-side

green topaz
#

yah its replicating

#

actually now that I typed that out I think i know what might up

jolly siren
#

so, a simulated client's playerstate doesn't have an owner because the player controller isn't replicated to it. does that mean there is no way to go from PlayerState -> Character for simulated client's?

twin juniper
#

hey so guys Ive been reading this tutorial

#

i got it to host a session

#

but how do i join a session>

modern fable
#

guess that's a no @jolly siren

jolly siren
#

@twin juniper he goes over that in there

twin juniper
#

uh?

jolly siren
#

@modern fable hmm okay, but the character is replicated. so it's there, i just can't get to it from the playerstate

twin juniper
#

so like

twin juniper
#

when u call FindSessions()

#

why doesnt it return an array of sessions

#

or something like that

#

where are the sessions stored

#

lol

jolly siren
#

that's in there too

#

SessionSearch

#

They are stored in the "SessionSearch" variable we created. "SessionSearch->SearchResults" is an array with all found Sessions.

modern fable
#

is there a Get Player Character function? @jolly siren

twin juniper
#

So basically

#

i have to call

#

FindSessions()

#

first

#

then call JoinGame

jolly siren
#

yep

#

@modern fable not that I see

twin juniper
#

but i already am calling both... im calling findsessions() in my begin play and then im calling joinsession after

jolly siren
#

I can get it on owning client/server obviously. but can't figure out how to on simulated

modern fable
#

you can add a custom variable as a reference to player's character, which is kinda lame but does the job

jolly siren
#

@twin juniper are you tellling it which session to join?

twin juniper
#

im calling that function

#

that was in the tutorial

jolly siren
#

debug it

twin juniper
#

Im not sure exactly

#

how the

#

FindSessions function is finding a session

#

like what is it finding it by

#

an id?

jolly siren
#

@modern fable hmm maybe that will work

#

thanks

modern fable
#

no problemo ๐Ÿ˜„

twin juniper
#

is there a way to filter the results

#

lol

modern fable
#

filter as in ..?

twin juniper
#

like how do the sessions work

#

do they have a name?

#

a id?

#

what is the identifier