fix palette matching regex

This commit is contained in:
synth_ruiner 2019-03-31 14:23:58 +01:00
parent eec0bdeb12
commit ed714df4cd
1 changed files with 3 additions and 1 deletions

View File

@ -109,7 +109,7 @@ $(document).ready(function() {
bitsyData = {}; bitsyData = {};
// get palettes // get palettes
var palettes = input.match(/PAL (.*)\s(NAME (.*)\s)?([0-9,]*[\s]){3}/g); var palettes = input.match(/PAL ([^\n]*)\n(NAME ([^\n]*)\n)?(([0-9,]+){3}\n){3,}/g);
bitsyData.palettes = {}; bitsyData.palettes = {};
@ -544,6 +544,8 @@ $(document).ready(function() {
// write // write
$textArea.val(newGameData); $textArea.val(newGameData);
handleBitsyGameData();
// todo: give the user some nice "yay! it worked!" kinda feedback? // todo: give the user some nice "yay! it worked!" kinda feedback?
}); });
}); });