Page 1 of 1

Breakable trees in multiplayer

Posted: Sun Apr 08, 2018 12:45 pm
by fury22uk
Hi. I am working on breakable trees in multiplayer. I obviously do not use GameSDK. Just blank template. I have a lot of stuff working in multiplayer for my game, now that the time for breakable trees has come, I faced a massive obstacle!
I managed to get breakable trees to work in editor without any issues. To make sure that everything is set up properly, I copied palm trees from gameSDK. They break nicely. But in singleplayer and in editor.
I am assuming, that vegetation trees physics sit on the server, since clients are unable to break them at all. When I break it on the server side though, something happens. Tree seems to break, but on the server is says, that this model is unsuitable for breaking as well as it does not have a mesh. Those errors don't appear in singleplayer at all, so tree setup is correct. I tried it with 3 scenarios - tree as vegetation / brush / rigid body component. All do exactly same thing. After this error on the server appears, it immidiately disconnects all clients without giving any reason. Any ideas?

Re: Breakable trees in multiplayer

Posted: Sun Apr 08, 2018 5:51 pm
by chernecoff
I have some issue. GameSDK 5.4

Re: Breakable trees in multiplayer

Posted: Sun Apr 08, 2018 6:22 pm
by creating1
It depends on what you want to use it for and how many want this effect.

Brush is easy but lacks the options for you to change in the future all the parts of the breakable object parts would be a waste on performance if just left there etc

Best thing is to Create an entity for the breakable tree and create new component for it
But physics seem to be a pain when it comes to servers

Re: Breakable trees in multiplayer

Posted: Sun Apr 08, 2018 6:36 pm
by fury22uk
Physics is not a problem for me to sync. I tried entity method. It crashes anyway. Unless you're talking about brand new implementation for boolean cut algorythm and so on, and I have absolutely no idea how to achieve it. Do you ?

Re: Breakable trees in multiplayer

Posted: Sun Apr 08, 2018 9:10 pm
by creating1
Sadly i dont know how to achieve it fury

Re: Breakable trees in multiplayer

Posted: Mon Apr 09, 2018 6:02 am
by mknmknmknjk
show debug info. such as file and line number.

Re: Breakable trees in multiplayer

Posted: Mon Apr 09, 2018 7:59 am
by fury22uk
No info there. Nothing crashes, all it does is just calling disconnect on client, so that client is thrown away from server, but it does not crash. Client says no errors, while server complains about tree being not suitable for breaking. The same tree breaks fine in editor. Without errors. The same thing happens to gamesdk trees as well as custom trees.
5.5 and 5.4 does the same thing

Re: Breakable trees in multiplayer

Posted: Mon Apr 09, 2018 12:56 pm
by fury22uk
I created another tree model, and this one crashes server when broken. The thing is that I can not debug it. It crashes in CryAction and I dont have access to it.

Code: Select all

Exception thrown at 0x00007FFFD879B372 (CryAction.dll) in Game_Server.exe: 0xC0000005: Access violation reading location 0x0000000000000000.

Re: Breakable trees in multiplayer

Posted: Thu Apr 12, 2018 3:09 pm
by fury22uk
I eliminated those errors that appeared on the server side, but it still disconnects clients while breaking without giving any reason