Hello Brian,
I'm going to add a paragraph on this on documentation.
In the meantime, you can check out how it is working on Gomoku to display an additional counter:
First, you write your HTML template for your game panels at the end of your TPL file:
Code: Select all
var jstpl_player_board = '\<div class="cp_board">\
<div id="stoneicon_p${id}" class="gmk_stoneicon gmk_stoneicon_${color}"></div><span id="stonecount_p${id}">0</span>\
</div>';
Then, you add this piece of code in your JS file to add this template to each player panel:
Code: Select all
// Setting up player boards
for( var player_id in gamedatas.players )
{
var player = gamedatas.players[player_id];
// Setting up players boards if needed
var player_board_div = $('player_board_'+player_id);
dojo.place( this.format_block('jstpl_player_board', player ), player_board_div );
}
And that's it! After that, you can use this HTML part of the game interface as any other part of your HTML interface in the main game area.
Cheers,