Setting up Tournaments and Gameplay Parameters
Tournaments and gameplay parameters allow you to further customize your game on Skillz. Tournaments allow you to specify the types of matches your game offers, while gameplay parameters can be used to alter the runtime behavior of your game.
Tournaments
Skillz offers you the ability to set up several different types of tournaments through which players can compete for virtual points, or cash. You can set up Tournaments in the Skillz Developer Console:
How Tournaments Work
In Skillz, tournaments are either asynchronous (what we call Play and Compare) or Real-Time Synchronous.
Play and Compare tournaments are asynchronous. This means players do not have to wait to be matched with another person and compete in realtime. Instead, any time a player enters a tournament they will immediately be put into a game. Their score will be recorded and matched against another player with a similar rating. If a match isn’t immediately found, Skillz will hold on to that player’s score and wait for another player with matching skill to enter the same tournament.
In Real-Time Synchronous tournaments, players are matched with another person and compete in real-time. Any time a player enters a tournament they must wait for another player to enter before being put into a game. Each player will see the opponent's progress in real-time, and aborting will immediately end the tournament.
Types of Tournaments
Head to Head Tournaments
These are the “standard” type of tournament, pitting two players directly against each other in a winner-take-all competition. Most Skillz games implement this kind of tournament, and they’re the best kind when still in the process of building up your player population.
Multiple Player Tournaments
In Multiple Player tournaments, you can have four players compete for the best score in the game. As in Head to Head, a lone winner takes all of the proceeds. These tournaments are best suited for games with large player populations, as more players are needed to fill in these games.
If your game supports standard tournaments, then it already supports Multiple Player tournaments as well! The differences between the two are all managed by Skillz.
Cash or Virtual Currency
Players in Skillz tournaments can choose between competing for Skillz Virtual Currency (known as 'Z') or for real money. While 'Z' may be used for certain in-Skillz purchases, only cash can be withdrawn from the system.
Editing Tournaments
Different tournaments can be configured from your game’s page on the Skillz Developer Console. These tournaments may use both 'Z' and cash. There, you can experiment with different tournaments and identify the ones that are most popular with your player base.
Along with configuring different tournament types and price levels, you can also customize different types of games by setting up Gameplay Parameters on the Skillz Developer Console.
Gameplay Parameters
The Skillz Developer Console allows you to set up different types of tournaments for your game. Additionally, you can configure each tournament to have specific gameplay parameters. These are essentially key-value pairs that you set up on the Skillz Developer Console. When a match begins, you can retrieve these parameters.
Purpose
So, what's the purpose of setting up gameplay parameters? In essence, gameplay parameters allow you to modify your game's gameplay behavior at runtime. Some examples of gameplay parameters include:
- Size or length of the game
- Level of difficulty and how difficulty increases over time
- Different characters or weapon loadouts
- Points for specific actions
- Bonuses for achievements
- Different game objectives
As you can see, the possibilities are endless. When set up thoughtfully, gameplay parameters can increase user engagement for your game and therefore increase monetization opportunities. If anything, they're an easy way to add excitement and replayability to your game.
Setting Up Gameplay Parameters
Gameplay parameters are set up in the Skillz Developer Console for your game. Please head over there and set some up before attempting to retrieve them from your game.
If your game is made with Unity, you can simulate gameplay parameters using the Skillz Unity Companion.
Retrieving Gameplay Parameters
Now that you have gameplay parameters set up, retrieving them is fairly straightforward. When a match begins, Skillz will send your gameplay parameters as key-value pairs. Each value is sent as a string, so you'll have to convert each value to the desired data type. The examples below retrieve a TimeLimit
gameplay parameter that is parsed as an integer.
- Unity/C#
- iOS/Swift
- iOS/Objective-C
- Android/Java
#import <UIKit/UIKit.h>
#import <Skillz/Skillz.h>
@interface AppDelegate : UIResponder <UIApplicationDelegate, SkillzDelegate>
@end
#import "AppDelegate.h"
#import <Skillz/SkillzInstance.h>
@implementation AppDelegate
- (void)tournamentWillBegin:(NSDictionary *)gameParameters withMatchInfo:(SKZMatchInfo *)matchInfo
{
if ([gameParameters objectForKey:@"TimeLimit"]) {
NSString *str= [gameParameters objectForKey:@"TimeLimit"];
int timeLimit = [str intValue];
// Modify your game's time limit for this match
}
}
import UIKit
import Skillz
class AppDelegate : UIApplicationDelegate, SkillzDelegate {
func tournamentWillBegin(_ gameParameters: [AnyHashable : Any]!, with matchInfo: SKZMatchInfo!) {
if gameParameters[AnyHashable("TimeLimit")] != nil {
let str = gameParameters[AnyHashable("TimeLimit")] as? String;
let timeLimit = Int(str!);
// Modify your game's time limit for this match
}
}
}
import com.skillz.SkillzActivity;
public class MainActivity extends SkillzActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
view = new MainView(this);
setContentView(view);
if (!Skillz.isMatchInProgress()) {
return;
}
Map<String, String> gameplayParameters = Skillz.getMatchRules();
if (!gameplayParameters.containsKey("TimeLimit")) {
return;
}
int timeLimit = Integer.parseInt(gameplayParameters.get("TimeLimit"));
// Modify your game's time limit
}
}
In this example, MainActivity
is the activity that will be launched when a match begins. As a precaution, we call Skillz.isMatchInProgress()
to check if the there actually is a match; otherwise, there won't be any gameplay parameters to retrieve.
After that, the TimeLimit
gameplay parameter is retrieved and parsed into an integer.
using SkillzSDK;
using UnityEngine.SceneManagement;
public sealed class SkillzGameController : SkillzMatchDelegate
{
public void OnMatchWillBegin(Match matchInfo)
{
if (matchInfo.GameParams.ContainsKey("TimeLimit"))
{
string timeLimitStr = matchInfo.GameParams["TimeLimit"];
int timeLimit = int.Parse(timeLimitStr);
// Modify your game's time limit
}
}
}
In this example, SkillzGameController
implements the SkillzMatchDelegate
interface so that it can be notified when a match is beginning. when that happens, OnMatchWillBegin()
will be called and provides gameplay parameters in the matchInfo
parameter.