#archived-networking

1 messages · Page 46 of 1

jade glacier
#

As well has doing all of my own Time keeping since float is garbage and the internal double isn't exposed.

#

So that too... expose the internal double time for gods sake

vital hawk
#

I don't think the double precision really matters in this context

#

next frame you get new value, it's error doesn't cumulate

jade glacier
#

it does for what I am doing, because timing errors adding up over half a day mean problems for physics

#

so just to avoid that I preemptively and keeping my own time in the updatemanger

#

and a second gets the latest execution time to capture a true "Post" callback hopefully after all other scripts have finished

vital hawk
jade glacier
#

Definitely something worthy of 2 lines of text to explain LOL

vital hawk
#

if you don't know about scriptable playerloop, definitely read that blog post

jade glacier
#

yeah, that's pretty much what we are talking about

#

that all of that needs to be happening to replace all of the workaround crap we are doing right now

#

I don't want to be writing or maintaining an UpdateManager

compact bramble
#

The idea is with dots its not needed anyway I mean it's not even a compatible pattern

vital hawk
#

apparently there is PhysicsUpdate that runs after FixedUpdate

compact bramble
#

but likewise they still need to work with mono land

jade glacier
#

If we start writing in full ECS things are different

vital hawk
#

so, essentially that could be PostPhysics

compact bramble
#

There we go again the same mistakes of history :D

#

"lets add another update..."

jade glacier
#

Its not so much a mistake as I see it - its just not ECS style

#

but Unity isn't going full ECS

#

Hybrid and mono will be a thing for quite some time

compact bramble
#

well I expect it to "go full ECS" by 2022, but with a side of greasy carcinogenic mono fries

jade glacier
#

The challenge with it will be how to make that still accessible

#

In the meantime.. I'm trying to write server auth around Physx... which requires all of this bullshit

compact bramble
#

I think really most new users will migrate to visual scripting and not even want it

#

(in 2022)

jade glacier
#

That may be, they may just have to make a whole now "easy" paradigm

compact bramble
#

those who are expert will be on dots because it's illogical not

#

so beginners? -> visual scripting

#

mono will fade in time because the song will be "is it fast in mono land" and the chorus will be "no no no!"

jade glacier
#

One can hope

#

Meanwhile, I am not quite sure what my future reworking of my network lib will consist of... its all based on my own UpdateManager currently, but I would rather scrap that for built in unity

compact bramble
#

I'm playing the waiting game - decided to scrap networking in my game until a strong contender arrives - it's hardly profitable for indies anyway imo. Might do local

jade glacier
#

I write networking library stuff, so I am kind of stuck on the bubble

indigo current
#

@compact bramble I love local multiplayer but the problem I run into regularly is having enough people to play at once, and varying skill level of those that can play

#

So ultimately a list of plausible games becomes very small.

compact bramble
#

I have no friends and will tolerate none in my grim eternal solitude, as I flog myself to the grave, clutching my magnum opus.

#

(typical everyday guy, then I guess)

vital hawk
#
latent plaza
#

I was wondering what would be the best framework for doing a multiplayer action game?

compact bramble
#

ue4

#

lol

#

I'm not actually kidding - often the best decision for something is based on your needs

#

But I would use photon personally (at least until Unity becomes dotted up)

latent plaza
#

yeah, unreal is a possibility honestly, but at the start it'll be in unity at least on a proto level

#

and maybe by the time the game is worthy of further dev, unity might have caught up

vital hawk
#

