Skip to content

Commit

Permalink
516 tgui support (#6931)
Browse files Browse the repository at this point in the history
new useragent new ui

(( doesnt include ie8 remove, only makes tgui load ))
  • Loading branch information
LetterN authored Dec 20, 2024
1 parent ee00e4c commit afba3a6
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion tgui/public/tgui.html
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,15 @@
: null;
})();

// Blink engine version
Byond.BLINK = (function () {
var groups = navigator.userAgent.match(/Chrome\/(\d+)\./);
var majorVersion = groups && groups[1];
return majorVersion ? parseInt(majorVersion, 10) : null;
})();

// Basic checks to detect whether this page runs in BYOND
var isByond = (Byond.TRIDENT !== null || window.cef_to_byond)
var isByond = (Byond.TRIDENT !== null || Byond.BLINK !== null || window.cef_to_byond)
&& location.hostname === '127.0.0.1'
&& location.search !== '?external';
//As of BYOND 515 the path doesn't seem to include tmp dir anymore if you're trying to open tgui in external browser and looking why it doesn't work
Expand Down

0 comments on commit afba3a6

Please sign in to comment.