// Tell the api to listen for the SCORES_LOADED event
API.addEventListener(APIEvent.SCORES_LOADED, onScoresLoaded);

// get our board and tell it what time period to load up, and how many results
var high_scores:ScoreBoard = API.getScoreBoard("High Scores");
high_scores.period = "Today";
high_scores.num_results = 20;

// Tell the api to listen for the SCORES_LOADED event
API.addEventListener(APIEvent.SCORES_LOADED, onScoresLoaded, this);

// get our board and tell it what time period to load up, and how many results
var high_scores:ScoreBoard = API.getScoreBoard("High Scores");
high_scores.period = "Today";
high_scores.num_results = 20;