I would avoid Photon personally (as I can't recommend people who refuse support you if you ask about their terms and can't tolerate it when you tell their terms are vague, it's just huge warning sign)

#

also Photon Bolt which is their most UE4 networking like product comes with closed source, so you can't even fix the bugs they have in it yourself. they also want to tie you to their Photon Cloud so you add extra dependency on their cloud solution and can't use the products without.

#

it's kinda bummer as Photon would probably have most robust networking solutions for Unity atm, why people always mess up the good things?

cosmic atlas
torn compass
#

can anyone write some pseudo code for that , i still don really get how its supposed to work, simply smooth network sync

grizzled creek
#

@vital hawk the argument they have is that, selling the package as a one time purchase was not a sustainable model

vital hawk
#

I know 😃

#

that point + their behavior makes me never consider their products tho, so they aren't sustaining their business with my support 😃

#

ok, never is a strong word

#

but not in short term

#

it's always better stay open minded in this industry

#

I also don't even buy the sustainability part, giving people option to self host / use steam is not really putting them in place where they'd have to make a completely new framework and get minimal return of investment

#

it's not about that

#

they have all that

#

they just want to force people on their cloud as it obviously makes them more money

#

they lose a lot of customers that would buy the framework with single fee but they've done the math for it being better deal to them this way

#

it's their business and their decision, but the sustainability part is really hard to believe

#

if they ONLY did one time fee frameworks and didn't additionally do the cloud, that would be totally different situation

#

but now they are forcing their users to their own cloud

jade glacier
#

Exit has titles on it that seem to be successful, so the model can and does seem to work for someone - though I obviously am not privy to everyone's financials. I think their business model is likely to become more common. Hoarding tech, and using that tech to get people into their garden. Rather than trying to get people to buy their tech - which is actually more of a turnoff for small companies, since it means a fixed cost, even if their title flops.

#

i also suspect that like with all things, private deals can be made behind the scenes if one is inclined.

#

But the basic model is "Use our tech, and if your title does well, we all do well" - the cost being a loss of upside to Exit taking a cut for inflated net costs.

vital hawk
#

pretty much yes, everyone wants their cut of your success now and it's up to the dev to judge what is worth it (and risks involved)

jade glacier
#

I think the quantity of free libraries lead things there. You either have to ding people up front the old way with one off software costs or on the long with a cut of success stories. Since the Unity market is largely dreamers and learners - most aren't willing to really risk the cost (which is why they are using Unity for free).

So I kind of think that the new playing field of free everything will drive success-based revenue models more and more as well.

split crescent
#

only so much pie to go around

#

30% platform cut is the elephant in that room tho

sand lotus
#

you could just demand a cut if company earns above x ammount.

split crescent
#

yeah thats a fairly popular model

jade glacier
#

I think with networking libraries like Bolt fholm mostly found that the money was hardly worth the work put in. Bolt produces more money as a honeytrap than as a one off purchase. That and you can generally feel better about not charging people $100 up front for software they likely will never make a dime on.

#

@split crescent That Unity fails to supply a real viable networking library is what makes their 30% problematic

sand lotus
#

unity should just finally put a big team together the size of SRP and make a proper build in networking solution

split crescent
#

first they need to deprecate the one they have in preview

#

as is convention

#

😄

jade glacier
#

Just release everything networking in deprecated form yeah.

sand lotus
#

yeah the current "new" multiplayer repo is trash

jade glacier
#

Its still just the transport no?

sand lotus
#

simple wrapper around native UDP sockets

#

without any reliablity protocol

#

and some shitty examples

#

and then slapped jobs on top of it

#

and call it scalable (which it isen't )

jade glacier
#

Jobs is pointless at this point

#

no one is shipping anything with it

#

much less some monstrosity that needs threading

#

I get that its their mandate though, that everything made fit into that future

sand lotus
#

Networktransport slapped in jobs is idiotic, the OS socket isen't multi threaded.

jade glacier
#

but its going to hold up progress waiting for dots to be ready for the average user

#

I think the keep failing to recognize what a black eye networking is for them.

#

Having your one built in library be abandoned and deprecated for years... is hardly something a top tier game engine should really find acceptable

sand lotus
#

welcome to unity

compact bramble
#

The gaffer on games thing is exactly why physics can be deterministic going forward as well as back, but it only works up until the interference and he does cover that scenario. I don't know why people got annoyed with me on forum when I tried to point out this being a pretty cool use case of determinism across different cpus (something that unity's networked physics will have by default)

#

Obviously it's not for all games

#

But it's really exciting that dots has the performance muscle to rewind this state so when interference does happen, the sim can be kept deterministic

jade glacier
#

@compact bramble 2018.3 does act deterministically, I have resim working with it

#

Hard to make out what is going on here, but the right screen is the owner client simulating inputs, and the left is the server. This is 20% packetloss - when the client gets and desync from the server, it applies the servers RB values to a copy of the player in a lightweight second physics scene, reapplies all of the inputs, and copies the results back to the primary scene, and it is back to 100% deterministic until another desync is forced.

#

I've been trying to get back to finishing up a good working demo of it, but have spent the last 2 weeks trying to fix old assets because of what Mirror broke on everyone. 😕

jade glacier
#

I will set up a proper test over the next few days, but this is the client spawning a bunch of server authority objects. The sprout a white bars when they are out of sync and are not 100% deterministically in sync with the server - which only happens when I force a desync, and they immediately resimulate back into agreement. No idea about cross platform since this is all float based - but so far the tests are working.

split crescent
#

nice!

jade glacier
#
PhysX guarantees the same simulation result when all the inputs are exactly the same. However, many things are considered “input” from the perspective of the physics engine. One such thing is the physics scene itself. Before 2018.3, it wasn’t possible to destroy the implicit physics scene. One could only destroy all the objects in it, which formally wasn’t enough. With multi-scene physics, this is easy to work around. However, another frequent issue was that adding a new body located somewhere far away and seemingly not interacting with the other objects also had the potential to change the simulation outcome. That was because of the way PhysX in Unity grouped objects internally. This is now possible to overcome by enabling a special option in the physics settings. It’s not free in terms of performance, but it shouldn’t slow your project down significantly.``` What that means for crossplatform.. vague
compact bramble
#

it just means that different cpus will not be deterministic but unity's burst compiler will make sure (if you want) that some floats can be deterministic

#

some not all because there is no point in having (a small) overhead if you don't need it

#

likely i will make a clear separation between network+physics and local+physics

#

so things that are gameplay basically

#

the idea that determinism is possible on different cpu architectures is not a new one but people dont usually do it

thing is though with streamed gaming or cross platform multiplayer, this becomes more important i suppose

sand lotus
#

@jade glacier from my testing physix in unity is completely deterministic on same arch

#

meaning intel cpu's from various generations ( 2012 and up) and windows 10

#

I have not tested amd

vital hawk
#

that physx thing only makes totally unrelated simulation play the same way on same cpu architecture regardless if you add or remove physics bodies etc during the simulation

#

it's just guaranteeing that the internal simulation order doesn't change

earnest wave
#

hey yall i'm looking for resources to help figure out how much bandwidth PUN is using at any moment, bonus if it can tell me specifically what RPC's and observables it's updating with that bandwidth

#

can anyone nudge me in the right direction on that? thanks

proven shale
#

what does PhotonNetwork.CacheSendMonoMessageTargets do?

ruby trench
#

Hello everyone, I've got a question that's not exactly related to Unity. I was wondering if someone could give me a hand. I'm looking into hosting a small perforce server on a cloud solution so I can work on my project and version control from anywere. The thing is that I know very little about servers and I looked at Google Cloud, Azure and AWS and they offer dozens of solutions, some pricy, some less. I am not sure what kind of solutions I should look into for the needs of a Perforce server.

ruby trench
#

Nevermind, I found how!

#

I set up a perforce on a small AWS server, it wasn't difficult!

jade glacier
acoustic jungle
#

Hey, i am currently using UNET for at school project ( I know its being deprecated, but i don't have time to switch), and i am having a problem with a client not sending the Cmd to the server.
The structure i am using is client-host.
The problem happens when the server does a scene change. Before the scene change i can send cmd's just fine, but after i can't.
Any ideas to what the problem could be?

lusty crow
#

maybe your network manager is a scene object and does not persist across scenes

#

does it have DontDestroyOnLoad

jade glacier
#

Generally NM sets itself to not unload on scene change, but worth looking to double check that

lusty crow
#

also, maybe there might be a hickup or inresponsiveness during a synchronous loading of a scene (I am not so sure how to handle that one either)

jade glacier
#

The object you are trying to send that command through still exists in both scenes?

lusty crow
#

I think an async load also caused me issues

jade glacier
#

Command is generally frustrating and annoying because of the dependence on an object with authority

#

I pretty much abandoned Command and RPCs about a week in to using UNET in exchange for MessageBase

#

@acoustic jungle

#

Drive by help request I think 😃

acoustic jungle
#

Right.. I am also getting increasingly frustrated with UNET, am this is definitely the first and last project i am creating with it.. I can try out this MessageBase thing. Is it easy to get into?

#

And yeah they do have DontDestroyOnLoad on. The weird thing is that it used to work, but suddenly stopped. I have no clue why

#

And i can see the objects in the hierarchy

#

@jade glacier @lusty crow

jade glacier
#

All of the HLAPIs use some form of RPC/Command/Syncvar system - they are just prone to tying your hands like that

#

Phase 1 of networking... RPCs and Syncvars
Phase 2 - messages with your own handlers
Phase 3 - dropping all of that and serializing your own byte[]

lusty crow
#

No idea about message base, I only have a bit experience with LLAPI unet,

Mirror (and I think some people were mentioning Telepathy (which does tcp connections)) are valid replacements for Unity UNET

#

just to give one example, Mirror I think does some of the higher level rpc stuff,

for lower level stuff, there are a lot of frameworks out there

acoustic jungle
#

How much of a hassle would it be to convert my project from UNET to Mirror, and is it worth it?

lusty crow
#

¯_(ツ)_/¯

#

but maybe sb. knows

acoustic jungle
#

sb?

#

Who dat

lusty crow
#

I still can't believe that this is not a common abbreviation?
somebody

acoustic jungle
#

Oh lol

lusty crow
#

apparently it is not, because so many people seem to be confused about it ^^

#

also, depends on the size of your project I would say, I don't know about all the high level networking stuff though,
if you were merely making connections and send bytes over some channels, that would probably be easy to port over

acoustic jungle
#

It's a pretty small project. I just have a Lobby and an arena, where players throw bombs at each other.
I can see that Mirror uses a lot of the same terms. So i might give it a go

#

They even have a migration guide

jade glacier
#

Generally when using HLAPIs I would try to avoid making use of the RPCs and Syncvars like @lusty crow is hinting at. I like the HLAPIs just to avoid dicking around with setting up connections and creating networked objects. I use the NetIds of like UNET and PUN, but do little else with the HLAPI. Everything gets sent as byte[] that I serialize and deserialize myself, which makes it a MUCH easier port.

gray pond
#

@acoustic jungle Mirror has a migration tool from UNet

#

the outward facing API is mostly the same

#

mostly the inner workings are vastly improved, add'l features added, UNet bugs fixed.

acoustic jungle
#

@gray pond Yeah i have tried using that, but i can't get my client to connect to the host.
What i did before was just this:

    NetworkManager.singleton.networkAddress = ipAddress;
    NetworkManager.singleton.StartClient();

And i gives this error:
Client Recv Exception: System.ExecutionEngineException: String conversion error: Partial byte sequence encountered in the input.

gray pond
#

with Mirror or UNet?

acoustic jungle
#

With mirror

gray pond
#

what are you using for ipAddress?

acoustic jungle
#

Just "localhost"

gray pond
#

come to our discord and we'll help you, please

acoustic jungle
#

@gray pond I'm a bit of a discord noob. How do i find your discord?

gray pond
#

sent PM since this server doesn't allow discord links for whatever reason

indigo current
#

@gray pond Does Mirror have match making like Photon PUN does?

gray pond
#

@indigo current We do not offer back-end paid services, but we're generally compatible with the common ones like GameLift, PlayFab, et al.

vital hawk
sand lotus
#

I was sure unity hired the wrong people to make the networking stack. But that they don't even know what UDP stands for is just outright shocking

#

When will networking finally become a first class citizen in unity like it is in unreal?

#

SRP is great Team. Ecs too. Why invest nothing in a good network stack?

#

This is really a joke

#

We get a depricated llapi and hlapi. Which I understand it was bad.

#

The replacement is worse

#

We get a unreliable transport implementation

#

Which is a very bad one and simply a wrap around native sockets

#

Without reliability protocol

#

And the project is dead for 6 months

lusty crow
#

I haven't watched the video, but I would assume that often the people holding the presentations are not the main programmer/member. networking will probably come (slowly), but probably also will still take many months or even a few years until there is a proper library, right now it seems too low level

#

I know someone who is making a wrapper with channels for the lib, I am excited to see it if he intends to release it to the public one day (not sure)

sand lotus
#

I understand the person presenting it is not working on it , but that is unity's mistake.

#

but the main problem is the actual code and lib given to customers

#

it's utter crap

#

For what it is it has way too much code, and wrong standards to build networking on any scale

#

it is like it's build by somebody that knows nothing about networking, nothing about operating systems, and nothing about how to make scalable games

#

this team or group that knows a lot about C# or something made a wrapper around native socket interop, slapped unity jobs on it and called it golden

#

it's really a joke.

#

i don't recommend ANYONE to implement it in their games.

lusty crow
#

I heard that they might spend too much on PR, marketing and not enough for the core team and that is why progress in some areas is super slow

#

I think they had at some point like 2 or 3 people working on the new input solution, back in 2015, then later they scrapped it, but now they continued to develop it fortunately

#

the other thing is that Unreal knows first hand how to make scalable games because they made some themselves with their own engine

#

Unity, while they make some impressive demos, mostly looks like a company that develops a product for customers. Nothing wrong with that.

#

I really don't know anything about the new transport layer solution, but I believe you, from what I heard it is pretty barebones atm

sand lotus
#

not just barebones

#

it is even a very bad solution for what is there

#

you are better off with simply making a standard C# udp socket in your application and have same functionality as what this thing now provides, and it performs better probably too.

lusty crow
#

I'll decided to use LiteNetLib for my current project, but haven't really tried it yet

#

luckily there are at least many viable alternatives for networking with unity out there

sand lotus
#

litenetlib is great

#

shoulden't have a problem with that.

lusty crow
#

awesome to hear that! 🙂

weak plinth
#

hi all. i'm having issues connecting to our own WSS server. I can connect to say wss://echo.websocket.org, but when trying our own server, it fails to authenticate in unity. with a browser it works, but not in unity. It also seems that I cannot get it to even connect at all on an editor running on a Mac, only on a windows one. I'm using the ninja.Websocket code that mirror uses.

#

does anyone have a working WSS solution, cross platform?

vital hawk
#

I'd love to get others opinions on the new networking thing, I mean beyond it lacking high level components like seen in HLAPI

#

I constantly see Vincenzo trashing it but haven't seen others complain about the actual implementation (only about functionality)

#

if I remember right, @graceful zephyr didn't think it's all horrible(?)

graceful zephyr
#

the networking repo they put up a while agO?

#

like a few months?

vital hawk
#

FPS Sample and new transport basically

#

I mean, there's nothing else

graceful zephyr
#

the fps sample is great

#

but it's not a generic library in any way

vital hawk
#

yeah, that's fine

graceful zephyr
#

the new transport is like 1200 lines of C# or something? it's nothing

#

its like 10 C# files in source code

#

with a few hundred lines tops in each

vital hawk
#

and yeah, I know most people wish for some more higher level generic solution, but that's another thing

#

afaik, there weren't any major news on this front at the GDC

compact bramble
#

yeah basically seems dead (tm)
-- 13 year old using unity

sand lotus
#

yeah i also think they scrapped it

compact bramble
#

again?

#

2x scrappage?

#

it's fine though so long as everything is on fire since at least we're warm

sand lotus
#

maybe unity would properly invest into networking like they did into ECS and SRP that would be great.

#

by the looks of it big AAA are going for Unreal/lumberyard etc because of networking

vital hawk
#

but then again that guy trashes almost everything

sand lotus
#

His comments here are very valid I would say.

vital hawk
#

I mainly see a lot of speculation on the post you referenced

sand lotus
#

read the whole topic perhaps

vital hawk
#

but it's all written by the person who I tend to ignore on the forums in the first place

#

as he's literally unhappy with everything

sand lotus
#

Alright. as you wish

#

would you say the multiplayer package unity posted in that repo is great?

vital hawk
#

no

#

I haven't used it or gone through the code myself, I don't have first hand experience on it

night radish
#

I don't remember where but I think I saw a post saying they were working on reliability and other basic features on a private repo but yeah the current networking package is a barebone wrapper on top of sockets

tired hound
#

I wish they had more time to go over the actual architecture rather than whatever transport they use. I don't care how you find errors in UDP, I care about networking my game. Some other library can do the transport part for me

#

it's so hard to find any resources on this stuff

jade glacier
#

Where Unity keeps failing with networking imo is extending any library into a set of drag and drop components, which is what most people really want. What NetworkTransform wanted to be is what typical unity users are looking for. Though I think they always had plans for that, just their networking projects implode before getting that far up the API

jade wharf
#

they need to make things more obvious with the transforms as well

#

you wont believe how many times people put network stuff on non-root objects

nimble berry
#

Seems to contain some more changes: "Showing with 17,567 additions and 991 deletions. "

void idol
#

Well, im not sure on how Unity's network API is going but last time i had searched something it was turning out obsolete (UNet), and now i need to use some HTML requests (get, post) and etc... Can someone give me a "light" on this? Like, it still possible retrieving/sending information from/to a server as HTML (Form)?

nimble berry
void idol
#

Thanks! Never made something online with Unity and probably i'll need to do a online quiz now

#

i'll need to retrieve quiz from server and send answers

nimble berry
#

Just use the WebRequest and some json, shouldn't be too hard 😃

void idol
#

Any good performance ideas on this? like, its better sending all needed information to client and grabbing only the result or its better doing an real time data transfer?

#

Yeah, was thinking on JSON data

#

I'll need to access an remote database, grab info and send it back

#

well, thanks @nimble berry

vital hawk
#

(the mentioned commit)

#

support for network pipelines, whatever they are

night radish
#

I'm glad they made that update but having that being a dump of code with no roadmap whatsoever and no visibility made my team lose 2-3 months of work

vital hawk
#

I agree on the tranaparency

#

Dots roadmap talk was a huge letdown

#

Guy who spoke there were proud how briefly he got it covered

#

Yet not much new info was given

undone sigil
#

the funniest thing is that their "wrapper on sockets" needs twice as much code as ready libs with reliability 😂

night radish
#

Well that update isn't just a wrapper on sockets anymore since it has a first iteration on entity replication, rpc, interpolation and reliability. While you may think it's not enough, it's already more than ready libs since it's things oriented to help you make a game (IMO)

stray scroll
jade glacier
#

@stray scroll

night radish
#

"Updated on Jan 24"

#

Also I don't get why we have access to release but not on going dev, I agree with the logic that they don't want to give constant support for a dev git branch for example but at least giving us access while saying there will be no support is a lot more helpful than a barebone package updated every 3 months

#

Example of what I'm saying, there is a few things in the current update that are not final or the "good way" to do it, we know it, they know it. But not knowing exactly what will change and on what we can rely on is making working with this package harder than it should

azure quail
#

how did it make you lose 3 months of work

night radish
#

Basically doing reliability on top of that and a few iterations on entity replication. While it was written that they were working on it, we could have used more smaller updates even if wasn't finished. We knew we were going to throw that work in the trash sooner or later but the lack of visibility is making us choose between doing it ourself or waiting for updates

undone sigil
#

why would you want to use that at first...

night radish
#

That's another subject of discussion and I won't start it here as it depends on context, a few factual arguments and a lot of biased ones

#

Again, I'm happy with that update but it's still frustrating

compact bramble
#

they did say transparency was so important over and over

#

i was the first to hit them with the transparency demand when they announced they would be making a new network lib

#

they did promise transparency in writing on forums

#

so far? very little to none.

#

virtue signalling, that's all.

#

can prove otherwise with actions.

#

so far no action has proved otherwise.

#

Some areas of unity are very helpful, such as terrain or graphics or dots teams, these have all been forthcoming and help avoid pitfalls of redundant work

#

but networking team, I think probaby are too busy

sand lotus
#

It is disappointing again.

#

This would create a pipeline with just the reliability pipeline stage present, and initialize it to a window size of 32 (so it can keep track of 32 reliable packets at a one time). The maximum value for this is 32.

Because only 32 packets can be tracked at a time there can't be more than 32 packets in flight at any one time, trying to send a 33rd packet will result in an error and it will not be reliable (no guarantee of delivery).

#

For instance

#

😂

graceful zephyr
#

The new networking update on github is solid, i think their reliability pipeline is just an example and not intended for production (?), read through all of the source changes, a lot of refactoring/renamings + the pipline concept, and some updates to the native libs. They are not doing anything 'wrong', the lib looks solid - but it's still so early I'm not sure who this library is intended for.

undone sigil
#

@graceful zephyr weren't they supposed to have high level API ready for 2019.3?

graceful zephyr
#

I doubt that will happen to be honest

undone sigil
#

If that's still the plan, i'm 90% convinced this would be the final version

graceful zephyr
#

The library they have on github now, i.e. bascially socket/transport

#

Is nowhere near finished

#

It's not bad in ANY WAY, it's in fact pretty well crafted and thought out

#

But it's still pretty early in development, and missing a ton of features

undone sigil
#

Yep, but i'm slightly worried they may say it is, due to lack of time 😂

jade glacier
#

@graceful zephyr Heya btw, been a long time

paper stone
#

Hey guys, anyone could give me a tip on name of architecture for splitting servers (login and game servers)?

#

Do i need to use TCP sockets to connect between these servers?

#

for example database server which asks game servers for data of actual active players within game servers

graceful zephyr
#

@jade glacier hey o/ yeah i've been staying off discord for a while

#

just too much noise at times

surreal blade
#

Hi there, is there anyone with games released with online gameplay happy to share how much bandwidth they use please ? (in/out ideally)

jade glacier
#

@graceful zephyr No worries, just throwing a wave out since its been ages.

gray pond
#

@surreal blade You really won't learn anything from any answer any of us could give, because every game has different messaging requirements. If you're doing a turn-based card game, bandwidth usage of an FPS tells you nothing helpful, for example.

undone sigil
#

is that helping you? 😄 (20 players, FPS with VoiceChat)

surreal blade
#

@gray pond Thank you but yeah I would definitely learn things because I would expect to also know the type of game the people answering are talking about!
Also sorry I didn't specify but I meant bandwidth per second

#

If for example, people have shipped games with not many people complaining with an average of 80KB/s I can know that it's an acceptable target and not worry for reaching 10KB/s

gray pond
#

Even so, there would be a wide difference in bandwidth between games that are quite similar, just on CCU alone, whether one has voice chat, maybe one is more prone to have idle players, etc.

surreal blade
#

Yes of course there are differences, but that's what a benchmark is.
Thanks @undone sigil by the way!

proper olive
#

Hey all. Not sure if anyone would be able to help me with this. But I have an issue when running a TCP Socket Client from an IOS device. I'm running the server on my local desktop on port 80. (Also tried port 8052) When playing in the editor both the client and the server have no issues communicating and connecting to each other. But after I've built out for IOS from XCode my networking code seems to just stop working. I'm not seeing any errors or strange messages in XCode console either. I'm not sure if someone has run into this in the past, but I would love some help.

jade wharf
#

Xcode? In unity?

#

Check to make sure whatever Xcode built for you is actually in the client that package

vernal remnant
#

It’s not in unity, the build process creates an Xcode project file that you have to then build for iOS.

@proper olive are the permissions set in the plist? I believe some of them have changed if you are targeting 12+

shrewd kraken
#

Been catching up on messages over the past week. Someone keeps insisting that the FPS example is somehow a dead project based on the gitHub repo.

Seriously, in the project .readme it says this this just the public repo that gets updated when the finish a branch. They are using a different source control for day to day development.

vital hawk
#

people always talk crap, there's no way around it

#

if update doesn't land in 1-2 months people tell it's dead

#

but that's definitely not what Unity is messaging about the FPS Sample

proper olive
#

@vernal remnant Thanks for the help. Though I actually ended up resolving this one on my own lol. I using the wrong port number on my mobile app. Stupid mistake.

weak lava
jade glacier
#

won't play as a video for me, but the first question is what are you using for buffering/interpolation, assuming this is networked

#

@weak lava

weak lava
#

I linked my script above. Using positions,rotation and timestamp for interpolation. My Statebuffer saves 20 states and interpolates between them. And yes, Photon Networking.

#

@jade glacier

#

I read through some articles which mentioned to increase the statebuffer to save 30 state and play with the interpolationBackTime which is at default 0.1. Not sure if this solves the problem. Also I read something about a hermit interpolation anyone got some more information about this?

jade glacier
#

you don't need that many frames in the buffer for smoothness, generally you only need a buffer of one or two frames and one extra that is mid interpolation. I can't see the video so I can't see how jittery things are.

#

That buffer code looks a bit suspect, its not quite a ring buffer there.

#

using network time of any kind I am not a fan of. Generally I always put my simulation on the Fixed timing, and I draw from the buffer on the fixed timing as well.

#

Otherwise things get a bit timey whimey

#

I generally don't use OnPhotonSerializeView for transform syncs, I use my own timing singleton that is based on FixedUpdate, which commands all net objects to serialize to a master byte[], and that gets mailed off on a regular fixedDeltaTime rate. @weak lava

weak lava
#

Gonna check it out, thx so far @jade glacier

indigo current
#

I've only seen issues with transforms skipping when rpc calls were being abused

solar garden
#

@jade glacier i see you everywhere 😄

jade glacier
#

@solar garden I'm in most of the networking chans yeah

weary walrus
#

o/

weak plinth
#

eeh, to be fair, unity was messaging that unet was fine and under development until we learned that only 2 devs were actually working on it

#

then it got deprecated out of no where

#

I can totally understand the concerns about the new networking

#

especially after they reinstated LLAPI in a hurry after they deprecated it

vital hawk
#

I dunno about the last point

#

it just tells they do listen to feedback

#

basically now they have to give the old system support for longer than they initially wanted to

#

but deprecating a system when replacement isn't ready is pretty shortsighted alright

jade glacier
#

There was no reason to put the System.Obsolete tags into the HLAPI

#

That was just hubris

verbal sandal
#

Hi guys,

im using photon server for a game i'm currently developing, but i have a problem with packets coming in faster or later than other packets.
I use tcp as the communication protocol , but not any queueing at the moment to wait for each packet individually.

Is there any specific way how i can wait for packets to be received before other packets are received?

Thanks in advance!

#

The reason for this is that only sometimes i get errors on specific code for packets which should be executed after another packet..

#

Im using the PhotonPeer

undone sigil
#

@verbal sandal doesn't TCP have sequencing?

verbal sandal
#

@undone sigil i thaught so too, but still it seems like packets are received earlier than other packets

undone sigil
#

@verbal sandal yeah, i've checked and it is, there is no possible way you can get packets out of order

#

Probably Photon is fucking with them

verbal sandal
#

@undone sigil or its something with unity, i have a packet which removes an monobehaviour and adds an new monobehaviour

#

however, in the next packet im trying to use that new monobehaviour

#

but it seems like the old monobehaviour still exists

#

maybe it has something to do with the next frame, im not sure..

jade glacier
#

@undone sigil TCP IS sequencing, to a fault

#

Photon has a TCP option?

#

I thought their orderered reliable was just RUDP ?

verbal sandal
#

yes they have tcp

#

they also have reliable udp yes

#

but im using tcp

jade glacier
#

Definitely should be arriving in order then, if not I would ping @stiff ridge about it

#

Any reason for TCP rather than RUDP (as an offtopic)? @verbal sandal

verbal sandal
#

Uhm well , just to be sure that all packets are received @jade glacier

#

I dont know if RUDP is really thát reliable

#

in a production evironment

jade glacier
#

It is, just a different mechanism that is less likely to congest quite as badly

verbal sandal
#

and why is that?

jade glacier
#

TCP is hardcoded at the hardware level for how it creates headers and how it deals with lost packets, and it didn't make any of those handling choices with games in mind. It was for reliable things like loading web pages.

#

RUDP is software level, so it can be way more flexible and less bloated in how it deals with lost packets

#

I haven't personally dealt with it, but I would think one example of TCP failing is will send a packet, and wait for an ACK I believe before sending the next, so it can really get hung up on lost packets doing resends.

#

So my understanding is that in an RUDP, while its waiting for an ack, it can be sending the next numbered frame... and if that earlier packet never acks back... the originator can THEN resend it. Meanwhile, the receiver isn't twiddling its thumbs, its still getting the later packets, and just needs to hold them in limbo until the earlier missing one arrives.

#

I am no transport expert, but that is my understanding of the kind of advantages RUDP gives for gaming over TCP

#

What we need is a different type of reliability. Instead of having all data treated as a reliable ordered stream, we want to send packets at a steady rate and get notified when packets are received by the other computer. This allows time sensitive data to get through without waiting for resent packets, while letting us make our own decision about how to handle packet loss at the application level.```  That sums it up better than how I was saying it I think
verbal sandal
#

Alright, thanks for your help man. Is it okay if I try to use rudp tomorrow and get back to you?

jade glacier
#

Personally, I always just go fully unordered unreliable and number my frames in a circular buffer, since I work to make my simulations tick based

#

Going full unreliable means you can make use of the data even if there are holes in it

#

if I am on frame 5, and I get frame 7 ... when it comes time to render frame 6 I can recreate it by tweening 5 and 7

#

rather than just having 7 held up in the ether without me being able to see or use it.

#

@verbal sandal You don't need my permission for any of this LOL

verbal sandal
#

Nah I know but I'll see if it changes anything @jade glacier

indigo current
#

@verbal sandal hey, photon networking has RPCs, which guarantees packet order and delivery.

#

They are expensive though.

#

but its still better than using TCP. So Id recommend UDP while using reliable packets when required.

jade glacier
#

You are welcome to drag in the package and try the example scene with PUN (pun does require a switch over in the settings)

honest maple
#

wow that explanation quote from the article explained it really well.

verbal sandal
#

@indigo current yeah i'm giving reliable UDP at the moment

#

seeing if that works fine and does the job

#

so far so good

stable cairn
#

Yo! Updated to the latest of Unity 2018.3 as well as the new Multiplayer Transport package, and I get this exception:

#

Just wondering if anyone else has the last of the transport package and can let me know if this is a bug with the package or if it's something I may've done wrong, since the exception is caused during some DefaultPipeLineStageCollection compilation.

verbal sandal
#

@stable cairn in the repository they say this:

#

Make sure you have a supported version of Unity (2019.1 or newer)

#

maybe consider upgrading unity to 2019.1

stable cairn
#

Damn... I was hoping to avoid that, just ported to 2018.3 and was hoping to stay that way until 2019 reached a steady configuration. Thought networking was supposed to be part of 2018.3 as well :S Really gonna need that reliable pipelining tho.

#

Then again, my game works atm, so it doesn't seem to be very critical yet.

verbal sandal
#

2019.1 is officially released @stable cairn

#

If you did not know that

stable cairn
#

Yeah, but it's the constant stream of minor updates that is a bit tedious for my programming team, so prefer to not have a "0f2" versions atm.

undone sigil
#

@stable cairn please don't use unitys networking stuff, that's terrible

stable cairn
#

Well I got high expectations for the new multiplayer 😉

heavy rapids
#

Hey all, I have a game that is LAN only and currently have all my VOIP functionality done thru RPCs and CMDs. Now I've had this for months and at first it was a stutter mess. Now after tweaking it and making a bigger buffer before sending, it is pretty decent. However it still stutters and for what I am accomplishing, voice quality needs to be as good as possible (especially since every user will be always in the same building <1 ping)....

Is it worth just purchasing something like this https://assetstore.unity.com/packages/tools/audio/dissonance-voice-chat-70078

I have been eyeing it for awhile and while I know it will work, I'm not sure if the reimplementation of the current VOIP system is worth it. I think so, but if theres a smoking gun for clearing the stutter, then I think thats my best option.

I currently just pack all sound data from the mic.getdata() into a byte array and send it via CMD and then back to clients via RPC. The input sits in a coroutine on a yield waitforsecondsrealtime for .2 seconds and then it checks the push to talk key before sending the buffered data.

Any advice?

Dissonance makes it easy to add real-time voice chat to your game.

  • Simple drag and drop setup - no scripting required.
  • Works with any network system.
  • Great audio quality, performance and compression with the Opus codec.
  • Positional/Spatialized audio playback ...
heavy rapids
#

(Also might use the Opus codec as I think I need to NOT fragment my packets and I cant do that as currently it sends way too many bytes)

true juniper
#

Hey @heavy rapids I'm one of the devs for Dissonance, I can answer any questions you've got 😃

#

Basically there are a whole bunch of problems with your current approach. For example if the mic is not recording data at the same sample rate as your playback system it won't work (unless you've got resampling in there), you really want a dynamic jitter buffer to buffer the minimum amount of audio (low latency) but not too low (can't handle jitter), raw mic audio generally sounds really bad so you want noise suppression/gain control/echo cancellation to clean that up.

heavy rapids
#

Hm okay great thanks for the explanation! @true juniper

So, if I were to purchase Dissonance, does it have support for the host/server also talking? Our system works with a host and multiple clients. The host has the ability to talk to anyone and I'm sure it works, but just want to clarify since most probably only have the clients communicate. Thanks!

#

@true juniper If that works and I can have users listen/connect to multiple chatrooms and have the ability to mute certain people ect, I will buy this right now.

true juniper
#

@heavy rapids You can start Dissonance either as a Host (client and server) or as a Dedicated Server (no voice audio at all, just networking).

#

You can have up to 2^16 chatrooms at once, you can mute people or individual incoming channels (e.g. mute the global room, but not the team chat room)

heavy rapids
#

@true juniper well perfect then! Looks like you've got my money. Thanks man

true juniper
#

Thanks 😄

solar garden
#

any ideas how i could have a shotgun shooting the same random spread on each clients ?

jade glacier
#

are you using any kind of frameid for your network messages? @solar garden

solar garden
#

no 😦

jade glacier
#

For mine, I have numbered frames, so I use the frameid for each tick as the seed. Otherwise you may just want to add a byte for a seed to your write

#

That will get you 256 different patterns

solar garden
#

i'd like to have tick system 😦 i dont have one but some guys told me a good trick, i have a shotgun with a for loop for the spread, the trick is since i use random floats for the spread i can use Random.seed() to have it being the same partern for every client but it doesn't work as intended thats why i though that using RPCs would solve the problem thinking that the call would be the same over the network

#

thats how my shotgun looks like

    void Update()
    {
        if (networkObject == null) return;

        if (fireTimer < fireRate) { fireTimer += Time.fixedDeltaTime; }

        RaycastHit hit;

        if (i.isShooting)
        {
            for (int i = 0; i < pellets; i++)
            {
                float spreadX = Random.Range(-maximumSpread, maximumSpread);
                float spreadY = Random.Range(-maximumSpread, maximumSpread);
                float spreadZ = 0f; //Don't adjust depth of spread.

                Vector3 spread = transform.TransformDirection(new Vector3(spreadX, spreadY, spreadZ));
                Vector3 direction = (transform.forward + spread).normalized;


                //Vector3 direction = Random.insideUnitCircle * spread;  THE OLD WAY
                if (Physics.Raycast(transform.position, transform.forward + direction, out hit, range))
                {
                    Debug.Log(hit.transform.name);
                    Instantiate(impact, hit.point, Quaternion.LookRotation(hit.normal));
                }                
            }
        }
    }```
jade glacier
#

How are you transmitting weapon fire right now?

solar garden
#

well its kinda bad if im honest i have this Input manager that is on every player but that detect if the player is the owner and able to use the input the other local player prefabs just wont use the inputs

public class Inputs : PlayerBehavior
{
    public bool isJumping;
    public bool isAiming;
    public bool isShooting;
    public float vertical;
    public float horizontal;
    public float mouseY;

    private void Update()
    {
        if (networkObject == null) return;

        if (networkObject.IsOwner)
        {
            horizontal = Input.GetAxis("Horizontal");
            vertical = Input.GetAxis("Vertical");
            mouseY = Input.GetAxis("Mouse Y");
            isJumping = Input.GetButton("Jump");
            isShooting = Input.GetButton("Fire1");
            isAiming = Input.GetButton("Fire2");

            networkObject.horizontal = horizontal;
            networkObject.vertical = vertical;
            networkObject.isJumping = isJumping;
            networkObject.isShooting = isShooting;
            networkObject.isAiming = isAiming;
        }
        else
        {
            horizontal = networkObject.horizontal;
            vertical = networkObject.vertical;
            isJumping = networkObject.isJumping;
            isShooting = networkObject.isShooting;
            isAiming = networkObject.isAiming;
        }
    }
}```
jade glacier
#

How are you transmitting that? RPC?

solar garden
#

err unreliable fields through the NCW

jade glacier
#

Not familiar enough with NCW to know how it times those and such, but I would say add a field for a byte that you can make the seed, and random generate that seed on the client and everyone can use it

#

Its a bit of a waste of space, but you already have a bloated non-bitpacked pile of data there anyway... no point getting frugal now

undone sigil
#

NCW?

jade glacier
#

Contract Wizard

#

its a forge thing

#

Basically you define structs in advance for what I believe is code gen

#

And it handles a bunch of the networking based on them

solar garden
#

"bloated non-bitpacked pile of data there anyway... no point getting frugal now" 😂 i am a beginner im sorry

jade glacier
#

Yeah, don't sweat efficiency yet. Add a byte and have the client generate a random seed from 0-255

#

and send that along with the input struct

#

have the networked weapon fire use that value for their seed as well

solar garden
#

being a unreliable field wont cause a problem of sync at some point ?

#

well i guess i dont have the luxury to care 😄

jade glacier
#

you need sync of your seed if your weapon fire gets lost?

#

They go hand in hand, so not sure why it would matter

#

if that input gets lost, the server is going to say the gun didn't fire

#

the seed and the fire event are entwined in one struct this way

solar garden
#

oh ok

jade glacier
#

it won't matter

#

don't seed the client, it needs to come up with a normally random value

#

oh yeah, for what we are doing on the other end yes

#

you stick this networked value into that right before the shotgun spread uses random

#

on the player side though you will want to randomize the seed probably though before picking the networked seed

#

You can randomize it by seeding with like Time.time

solar garden
#

Time.Time is a int ?

jade glacier
#

I'm sure there is a better way, no idea. google that

#

no, you would have to do some stuff

#

Just google the best way to reshuffle the randimizer

#

I just don't know off the top of my head

solar garden
#

its ok thanks a lot

jade glacier
#

np

simple sparrow
#

I assume this is where I can talk about PUN yes?

#

the Photon animation view

if I were to have something like a floating platform, where the platforms position is controlled via the unity Animation Controller system and an animation clip.
Attaching the PhotonView and PhotonAnimatorView to the object, to me, this makes me assume that the platforms position will be syncronized across all connected clients.

But it doesn't every client is different.

What am I missing?

indigo current
#

@simple sparrow

#

the animation view does not sync transform positions.

#

it syncs animation states.

#

if the animation timing is out of sync at all the platform wont align properly.

#

you should be using a photon transform view. this assumes youre animating the parent object (which is a bad idea in general).

vital hawk
compact bramble
#

DO TELL

#

smoothly moves toward unity networking

indigo current
#

hippocoder used SmoothDamp. -- It was highly effective.

lean onyx
#

What are pros and cons between dark rift networking and mirror networking for a ~100 CCU MMO?

cosmic atlas
#

I haven't heard bad things about either, so probably just try one and see how it goes @lean onyx

#

compare their methods for your own tastes

gloomy axle
#

@lean onyx I haven't looked at dark rift networking at all, but Mirror might be good to go with because there are example MMO assets on the unity asset store

warped goblet
#

hey guys, I am having a hard time with the UnityWebRequest. I want to use the Get method to retrieve some objetcs ( a hashset of a custom class) from our rest api, but i also need to send data to the server used for a query. The api expects json data however the uploadhandler only works with byte arrays(?). But when parsing the json to byte[] and sending that to the server i always get the response that the request could not be parsed correclty : "Request finished in 681.2597ms 400 application/problem+json; charset=utf-8" Anybody knows how to handle this issue?

compact bramble
#

I suggest avoiding homebrew network libs and going with Photon until Unity's done with their new networking.

gray pond
#

@compact bramble I would think with over a dozen launched games and a growing list of 3rd party asset integrations, support for TCP, UDP, Steam, and WebGL, and 10 actively contributing devs, Mirror can't really be called "homebrew".

compact bramble
#

for me it is

swift plinth
#

more like urine in practice than beer, I am ashamed that we tried to run it in the public beta test, it was a frustrating experience. photon is the way to go if you don't want to shoot yourself in the foot, but you need to invest money into it.

#

but after an initial period, if you more or less successful you will have money to keep it on rails in long-term

compact bramble
#

Indies without a full time network engineer on team will find their game does not scale or offer any form of resilience with these homebrew efforts.

"a dozen launched games" vs "thousands of actual games by AAA and indie alike" is a big difference, and worth the Photon cost.

#

But if you have a full time network guy, its worth a try to go with alternatives.

undone sigil
#

lol, you seem like a hardcore Photon fanboy

subtle relic
#

@vital hawk Stuff that I'm posting on forums is well-argued, and unlike you, I don't deal in absolutes.

#

If you can't counter-argue what I'm writing there then keep your immature tears to yourself.

#

Hypocrite who criticizes the new UI on the right and left.

split crescent
#

personal attacks aren't super constructive - can we keep things civil?

jade glacier
#

🍿

vital hawk
#

I'm not going to address that further than say that people can have their opinions, there are no tears shed here nor need to attack people. and yes it's true that I tend to ignore peoples posts that are almost always overwhelmingly negative. maybe lighten up a bit, game dev can be fun too 😃

split crescent
#

game dev can be fun too

#

[Citation Needed]

compact bramble
#

I don't feel offended, that would imply the person wasted my time (pretty much the only way I can be offended) :)

#

I will explain slightly futher, the rationale behind recommending Photon, it's really just a matter of perspective. As a tiny indie, you'd be unlikely to ever hit a situation where a homebrew or amateur network library will struggle, but if you're serious then it makes sense to go with something based on enet (photon is funnily enough) or just hire a proper person that will work with you and keep your net code and server running. These things need constant attention for a popular title. I would get killed if I ran my own server with 20CCU if I'm honest. That situation would eventually require hands on.

As the game got more popular, with more CCU...
Strange things would start happening that you would fail to track like people quietly not connecting, or half the planet timing out trying connect, and you never knowing why as steam reviews get more and more hateful and your title gets review bombed. This is why (if successful) you cannot take the cheap option. It is hiring someone, or using Photon.

But of course for tiny unknown or hobby titles please disregard everything :)

