Playfab Quick Start - Unable to update gui script?

Hello All,

I was going through the playfab quick start guide and was not able to edit the gui_script.

I see some changes in the editor as there was no option to open it in text editor. Seems like the quick start is not updated, can someone tell me how to update it ?

Thanks, Appreciate your help.

Why were you not able to edit the script?

The guide is horribly outdated, but it is available on GitHub so someone could submit an update. We’ve offered to partner with Microsoft to keep the documentation up to date and provide support, but MS has so far not been interested in our offer. I hope someone invested in PlayFab will submit an update or at least let MS know that the documentation is old and incorrect.

I am sharing the screenshots for your reference : -


According to the doc, it says In the **Defold** editor, right-click **PfGettingStarted.gui** -> **Open With** -> **Text Editor** . but there is no Open With I can only see Open As. There is no Text Editor its just Text.


In the editor I can’t paste anything as its not taking keyboard input or has any option to paste

Ah, I see. Open the .gui file in an external editor.

1 Like

Is it something we have to do externally or it can be configured in Defold’s editor itself ?

You can define a custom editor from the preferences popup.

BUT to be honest I do understand why MS didn’t decide to provide proper instructions for this part. (They do mentioned that “Our instructions for PfGettingStarted.gui are for expediency, not instruction” but that is really not very helpful).

The correct and updated tutorial should look something like this:

  1. In the Defold editor, open PfGettingStarted.gui.
  • Select the Gui root in the Outline
    • In the Script field in the Properties panel select the main/PfGettingStarted.gui_script

  • Right-click on Fonts in the Outline and select Add->Font
    • Select system_font.font from the list.

addfont

  • Right-click on Nodes in the Outline and select Add->Text
    • Select the new text node and in the Properties panel change the Id to pfOutput
    • Set the font to system_font
    • Move the text node so it is centered in the gui.
    • Set the text to “Logging in…”

1 Like

I got the following error : -

clojure.lang.ExceptionInfo: handler ':open-as' in context ':global' failed at ':run' with message 'Cannot run program "Sublime" (in directory "/Users/Mymac/Projects/Defold Projects/TestPlayFab"): error=2, No such file or directory'
java.io.IOException: Cannot run program "Sublime" (in directory "/Users/Mymac/Projects/Defold Projects/TestPlayFab"): error=2, No such file or directory
java.io.IOException: error=2, No such file or directory

You may need to provide the entire path (ie /Applications/Sublime"). Or try Sublime.app.

Sharing the screenshot for more clarity : -

With this i got the error : -

This can happen if the file type is not mapped to an application in your OS.

Underlying error from the OS:
Failed to open, edit or print /Users/Mymac/Projects/Defold Projects/TestPlayFab/main/PfGettingStarted.gui_script. Error code: -10814

Try:

/Applications/Sublime.app/Contents/MacOS/Sublime

And double check your path locally!
My app is called ”Sublime\ Text.app”

this is the path : - /Applications/Sublime Text.app

anyway, I edited it externally and everything is working as expected now!

2 Likes