## User Tag List

1. 0
Veteran
Join Date
Apr 2014
Posts
433
Hi @Getnamo

Little update on my problem with UESocket.io not connecting to my server. I'm not really sure how I've got it set up as i'm basically fudging my server code together, but it seems that the way I was hosting my webpage may have something to do with it. I started getting connections to UE4 when I set up second socket.io 'instance' in my server code, listening on another port.

My original setup is a node server which acts as a CMS reading and writing to an SQLite database and serving up a webpage. I bolted on lots of other stuff like OSC and stuff - and originally I was running with XMLHTTPrequests rather than Socket.io - then I switched to socket.io for communication between the server and the served webpage-interface but when I tried to connect from UE4 through the same address and port I got nothing.

Don't know what I did, and I don't' really like running 2 ports (it seems clunky) but it's working now.

2. 0
Champion
Join Date
Mar 2014
Posts
561
Originally Posted by Dannington
Hi @Getnamo

Little update on my problem with UESocket.io not connecting to my server. I'm not really sure how I've got it set up as i'm basically fudging my server code together, but it seems that the way I was hosting my webpage may have something to do with it. I started getting connections to UE4 when I set up second socket.io 'instance' in my server code, listening on another port.

My original setup is a node server which acts as a CMS reading and writing to an SQLite database and serving up a webpage. I bolted on lots of other stuff like OSC and stuff - and originally I was running with XMLHTTPrequests rather than Socket.io - then I switched to socket.io for communication between the server and the served webpage-interface but when I tried to connect from UE4 through the same address and port I got nothing.

Don't know what I did, and I don't' really like running 2 ports (it seems clunky) but it's working now.
It could be that your other service is holding the other port and you can't connect to it with another service. See http://stackoverflow.com/questions/3...80-on-a-server, specifically:

Ports are a way to multiplex IP addresses so that different applications can listen on the same IP address/protocol pair. Unless an application defines its own higher-level protocol, there is no way to multiplex a port. If two connections using the same protocol have identical source and destination IPs and identical source and destination ports, they must be the same connection.

There are ways to forward ports however so that e.g. port 80 requests will happen on 3000 transparently to the user, which should work for socket.io traffic as well.

Originally Posted by SteffenN
Hi @getnamo, nice work btw.

My UE4Editor is crashing as soon as I am connecting to my server. I should say that I am not using an socket.io server. With javascript in a browser everything works fine (communication with a sps-controller). I am using version 4.14.3 of unreal.
Do you have any ideas? I can't even debug because the whole Unreal crashes, only with a short info "not working any more..." It crashes both on blueprint and on c++. Tried also the latest release(0.4.1) and my own compilation with the latest source files from github (0.4.7).

Thanks,
Steffen
If this is related to the socket.io-client plugin, PM me your logs under saved related to the crash. They usually have more information. Also have you tried a clean project? What platform are you using this on?

3. 1
Promoter

Join Date
Mar 2014
Posts
207
I'm having a similar crash as SteffanN, but only in packaged builds. I've experienced crashes in non-packaged builds if I fail to connect. I have tried in a blank project with variable success. The frustrating thing is that is seems really inconsistent. Sometimes ti connects, sometimes it crashes. Mostly crashing these days.
https://1drv.ms/v/s!AuBS3k7nbgsXjQkGIexhhJx_dJxK
Here's an actor crashing after 5 seconds.
It does seem more stable if I connect with the PC using auto-connect or in the construction script. But that's not a guarantee. The logs are pretty unhelpful as they simply end before the crash.

4. 0
Champion
Join Date
Mar 2014
Posts
561
Originally Posted by Tom Shannon
I'm having a similar crash as SteffanN, but only in packaged builds. I've experienced crashes in non-packaged builds if I fail to connect. I have tried in a blank project with variable success. The frustrating thing is that is seems really inconsistent. Sometimes ti connects, sometimes it crashes. Mostly crashing these days.
https://1drv.ms/v/s!AuBS3k7nbgsXjQkGIexhhJx_dJxK
Here's an actor crashing after 5 seconds.
It does seem more stable if I connect with the PC using auto-connect or in the construction script. But that's not a guarantee. The logs are pretty unhelpful as they simply end before the crash.
Got an example minimal project to replicate the crash?

