diff --git a/exec/loadfont.js b/exec/loadfont.js index 7471abded6d83138d2662837edcdf25fdce1fdcc..dae6fc6c2a4fdf322f8131fc5f4f8fff34767f38 100644 --- a/exec/loadfont.js +++ b/exec/loadfont.js @@ -8,8 +8,8 @@ */ load("sbbsdefs.js"); -if(this.CTerm_Version==undefined) - js.global.CTerm_Version=null; +if(bbs.mods.CTerm_Version==undefined) + bbs.mods.CTerm_Version=null; loadfont(); function loadfont() @@ -71,7 +71,7 @@ function loadfont() // Check if it's CTerm and supports font loading... var ver=new Array(0,0); - if(CTerm_Version == undefined || CTerm_Version == null) { + if(bbs.mods.CTerm_Version == undefined || bbs.mods.CTerm_Version == null) { // Disable parsed input... we need to do ESC processing ourselves here. var oldctrl=console.ctrlkey_passthru; console.ctrlkey_passthru=-1; @@ -92,14 +92,14 @@ function loadfont() // alert("Response: "+printable); if(response.substr(0,21) != "\x1b[=67;84;101;114;109;") { // Not CTerm - CTerm_Version=0; + bbs.mods.CTerm_Version=0; console.ctrlkey_passthru=oldctrl; if(showprogress) writeln("Not detected."); return(0); } if(response.substr(-1) != "c") { // Not a DA - CTerm_Version=0; + bbs.mods.CTerm_Version=0; console.ctrlkey_passthru=oldctrl; if(showprogress) writeln("Not detected."); @@ -107,12 +107,12 @@ function loadfont() } var version=response.substr(21); version=version.replace(/c/,""); - CTerm_Version=version; + bbs.mods.CTerm_Version=version; ver=version.split(/;/); console.ctrlkey_passthru=oldctrl; } else { - ver=CTerm_Version.split(/;/); + ver=bbs.mods.CTerm_Version.split(/;/); if(parseInt(ver[0]) < 1 || (parseInt(ver[0])==1 && parseInt(ver[1]) < 61)) { // Too old for dynamic fonts if(showprogress) diff --git a/exec/pickfont.js b/exec/pickfont.js index 24062fda97a38287562cffcf57112bab4364cd8c..877f5b26e0e3c27585332e88a83aefcbd40052ca 100644 --- a/exec/pickfont.js +++ b/exec/pickfont.js @@ -2,8 +2,8 @@ // Pass the desired fotn slot on the command line // If nothing passed, changes to font 0 (CP437) -if(this.CTerm_Version==undefined) - js.global.CTerm_Version=null; +if(bbs.mods.CTerm_Version==undefined) + bbs.mods.CTerm_Version=null; pickfont(); function pickfont() @@ -22,7 +22,7 @@ function pickfont() // Check if it's CTerm and supports font loading... var ver=new Array(0,0); - if(CTerm_Version==undefined || CTerm_Version==null) { + if(bbs.mods.CTerm_Version==undefined || bbs.mods.CTerm_Version==null) { if(detect) { // Disable parsed input... we need to do ESC processing ourselves here. var oldctrl=console.ctrlkey_passthru; @@ -44,24 +44,24 @@ function pickfont() // alert("Response: "+printable); if(response.substr(0,21) != "\x1b[=67;84;101;114;109;") { // Not CTerm - CTerm_Version=0; + bbs.mods.CTerm_Version=0; console.ctrlkey_passthru=oldctrl; return(0); } if(response.substr(-1) != "c") { // Not a DA - CTerm_Version=0; + bbs.mods.CTerm_Version=0; console.ctrlkey_passthru=oldctrl; return(0); } var version=response.substr(21); version=version.replace(/c/,""); - CTerm_Version=version; + bbs.mods.CTerm_Version=version; ver=version.split(/;/); console.ctrlkey_passthru=oldctrl; } } else { - ver=CTerm_Version.split(/;/); + ver=bbs.mods.CTerm_Version.split(/;/); if(parseInt(ver[0]) < 1 || (parseInt(ver[0])==1 && parseInt(ver[1]) < 61)) { // Too old for dynamic fonts return(0);