Professional Documents
Culture Documents
Untitled Document
Untitled Document
Untitled Document
//Maximum Input
onEvent("maxInput", "input", function( ) {
filter(getText("maxInput"));
updateScreen();
});
//Function
var filterGameList = [];
var game;
function filter(maxInput) {
for (var i = 0; i < nameList.length; i++) {
game = nameList[i];
if (maxInput == maxList[i]) {
appendItem(filterGameList, game);
}
}
}
function reset() {
filterGameList = [];
}
//Update Screen
function updateScreen() {
var text = "Board Games: " + "\n" + filterGameList;
setText("text_area1", text);
reset();
}