undone sigil
#

That still doesn't explain why Photon wouldn't struggle when other libs would 😄

jade glacier
#

I do networking as my main thing, and I have no idea what this discussion is even about.

#

I would abstract the library regardless. Having hard coded components, timings and messaging intertwined with your actual simulation and serialization code sounds like a recipe for pain.

compact bramble
#

Sounds good. I'd love if Unity's solution was further on, then I could start digging deep into it like I did with UNet (which turned out to be quite a bother really)

cosmic atlas
#

mmm, I'm rolling my own solution with LiteNetLib and a cost-effective VPS provider as a cost-saving exercise and learning experience, for better or worse

indigo current
#

Photon is good for things you don't need absolute precision on (eg competitive shooters), and that don't use a lot of bandwidth.

#

You can make a ton of casual games with photon and learn good practices. It's kind of a stepping stone for more serious networking though.

compact bramble
#

I don't particularly have a bias toward photon or anything, just I'm not seeing how they're more expensive than hiring a staff member + a bunch servers across the world + debugging unproven code

#

its fine if you're a contractor but from the POV of an indie running a business where small downtime is able to kill the product, well that's that.

#

I just think the main arguments occur because the POV of the person speaking is dramatically different to the other

#

for example I really enjoyed using TNet from tasharen and it was cool and fun, but wouldn't ever scale to anything

