Lots of fixes + clans
* Added clans * Fixed interior exit labels * Disabled nametags on games without 3D label support * Fixed mouse cursor toggle command * Fixed SA fight-style not being applied * Added manageRanks clan permission bitflag * Added interior lights toggle * Fixed clan chat * Added real-time support with optional timezone offset * Added lots of JSDoc stuff * Added command for managers to set server GUI colour * Added GeoIP command for admins * Added command for admins to force an immediate payday * Added admins gotospawn command * Added return player command for teleported players * Added pizza delivery job const * Fixed biz/house set pickup & interior type * Fixed inventory showing ammo count for melee weapons * Fixed SA using wrong pickup types * Fixed char select screen breaking when in a clan * Added +/- symbol util for number display * Added get current timestamp for timezone offset util * Fixed vehicle owner ID being set wrong for job veh
This commit is contained in:
@@ -7,8 +7,6 @@
|
||||
// TYPE: Client (JavaScript)
|
||||
// ===========================================================================
|
||||
|
||||
"use strict";
|
||||
|
||||
let businessLabels = [];
|
||||
let houseLabels = [];
|
||||
let jobLabels = [];
|
||||
@@ -165,7 +163,7 @@ function renderPropertyExitLabel(position) {
|
||||
}
|
||||
|
||||
let text = "EXIT";
|
||||
size = propertyLabelNameFont.measure(text, game.width, 0.0, 0.0, propertyLabelNameFont.size, true, true);
|
||||
let size = propertyLabelNameFont.measure(text, game.width, 0.0, 0.0, propertyLabelNameFont.size, true, true);
|
||||
propertyLabelNameFont.render(text, [screenPosition.x-size[0]/2, screenPosition.y-size[1]/2], game.width, 0.0, 0.0, propertyLabelNameFont.size, COLOUR_WHITE, false, true, false, true);
|
||||
}
|
||||
|
||||
|
||||
@@ -140,6 +140,10 @@ function drawNametag(x, y, health, armour, text, ping, alpha, distance, colour,
|
||||
// ===========================================================================
|
||||
|
||||
function updateNametags(element) {
|
||||
if(!areWorldLabelsSupported()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if(localPlayer != null) {
|
||||
let playerPos = localPlayer.position;
|
||||
let elementPos = element.position;
|
||||
|
||||
@@ -50,7 +50,7 @@ function addAllNetworkHandlers() {
|
||||
addNetworkHandler("vrr.drunkEffect", setLocalPlayerDrunkEffect);
|
||||
addNetworkHandler("vrr.showItemActionDelay", showItemActionDelay);
|
||||
addNetworkHandler("vrr.set2DRendering", setPlayer2DRendering);
|
||||
addNetworkHandler("vrr.mouseCursor", setMouseCursorState);
|
||||
addNetworkHandler("vrr.mouseCursor", toggleMouseCursor);
|
||||
addNetworkHandler("vrr.mouseCamera", setMouseCameraState);
|
||||
addNetworkHandler("vrr.weaponDamageEnabled", setPlayerWeaponDamageEnabled);
|
||||
addNetworkHandler("vrr.weaponDamageEvent", setPlayerWeaponDamageEvent);
|
||||
|
||||
@@ -227,7 +227,7 @@ function syncPlayerProperties(player) {
|
||||
if(getGame() == GAME_GTA_SA) {
|
||||
if(doesEntityDataExist(player, "vrr.fightStyle")) {
|
||||
let fightStyle = getEntityData(player, "vrr.fightStyle");
|
||||
player.fightStyle = fightStyle;
|
||||
player.setFightStyle(fightStyle[0], fightStyle[1]);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -443,9 +443,9 @@ function setMouseCameraState(state) {
|
||||
|
||||
// ===========================================================================
|
||||
|
||||
function setMouseCursorState(state) {
|
||||
logToConsole(LOG_DEBUG, `[VRR.Utilities] ${(state)?"Enabled":"Disabled"} mouse cursor`);
|
||||
gui.showCursor(state, !state);
|
||||
function toggleMouseCursor() {
|
||||
logToConsole(LOG_DEBUG, `[VRR.Utilities] ${(!gui.cursorEnabled)?"Enabled":"Disabled"} mouse cursor`);
|
||||
gui.showCursor(!gui.cursorEnabled, gui.cursorEnabled);
|
||||
}
|
||||
|
||||
// ===========================================================================
|
||||
|
||||
Reference in New Issue
Block a user