I've been able to replicate hangs from not using auto-connect, but haven't found a way to crash due to socket.io. What's the server you're connecting to? does it have socket.io v1.4 or newer?

5. 1
Patron
Join Date
Mar 2014
Posts
31
Great Plugin.

Just upgraded to UE 4.15(Github Version) but the Plugin no longer works, the editor tries to compile when i start my project but it fails.

\Plugins\socketio-client-ue4\Source\SIOJEditorPlugin\Private\SIOJ_BreakJson.cpp(34): error C2653: 'FEdGraphUtilities': is not a class or namespace name
\Plugins\socketio-client-ue4\Source\SIOJEditorPlugin\Private\SIOJ_BreakJson.cpp(121): error C2653: 'FEdGraphUtilities': is not a class or namespace name
thats the error in the log

edit:

#include "EdGraphUtilities.h

in the "SIOJ_BreakJson.cpp" file

6. 0
Champion
Join Date
Mar 2014
Posts
561
Originally Posted by KenshiHH
Great Plugin.

Just upgraded to UE 4.15(Github Version) but the Plugin no longer works, the editor tries to compile when i start my project but it fails.

thats the error in the log

edit:

#include "EdGraphUtilities.h

in the "SIOJ_BreakJson.cpp" file
Excellent, kindly make a pull request in github with the fix

7. 1
Patron
Join Date
Mar 2014
Posts
31
Just made a pull request, first time ever, i hope i did it right

8. 0
Supporter
Join Date
Feb 2017
Posts
2
The problem with editor freezing, if the server goes down during session still persist, though now it only happens when you stop play/simulation. Are there, maybe any way to check server availability and disconnect after a certain number of attempts? I tried this:

but to no avail

9. 0
Supporter
Join Date
Feb 2017
Posts
2
Also, is there any way to check connection status? Especially good, if you could do it through blueprints, but ++ approach is ok. As far as I learned, issue with editor freeze goes even further. If you try to disconnect while server is sending/waiting to send you smth, it freezes too, but then, strange things happens. Server getting the dc message, but then socket reconnects again, all with editor frozen on client side. Moreover, if you try to connect to server, that ain't there two times in a row, on second try editor freezes too.

All of the above is for 4.15

10. 0
Veteran
Join Date
Apr 2014
Posts
433
Hi @getnamo,

How is sunny Oxford?

Do you know if anyone's been successful in creating an android build of this plugin? I'm trying to port my build to my shield tv device so I don't have to lug my PC around. (I'm planning to possibly do a presentation at UELondon with it this month too.)

Cheers!

Dan

11. 0
Champion
Join Date
Mar 2014
Posts
561
Originally Posted by KenshiHH
Just made a pull request, first time ever, i hope i did it right
It looks good, merged.

Originally Posted by Avatarochnik
Also, is there any way to check connection status? Especially good, if you could do it through blueprints, but ++ approach is ok. As far as I learned, issue with editor freeze goes even further. If you try to disconnect while server is sending/waiting to send you smth, it freezes too, but then, strange things happens. Server getting the dc message, but then socket reconnects again, all with editor frozen on client side. Moreover, if you try to connect to server, that ain't there two times in a row, on second try editor freezes too.

All of the above is for 4.15
There is a bIsConnected attached to the main component you can use. Still looking for some free time to fix the timeout connection issue. If you have C++ experience, consider contributing

Originally Posted by Dannington
Hi @getnamo,

How is sunny Oxford?

Do you know if anyone's been successful in creating an android build of this plugin? I'm trying to port my build to my shield tv device so I don't have to lug my PC around. (I'm planning to possibly do a presentation at UELondon with it this month too.)

Cheers!

Dan
Actually sunny for once

Regarding android build, I forward you to the issue on github related to it https://github.com/getnamo/socketio-...-ue4/issues/21. As of right now there is no successful build for android, looking for contributors for that platform as I don't personally use it with ue4 yet. If anyone has C++ and android experience, kindly try to build the libs!

12. 0
Veteran
Join Date
Apr 2014
Posts
433
Originally Posted by getnamo
It looks good, merged.

There is a bIsConnected attached to the main component you can use. Still looking for some free time to fix the timeout connection issue. If you have C++ experience, consider contributing