gray pond
#

Sounds a bit like your comparing apples to oranges...Photon services vs. Mirror networking, and bashing the latter for not having a multimillion dollar infrastructure, even though Mirror is portable to services like PlayFab, GameLift, etc.

#

And comparing the number of launched titles is bad form, given that Mirror's only been around for months vs Exit Games for years

#

Comparing Mirror, DarkRift, PUN, MLAPI, UNet (without Unity services), would be more reasonable in terms of API features and project structure. None of these are great for all types of games...some are better than others for certain types. I wouldn't use any of them for a turn-based game.

#

@compact bramble @swift plinth I don't know when you last worked with Mirror, or what your issues were , but if it wasn't this year, you may be basing your opinions on outdated information.

dapper tusk
#

I came to some problems, I am using new Unity.Networking.Transport and I cant make the UdpCNetworkDriver as the Unity.Networking.Transport.BasicNetworkDriver<T> does not exist, how is that possible? I am using the git version and their docs but it does not seem to work

graceful zephyr
#

@dapper tusk It's pretty early in the dev of the new library, most likely docs are out of date

dapper tusk
#

Yea, I will wait a bit until they make some more progress on it

undone sigil
#

or just don't use it at all

frank thorn
#

Using Photon is a mistake

#

Forge Networking Remastered is the best

