question

janphilippstruck avatar image
janphilippstruck asked

CSharp SDK how to start,CSharpSDK how to start

Hey

I'm a completely newbie with c#, so my question could sound a little bit weird

I want to design a Multiplayer RPG with Discord Chat and Playfab.

I downloaded the CSharp SDK from GitHub (https://github.com/PlayFab/CSharpSDK) and opened the one with the example project (UUNitTestRunner)

I created a json file like the readme told me to do

now, when I debug the UUnitTestRunner, he checks for the args.Length, but it remains 0

so he's not trying to read any testInputFiles and I don't know where to start

please help and explain in a simple manner what am I doing wrong and where I should start?`

Thanks in advance, Struck

sdksPartner Add-ons
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

brendan avatar image
brendan answered

How is your testTitelData.json set up (step 5 in the readme for the CSharpSDK in GitHub)? Please be sure to not post your developer secret key or password, obviously.

Also, what are you passing in for the testInputsFile command line parameter? Can you make sure it correctly points the executable to the actual location of your testTitelData.json?

4 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

janphilippstruck avatar image janphilippstruck commented ·

Thanks for the fast response! Appreciate it

I just created a editor file and saved it with .json. It's in the same directory as the PlayFabSDK Project File and it looks like this:

"titleId": "XXXX",

"developerSecretKey": "..................................",

and so on

"Also, what are you passing in for the testInputsFile command line parameter? Can you make sure it correctly points the executable to the actual location of your testTitelData.json?"

thats the main problem. I guess I don't really understand what to do :/

Thanks again @Brendan!!

0 Likes 0 ·
brendan avatar image brendan janphilippstruck commented ·

The testInputsFile parameter tells the program where to find your JSON file. So, for example, if you saved it to the same folder as the executable, you would launch your exe with something like:

game.exe -testInputsFile myfile.json

0 Likes 0 ·
janphilippstruck avatar image janphilippstruck brendan commented ·

alright, I'm making progress

just to be sure:

There is a Visual C# Project File and an executable in the /bin folder with the same name

I renamed both of them to "UnittestRunner -testInputsFile InputFile.json" and put the InputFile.json into the same directory. I double checked both of them, none of them having args, so he's skipping the PlayFabApiTest part completely

if needed, I can share screenshots as well

0 Likes 0 ·
Show more comments
janphilippstruck avatar image
janphilippstruck answered

Alrighty, I found a way to pass the arguments in visual studio (Debug, Settings, ...)

now let's see how far I'll come, thanks so far :)


1 comment
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

brendan avatar image brendan commented ·

Hmm... That would be because the SaveTestData Cloud Script isn't in the SDK. I'll get that updated today.

0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.