Actually sunny for once

Regarding android build, I forward you to the issue on github related to it https://github.com/getnamo/socketio-...-ue4/issues/21. As of right now there is no successful build for android, looking for contributors for that platform as I don't personally use it with ue4 yet. If anyone has C++ and android experience, kindly try to build the libs!

I can see you've got some iOS bits in the GitHub. Does it work? I'm thinking of picking up an Apple TV. I really need to make a portable version of my project somehow.

Dan

13. 0
Champion
Join Date
Mar 2014
Posts
561
Originally Posted by Dannington

I can see you've got some iOS bits in the GitHub. Does it work? I'm thinking of picking up an Apple TV. I really need to make a portable version of my project somehow.

Dan
Same situation as android, this is the issue tracking that platform: https://github.com/getnamo/socketio-...-ue4/issues/19. What's missing in both cases is to have the static libs for socket.io-cpp and boost built and correctly embedded in the project. It will require other contributors as I don't work on these platforms myself. I hope any of you C++ experts with iOS and Android experience consider contributing

14. 0
Supporter
Join Date
Feb 2017
Posts
4
I have a 4.14 project using the Socket IO plugin, trying to upgrade it to 4.15 for SLI support, was using the latest 4.14 release of Socket IO Unreal plugin but have now switched to the master for the 4.15 fix, however when i try to open the project in 4.15 using the master branch version of the plugin i get the following error;

Plugin 'SocketIOClient' failed to load because module @SIOJson' could not be found. Please ensure the plugin is properly installed, otherwise consider disabling the plugin for this project.

Have tried to rebuild the plugin using the package button in the plugins window but it errors out, even with a black project.

Anyone have any tips on how they got it to work or what i am doing wrong?

15. 0
Champion
Join Date
Mar 2014
Posts
561
I have a 4.14 project using the Socket IO plugin, trying to upgrade it to 4.15 for SLI support, was using the latest 4.14 release of Socket IO Unreal plugin but have now switched to the master for the 4.15 fix, however when i try to open the project in 4.15 using the master branch version of the plugin i get the following error;

Plugin 'SocketIOClient' failed to load because module @SIOJson' could not be found. Please ensure the plugin is properly installed, otherwise consider disabling the plugin for this project.

Have tried to rebuild the plugin using the package button in the plugins window but it errors out, even with a black project.

Anyone have any tips on how they got it to work or what i am doing wrong?