jade glacier
#

Is this conversation ever not religious?

gray pond
#

Probably not, but bashing something without cause or context isn't necessary

#

Yes, I contribute to Mirror, but I'd never bash the others just to be an ass

#

If someone wants to make a turn-based game, I've told many to use something simpler than Mirror

#

Would Mirror work for that? Sure, but it's overkill.

#

On the other hand, if someone has a UNet game nearly finished, I'd certainly call them over to Mirror because it would surely be the least painful conversion.

#

If someone is trying to make a fast twitch physics game for 200 players, Mirror would fall short out of the box. Perhaps others would be a better choice. Mirror can be extended to support that, but it'd be some work. It can handle the 200, but the physics components aren't there...yet.

cosmic atlas
#

Different tools for different things
If networking was easy, every game under the sun would be networked

gray pond
#

exactly, so saying one is "best" or "urine" without any context is just pointless.

jade glacier
#

Its not even quite that... networking in Unity at the HLAPI is just in a state.

#

There is a lot of loathing, because its really a landscape of "not good enough" across the board. Unity is really to blame, but it does seem like enough people realize its a problem that it might actually get some improvements over the next couple of years.

#

Either from Unity, or from some of the smaller projects spawning out of the lack of anything complete

#

I like the Mirror concept, but I do agree it keeps breaking the promises it has made. Once that stops and it tightens up on the original promise of "HLAPI but better", it may get some respect.

#

PUN has a lot going for it, but it also rides on a lot of legacy code that hurts it

#

Photon's back end I hear is solid

cosmic atlas
#

It is a shame that Unity's current live network offerings have been deprecated, has left it in a not-so-desirable state
rip raknet, rip UNet
I also read about this the other day: https://unity3d.com/partners/google/connectedgames which is like some other angle for turn-based projects

Unity

The next generation of multiplayer games and beyond with Unity and Google Cloud.

jade glacier
#

Forge I still know little about, because its architecture is not conducive to me porting my networking libs to it.

cosmic atlas
#

