essential.winnerResult
Prototype
function winnerResult(nameScores)
Input parameters
nameScores - array of names and scores with the results of the game
Return value
null
Description
Called at the end of a game. The nameScores object contains an array of all the players in the game, sorted by score. This is normally the place to send a data packet to all the players in the game with the results.
Example code
function winnerResult(nameScores)
{
trace("Winner result");
for (var i=0;i< nameScores.length;i++)
{
trace(nameScores[i].player+" got "+nameScores[i].score);
}
}
