Hello, after searching information i dont know what i should do to package project with this plugin. I add plugin to project build.cs and set in uplugin file “installed- true” I always have error with UE4-SIOJson.lib no mater what i do package project in unreal 4.17.1, or try compile in VS2017 . Just for example this log from unreal:If anyone know right action to decide this i would glad to learn it. [SPOILER] UATHelper: Packaging (Windows (32-bit)): Running AutomationTool…
UATHelper: Packaging (Windows (32-bit)): Automation.ParseCommandLine: Parsing command line: -ScriptsForProject=F:/UnrealProjects/HarvySport/HarvySport.uproject BuildCookRun -nocompile -nocompileeditor -installed -nop4 -project=F:/UnrealProjects/HarvySport/HarvySport.uproject -cook -stage -archive -archivedirectory=“F:/new folder” -package -clientconfig=Devel
opment -ue4exe=UE4Editor-Cmd.exe -pak -prereqs -nodebuginfo -targetplatform=Win32 -build -utf8output
UATHelper: Packaging (Windows (32-bit)): BuildCookRun.SetupParams: Setting up ProjectParams for F:\UnrealProjects\HarvySport\HarvySport.uproject
UATHelper: Packaging (Windows (32-bit)): Project.Build: ********** BUILD COMMAND STARTED **********
UATHelper: Packaging (Windows (32-bit)): CommandUtils.Run: Run: F:\Program Files\Epic Games\UE_4.17\Engine\Binaries\DotNET\UnrealBuildTool.exe HarvySport Win32 Development -Project=F:\UnrealProjects\HarvySport\HarvySport.uproject F:\UnrealProjects\HarvySport\HarvySport.uproject -NoUBTMakefiles -remoteini=“F:\UnrealProjects\HarvySport” -skipdeploy -noxge -g
eneratemanifest -NoHotReload
UATHelper: Packaging (Windows (32-bit)): CommandUtils.Run: Run: Took 1,0965408s to run UnrealBuildTool.exe, ExitCode=0
UATHelper: Packaging (Windows (32-bit)): CommandUtils.Run: Run: F:\Program Files\Epic Games\UE_4.17\Engine\Binaries\DotNET\UnrealBuildTool.exe HarvySport Win32 Development -Project=F:\UnrealProjects\HarvySport\HarvySport.uproject F:\UnrealProjects\HarvySport\HarvySport.uproject -NoUBTMakefiles -remoteini=“F:\UnrealProjects\HarvySport” -skipdeploy -noxge -N
oHotReload -ignorejunk
UATHelper: Packaging (Windows (32-bit)): UnrealBuildTool: Performing 13 actions (4 in parallel)
UATHelper: Packaging (Windows (32-bit)): UnrealBuildTool: ERROR: UBT ERROR: Failed to produce item: F:\UnrealProjects\HarvySport\Plugins\socketio-client-ue4\Binaries\Win32\UE4-SIOJson.lib
UATHelper: Packaging (Windows (32-bit)): UnrealBuildTool: Total build time: 5,19 seconds (Local executor: 0,00 seconds)
UATHelper: Packaging (Windows (32-bit)): CommandUtils.Run: Run: Took 5,3766014s to run UnrealBuildTool.exe, ExitCode=5
UATHelper: Packaging (Windows (32-bit)): Program.Main: ERROR: AutomationTool terminated with exception: AutomationTool.CommandUtils+CommandFailedException: Command failed (Result:5): F:\Program Files\Epic Games\UE_4.17\Engine\Binaries\DotNET\UnrealBuildTool.exe HarvySport Win32 Development -Project=F:\UnrealProjects\HarvySport\HarvySport.uproject F:\UnrealP
rojects\HarvySport\HarvySport.uproject -NoUBTMakefiles -remoteini=“F:\UnrealProjects\HarvySport” -skipdeploy -noxge -NoHotReload -ignorejunk. See logfile for details: ‘UnrealBuildTool-2017.09.11-04.11.32.txt’
UATHelper: Packaging (Windows (32-bit)): в AutomationTool.CommandUtils.RunAndLog(String App, String CommandLine, String Logfile, Int32 MaxSuccessCode, String Input, ERunOptions Options, Dictionary2 EnvVars, SpewFilterCallbackType SpewFilterCallback) UATHelper: Packaging (Windows (32-bit)): в AutomationTool.CommandUtils.RunAndLog(CommandEnvironment Env, String App, String CommandLine, String LogName, Int32 MaxSuccessCode, String Input, ERunOptions Options, Dictionary
2 EnvVars, SpewFilterCallbackType SpewFilterCallback)
UATHelper: Packaging (Windows (32-bit)): в AutomationTool.CommandUtils.RunUBT(CommandEnvironment Env, String UBTExecutable, String CommandLine, String LogName, Dictionary2 EnvVars) UATHelper: Packaging (Windows (32-bit)): в AutomationTool.CommandUtils.RunUBT(CommandEnvironment Env, String UBTExecutable, FileReference Project, String Target, String Platform, String Config, String AdditionalArgs, String LogName, Dictionary
2 EnvVars)
UATHelper: Packaging (Windows (32-bit)): в AutomationTool.UE4Build.BuildWithUBT(String TargetName, UnrealTargetPlatform TargetPlatform, String Config, FileReference UprojectPath, Boolean ForceMonolithic, Boolean ForceNonUnity, Boolean ForceDebugInfo, Boolean ForceFlushMac, Boolean DisableXGE, String InAddArgs, Boolean ForceUnity, Dictionary2 EnvVars) UATHelper: Packaging (Windows (32-bit)): в AutomationTool.UE4Build.Build(BuildAgenda Agenda, Nullable
1 InDeleteBuildProducts, Boolean InUpdateVersionFiles, Boolean InForceNoXGE, Boolean InUseParallelExecutor, Boolean InForceNonUnity, Boolean InForceUnity, Boolean InShowProgress, Dictionary2 PlatformEnvVars, Nullable
1 InChangelistNumberOverride, Diction
ary2 InTargetToManifest) UATHelper: Packaging (Windows (32-bit)): в Project.Build(BuildCommand Command, ProjectParams Params, Int32 WorkingCL, ProjectBuildTargets TargetMask) UATHelper: Packaging (Windows (32-bit)): в BuildCookRun.DoBuildCookRun(ProjectParams Params) UATHelper: Packaging (Windows (32-bit)): в BuildCookRun.ExecuteBuild() UATHelper: Packaging (Windows (32-bit)): в AutomationTool.BuildCommand.Execute() UATHelper: Packaging (Windows (32-bit)): в AutomationTool.Automation.Execute(List
1 CommandsToExecute, Dictionary2 Commands) UATHelper: Packaging (Windows (32-bit)): в AutomationTool.Automation.Process(String] Arguments) UATHelper: Packaging (Windows (32-bit)): в AutomationTool.Program.MainProc(Object Param) UATHelper: Packaging (Windows (32-bit)): в AutomationTool.InternalUtils.RunSingleInstance(Func
2 Main, Object Param)
UATHelper: Packaging (Windows (32-bit)): в AutomationTool.Program.Main()
UATHelper: Packaging (Windows (32-bit)): Program.Main: AutomationTool exiting with ExitCode=5 (5)
UATHelper: Packaging (Windows (32-bit)): BUILD FAILED
PackagingResults: Error: Unknown Error[/SPOILER]
Update: Compile in VS2017 and package in UE4 success but only in win64, in win32 i still get error and in VS2017 get MSB3075…
-waitmutex" exited with code 5. Please verify that you have sufficient rights to run this command.
Is it related to https://github.com//socketio-…ue4/issues/62 ? try altering your .uplugin to Default to SIOJson.
Hi Everybody!
Has anyone tried to use the socket.io UE4 plugin on Unreal Engine 4.18?
Is it compatible at the moment?
The git master repo is now UE 4.18 compatible (since 0.6.5). If you don’t mind compiling the plugin yourself you can grab it at https://github.com//socketio-client-ue4. I’m however still looking to fix an outstanding issue or two before releasing a 4.18 binary.
I am trying to integrate the plugin in my own editor plugin module using the non-actor-component approach. Added the entry “SocketIOClient” in publicdependencymodule list as well as private and public include paths in PublicIncludePaths and PrivateIncludePaths. No error when I include the “SocketIONative.h” in my PCH and declare a TSharedPtr<FSocketIONative> it compiles but when I create the object through Makesharable then I get the “error LNK2019: unresolved external symbol “public: __cdecl FSocketIONative::FSocketIONative(void)”” error. Using 4.16.
Some sanity checks: Does the SIOClientComponent method work?
I’m assuming you’re following the guide https://github.com//socketio-client-ue4#setup which should work, but I haven’t tested making FSocketioNative across module boundaries. You can try adding SOCKETIOCLIENT_API infront of https://github.com//socketio-client-ue4/blob/master/Source/SocketIOClient/Public/SocketIONative.h#L15, let me know if that works.
Adding SOCKETIOCLIENT_API did the trick.
Thanks
**Plugin Update to 0.7.0
Changes**
- Compile fixes for 4.18
- New Plugin scoped memory architecture for reliable and fast FSocketIONative management. Candidate fixes for #44](https://github.com//socketio-client-ue4/issues/44), #45](https://github.com//socketio-client-ue4/issues/45), #55](https://github.com//socketio-client-ue4/issues/55), #56](https://github.com//socketio-client-ue4/issues/56), #57](https://github.com//socketio-client-ue4/issues/57), #60](https://github.com//socketio-client-ue4/issues/60), and #63](https://github.com//socketio-client-ue4/issues/63). If you were having any of those problems, try the new plugin and give it a good test. Re-open if issues persist. Architecture merged in as f17df08
- New optional fully plugin-scoped connections which remain even through level transitions. Tick bPluginScopedConnection true and ensure your component before and after use the same PluginScopedId. Unless disconnect is manually called these type of connections will only close on app exit.
- New OnConnectionProblems callback with verbose signature allowing you to detect when you get disconnected while the socket.io client is still trying to reconnect (default: always trying infinite times). If you wish to change this behavior new parameters have been exposed which control connection attempts and delay.
- New default toggle bVerboseConnectionLog allows you to quiet your log. Default is true.
- Blueprint TMap support added! This should be a massive boost to productivity if you used map like data structures. Issue #59](https://github.com//socketio-client-ue4/issues/59) fix merged in f640f63
- Auto-conversion for As String if string type not supplied. Issue #64](https://github.com//socketio-client-ue4/issues/64) merged in 2b118c4
- Direct convenience function binds added. This allows you to bind an event or callback to a blueprint function with e.g. String signature only if you know the data type will be a string. See emit with callback section for a list of supported signatures. Issue #65](https://github.com//socketio-client-ue4/issues/65) fix merged in 591c150
- FSocketIONative now exposed as API. Issue #66](https://github.com//socketio-client-ue4/issues/66) merged in 7e32f70 spotted by GeneralD
This is a big update. Lot’s of potential crashes should now be fixed with the new architecture, there’s a new plugin scoped connection type, a new callback for connection problems, a few productivity enhancements when using blueprints, and misc utility stuff.
Kindly test it and let me know if new bugs creep up!
Grab it at the usual https://github.com//socketio-client-ue4/releases
Hi! I have a question, is there any way to transform the chat widget to a UMG 2D component? I’d like to “attach” it to a player’s screen/camera lika a common chatbox, and rendering it like a 3D asset it’s quite tricky for my needs x)
Thanks!
You probably want to read up on how to add widgets to game UI, see Creating Widgets in Unreal Engine | Unreal Engine 5.3 Documentation. I’m assuming you’re using the example project, https://github.com//socketio-client-ue4-example, in that case you want to attach the *sioclient/Content/ExampleContent/ChatBoxWidget.uasset *to your game UI.
Thanks for the answer! I know how to create widgets and put them into the viewport, but I’m having trouble migrating the logic from the ChatWindowActor (to open the input text and send messages etc.) to my character (casting problems in a different places, such as in the function SetupWidgetLinks). What procedure should I follow to achieve it? I’m kinda lost
Edit: okay, I think I managed to get it working. I had to make my character inherit from the ChatEmitter interface, and that was almost it. I also have got a reference of my chatboxwidget (just added to the viewport) to link it with the messages.
Thanks!
Hi !
First of all, congrats on your awesome plugin work, you are awesome!
I wanted to ask you something about Linux cross-compiling, as I’m trying to compile a Linux Server with your plugin but it fails in this line:
PrivateClient->connect(StdAddressString, QueryMap, HeadersMap);
With this message:
SocketIONative.cpp:51: undefined reference to sio::client::connect(std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator > const&, std::__1::map<std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, std::__1::less<std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator > const, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator > > > > const&, std::__1::map<std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator >, std::__1::less<std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator > >, std::__1::allocator<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator > const, std::__1::basic_string<char, std::__1::char_traits, std::__1::allocator > > > > const&)'`
What is your Linux compiling setup? I’m using the basic config for cross-compile that is shown in the Unreal Engine wiki.
thank you!
Hi !
I’ve encountered a problem when switching to reliable (with acknowledge) messages from server to client.
I’ve saw your implementation of Emit with Callback that allows the server to reply affirmative if it successfully received a message from the client, but now I need to implement the other acknowledgment direction (get a callback from client after a server emit).
To accomplish this, I think that I need to call a server defined function from the client, but the OnEvent (SocketIOClient) event only have two arguments instead of the required three (the actual implementation have Event and Message JSON but in order to accomplish this it should have Event, Message JSON and Server Ack Function)
Is it possible to extend the behaviour of the OnEvent implementation and enable it to reply a server acknoledgement request by function?
On the below link you can find some references:
https://socket.io/docs/server-api/#socketemiteventname-args-ack
And here you find the important code snippet:
io.on(‘connection’, (socket) => { socket.emit(‘an event’, { some: ‘data’ }); socket.emit(‘ferret’, ‘tobi’, (data) => { console.log(data); // data will be ‘woot’ }); // the client code // client.on(‘ferret’, (name, fn) => { // fn(‘woot’); // }); }); Thanks in advance!
Meanwhile, I’ve used another emit instead of callback and implemented a proprietary message id dequeue system (for reliability).
Anyway, I think this could be an interesting feature for future releases
Agreed. This would need a little think on how to create a callback reference in blueprint so I’ve added it to issues as an enhancement here: https://github.com//socketio-client-ue4/issues/79
Thanks a lot you are so awesome!
Can’t wait to try it
Hey,
running a bit of a headache here, i’d appreciate any help with this great plugin.
i’m using a button to connect and disconnect ( not using the auto-connect ).
my problem is, if you connect - disconnect - connect, the connection will fail, if you try to connect again while connection is failing, this crash happens :
Fatal error: [File:D:\Build\++UE4+Release-4.19+Compile\Sync\Engine\Source\Runtime\Core\Private\GenericPlatform\GenericPlatformMemory.cpp] [Line: 183] Ran out of memory allocating 787246532583 bytes with alignment 0
KERNELBASE
UE4Editor_ApplicationCore
UE4Editor_Core
UE4Editor_Core
UE4Editor_Core
UE4Editor_Core
UE4Editor_Core
UE4Editor_SocketIOClient!std::_Allocate<std::_Default_allocate_traits<1> >()
UE4Editor_SocketIOClient!std::basic_string<char,std::char_traits<char>,std::allocator<char> >::assign()
UE4Editor_SocketIOClient!sio::client_impl::connect()
UE4Editor_SocketIOClient!<lambda_599c41d4c2235fe6cf505ad2fc4823d6>::operator()() [c:\XXX\plugins\socketio-client-ue4-master\source\socketioclient\private\socketionative.cpp:51]
UE4Editor_CoreUtility!FLambdaRunnable::Run() [c:\XXX\plugins\socketio-client-ue4-master\source\coreutility\private\lambdarunnable.cpp:47]
UE4Editor_Core
UE4Editor_Core
kernel32
ntdll
kindly post issue to https://github.com//socketio-client-ue4/issues with plugin version and steps to reproduce.
Cheers for bug catching!
it deosn’t work with me and i don’t know whats is wrong ! i did everything like the tutorial and it just didnt work , any help ?
I want to execute a basic url call with static void CallURL() function. Where do i have to connect the delegate pointer in blueprint which is called by reference?