yeah the main complaints I hear about Photon/PUN is that the packet overhead is quite "large", but it all works if it's not a big deal to the developer

jade glacier
#

yeah, though you can work around it. For my asset I just raise events, so I just bitpack my own byte[] and I run my test stuff at 60 ticks a second with no trouble on PUN

cosmic atlas
#

I've meddled with Tasharen's TNet too, seems solid if you don't mind its prefab system, an interesting take on things

jade glacier
#

But the built in PUN stuff is a pig for net traffic

#

UNet/Mirror/Forge/PUN all focus on replicating primitves and none of them touch bitpacking, so its really on you to do that

#

Bolt is still alive and kicking, and releasing titles. No clue what its current state is

#

Never even heard of Tasharen's thing, will look into it out of curiousity

cosmic atlas
#

TNet's hook is that it stores copies of the game world to memory/disk, so you can disconnect/reconnect without much issue, like acting as a server that retains data, rather than fully relying on clients to supply data
the server does not do physics processing or anything though

jade glacier
#

Unet/Mirror/PUN all have paths to the transport you can bypass much of the bloat with, so that brings it down to hosting and pricing models

#

Interesting

cosmic atlas
#

yeah the Tasharen dev said he was able to just host servers from his home for his Windward game lol

jade glacier
#

I'm so deep in 3d realtime physics based stuff I forget about the other avenues

gray pond
#

That's another thing - if a game doesn't need server-side physics / collisions / raycasting / navmesh, then there are definitely other choices because the server can be a non-Unity service

cosmic atlas
#

yea

jade glacier
#

Yeah, people get tied into these options regardless of what they are making, and then get religious about it.

gray pond
#

There's no good reason to have a server running inside Unity if you're not going to leverage it.

jade glacier
#

I think most people first experience networking as the UNET/PUN tutorials

#

and get stuck in that thinking

#

not realizing that you can have a server that is something totally not unity

gray pond
#

true, but they do want those features on the server more often than not

jade glacier
#

And not realizing that a unity based server is going to cost them a lot

#

yeah, most I think get built as player hosted, because that is the nature of the tutorials

gray pond
#

It's not trivial to implement that stuff without Unity

jade glacier
#

or with PUN relayed and serverless

cosmic atlas
#

There are so many options 😄

jade glacier
#

They just aren't obvious from inside of unity if you are starting

#

and Unity doesn't exactly direct you toward them 😃

gray pond
#

very true

jade glacier
#

I have issues with Mirror (mainly because it still causes me hours of work a week patching around it), but I refrain from bashing it because I want to see it make it to an LTS and stabilize. There is an audience for it of people who Unity stranded.

#

I do wonder what Vis2k has smoking sometimes with the directions its allowed to take. but I have issues with all of the libs I have had to deal with.

indigo current
#

I don't think Photon is the best, by any means. I was only saying for those learning networking with no experience or that want something out fast PUN is probably better.

#

If you already have experience with networking and know the ins and outs then yeah, use something else.

compact bramble
#

speaking of which

#

has anyone any experience with unity's new networking?

graceful zephyr
#

The endless networking lib arguments are still going strong eh? People get way to upset, zealous and invested in these things.

#

Just pick the one which matches your experience level, game type, budget, etc.

#

@compact bramble a bit yes, why?

#

It's still too early to use it for anything serious

jade glacier
#

ENALBE_UNET as a define is always true? Even in 2019 when UNET has been removed?

graceful zephyr
#

@weak plinth hey o/

#

@jade glacier that's their own define i think

jade glacier
#

It seems to not change and is always there

#

And heya 😃

graceful zephyr
#

you still in our side of the pond?

jade glacier
#

for 2 more weeks, then london for a week

#

then back to Trumperica

graceful zephyr
#

ah

jade glacier
#

So seems !UNITY_2019_1_OR_NEWER is the only viable test for UNET?

graceful zephyr
#

probably

jade glacier
#

Users can't enable it as a module or anything?

#

Weather starting to get springlike up there? @graceful zephyr

graceful zephyr
#

Ish

#

it's like 8C outside atm

#

cold AF

jade glacier
#

Warmer here than that, but still chilly as well. Not sure if its the norm for EU or just a weird season

graceful zephyr
#

weird season

#

it's been getting weird the past 10 years or so on and off

jade glacier
#

was starting to get really warm a few weeks ago... the bam.. wearing jackets again

graceful zephyr
#

we had snow here last week

#

in may

#

that ... never happens

jade glacier
#

Shifts in the jetstream I believe

graceful zephyr
#

watch out apparently they make frogs gay or something

jade glacier
#

What's melting the poles is making us all colder

graceful zephyr
#

i know what the jetstream is, just missunderstanding on purpose 😄

#

to drop an alex jones ref

jade glacier
#

They stole our warm

#

ah Alex Jones... consumer of old friends who I never talk to any more

#

Funny thing is I lived in Texas when he was starting up

graceful zephyr
#

I'd like to live a year or two in texas

jade glacier
#

and he used to actually at one time be useful and interesting

graceful zephyr
#

guns and big trucks, my kind if people

#

😄

jade glacier
#

Big hair.. .big everything

#

Every ad in Texas has the words "Texas sized" n it

graceful zephyr
#

😄

jade glacier
#

Between, PUN, PUN2, MIRROR, and UNITY_2018 ... my code is becoming more ifdef than code.

graceful zephyr
#

lol

sand lotus
#

And all of that pain for assets that don't have a lot of turnover 😕

indigo current
#

@graceful zephyr argument: an exchange of diverging or opposite views, typically a heated or angry one.

graceful zephyr
#

@indigo current Your point?

jade glacier
#

People speak about the various libraries always in absolutes, but absolutes are hard to come by in Unity networking. EVERY option has a downside, be it cost, or bugs, or lack of support, or relying on relays, or not offering relays.. etc. It's pretty pointless debating any of them as crap or great... they are all crap and great - if they don't or do match what you are trying to do.

graceful zephyr
#

Only a sith deals in absolutes and all that

#

😄

indigo current
#

@graceful zephyr my point, there's a difference between debating and arguing. Debating is resourceful, arguing is not.

vital hawk
#

in internet discussions, there usually isn't distinction between the two

#

most of the time it's just people pushing their own opinions

graceful zephyr
#

All I meant is that people tend to get way to invested in this stuff

#

And the discussions/arguments/whatever is endless 😃

night radish
#

You should only push commits, nothing else 👌🏻

compact bramble
#

@graceful zephyr I need to seriously consider at least 4-8 player small scale networking for the project I am doing. I need this to be a medium rate - think basically mario style rate of change so any recommendations or advice you have I'm all ears. Tobias recommended I chat to photon regarding a discount or influencer perks (which is what I am I guess) and so I figure that's also an angle I can take if it's cost effective for my game.

I don't have a lot of net experience but I'm far from stupid, which is why I'm leaning so hard toward a company that might have said experience.

graceful zephyr
#

Most importantly... what type of game is it?

compact bramble
#

it's a third person arena based game at the moment with 2-8 players (flexible, I can compromise)

#

melee combat

#

platforming elements

graceful zephyr
#

Hmm

compact bramble
#

capsules for players, occasional rigidbodies need synching (pickups)

graceful zephyr
#

Full 3d movement?

compact bramble
#

yeah

#

x,y,z needed, can jump, some can glide a little

#

the rigidbodies dont really need synching at all actually

#

i can suffice with a position for them

graceful zephyr
#

I'd say bolt tbh ... I'm obviously biased. But I don't know any other that has client side prediction and other goodies built in

compact bramble
#

bolt sounds fun what happens server wise?

graceful zephyr
#

One of the players would be the server

compact bramble
#

host migration's important to me

graceful zephyr
#

Bolt has punch through and relay fallback

#

Does not have that tho

#

You've set the bar pretty high with that game and features like host migration

#

Its a good target for a custom solution obviously

#

If you go with something like pun, unet, etc be sure that you will really not be able to use any of the built in components

#

As they're usually not built for games like that

compact bramble
#

it's small but the quality is really high overall in the game, lots of attention to quality over quantity so the networking needs to be as professional

#

so having a player drop and others all suffer, that's just too low quality

graceful zephyr
#

I know that stanchion (our bolt community guy) has a host migration sample for bolt tho

compact bramble
#

it'll have to work also on consoles, or be tested for them

graceful zephyr
#

Bolt works on console

#

Tested and verified afaik

compact bramble
#

yeah with one player hosting don't see why not

#

the migration is a headache

graceful zephyr
#

Yeah, it really is2

compact bramble
#

pausing it while a new guy is found can be acceptable

graceful zephyr
#

Massive headache

compact bramble
#

so long as everyone isn't dumped

#

I think it was halo 4 or 5 that did that

#

(pause to find new host)

graceful zephyr
#

Oh right not allowed to send discord invites here

compact bramble
#

pm me for it

graceful zephyr
#

Can you PM me? I'm ob phone

#

Just pong me

#

The android client isn't letting me PM you for some reason

compact bramble
#

weird thing

graceful zephyr
#

But yeah talk to stanchions there about host migration

#

Stanchion

#

For bolt

compact bramble
#

thanks

graceful zephyr
#

Bolt is by no means perfect

compact bramble
#

sounds like bolt might be simpler though

graceful zephyr
#

But I think the amount of work you have to do is way less than any other lib

compact bramble
#

simpler or more direct without fluff (and hopefully without too much allocations) is +1

graceful zephyr
#

As you're going to end up building a lot of the features that come out of the box with bolt

#

Depending on the exact game mechanics and such you might be able to use quantum

compact bramble
#

So bolt is free but I can optionally use it with photon's cloud stuff?

graceful zephyr
#

Bolt free uses the cloud always but does punch through via it

#

And only uses the cloud as relay incase punch fails

compact bramble
#

bolt vs pun ?

graceful zephyr
#

Pun is always relay

#

Doesn't have the concept of a server

#

Very different to use

fading pawn
#

@compact bramble Sent you a voucher for the Photon Bolt Sample Pack

#

it includes a bare bones host migration sample

graceful zephyr
#

@compact bramble bolt is higher level than pun is a simple way of putting it

compact bramble
#

thanks a lot, appreciated very handy

graceful zephyr
#

Don't need to deal with serialization by hand on bolt, automatic delta compression, built in systems for authority and predictions

#

Pun is more serialize and RPCS

compact bramble
#

