Lesson 6 - Adaptable board size



In this chapter, we will Learn how to create an adaptable board size.

One of the factors channel owners think about, before choosing a game to use at their site, is the size of the game,
some channel owners will want the game as big as possible, while others will want a smaller version to fit the design of their page.

To make your game more popular you can let them have control over the size of your game, making it a perfect fit, no matter what size is required.

In our game, during the getCustomInfo callback, we call T.custom(CUSTOM_INFO_KEY_gameWidth, 300) to get the game’s width as desired by the channel owner, 300 is the default width for our game in case the channel owner doesn’t have any preferences.

And we call T.custom(CUSTOM_INFO_KEY_gameHeight, 300) to get the game’s height as desired by the channel owner, 300 is the default height for our game.