CloudScriptSamples
CloudScriptSamples copied to clipboard
Sample scripts demonstrating custom game logic for hosting in PlayFab.
Cloud Script Samples README
- Overview:
This repository contains several examples on how to use Cloud Script in PlayFab.
- Prerequisites:
To get the most from these samples you should be very familiar with PlayFab's Cloud Script service. Check out our Cloud Script getting started guide.
To connect to the PlayFab service, your machine must be running TLS v1.1 or better.
- For Windows, this means Windows 7 and above
- Official Microsoft Documentation
- Support for SSL/TLS protocols on Windows
- Source Code & Key Repository Components:
- BasicSample/basic_sample.js -- This is the default Cloud Script which is automatically created as revision 1 for all new titles, demonstrating basics of using Cloud Script including Photon webhook integration.
- Rewards/CloudScript_Rewards.js -- A Cloud Script file illustrating simple methods that read and write to a player's internal data as well as grant inventory items.
- Installation & Configuration Instructions:
- Rewards/CloudScript_Rewards.js -- Upload it to your title via the PlayFab Game Manager by going to Servers > Cloud Script.
- BasicSample/basic_sample.js -- Upload it to your title via the PlayFab Game Manager by going to Servers > Cloud Script.
- Photon-Cloud-Integration -- This is a pointer to our repro showing the full Photon Cloud sample for PlayFab.
- Usage Instructions:
- Rewards/CloudScript_Rewards.js -- As with any Cloud Script file, you can trigger any handlers._____ method from RunCloudScript. Note that you must first establish the correct URL for your Cloud Script via a call to GetCloudScriptUrl.
- BasicSample/basic_sample.js -- As with any Cloud Script file, you can trigger any handlers._____ method from RunCloudScript. Note that you must first establish the correct URL for your Cloud Script via a call to GetCloudScriptUrl.
- Photon-Cloud-Integration -- Please see the Photon Cloud sample for PlayFab.
- Troubleshooting:
For a complete list of available APIs, check out the online documentation.
Contact Us
We love to hear from our developer community! Do you have ideas on how we can make our products and services better?
Our Developer Success Team can assist with answering any questions as well as process any feedback you have about PlayFab services.
Forums, Support and Knowledge Base
- Copyright and Licensing Information:
Apache License -- Version 2.0, January 2004 http://www.apache.org/licenses/
Full details available within the LICENSE file.
- Version History:
- (v1.00) Initial Release
- (v1.10) Updated for latest changes to examples