I havent provided 4.15 binary release yet for the plugin, but you do have full source so you can recompile it. What you need to do is add a C++ class to your project (https://docs.unrealengine.com/latest...t/2/index.html) and recompile it. When you do this, the plugin will be compiled along with the project and it will launch.

16. 0
Supporter
Join Date
Feb 2017
Posts
4
Originally Posted by getnamo
I havent provided 4.15 binary release yet for the plugin, but you do have full source so you can recompile it. What you need to do is add a C++ class to your project (https://docs.unrealengine.com/latest...t/2/index.html) and recompile it. When you do this, the plugin will be compiled along with the project and it will launch.
Thank you so much for your reply, i will have a go at this today, its not something i have done before, but you make it sounds easy enough.

Thanks,

17. 0
Champion
Join Date
Mar 2014
Posts
561
Thank you so much for your reply, i will have a go at this today, its not something i have done before, but you make it sounds easy enough.

Thanks,
Just released a new 4.15 binary build, but I'd recommend trying the build yourself once to see that it's not that bad overall

Update to 0.4.8
-Includes changes from 0.4.2 to 0.4.8
-UTF8 support
-4.15 compile fixes (thanks @KenshiHH)
-Session ID fixes
-Connection fixes

grab latest release at the usual https://github.com/getnamo/socketio-client-ue4/releases

If you've had disconnection hangs, try the new version and let me know if it fixes things for you.

18. 0
Veteran
Join Date
Apr 2014
Posts
433
Thanks for the update, I'll let you know if it hangs. I get a crash more often than not on my packaged build so I should be in a good position to let you know.

Cheers!

19. 0
Veteran
Join Date
Apr 2014
Posts
433
Still getting crash on exit for packaged games. I'll try to put together something you can look at.

Thanks though!

20. 2
Veteran
Join Date
Apr 2014
Posts
433
Don't know if this helps - I rigged it so I can toggle a connect/disconnect and it crashed (in editor)

Fatal error: [File:\Build\++UE4+Release-4.15+Compile\Sync\Engine\Source\Runtime\Core\Private\GenericPlatform\GenericPlatformMemory.cpp] [Line: 160]
Ran out of memory allocating 4453159313439771895 bytes with alignment 0

KERNELBASE
UE4Editor_Core
UE4Editor_Core
UE4Editor_Core
UE4Editor_Core
UE4Editor_Core
UE4Editor_SocketIOClient!std::basic_string<char,std::char_traits<char>,std::allocator<char> >::_Copy() [c:\program files (x86)\microsoft visual studio 14.0\vc\include\xstring:2196]
UE4Editor_SocketIOClient!std::basic_string<char,std::char_traits<char>,std::allocator<char> >::assign() [c:\program files (x86)\microsoft visual studio 14.0\vc\include\xstring:1155]
UE4Editor_SocketIOClient!sio::client_impl::connect()
UE4Editor_SocketIOClient!sio::client::connect()
UE4Editor_SocketIOClient!<lambda_528b49ce01ebae6e90043a74545a1705>:perator()() [c:\users\danrs\documents\unreal projects\damab_6_0\plugins\socketio-client-ue4\source\socketioclient\private\socketioclientcomponent.cpp:150]
UE4Editor_SocketIOClient!FSIOLambdaRunnable::Run() [c:\users\danrs\documents\unreal projects\damab_6_0\plugins\socketio-client-ue4\source\socketioclient\private\siolambdarunnable.cpp:47]

21. 1
Supporter
Join Date
Dec 2016
Posts
2
Hey getnamo!

Thank you very much for the plugin it is awesome, although I have started using it in 4.15.1 and I have some strange error while emiting event, my unreal crashes with fatal error and in logs I found this:
[2017.03.26-23.56.13:486][917]LogCrashTracker:

[2017.03.26-23.56.13:486][917]LogWindows:Error: === Critical error: ===
[2017.03.26-23.56.13:486][917]LogWindows:Error:
[2017.03.26-23.56.13:486][917]LogWindows:Error: Fatal error!
[2017.03.26-23.56.13:486][917]LogWindows:Error:
[2017.03.26-23.56.13:486][917]LogWindows:Error:
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor-SocketIOClient.dll!USIOMessageConvert::ToSIOMessage() [c:\users\newicz\documents\unreal projects\ao\plugins\socketio-client-ue4\source\socketioclient\private\siomessageconvert.cpp:83]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor-SocketIOClient.dll!USocketIOClientComponent::Emit() [c:\users\newicz\documents\unreal projects\ao\plugins\socketio-client-ue4\source\socketioclient\private\socketioclientcomponent.cpp:179]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor-SocketIOClient.dll!USocketIOClientComponent::execEmit() [c:\users\newicz\documents\unreal projects\ao\plugins\socketio-client-ue4\source\socketioclient\public\socketioclientcomponent.h:52]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor-CoreUObject.dll!UFunction::Invoke() [c:\unrealengine-4.15\engine\source\runtime\coreuobject\private\uobject\class.cpp:4525]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor-CoreUObject.dll!UObject::CallFunction() [c:\unrealengine-4.15\engine\source\runtime\coreuobject\private\uobject\scriptcore.cpp:721]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor-CoreUObject.dll!UObject::ProcessContextOpcode() [c:\unrealengine-4.15\engine\source\runtime\coreuobject\private\uobject\scriptcore.cpp:2149]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor-CoreUObject.dll!UObject::ProcessInternal() [c:\unrealengine-4.15\engine\source\runtime\coreuobject\private\uobject\scriptcore.cpp:948]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor-CoreUObject.dll!UFunction::Invoke() [c:\unrealengine-4.15\engine\source\runtime\coreuobject\private\uobject\class.cpp:4525]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor-CoreUObject.dll!UObject::ProcessEvent() [c:\unrealengine-4.15\engine\source\runtime\coreuobject\private\uobject\scriptcore.cpp:1318]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor-Engine.dll!AActor::ProcessEvent() [c:\unrealengine-4.15\engine\source\runtime\engine\private\actor.cpp:684]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor-Engine.dll!FTimerUnifiedDelegate::Execute() [c:\unrealengine-4.15\engine\source\runtime\engine\public\timermanager.h:50]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor-Engine.dll!FTimerManager::Tick() [c:\unrealengine-4.15\engine\source\runtime\engine\private\timermanager.cpp:574]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor-Engine.dll!UWorld::Tick() [c:\unrealengine-4.15\engine\source\runtime\engine\private\leveltick.cpp:1427]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor-UnrealEd.dll!UEditorEngine::Tick() [c:\unrealengine-4.15\engine\source\editor\unrealed\private\editorengine.cpp:1630]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor-UnrealEd.dll!UUnrealEdEngine::Tick() [c:\unrealengine-4.15\engine\source\editor\unrealed\private\unrealedengine.cpp:391]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor.exe!FEngineLoop::Tick() [c:\unrealengine-4.15\engine\source\runtime\launch\private\launchengineloop.cpp:3025]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor.exe!GuardedMain() [c:\unrealengine-4.15\engine\source\runtime\launch\private\launch.cpp:166]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor.exe!GuardedMainWrapper() [c:\unrealengine-4.15\engine\source\runtime\launch\private\windows\launchwindows.cpp:134]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor.exe!WinMain() [c:\unrealengine-4.15\engine\source\runtime\launch\private\windows\launchwindows.cpp:210]
[2017.03.26-23.56.13:486][917]LogWindows:Error: UE4Editor.exe!__scrt_common_main_seh() [f:\dd\vctools\crt\vcstartup\src\startup\exe_common.inl:253]
[2017.03.26-23.56.13:486][917]LogWindows:Error: KERNEL32.DLL!0x0000000025388364
[2017.03.26-23.56.13:486][917]LogWindows:Error: ntdll.dll!0x0000000027DD70D1
[2017.03.26-23.56.13:486][917]LogWindows:Error: ntdll.dll!0x0000000027DD70D1
[2017.03.26-23.56.13:486][917]LogWindows:Error:
[2017.03.26-23.56.13:514][917]LogExit: Executing StaticShutdownAfterError
[2017.03.26-23.56.13:521][917]LogWindows: FPlatformMisc::RequestExit(1)
[2017.03.26-23.56.13:521][917]Log file closed, 03/27/17 01:56:13
Do you have any idea what could cause it and how to fix it?

22. 1
Champion
Join Date
Mar 2014
Posts
561
Originally Posted by newicz
Hey getnamo!

Thank you very much for the plugin it is awesome, although I have started using it in 4.15.1 and I have some strange error while emiting event, my unreal crashes with fatal error and in logs I found this:

Do you have any idea what could cause it and how to fix it?
Crash points to https://github.com/getnamo/socketio-...onvert.cpp#L83 which likely means JsonValue->Type dereferencing is failing on a null type pointer. What method are you using to generate the data you're emitting? struct->json? or manual object building? Maybe a blueprint picture or two could help replicating this crash.

Originally Posted by Dannington
Don't know if this helps - I rigged it so I can toggle a connect/disconnect and it crashed (in editor)

Fatal error: [File:\Build\++UE4+Release-4.15+Compile\Sync\Engine\Source\Runtime\Core\Private\GenericPlatform\GenericPlatformMemory.cpp] [Line: 160]
Ran out of memory allocating 4453159313439771895 bytes with alignment 0

KERNELBASE
UE4Editor_Core
UE4Editor_Core
UE4Editor_Core
UE4Editor_Core
UE4Editor_Core
UE4Editor_SocketIOClient!std::basic_string<char,std::char_traits<char>,std::allocator<char> >::_Copy() [c:\program files (x86)\microsoft visual studio 14.0\vc\include\xstring:2196]
UE4Editor_SocketIOClient!std::basic_string<char,std::char_traits<char>,std::allocator<char> >::assign() [c:\program files (x86)\microsoft visual studio 14.0\vc\include\xstring:1155]
UE4Editor_SocketIOClient!sio::client_impl::connect()
UE4Editor_SocketIOClient!sio::client::connect()
UE4Editor_SocketIOClient!<lambda_528b49ce01ebae6e90043a74545a1705>:perator()() [c:\users\danrs\documents\unreal projects\damab_6_0\plugins\socketio-client-ue4\source\socketioclient\private\socketioclientcomponent.cpp:150]
UE4Editor_SocketIOClient!FSIOLambdaRunnable::Run() [c:\users\danrs\documents\unreal projects\damab_6_0\plugins\socketio-client-ue4\source\socketioclient\private\siolambdarunnable.cpp:47]
This should be helpful, looks like it's related to an invalid string pointer or size causing an oversized allocation. Not quite sure yet when I can carve the time to finally fix the disconnect bug. Any possibility to rig up and share a minimal example project that replicates the problem easily?

23. 0
Supporter
Join Date
Dec 2016
Posts
2
Maybe a blueprint picture or two could help replicating this crash.
Sure I can give you whole example as it's very easy, it is clean ThirdPersonExample with starter content with custom GameMode containing only what you can see on screens. It is running with dedicated server in the background with 1 client. Engine version is 4.15.1 here are the screens from Unreal:

Here is the code for my node.js app (in TypeScript):

Code:
import * as express from 'express'
import * as http from 'http'
import * as socketIO from 'socket.io'

import SelectPlayerNation from './src/SelectPlayerNation'

const app = express()
const server = http.createServer(app)
var io = socketIO(server)

io.on('connection', (socket) => {
console.log('Game server connected from: ' + socket.handshake.address)

socket.on('nationize', (msg) => {
console.log('Selecting nation started...')
if (SelectPlayerNation("a", 1)) {
console.log('Nation selected')
socket.emit('nation-selected')
return
}

console.log('Error while selecting nation')
socket.emit('nation-selection-error')
})
})

server.listen(3000, () => {
console.log('Server listen on *:3000')
})
And here is SelectPlayerNation function that is imported:

Code:
export default function GetPlayerNation(sid:string):number {
return 0;
}
PM2 Logs when I run the server and try to run Unreal client:
Code:
C:\Users\newicz\.pm2\pm2.log last 15 lines:
PM2        | 2017-03-29 01:01:30: ===============================================================================
PM2        | 2017-03-29 01:01:30: --- New PM2 Daemon started ----------------------------------------------------
PM2        | 2017-03-29 01:01:30: Time                 : Wed Mar 29 2017 01:01:30 GMT+0200 (Central European Daylight Time)
PM2        | 2017-03-29 01:01:30: PM2 version          : 2.4.2
PM2        | 2017-03-29 01:01:30: Node.js version      : 6.10.1
PM2        | 2017-03-29 01:01:30: Current arch         : x64
PM2        | 2017-03-29 01:01:30: PM2 home             : C:\Users\newicz\.pm2
PM2        | 2017-03-29 01:01:30: PM2 PID file         : C:\Users\newicz\.pm2\pm2.pid
PM2        | 2017-03-29 01:01:30: RPC socket file      : \\.\pipe\rpc.sock
PM2        | 2017-03-29 01:01:30: BUS socket file      : \\.\pipe\pub.sock
PM2        | 2017-03-29 01:01:30: Application log path : C:\Users\newicz\.pm2\logs
PM2        | 2017-03-29 01:01:30: Process dump file    : C:\Users\newicz\.pm2\dump.pm2
PM2        | 2017-03-29 01:01:30: Concurrent actions   : 2
PM2        | 2017-03-29 01:01:30: SIGTERM timeout      : 1600
PM2        | 2017-03-29 01:01:30: ===============================================================================

[STREAMING] Now streaming realtime logs for [all] processes
PM2        | [Watch] Start watching 0
PM2        | Starting execution sequence in -fork mode- for app name:api-app id:0
PM2        | App name:api-app id:0 online
0|api-app  | Server listen on *:3000
0|api-app  | Game server connected from: ::1
EDIT: SOLUTION FOUND
I've found the reason it was emiting the clean event from nodejs app. Once I changed:

Code:
socket.emit('nation-selected')
to

Code:
socket.emit('nation-selected', {})
It worked just fine! Thank you for pointing me into right direction, I will leave this for others that may have problem with that.

Page 2 of 2 First 12