better scripts

This commit is contained in:
Kyle
2018-11-18 20:39:43 -08:00
parent 7b71a1911b
commit d1fd6281f8
14 changed files with 203 additions and 52 deletions

View File

@@ -0,0 +1,9 @@
//loadColors("white-White,blue-Blue,colorlessLand-Colorless Land,gold-Gold"), this is an example of how to use the function
function loadColors(colors) {
var endResult = ""
var colorList = colors.split(",")
for (i = 0; i < colorList.length; i++) {
endResult += "<option value='" + colorList[i].split("-")[0] + "'>" + colorList[i].split("-")[1] + "</option>"
}
document.getElementById("colorSelection").innerHTML = endResult
}