function generateSave() {
    
    var result = "";
    var i;
    
    //alert("Compressing and preparing file. This WILL take time, do not refresh.");
    
    
    //Okay, we need to go through our cached file and concatenate the lines
    for (i = 0; i < cachedFile.length; i++) {
        result += cachedFile[i] + "\n"; //Can't forget the newline      
    }
    

    var enc = new string_transcoder("windows-1252");
    var tenc = enc.transcode(result);
    
    var data = btoa(JSZip.utils.uint8Array2String(tenc));
    
    return data;
       
    //var res = (new TextDecoder("iso-8859-1")).decode(new Uint8Array(bytes));
    

   
   //return tempRes;
   //return console.log((Base64["encode"])(tenc));
    
    //$("#saveInputStringN").val(res);
    //$("#saveInputStringP").val(res);
    
   
}
//Generate a savefile from our changes
Generate a savefile from our changes
Generate a savefile from our changes
function generateSave() {
    var result = "";
    var i;
    for (i = 0; i < cachedFile.length; i++) {
        result += cachedFile[i] + "\n"; 
    }
    var enc = new string_transcoder("windows-1252");
    var tenc = enc.transcode(result);
    var data = btoa(JSZip.utils.uint8Array2String(tenc));
    return data;
}
function generateSave ( ) { var result = "" ; var i ; for ( i = 0 ; i < cachedFile . length ; i ++ ) { result += cachedFile [ i ] + "\n" ; } var enc = new string_transcoder ( "windows-1252" ) ; var tenc = enc . transcode ( result ) ; var data = btoa ( JSZip . utils . uint8Array2String ( tenc ) ) ; return data ; }
Generate a savefile from our changes
Generate a savefile from our changes
//alert("Compressing and preparing file. This WILL take time, do not refresh."); //Okay, we need to go through our cached file and concatenate the lines //Can't forget the newline       //var res = (new TextDecoder("iso-8859-1")).decode(new Uint8Array(bytes)); //return tempRes; //return console.log((Base64["encode"])(tenc)); //$("#saveInputStringN").val(res); //$("#saveInputStringP").val(res);