Scale up server logo on some GUI

This commit is contained in:
Vortrex
2022-01-09 05:23:06 -06:00
parent a526497f48
commit b3ef262697
4 changed files with 38 additions and 35 deletions

View File

@@ -22,7 +22,7 @@ let login = {
function initLoginGUI() {
logToConsole(LOG_DEBUG, `[VRR.GUI] Creating login GUI ...`);
login.window = mexui.window(game.width/2-150, game.height/2-129, 300, 258, 'LOGIN', {
login.window = mexui.window(game.width/2-150, game.height/2-130, 300, 260, 'LOGIN', {
main: {
backgroundColour: toColour(secondaryColour[0], secondaryColour[1], secondaryColour[2], windowAlpha),
transitionTime: 500,
@@ -42,7 +42,7 @@ function initLoginGUI() {
login.window.titleBarIconSize = toVector2(0,0);
login.window.titleBarHeight = 0;
login.logoImage = login.window.image(100, 20, 100, 100, mainLogoPath, {
login.logoImage = login.window.image(85, -10, 140, 140, mainLogoPath, {
focused: {
borderColour: toColour(0, 0, 0, 0),
},
@@ -96,7 +96,7 @@ function initLoginGUI() {
},
}, checkLogin);
login.forgotPasswordButton = login.window.button(200, 240, 60, 15, 'RESET PASS', {
login.forgotPasswordButton = login.window.button(200, 240, 80, 15, 'RESET PASS', {
main: {
backgroundColour: toColour(primaryColour[0], primaryColour[1], primaryColour[2], buttonAlpha),
textColour: toColour(0, 0, 0, 255),
@@ -109,11 +109,11 @@ function initLoginGUI() {
},
}, switchToPasswordResetGUI);
login.resetPasswordLabel = login.window.text(20, 140, 60, 15, 'Forgot your password?', {
login.resetPasswordLabel = login.window.text(125, 240, 60, 15, 'Forgot your password?', {
main: {
textSize: 8.0,
textAlign: 1.0,
textColour: toColour(200, 200, 200, 255),
textColour: toColour(180, 180, 180, 255),
textFont: robotoFont,
},
focused: {
@@ -134,14 +134,14 @@ function showLoginGUI() {
login.window.shown = true;
mexui.focusedControl = login.passwordInput;
guiSubmitKey = checkLogin;
showSmallGameMessage(`If you don't have a mouse cursor, press ${toUpperCase(getKeyNameFromId(disableGUIKey))} to disable GUI`, COLOUR_WHITE, 7500);
//showSmallGameMessage(`If you don't have a mouse cursor, press ${toUpperCase(getKeyNameFromId(disableGUIKey))} to disable GUI`, COLOUR_WHITE, 7500);
}
// ===========================================================================
function checkLogin() {
logToConsole(LOG_DEBUG, `[VRR.GUI] Checking login with server ...`);
triggerNetworkEvent("vrr.checkLogin", login.passwordInput.lines[0]);
sendNetworkEventToServer("vrr.checkLogin", login.passwordInput.lines[0]);
}
// ===========================================================================