"Host Migration Sample: Basic host migration functionality, when a host quits, the selected "backup host" will host, and the other clients will connect to that host. If that "new host" then quits, the "backup host" it selected will host, and all if any other clients will connect to that. And on and on and on... "

#

thats truly OK for my purposes

#

I might have to start recommending bolt to all if I get some good results with this :D

graceful zephyr
#

I have to put my two turdbirds to sleep now

#

I love my kids but every day is a struggle of how early can we put them to sleep

compact bramble
#

they know this

#

and wage war

#

eventually winning

jade glacier
#

Thimble of whiskey... done

#

Texas style

compact bramble
#

love the restraint

indigo current
#

I'm done recording, will be trying to edit and add 3 videos a day to the playlist.

compact bramble
#

I never said I liked PUN only that it seems like a solid choice

#

but yep I will mention you

indigo current
#

That was a joke 😛

jade glacier
#

PUN doesn't really have a way to serialize an initial state in with instantiation does it? @indigo current

indigo current
#

what do you mean exactly?

jade glacier
#

Looking at the PhotonTransformViews, looks likes its a bit hacky

#

Familiar with UNET so if I refer to how it does it you can get the sense of the equivalent?

#

public override bool OnSerialize(NetworkWriter writer, bool initialState){} is how you do it with UNET - when a NetworkIdentity is spawned, the creation over the network is accompanied by an initial serialization event, where you can write in the current state from the authority, to whomever just got it.

#

I get that PUN doesn't have a server, so the equivalency can't be there

#

but how does it handle that period between when the object is created on other clients... and when they get their first serialized data from the owner?

indigo current
#

you keep saying current state but I don't know what that implies

jade glacier
#

In this example... lets use position

indigo current
#

ah

#

yes and no

jade glacier
#

Relay server says "spawn this" to all

#

But they may not get a position for a frame or two

indigo current
#

When you instantiate over the network photon passes in position/rot over the instantiate call

#

as well the owner.

#

the other clients locally instantiate and initialize with that data.

#

so the position should be set soon as it instantiates

jade glacier
#

I'm not seeing the current position happening by default - you are saying it Transform data is kept by the Relay server and is part of instantiation?

#

I may have a flaw that is just keeping that from happening for me

#

I don't see though how the server would be aware of position of clients

#

Its not something I am explicitly telling it

indigo current
#

its sent with the instantiate call

#

position, rot, and owner

jade glacier
#

But the instantiate doesn't talk to the owner does it?

#

Or is the authority owner part of the spawn process?

#

When I join late - I don't have any positions

indigo current
#

so basically anyone can instantiate, whoever instantiates by default owns the object (this can be changed)

jade glacier
#

of other players

indigo current
#

so lets say playerB says photonnetwork.instantiate(vector3.zero, quaternion.identity);

jade glacier
#

yeah, but if I join 1 minute into a game - the only place players position data exists is either compressed in mystery packets on the net... or is only known by the owner

indigo current
#

I think on playerB it instantiates locally at those positions and assigns owner view ID the moment it instantiates.

#

playerA then gets the same call with the prefab name, position, rot, and owner

jade glacier
#

I am more concerned about what that new players see of the OTHER players

indigo current
#

then instantiates at the pos, rot, and applies owner

#

oh i have no idea

jade glacier
#

because its all defaults until the new player gets updates from them

indigo current
#

that may be true

jade glacier
#

Looking at the photon transform code it looks like a hacky after the fact update

#

So that may be the nature of the beast

#

That since the relay server is dumb, there is a momentary desync that cannot be avoided

indigo current
#

photontransformview uses onphotonserializeview

#

the default to that is 10 updates sent per second

jade glacier
#

Does the relay cache the last serialization?

indigo current
#

dont think so

jade glacier
#

So its possible for me to join a game, see a bunch of other players, all in the wrong place if that is the case?

#

until their updates arrive

indigo current
#

let me look into that real quick

#

i dont think it would happen because realistically their positions will update well before any models or visuals load

jade glacier
#

PhotonTransformClassic has some hinting about this in its comments

#

What is the mechanic that would delay that?

indigo current
#

Id assume what you said. I'm not sure if viewing how the server sends already instantiated objects is in the source. I'm abotu to check

jade glacier
#

cool, appreciate it

indigo current
#

okay found it

#

you're looking for internal GameObject DoInstantiate under NetworkingPeer

#

the data is set on awake by the photonview

jade glacier
#

Hmm, might not be usable in my case since this is an asset

indigo current
#

and looks like the data needed is passed in as evData

#

a hashtable

jade glacier
#

Hmm, I'll have to see if I can make use of that when I am not in control of the instantiation

indigo current
#

so new clients receive "DoInstantiate" which passes in the obj to instantiate as well the position/rot/view data.

#

and it instantiates and applies on awake, which is basically immediately.

#

but I suppose it is possible if u perform operations off awake which use id/pos/rot

#

you might face troubles

jade glacier
#

Who is calling the DoInstatniate? I may just need to read up on it a bit here.

indigo current
#

I didn't go that deep

#

but I suspect the photon network or maybe masterclient more likely tells the new players where each object is

#

and passes in all that data

jade glacier
#

Could be, I don't know the whole instantiation process

#

If the relay server leaves it up to each owner to give you the details that would be complete, but that would be super problematic

#

The Master will be outdated, so doubt that would be a source of current states

indigo current
#

how would the master be outdated

#

the master is already in the room, it already knows everything

jade glacier
#

The Master is already 3 hops to and from the relay vs the object that actually is broacasting positions

#

That would be an awfully Server/Client way of handling it - wouldn't make sense in PUN being pure relay

indigo current
#

oh you mean the master would be further behind

#

you could be right that the owner passes on the information.

jade glacier
#

The master is just there to settle scores and such, not to have the ultimate word on non-authority stuff

indigo current
#

thats how id probably do it, makes most sense

jade glacier
#

yeah, like WAY behind - that and the architecture just doesn't make sense for that master to act as a server

indigo current
#

but your question has been answered about the desync potential, and that there is none 😛

#

it does seem you cannot rely on the viewid/rot/pos on awake though unless PhotonView has a higher script priority (didnt check)

jade glacier
#

I think the ideal way is the Relay isn't dumb, and retains cached serializations, but that is a whole extension of functionality and can of worms

#

So I think its on the dev to just work around that initial "fuzziness"

indigo current
#

if it does, its not in the script execution order settings

jade glacier
#

If I join a game in session, the relay doesn't know the positions of things... but it lets me in... so I can only assume there is a moment of uncertainty there. Probably ideally handled by devs - where you don't make other objects visible until they get a serialization

#

is just my guess

#

I never solved it with my previous asset

#

in NetworkSyncTransform, I just made the gameobject stay invisible until my first update came in

#

So basically after joining, other entities started popping in as they reported in

indigo current
#

Thats not how it works from what i gathered

#

Okay sooo scene objects might be desyncd, thats entirely a possibility

#

but instantiated objects shouldnt be

jade glacier
#

Is the spawn logic posted anywhere as far as you know? Or do I just need to follow the methods and see where it all goes?

indigo current
#

you receive a call over the network to instantiate them and that call includes the initial data.

jade glacier
#

yeah, its the scene objects that are the concern

indigo current
#

well, I don't know couldn't track those. would be really easy to test though.

jade glacier
#

other players that I am told are in the game... but I haven't gotten current states from yet

indigo current
#

those arent scene views

#

other players would be instantiated

jade glacier
#

Mostly was just asking here in case there was a known best pratice

indigo current
#

sceneviews are objects in your scene at build that have a photonview.

jade glacier
#

yeah, they exist

indigo current
#

I'll have to test the scene view thing for you to be sure.

jade glacier
#

the issue is if I join a game, and it says there are 4 other players.... but I haven't gotten updates... then their transform/animation/etc states are all unknown to me

#

until they start reporting in

indigo current
#

they would be known to you

jade glacier
#

They don't spawn locally until a serialization from them arrives?

indigo current
#

Im not sure about the animation states but the position/rot/viewId are definitely known when you spawn them locally.

jade glacier
#

I don't get how though

#

The server has no innate knowledge of position past initial spawn

indigo current
#

I just want to be clear I'm talking about objects which are instantiated over the network.

#

Not objects which you place in your scene, and build.

jade glacier
#

I am talking about other players in this case

#

non-determinstic objects

indigo current
#

Well I would assume other players are instantiated over the network at some point.

#

Then yes, pos/rot is set on spawn even for new players.

jade glacier
#

That is the missing part

#

does the relay server hold off on telling me about them until they are passing through some serialization?

indigo current
#

Look at the method "DoInstantiate"

#

it's all there.

jade glacier
#

I tried, no return in the docs, will look around some more

indigo current
#

You can't know they're there until the server tells you anyway, right?

#

So it only makes sense that the server tells you their transform data when it tells you they're there as well.

#

But I looked at the code and I can tell you, that is how it works.

jade glacier
#

I think the serarch feature is just lame is my guess

indigo current
#

I didn't look at the API

#

I followed the source files.

jade glacier
#

ahh

indigo current
#

I'm unsure about the synchronization delays on scene objects though. I want to test that out, and will tomorrow.

jade glacier
#

Is DoInstantiate even a thing in PUN2

#

project search found no instances of it

#

Oh well, first I am just going to ignore the problem and see if it just magically isn't a problem. Such as the server holds spawning objects until a serialization goes through for them. Will see here.

#

Nope, left to its own devices, other characters all start at their origin on the new players screen, and then move to their correct position shortly after when the new player starts getting their updates.

jade glacier
#

I think it does tie it to a serialization tick coming through, but that requires you to be using OnSerialize rather than raising your own events... so I think it works if you stay inside the lines - just going to be a problem for me doing this all on a master tick @indigo current

compact bramble
#

any news on unity's own networking? I'll be evaluating bolt soon and any other suggestions people have

azure quail
#

tho seems more aimed at VR

jade glacier
#

