I am stuck with a weird problem. I think that is something easy to solve, but I have been two days trying to fix this issue.
The problem is with a c++ project on Unreal. I want to check if the user is authenticated and I don't want to use UGameSparksComponent for this. Instead I am using this function:
The only diferent is that GetAvailable has its body on the .h, and GetAuthenticated on the .cpp...
Seems like a linking problem, but I have tried to Clean and build...delete build and intermediate folder on your plugin and my project...but the problem persists.
Could you help me with this? It would be apreciated.
I am testing it and the problem seem fixed, but I am having troubles with the connection( I hadn't this error before). Something has changed? I am receiving this message on loop:
UGameSparksModuleLog: Create new connection
UGameSparksModuleLog: WebSocket closed
UGameSparksModuleLog: Received websocket error: DNS Lookup, TLS-handshake or websocket-handshake failed
UGameSparksModuleLog: Got websocket error. Please make sure, that you've setup you credentials.
I did some changes in my code and I used your new methods...I leave to receive the before message, but now I get a new one, and I am completely stucked:
Jesús Torrijo Gimeno
Hello,
I am stuck with a weird problem. I think that is something easy to solve, but I have been two days trying to fix this issue.
The problem is with a c++ project on Unreal. I want to check if the user is authenticated and I don't want to use UGameSparksComponent for this. Instead I am using this function:
bool XXXX::IsAuthenticated()
{
return UGameSparksModule::GetModulePtr()->GetGSInstance().GetAuthenticated();
}
This function fails with the following log error:
error LNK2019: unresolved external symbol "public: bool __cdecl GameSparks::Core::GS::GetAuthenticated(void)const " (?GetAuthenticated@GS@Core@GameSparks@@QEBA_NXZ) referenced in function "public: bool __cdecl XXXX::IsAuthenticated(void)" (?IsAuthenticated@XXXX@@QEAA_NXZ)
but the next one works, and both are on the same file...
bool XXXX::IsGamesparksAvailable()
{
return UGameSparksModule::GetModulePtr()->GetGSInstance().GetAvailable();
}
The only diferent is that GetAvailable has its body on the .h, and GetAuthenticated on the .cpp...
Seems like a linking problem, but I have tried to Clean and build...delete build and intermediate folder on your plugin and my project...but the problem persists.
Could you help me with this? It would be apreciated.
Best regards!
New SDK out. Thank you for waiting!
https://bitbucket.org/gamesparks/gamesparks-cpp-unreal/commits/e89f3e36ed4215ae01442fe6bedc86babbb4fe0b
Cheers,
Omar
1 person has this question
- Oldest First
- Popular
- Newest First
Sorted by Oldest FirstIgnacio Ruiz
Hey,
I'm having this problem too. Any clue?
Best,
Ignacio
1 person likes this
Tech Support
Hi guys, I apologise for the late reply.
The fix is done, the release is soon. I'll update this thread when the new update is out.
Cheers,
Omar
2 people like this
Jesús Torrijo Gimeno
Hi Omar,
Thanks!!
I will wait your update gladly!!
Best,
Jesús
Tech Support
New SDK out. Thank you for waiting!
https://bitbucket.org/gamesparks/gamesparks-cpp-unreal/commits/e89f3e36ed4215ae01442fe6bedc86babbb4fe0b
Cheers,
Omar
1 person likes this
Jesús Torrijo Gimeno
Thanks Omar!
I am going to test it right now :D
Best regards!!
Jesús
Jesús Torrijo Gimeno
Hi Omar,
I am testing it and the problem seem fixed, but I am having troubles with the connection( I hadn't this error before). Something has changed? I am receiving this message on loop:
UGameSparksModuleLog: Create new connection
UGameSparksModuleLog: WebSocket closed
UGameSparksModuleLog: Received websocket error: DNS Lookup, TLS-handshake or websocket-handshake failed
UGameSparksModuleLog: Got websocket error. Please make sure, that you've setup you credentials.
UGameSparksModuleLog: Backing off for one seconds
And I do the connectio like follow:
UGameSparksComponent* GameSparksComponent = GameMode->CreateDefaultSubobject<UGameSparksComponent>(TEXT("GameSparksCom"));
GameSparksComponent->OnGameSparksAvailableDelegate.AddDynamic(this, &UCloud::OnGameSparksAvailable);
GameSparksComponent->Connect("player/XXXX", "XXXXXX", true);
Have I to change something?
Best regards!!
Jesús
Jesús Torrijo Gimeno
Hi Omar,
I did some changes in my code and I used your new methods...I leave to receive the before message, but now I get a new one, and I am completely stucked:
MY CODE-->
LOG-->
UGameSparksModuleLog: Create new connection
UGameSparksModuleLog: WebSocket callback: {"@class":".AuthenticatedConnectResponse","nonce":"mynonce","requestId":"0"}
UGameSparksModuleLog: Handle authentication connect response with immediate handshake
UGameSparksModuleLog: Send immediate request: {
"@class": ".AuthenticatedConnectRequest",
"hmac": "mymacid",
"os": "Windows",
"platform": "Windows",
"deviceId": "mydeviceid"
}
UGameSparksModuleLog: Handshake request sent
UGameSparksModuleLog: WebSocket callback: {"@class":".AuthenticatedConnectResponse","error":"VALIDATION FAILURE","requestId":"0"}
UGameSparksModuleLog: Handle authentication connect response with immediate handshake
UGameSparksModuleLog: Got error during handshake. Please make sure, that you've setup you credentials.
UGameSparksModuleLog: Backing off for five seconds
Am I missing something?
Best regards!!
Jesús
Jesús Torrijo Gimeno
I have found the problem!
The problem were on GameSparksModule, so I made a pull request to fix it. Now all works perfectly. I hope this helps!
https://bitbucket.org/gamesparks/gamesparks-cpp-unreal/pull-requests/3/gamesparksmodule-fixed-credentials-stage/diff
Best regards!!
Jesús
Customer Support
Hi Jesus,
Glad to hear you fixed the issue. I'll pass this information on to the SDK team.
Regards,
Liam
Tech Support
Hi Jesus,
why are you using the following:
GameSparksComponent->SetApiDomain("");
Can you try to connect without using that line?
And again I'm sorry for the late reply, we're having a transitional period here at GameSparks that means I don't have enough time on the forums.
Cheers,
Omar
Jesús Torrijo Gimeno
Hi Omar.
Don't worry. Yes, I also tryed this way, but this problem was solved with the pull request that I sent a week ago and you accepted.
All is fine now!
Thansk again!
Best regards!
Jesús
-
Documentation Notes
-
Design issues with user events
-
Using NoSQL
-
Runtime Collections vs Metadata Collections
-
Anonymous authentication from browser app
-
Modules
-
Movement With Unity
-
Problem with url parameters for downloadables
-
Querying NoSql GameSparks database
-
Challenge accesType
See all 2486 topics