From 4a026c44bbe16b268db1abcb1586be7701aede5a Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 01:23:12 -0300 Subject: [PATCH 01/17] fix call to wrong function --- [admin]/admin/client/gui/admin_permissions.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/[admin]/admin/client/gui/admin_permissions.lua b/[admin]/admin/client/gui/admin_permissions.lua index 73b9557a3..bd88b98c9 100644 --- a/[admin]/admin/client/gui/admin_permissions.lua +++ b/[admin]/admin/client/gui/admin_permissions.lua @@ -100,7 +100,7 @@ function aPermissions.ConfirmChange(add) if (not isElement(player)) then aPermissions.Close(false) - messageBox("Player not found!", MB_WARNING) + aMessageBox ( "error", "Player not found!") return end From 6aecfd7f42289149dd9546ee5751ef09ae61963d Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 01:30:33 -0300 Subject: [PATCH 02/17] replace deprecated "doesPedHaveJetPack" --- [admin]/admin/client/gui/admin_main.lua | 2 +- [admin]/admin/server/admin_server.lua | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/[admin]/admin/client/gui/admin_main.lua b/[admin]/admin/client/gui/admin_main.lua index 7dc143a96..fd85134b7 100644 --- a/[admin]/admin/client/gui/admin_main.lua +++ b/[admin]/admin/client/gui/admin_main.lua @@ -515,7 +515,7 @@ function aAdminRefresh () guiSetText ( aTab1.Money, "Money: "..( aPlayers[player]["money"] or 0 ) ) if ( getElementDimension ( player ) ) then guiSetText ( aTab1.Dimension, "Dimension: "..getElementDimension ( player ) ) end if ( getElementInterior ( player ) ) then guiSetText ( aTab1.Interior, "Interior: "..getElementInterior ( player ) ) end - guiSetText ( aTab1.JetPack, iif ( doesPedHaveJetPack ( player ), "Remove JetPack", "Give JetPack" ) ) + guiSetText ( aTab1.JetPack, iif ( isPedWearingJetpack ( player ), "Remove JetPack", "Give JetPack" ) ) if ( getPedWeapon ( player ) ) then guiSetText ( aTab1.Weapon, "Weapon: "..getWeaponNameFromID ( getPedWeapon ( player ) ).." (ID: "..getPedWeapon ( player )..")" ) end local x, y, z = getElementPosition ( player ) diff --git a/[admin]/admin/server/admin_server.lua b/[admin]/admin/server/admin_server.lua index 520266ea6..9aff9fef6 100644 --- a/[admin]/admin/server/admin_server.lua +++ b/[admin]/admin/server/admin_server.lua @@ -1088,7 +1088,7 @@ addEventHandler ( "aPlayer", _root, function ( player, action, data, additional, action = nil end elseif ( action == "jetpack" ) then - if ( doesPedHaveJetPack ( player ) ) then + if ( isPedWearingJetpack ( player ) ) then removePedJetPack ( player ) action = "jetpackr" else From de2770ae480db9087bf24288b34786a6d4392de8 Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 01:31:56 -0300 Subject: [PATCH 03/17] replace deprecated "removePedJetPack" --- [admin]/admin/server/admin_server.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/[admin]/admin/server/admin_server.lua b/[admin]/admin/server/admin_server.lua index 9aff9fef6..ef7a3817e 100644 --- a/[admin]/admin/server/admin_server.lua +++ b/[admin]/admin/server/admin_server.lua @@ -1089,7 +1089,7 @@ addEventHandler ( "aPlayer", _root, function ( player, action, data, additional, end elseif ( action == "jetpack" ) then if ( isPedWearingJetpack ( player ) ) then - removePedJetPack ( player ) + setPedWearingJetpack ( player, false ) action = "jetpackr" else if ( getPedOccupiedVehicle ( player ) ) then outputChatBox ( "Unable to give a jetpack - "..getPlayerName ( player ).." is in a vehicle", source, 255, 0, 0 ) From ff3c38e76ebebfa3febb8f568495d139c0647717 Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 01:33:23 -0300 Subject: [PATCH 04/17] replace deprecated "givePedJetPack" --- [admin]/admin/server/admin_server.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/[admin]/admin/server/admin_server.lua b/[admin]/admin/server/admin_server.lua index ef7a3817e..36b7ea7ab 100644 --- a/[admin]/admin/server/admin_server.lua +++ b/[admin]/admin/server/admin_server.lua @@ -1094,7 +1094,7 @@ addEventHandler ( "aPlayer", _root, function ( player, action, data, additional, else if ( getPedOccupiedVehicle ( player ) ) then outputChatBox ( "Unable to give a jetpack - "..getPlayerName ( player ).." is in a vehicle", source, 255, 0, 0 ) else - if ( givePedJetPack ( player ) ) then + if ( setPedWearingJetpack ( player, true ) ) then action = "jetpacka" end end From 0e47453999047a0fc9bba5234b3bc31b4a742a05 Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 01:35:37 -0300 Subject: [PATCH 05/17] remove unused function (it was calling non-existent function) --- [admin]/admin/client/admin_client.lua | 8 -------- 1 file changed, 8 deletions(-) diff --git a/[admin]/admin/client/admin_client.lua b/[admin]/admin/client/admin_client.lua index c0a684751..5c4a15996 100644 --- a/[admin]/admin/client/admin_client.lua +++ b/[admin]/admin/client/admin_client.lua @@ -214,14 +214,6 @@ function realTimeToSeconds( time ) return seconds end -function realTimeToSecondsTest() - for i=1,100 do - local time1 = getRealTime( math.random(0, 60*60*24*365*50) ) -- Get a random date between 1970 and 2020 - local time2 = getRealTime( realTimeToSeconds( time1 ) ) - assert( getRealDateTimeString( time1 ) == getRealDateTimeString( time2 ) ) - end -end - -- seconds to description i.e. "10 mins" function secondsToTimeDesc( seconds ) if seconds then From bf0e4c81e1370d92babce6f12bdeb9acbe8362e6 Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 01:36:55 -0300 Subject: [PATCH 06/17] remove invalid variable assignment --- [admin]/admin/client/gui/admin_messagebox.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/[admin]/admin/client/gui/admin_messagebox.lua b/[admin]/admin/client/gui/admin_messagebox.lua index aec97d8ca..6005ea82d 100644 --- a/[admin]/admin/client/gui/admin_messagebox.lua +++ b/[admin]/admin/client/gui/admin_messagebox.lua @@ -9,7 +9,7 @@ **************************************]] aMessageForm = nil -local varOne, varTwo, varThree = vOne, vTwo, vThree +local varOne, varTwo, varThree function aMessageBox ( type, message, action, vOne, vTwo, vThree ) local x, y = guiGetScreenSize() From 72bd65abb678c523eca6cb0a46ccde8f415a6701 Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 01:40:27 -0300 Subject: [PATCH 07/17] disable reference to commented button --- [admin]/admin/client/gui/admin_vehicle.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/[admin]/admin/client/gui/admin_vehicle.lua b/[admin]/admin/client/gui/admin_vehicle.lua index 063583751..aef0416c1 100644 --- a/[admin]/admin/client/gui/admin_vehicle.lua +++ b/[admin]/admin/client/gui/admin_vehicle.lua @@ -241,9 +241,9 @@ function aClientVehicleClick ( button ) triggerServerEvent ( "aVehicle", getLocalPlayer(), aVehicleCustomizePlayer, "setlights", { guiGetText ( aLightsColor ) } ) elseif ( source == aLicensePlateSet ) then triggerServerEvent ( "aVehicle", getLocalPlayer(), aVehicleCustomizePlayer, "setplates", { guiGetText ( aLicensePlate ) } ) - elseif ( source == aVehicleColorScheme ) then - guiSetVisible ( aVehicleColorForm, true ) - guiBringToFront ( aVehicleColorForm ) + -- elseif ( source == aVehicleColorScheme ) then + -- guiSetVisible ( aVehicleColorForm, true ) + -- guiBringToFront ( aVehicleColorForm ) elseif ( source == aVehicleUpgradeAll ) then triggerServerEvent ( "aVehicle", getLocalPlayer(), aVehicleCustomizePlayer, "customize", { "all" } ) setTimer ( aVehicleCheckCurrentUpgrades, 2000, 1, aVehicleCustomizeVehicle ) From 063a84215521d9e59826eed6ea287e484ea35451 Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 02:00:12 -0300 Subject: [PATCH 08/17] fix use of undeclared variables --- [admin]/admin/server/admin_server.lua | 2 ++ 1 file changed, 2 insertions(+) diff --git a/[admin]/admin/server/admin_server.lua b/[admin]/admin/server/admin_server.lua index 36b7ea7ab..ea968466a 100644 --- a/[admin]/admin/server/admin_server.lua +++ b/[admin]/admin/server/admin_server.lua @@ -1637,6 +1637,8 @@ function checkClient(checkAccess,player,...) return false -- Access ok end if hasObjectPermissionTo ( player, "general.adminpanel" ) then + local desc = table.concat({...}," ") + local ipAddress = getPlayerIP(player) outputDebugString( "Admin security - Client does not have required rights ("..checkAccess.."). " .. tostring(ipAddress) .. " (" .. tostring(desc) .. ")" ) return true -- Low risk fail - Can't do specific command, but has access to admin panel end From 7bcc03f474933cf7523c8c2e3a52812dcc2ee422 Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 02:47:50 -0300 Subject: [PATCH 09/17] remove everything related to the deprecated "community username" --- [admin]/admin/client/gui/admin_main.lua | 6 +----- [admin]/admin/server/admin_server.lua | 4 ++-- [admin]/admin/server/admin_sync.lua | 2 -- 3 files changed, 3 insertions(+), 9 deletions(-) diff --git a/[admin]/admin/client/gui/admin_main.lua b/[admin]/admin/client/gui/admin_main.lua index fd85134b7..e971fafe1 100644 --- a/[admin]/admin/client/gui/admin_main.lua +++ b/[admin]/admin/client/gui/admin_main.lua @@ -498,7 +498,6 @@ function aAdminRefresh () guiSetText ( aTab1.Name, "Name: ".. playerName) guiSetText ( aTab1.Mute, iif ( aPlayers[player]["mute"], "Unmute", "Mute" ) ) guiSetText ( aTab1.Freeze, iif ( aPlayers[player]["freeze"], "Unfreeze", "Freeze" ) ) - --guiSetText ( aTab1.Username, "Community Username: "..( aPlayers[player]["username"] or "" ) ) guiSetText ( aTab1.Version, "Version: "..( aPlayers[player]["version"] or "" ) ) guiSetText ( aTab1.Accountname, "Account Name: "..getSensitiveText( aPlayers[player]["accountname"] or "" ) ) guiSetText ( aTab1.Groups, "Groups: "..( aPlayers[player]["groups"] or "None" ) ) @@ -776,7 +775,7 @@ function aClientResourceStop ( resource ) end end -function aClientPlayerJoin ( ip, username, accountname, serial, admin, country ) +function aClientPlayerJoin ( ip, accountname, serial, admin, country ) if ip == false and serial == false then -- Update country only if aPlayers[source] then @@ -787,7 +786,6 @@ function aClientPlayerJoin ( ip, username, accountname, serial, admin, country ) aPlayers[source] = {} aPlayers[source]["name"] = getPlayerName ( source ) aPlayers[source]["IP"] = ip - aPlayers[source]["username"] = username or "N/A" aPlayers[source]["accountname"] = accountname or "N/A" aPlayers[source]["serial"] = serial aPlayers[source]["admin"] = admin @@ -1250,14 +1248,12 @@ function aAdminReloadInfos() outputConsole(('Name: %s'):format(playerName)) outputConsole(('IP: %s'):format(aPlayers[player]["IP"])) outputConsole(('Serial: %s'):format(aPlayers[player]["serial"])) - -- outputConsole(('Community Username: %s'):format(aPlayers[player]["username"])) outputConsole(('Account Name: %s'):format(aPlayers[player]["accountname"])) outputConsole(('D3D9.DLL: %s'):format(aPlayers[player]["d3d9dll"])) outputConsole(' ') end guiSetText ( aTab1.IP, "IP: "..getSensitiveText( aPlayers[player]["IP"] ) ) guiSetText ( aTab1.Serial, "Serial: "..getSensitiveText( aPlayers[player]["serial"] ) ) - --guiSetText ( aTab1.Username, "Community Username: "..aPlayers[player]["username"] ) guiSetText ( aTab1.Accountname, "Account Name: "..getSensitiveText( aPlayers[player]["accountname"] ) ) guiSetText ( aTab1.ACDetected, "AC Detected: "..aPlayers[player]["acdetected"] ) guiSetText ( aTab1.ACD3D, "D3D9.DLL: "..aPlayers[player]["d3d9dll"] ) diff --git a/[admin]/admin/server/admin_server.lua b/[admin]/admin/server/admin_server.lua index ea968466a..f83ce57f9 100644 --- a/[admin]/admin/server/admin_server.lua +++ b/[admin]/admin/server/admin_server.lua @@ -381,7 +381,7 @@ addEventHandler ( "onPlayerJoin", _root, function () aPlayerInitialize ( source ) for id, player in ipairs(getElementsByType("player")) do if ( hasObjectPermissionTo ( player, "general.adminpanel" ) ) then - triggerClientEvent ( player, "aClientPlayerJoin", source, getPlayerIP ( source ), getPlayerUserName ( source ), getPlayerAccountName ( source ), getPlayerSerial ( source ), hasObjectPermissionTo ( source, "general.adminpanel" ), aPlayers[source]["country"] ) + triggerClientEvent ( player, "aClientPlayerJoin", source, getPlayerIP ( source ), getPlayerAccountName ( source ), getPlayerSerial ( source ), hasObjectPermissionTo ( source, "general.adminpanel" ), aPlayers[source]["country"] ) end end setPedGravity ( source, getGravity() ) @@ -394,7 +394,7 @@ function aPlayerInitialize ( player ) kickPlayer ( player, "Invalid Serial" ) else bindKey ( player, "p", "down", "admin" ) - --callRemote ( "http://community.mtasa.com/mta/verify.php", aPlayerSerialCheck, player, getPlayerUserName ( player ), getPlayerSerial ( player ) ) + --callRemote ( "http://community.mtasa.com/mta/verify.php", aPlayerSerialCheck, player, getPlayerSerial ( player ) ) aPlayers[player] = {} aPlayers[player]["country"] = getPlayerCountry ( player ) aPlayers[player]["money"] = getPlayerMoney ( player ) diff --git a/[admin]/admin/server/admin_sync.lua b/[admin]/admin/server/admin_sync.lua index 5324a3311..17ccdadb3 100644 --- a/[admin]/admin/server/admin_sync.lua +++ b/[admin]/admin/server/admin_sync.lua @@ -23,7 +23,6 @@ function aSynchCoroutineFunc( type, data, typeOfTag, banSearchTag ) tableOut["mute"] = isPlayerMuted ( data ) tableOut["freeze"] = isPlayerFrozen ( data ) tableOut["money"] = getPlayerMoney ( data ) - tableOut["username"] = getPlayerUserName ( data ) or "N/A" tableOut["version"] = aPlayers[data]["version"] tableOut["accountname"] = getPlayerAccountName ( data ) or "N/A" tableOut["groups"] = "None" @@ -48,7 +47,6 @@ function aSynchCoroutineFunc( type, data, typeOfTag, banSearchTag ) tableOut[player] = {} tableOut[player]["name"] = getPlayerName ( player ) tableOut[player]["IP"] = getPlayerIP ( player ) - tableOut[player]["username"] = getPlayerUserName ( player ) or "N/A" tableOut[player]["version"] = aPlayers[player]["version"] tableOut[player]["accountname"] = getPlayerAccountName ( player ) or "N/A" tableOut[player]["serial"] = getPlayerSerial ( player ) From ebf7a40ba1199a1d001a11fb7ae02b421bc57933 Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 02:52:12 -0300 Subject: [PATCH 10/17] remove unused variable --- [admin]/admin/server/admin_server.lua | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/[admin]/admin/server/admin_server.lua b/[admin]/admin/server/admin_server.lua index f83ce57f9..d320efb36 100644 --- a/[admin]/admin/server/admin_server.lua +++ b/[admin]/admin/server/admin_server.lua @@ -569,7 +569,6 @@ addEvent ( "aTeam", true ) addEventHandler ( "aTeam", _root, function ( action, name, r, g, b ) if checkClient( "command."..action, source, 'aTeam', action ) then return end if ( hasObjectPermissionTo ( client or source, "command."..action ) ) then - mdata = tostring ( data ) mdata = "" if ( action == "createteam" ) then local success = false @@ -592,7 +591,7 @@ addEventHandler ( "aTeam", _root, function ( action, name, r, g, b ) else action = nil end - if ( action ~= nil ) then aAction ( "server", action, source, false, mdata, mdata2 ) end + if ( action ~= nil ) then aAction ( "server", action, source, false, mdata ) end return true end outputChatBox ( "Access denied for '"..tostring ( action ).."'", source, 255, 168, 0 ) From a4604b70d018df1b7e552c22d0415c1cc519173f Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 03:03:37 -0300 Subject: [PATCH 11/17] replace deprecated "get/setPedRotation" --- [admin]/admin/server/admin_server.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/[admin]/admin/server/admin_server.lua b/[admin]/admin/server/admin_server.lua index d320efb36..498dbd3b2 100644 --- a/[admin]/admin/server/admin_server.lua +++ b/[admin]/admin/server/admin_server.lua @@ -879,7 +879,7 @@ function warp ( p, to ) r, dim, int = 0, 0, 0 else x, y, z = getElementPosition ( to ) - r = getPedRotation ( to ) + _, _, r = getElementRotation ( to ) dim = getElementDimension ( to ) int = getElementInterior ( to ) end @@ -1069,7 +1069,7 @@ addEventHandler ( "aPlayer", _root, function ( player, action, data, additional, setElementPosition ( vehicle, x, y, z + 0.2 ) else setElementPosition ( player, x, y, z + 0.2 ) - setPedRotation ( player, rot ) + setElementRotation ( player, 0, 0, rot, 'default', true ) end action = "interior" mdata = data @@ -1129,7 +1129,7 @@ addEventHandler ( "aPlayer", _root, function ( player, action, data, additional, fixVehicle(vehicle) else local x, y, z = getElementPosition ( player ) - local r = getPedRotation ( player ) + local _, _, r = getElementRotation ( player ) local vx, vy, vz = getElementVelocity ( player ) vehicle = createVehicle ( data, x, y, z, 0, 0, r ) setElementDimension ( vehicle, getElementDimension ( player ) ) From 32945be871c353899e9e326245ff2c70a7f93e41 Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 03:08:46 -0300 Subject: [PATCH 12/17] replace deprecated "get/setVehicleRotation" --- [admin]/admin/server/admin_server.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/[admin]/admin/server/admin_server.lua b/[admin]/admin/server/admin_server.lua index 498dbd3b2..29091910f 100644 --- a/[admin]/admin/server/admin_server.lua +++ b/[admin]/admin/server/admin_server.lua @@ -1216,10 +1216,10 @@ addEventHandler ( "aVehicle", _root, function ( player, action, data ) local mdata = "" if ( action == "repair" ) then fixVehicle ( vehicle ) - local rx, ry, rz = getVehicleRotation ( vehicle ) + local rx, ry, rz = getElementRotation ( vehicle ) if ( rx > 110 ) and ( rx < 250 ) then local x, y, z = getElementPosition ( vehicle ) - setVehicleRotation ( vehicle, rx + 180, ry, rz ) + setElementRotation ( vehicle, rx + 180, ry, rz ) setElementPosition ( vehicle, x, y, z + 2 ) end elseif ( action == "customize" ) then From 6fedc73d45bc04d81d1b2c81c077f8b348fe644b Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 03:09:57 -0300 Subject: [PATCH 13/17] fix invalid character in patterns --- [admin]/admin/server/admin_server.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/[admin]/admin/server/admin_server.lua b/[admin]/admin/server/admin_server.lua index 29091910f..eef86c188 100644 --- a/[admin]/admin/server/admin_server.lua +++ b/[admin]/admin/server/admin_server.lua @@ -440,7 +440,7 @@ addEventHandler ( "aPlayerVersion", _root, function ( version ) end -- Format it all prettyful - local _,_,ver,type,build = string.find ( playerVersion, "(.*)-([0-9])\.(.*)" ) + local _,_,ver,type,build = string.find ( playerVersion, "(.*)-([0-9])%.(.*)" ) if aPlayers[source] then aPlayers[source]["version"] = ver .. ( type < '9' and " pre " or " " ) .. "(" .. type .. "." .. build .. ")" end From 2ce4531ee1ee5819c698076d6ad989b36028c0f2 Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 03:30:12 -0300 Subject: [PATCH 14/17] remove unused code --- [admin]/admin/server/admin_sync.lua | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/[admin]/admin/server/admin_sync.lua b/[admin]/admin/server/admin_sync.lua index 17ccdadb3..a2ff916b1 100644 --- a/[admin]/admin/server/admin_sync.lua +++ b/[admin]/admin/server/admin_sync.lua @@ -122,20 +122,6 @@ function aSynchCoroutineFunc( type, data, typeOfTag, banSearchTag ) tableOut["map"] = getMapName() tableOut["password"] = getServerPassword() tableOut["fps"] = getFPSLimit() - elseif ( type == "rights" ) then - for gi, group in ipairs ( aclListGroups() ) do - for oi, object in ipairs ( aclGroupListObjects ( group ) ) do - if ( ( object == data ) or ( object == "user.*" ) ) then - for ai, acl in ipairs ( aclGroupListACL ( group ) ) do - for ri, right in ipairs ( aclListRights ( acl ) ) do - local access = aclGetRight ( acl, string ) - if ( access ) then table.insert ( tableOut, right ) end - end - end - break - end - end - end elseif ( type == "bansdirty" ) then tableOut = nil g_Bans = nil From 27092d4042d6f8b56aa9b2f49533811c37870bbc Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 03:33:19 -0300 Subject: [PATCH 15/17] remove reference to non-existent checkboxes --- [admin]/admin/client/gui/admin_acl.lua | 2 +- [admin]/admin/client/gui/admin_interior.lua | 2 +- [admin]/admin/client/gui/admin_settings.lua | 2 +- [admin]/admin/client/gui/admin_warp.lua | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/[admin]/admin/client/gui/admin_acl.lua b/[admin]/admin/client/gui/admin_acl.lua index 63276a875..2a4e9c45d 100644 --- a/[admin]/admin/client/gui/admin_acl.lua +++ b/[admin]/admin/client/gui/admin_acl.lua @@ -61,7 +61,7 @@ function aManageACL () end function aACLClose ( destroy ) - if ( ( destroy ) or ( aPerformanceACL and guiCheckBoxGetSelected ( aPerformanceACL ) ) ) then + if ( destroy ) then if ( aAclForm ) then removeEventHandler ( "onClientGUIClick", aAclForm, aClientACLClick ) removeEventHandler ( "onClientGUIDoubleClick", aAclForm, aClientACLDoubleClick ) diff --git a/[admin]/admin/client/gui/admin_interior.lua b/[admin]/admin/client/gui/admin_interior.lua index 3e62a5621..c5d31f1d6 100644 --- a/[admin]/admin/client/gui/admin_interior.lua +++ b/[admin]/admin/client/gui/admin_interior.lua @@ -43,7 +43,7 @@ function aPlayerInterior ( player ) end function aPlayerInteriorClose ( destroy ) - if ( ( destroy ) or ( aPerformanceInterior and guiCheckBoxGetSelected ( aPerformanceInterior ) ) ) then + if ( destroy ) then if ( aInteriorForm ) then removeEventHandler ( "onClientGUIDoubleClick", aInteriorForm, aClientInteriorDoubleClick ) removeEventHandler ( "onClientGUIClick", aInteriorForm, aClientInteriorClick ) diff --git a/[admin]/admin/client/gui/admin_settings.lua b/[admin]/admin/client/gui/admin_settings.lua index 07a57b278..20efa4287 100644 --- a/[admin]/admin/client/gui/admin_settings.lua +++ b/[admin]/admin/client/gui/admin_settings.lua @@ -42,7 +42,7 @@ function aManageSettings ( resName ) end function aSettingsClose ( destroy ) - if ( ( destroy ) or ( aPerformanceSettings and guiCheckBoxGetSelected ( aPerformanceSettings ) ) ) then + if ( destroy ) then if ( aSettingsForm ) then removeEventHandler ( "onClientGUIClick", aSettingsForm, aClientSettingsClick ) removeEventHandler ( "onClientGUIDoubleClick", aSettingsForm, aClientSettingsDoubleClick ) diff --git a/[admin]/admin/client/gui/admin_warp.lua b/[admin]/admin/client/gui/admin_warp.lua index 2da10c769..6843c38be 100644 --- a/[admin]/admin/client/gui/admin_warp.lua +++ b/[admin]/admin/client/gui/admin_warp.lua @@ -38,7 +38,7 @@ function aPlayerWarp ( player ) end function aPlayerWarpClose ( destroy ) - if ( ( destroy ) or ( aPerformanceWarp and guiCheckBoxGetSelected ( aPerformanceWarp ) ) ) then + if ( destroy ) then if ( aWarpForm ) then removeEventHandler ( "onClientGUIDoubleClick", aWarpForm, aClientWarpDoubleClick ) removeEventHandler ( "onClientGUIClick", aWarpForm, aClientWarpClick ) @@ -73,7 +73,7 @@ function aPlayerWarpToPosition ( ) end function aPlayerWarpToPositionClose ( destroy ) - if ( ( destroy ) or ( aPerformanceWarp and guiCheckBoxGetSelected ( aPerformanceWarp ) ) ) then + if ( destroy ) then if ( aWarpToPositionForm ) then removeEventHandler ( "onClientGUIDoubleClick", aWarpToPositionForm, aClientWarpDoubleClick ) removeEventHandler ( "onClientGUIClick", aWarpToPositionForm, aClientWarpClick ) From eabaf759922f10f25f86fbfa142c2fc095fdb4e0 Mon Sep 17 00:00:00 2001 From: Breno Danyel Date: Tue, 24 Aug 2021 15:36:32 -0300 Subject: [PATCH 16/17] fix min_mta_version --- [admin]/admin/meta.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/[admin]/admin/meta.xml b/[admin]/admin/meta.xml index e4821bfd1..10641d1a6 100644 --- a/[admin]/admin/meta.xml +++ b/[admin]/admin/meta.xml @@ -1,6 +1,6 @@ - +