Anyone using UNET/Mirror (possible PUN2, but I haven't fully tested that) you are welcome to try my Transform and Animator sync asset Alpha. Will be a paid asset down the line, but will grandfather anyone in who tests it for me.

https://github.com/emotitron/Simple-Network-Sync

compact bramble
#

whats this pun2 lark about?

#

I've looked at bolt but I see Pun and Pun2 being things to consider now

jade glacier
#

lark?

#

PUN and Bolt are WAY different net models

#

so its really going to depend a lot on what you are making

indigo current
#

@compact bramble PUN2 is just a newer variant of PUN1 😛

#

a few APIs changed, minor internal changes. It now uses inheritance instead of reflection callbacks.

compact bramble
#

So the reason to use Pun1 for new devs is....

indigo current
#

none

compact bramble
#

right! ok so PUN2 vs Bolt, what are your unbiased views on what I should be using for this game? From monday next week til friday I have time to evaluate one networking option

indigo current
#

Bolt is a client auth or server auth solution which uses photons cloud service to match make. PUN is only client auth.

compact bramble
#

Obviously Unity's networking is just way too soon and mlapi and mirror are basically Unet 2.0 which isn't really what I want to be relying on.

indigo current
#

Bolt is more efficient but the documentation is complete crap and it takes a really long time to get questions answered in their discord.

#

IMO go with something that has better documentation and use a third party match making service.

compact bramble
#

why third party match making service?

indigo current
#

because Bolt afaik is the only one that has it built in, using photons service.

compact bramble
#

and Bolt is more efficient than PUN2?

indigo current
#

yes, bolt is an entirely different system

#

its my understanding a lot of modern networking solutions are compatible with amazon playfab (paid service, but its REALLY cheap)

compact bramble
#

I don't undertand why one should use third party match making just because "it's built in" - 'I am not clear what the negative points are

indigo current
#

actually playfab is free too, and much more generous with pricing than photon

#

*Use PlayFab's platform of back-end game services to launch and run your game quickly and without hassle. The first 1,000 daily users are free. *

#

I looked away from bolt because I didnt like how you had to setup network objected. it felt very clunky.

#

also the documentation is really bad

#

and their support is slow.

#

3 big reasons to turn me away from it

#

If I wanted something that had server auth personally I would look at a networking solution which supported playfab (and other third party matchmaking services)

#

there are plenty out there better than bolt.

compact bramble
#

playfab is a platform for recording user data though for items and currency etc?

#

pricing was changed recently too

#

bolt's cloud is optional I thought? also I'm a little concerned that bolt needs to compile code

indigo current
#

yes its optional

compact bramble
#

host migration is a concern also but apparently bolt can support it

indigo current
#

I cant make decisions for u 😛

#

I'm just telling you what I know.

#

IMO investigate the API and browse reviews and documentation before committing. Crappy documentation can drastically slow down development cough unreal engine

vital hawk
#

wonder if anyone is in the beta for that

#

but that probably has some sort of NDA as I think it's apply and get invite kinda thing for now

#

multiplay at least is battle proven solution, Unity's new integration isn't tho

graceful zephyr
#

@indigo current @compact bramble most (all?) negative reviews on Bolt on the asset store complain about the CCU model, the people that actually reviewed the product - i.e. what it can do, all gave it 4 or 5 stars essentially

compact bramble
#

Yeah I don't doubt it's great, seems like it does not actually need much code even.

indigo current
#

@graceful zephyr @compact bramble You should disclose that you're a developer of Bolt fholm.

jade glacier
#

I think he tries to not over advertise that, since its not his and he doesn't really want to be asked to be tech support for it

indigo current
#

My complaints are with the poor documentation and slow response times of support chat. While support chat is a luxury more than anything, it's not effective enough to shine out the fact Bolt documentation is meh.

jade glacier
#

He made it, but its Exit's baby now

compact bramble
#

Yeah the father must sometimes give his children whiskey (or sell them)

indigo current
#

I was implying his opinion is biased emoititron

jade glacier
#

Technically he isn't bsing, its the most solid option on the market

#

but it is its own animal, with a beast learning curve if you are coming from basic Unity

indigo current
#

That's your opinion. I won't touch a framework without solid documentation.

jade glacier
#

I don't disagree that Exit is lacking in the docs department

#

Just saying that having used all of them, Bolt is definitely the only one that "gets" AAA standards and practices

#

But being such, its not "Unity-like"

compact bramble
#

There is no Unity-like any more though TBF

jade glacier
#

which makes a shortage of great docs and walk throughs troublesome for people checking it out

compact bramble
#

for a good while now the API has been spidering in all sorts of directions...

jade glacier
#

Unity-like is changing with DOTS anyway

compact bramble
#

and frankly this is actually a good thing as much as I hate it, because trying to bully a solution into using a specific shape that does not suit the solution is worse.

indigo current
#

I'm not talking about it being or not being "Unity-like".

compact bramble
#

so while I do prefer classic unity (from a few years ago) to learn from, it won't fit shapes to come because the solutions are so different.

indigo current
#

All I said is that it has crappy documentation, and that's a fact.

compact bramble
#

for example the whole mess that's unitys collision events (OnStay etc) is purely because of the unity-ifying of it, and this limited the performance, limited what you could do with it and severely delayed many performance improvements

#

so if an API is different thinking we should probably just accept it.

#

so long as its consistent within it's own API surface

#

therefore if bolt is different or something else is different I'll just have to pretend I dont have a mild touch of asperger's

#

I mean frankly what else is there? Pun2 or Bolt vs.... .....Unet and being at the mercy of unpaid individuals

#

But I will keep an open mind and evaluate all options.

indigo current
#

There's a ton of options.

#

Mirror and DarkRift 2 are updated iirc.

#

There's several more though.

#

You also have Forge Remastered

compact bramble
#

I will start by looking at released games made with something, I don't want to be first :'D

#

Also host migration is mandatory, so anything not doing that is immediately dismissed

#

also drop-in is mandatory as well, which makes it really quite hard to find the right one

indigo current
#

so you're talking client auth

#

I assume you aren't releasing for desktop?

compact bramble
#

well 1 client as host would be ideal

#

it's for PS4 first then 6 months later I can port elsewhere (prob to xbox)

indigo current
#

gotcha

compact bramble
#

PC is last market I will touch

indigo current
#

how much bandwidth do you need? does networked stuff have to be really precise?

compact bramble
#

so yeah I forgot - it's mandatory it works on psn

#

it's melee combat and platforming

#

collision can be resolved by host or client in inaccurate ways just fine

#

how secure it is, is not that important

indigo current
#

how many players per room?

compact bramble
#

8 would be maximum I think. Planning for stable 4

indigo current
#

PUN would probably be fine. If you want something more performant though search elsewhere.

compact bramble
#

very little needs rotations synched for example just positions and messages would suffice

jade glacier
#

If you want a lower data usage PUN I make stuff for that, there are plenty of options for crushing down data usage

indigo current
#

PUN uses onphotonserializeview for transform data. Just turn down the serialization rate and use photon transform view classic and set to estimated speed

#

works pretty good

compact bramble
#

Bolt would be perfect if it had proper host migration built in . As I undertstand it there is a sort of hack in the samples though

indigo current
#

you can also bump up how many packets each player can send. since there will be so few that probably wont hurt

#

bolt doesnt offer master client hand off?

compact bramble
#

Bolt based games have higher latency too

indigo current
#

bolt doesnt offer master client hand off?

#

bolt is supposed to use less bandwidth... hows that possible

compact bramble
#

I'm just reading the docs

indigo current
#

link plz

compact bramble
#

however I imagine such a list should be regenerated each time a client comes or goes

indigo current
#

wow

#

so it goes through the master client then other players

#

that is nasty

compact bramble
#

is it?

#

I thought it was cost effective myself

#

Surely cheaper than servers etc

jade glacier
#

PUN isn't server auth

#

Oh you mean bolt

#

if you use bolt with a relay, that I would not recommend

#

you would want to avoid the relay with Bolt and host on a reachable server

vital hawk
#

you still pay for CCU to Exit Games on bolt tho, even if you bypass their services

jade glacier
#

The relay environment really calls for client auth

indigo current
#

But if you're using server auth you might as well not use bolt because there are better options.

jade glacier
#

not for the price, because a relay server hop for server auth is a LOT of internet to go through

indigo current
#

IMO if you want ease and you're okay with client auth use PUN. Otherwise just use something better/cheaper and link up to playfab

jade glacier
#

You can;t pick between Bolt and PUN without actually have your game arch decided

#

they aren't even somewhat related

indigo current
#

The no master hand off is not great either for Bolt

jade glacier
#

Your game arch will demand one or the other

#

What are you even making? @compact bramble

#

and do you have a team for this? Because the elephant in the room is if this is your first networking adventure... its going to end in failure. I would do some tutorials and fake projects before even going down any of these paths.

vital hawk
#

one thing I'm pretty excited to see is Epic Online Services, it's not there yet tho but they plan Unity SDK for it as well

#

it's basically steamworks like framework that also supports crossplatform

#

where latter is the main reason I want to see that happen

graceful zephyr
#

@indigo current no it does not go through the master client and other players

#

it uses the cloud relay to punch directly to the clients, the relay is ONLY used as a fallback incase of a punch failing, and assuming you're hosting dedicated servers... the punch never fails (obviously)

#

@compact bramble fyi if psn and xbox live are mandatory then you're basically stuck with the photon products as they are the only ones that have validation and are authorized by Sony and MS

#

Smartfox might be also

#

But mirror, mlapi, etc. Are not

#

I don't really have a horse in this race, yes I made bolt but exit games owns it and I don't have any monetary benefit or interests in it

#

I try to be as unbiased as possible when it comes to recommending networking libs, and have recommended mirror to a bunch of people

#

If you're looking to connect using psn and live sockets then you need bolt pro (which can do this) or you need to create your own linking layer for them for mirror/mlapi etc

#

The status of the bolt documentation I don't really know, as I've been working on quantum the past few years and other people do the maintenance and updates of bolt now a days

compact bramble
#

@graceful zephyr thanks for advice! looks like bolt pro is required then!

graceful zephyr
#

@compact bramble you can of course use bolt free with its relay/punch facility on those platforms also

#

But if you specifically want to use psn sockets and xbox live sockets you have a use bolt pro

#

To my knowledge no other net lib has built in support for either psn or xbox live

compact bramble
#

I'm not sure what sockets are - didn't read much about it on dev net - I assumed at that point it was all handled by unity (how wrong I was)

graceful zephyr
#

But I could be wrong, was a while since I checked

compact bramble
#

bolt pro is same as bolt but just sockety stuff added?

graceful zephyr
#

Yes

compact bramble
#

Sounds great, I can pay for that by driving half the unity forums at bolt I guess :D