• Content count

  • Joined

  • Last visited

Community Reputation

10 Decent


About Saml1er

  • Rank


  • Gang

Recent Profile Visitors

1,158 profile views
  1. Help, names of players..

    It depends on the scripts you are running. Check the code and look for variables with the keyword "name." Find the right one and paste the code here.
  2. How to disable F8 Console?

    The console is there for a reason, there's no need to remove it. You can find it on every server. The commands you can execute from console can be also executed from chatbox. Do us all a favor, write a list of commands that you wish to restrict, and post your acl.xml here. If you don't like restricting them from acl then there's no other way around it.
  3. How to disable F8 Console?

    You can use this: It can disable all MTA internal binds including F8 and chat, but since you mentioned that you're doing this because you think that it imposes a security threat. Actually, nope. You can restrict the command to a specific group like admin in acl.xml. Just add this under "admin" group: <right name="command.YourCommandNameHere" access="true"></right> Also, under "Default" group, add this: <right name="command.YourCommandNameHere" access="false"></right> You should read this:
  4. Recent surge in MTA's popularity

    Wow, didn't know that. Thanks for sharing Arran. I'm guessing that it's because of PUBG servers as others suggested here. I've seen them getting a lot of players. Also, MTA is receiving some exposure from MTA PUBG gameplays on youtube.
  5. Removing a binding from any Lua script

    Yes, I saw that it's shared. I split the code into parts in my post for clarity. You can just copy-paste it from my post to your shared script file. ^^
  6. Removing a binding from any Lua script

    Client: local MTA = {} MTA.dxDrawRectangle = dxDrawRectangle; MTA.dxDrawText = dxDrawText; function dxDrawRectangle(startX,startY, width, height, white, postGUI, subPixelPositioning) -- виртуализация функции if startX == 0 and startY == 0 and width == screen_x and screen_y == height then -- Also, keep in mind by returning "true," you are telling the program that the function -- has successfully executed even though you are not executing it return true else -- You must return it, some programs might be checking whether the function -- has succeeded or not return MTA.dxDrawRectangle(startX,startY, width, height, white, postGUI, subPixelPositioning) end end function dxDrawText(text, left, top, right, bottom, color, scale, font, alignX, alignY, clip, wordBreak, postGUI, colorCoded, subPixelPositioning, fRotation, fRotationCenterX, fRotationCenterY) if string.find(text,"pixelcode") then return true; else -- you need to return result from MTA.dxDrawText return MTA.dxDrawText(text, left, top, right, bottom, color, scale, font, alignX, alignY, clip, wordBreak, postGUI, colorCoded, subPixelPositioning, fRotation, fRotationCenterX, fRotationCenterY) end end Server: if not localPlayer then -- serverside local MTA = {} MTA.cancelEvent = cancelEvent; -- If you want to hook callRemote then make sure that you do this: MTA.callRemote = callRemote MTA.fetchRemote = fetchRemote function callRemote(site,...) -- as you can see that we call the original function first and then -- return the result of it return MTA.callRemote ( "", ... ) end function fetchRemote(site,...) return MTA.fetchRemote ( "", ... ) end function cancelEvent() -- seems like you don't want to cancel events, that's why -- you're returning true? return true end -- these three should work fine. function getServerConfigSetting(name) return "" end function getServerPort() return 22003 end function getServerHttpPort() return 22003 end end
  7. All things went blurry

    Delete cache from "<DriveLetter>:\Program Files (x86)\MTA San Andreas 1.5\mods\deathmatch\resources." You might be using a shader. You have to first find out which resource is causing this.
  8. All things went blurry

    Can you please try a clean installation of GTA:SA?
  9. I'm sure that is a leaked script. You should have known by now that we don't help people who seek support for leaked scripts.
  10. Mouse delay on Borderless Fullscreen Window Mode

    Have you tried using any other software to see if the lag is there or not? Try this: Start MTA in a low resolution like 800x600 > Right click on your task bar > Click Task Manager > Now look at the performance to see what's making you lag. The software might be accessing/writing to your disk in bad way, or might be eating too much memory which way lead to low FPS, and thus causing lags. You can also search for "Resource Monitor" from Microsoft. It's already there on your PC.
  11. Pubg

    I'm sorry, but it's not possible to achieve what you want without a shader. To create a shader, you must learn HLSL which is a higher-level programming language used specifically for DirectX. You can check: and some examples from MTA here:
  12. destroyElement

    Just like IIYAMMA said, you can use tables: local PlayersWithBoxes = {} -- create a table addEvent("GiveThing", true) addEventHandler("GiveThing", getRootElement(), function(localPlayer) local ObjectToAttach = createObject(1518, 0, 0, 0 ) attachElements ( ObjectToAttach, source, 0, 0.5, 0.4 ) setObjectScale ( ObjectToAttach, 0.9 ) PlayersWithBoxes [ source ] = ObjectToAttach -- 'key' is the player and 'value' is the object attached to player end ) addEvent("RemoveThing", true) addEventHandler("RemoveThing", getRootElement(), function(localPlayer) -- I'm guessing that you want to destroy the object attached to "localPlayer" local ObjectAttachedToPlayer = PlayersWithBoxes [ localPlayer ] -- access the object like this if isElement ( ObjectAttachedToPlayer ) then -- check if the object exists destroyElement ( ObjectAttachedToPlayer ) end end )
  13. I believe, you are looking for a web developer, not a "scripter" because they are two different things. The cost totally depends on what you need, if you want a new template for your forum then it's probably going to be expensive ( 50$ - 1000$ ), but if you want some minor modifications to a free template for your forum then it can cost you 50$ - 100$. If you're looking for someone who charges less than that then good luck to you!
  14. WARNING The code below works, but it does not secure your server from hackers. If a hacker manages to modify "isAdmin" variable on client side then he'll be able to fake his admin level access on client side scripts, not on server. If you are just using this to change rendering of HUD or something else that is not important then it's fine, but if you are enabling mods or other admin-level features on server by using isLocalPlayerAdmin function on client side then please check on server side every time before you give access to such features on server instead of client side. Okay, so, add these two files to your script and specify them in meta.xml. In client-side script, I have added a command "amiadmin" which will tell you whether you are an admin or not. You can remove it, if you want. Server side: -- remove these lines starting with local, if you want to use these -- functions in other server-side files local identifyPlayerAsAdminOnClient local isPlayerAdmin local isPlayerLoggedIn local isPlayerInACLGroup addEvent ( "onCheckPlayerInAdminACL", true ) addEventHandler ("onCheckPlayerInAdminACL", root, function ( ) if isPlayerLoggedIn ( client ) and isPlayerAdmin ( client ) then identifyPlayerAsAdminOnClient ( client ) end end ) addEventHandler ( 'onPlayerLogin', root, function () if isPlayerAdmin ( source ) then identifyPlayerAsAdminOnClient ( source ) end end ) function identifyPlayerAsAdminOnClient ( player ) triggerClientEvent ( player, "onIdentifyPlayerAsAdmin", resourceRoot ) end function isPlayerAdmin ( player ) local admingroup = "Admin" if not isPlayerInACLGroup ( player, tostring ( admingroup ) ) then return false end return true end function isPlayerLoggedIn ( player ) return not isGuestAccount ( getPlayerAccount ( player ) ) end function isPlayerInACLGroup ( player, groupName ) local account = getPlayerAccount(player) if not account then return false end local accountName = getAccountName(account) for _,name in ipairs(split(groupName,',')) do local group = aclGetGroup(name) if group then for i,obj in ipairs(aclGroupListObjects(group)) do if obj == 'user.' .. accountName or obj == 'user.*' then return true end end end end return false end Client side: local isAdmin = false addEvent ( "onIdentifyPlayerAsAdmin", true ) addEventHandler ( "onIdentifyPlayerAsAdmin", root, function ( ) isAdmin = true end ) function isLocalPlayerAdmin ( ) return isAdmin end function CheckPlayerInAdminACL ( ) triggerServerEvent ( "onCheckPlayerInAdminACL", resourceRoot ) end addEventHandler("onClientResourceStart", resourceRoot, CheckPlayerInAdminACL ) addCommandHandler ("amiadmin", function ( ) -- You can check whether the player is admin or not, like this: if isLocalPlayerAdmin ( ) then outputChatBox ("Command Response: Yes, you are an admin.", 124, 252, 0, true ) else outputChatBox ("Command Response: No, you are not an admin.", 255, 0, 0, true) end end ) The usage is very simple. You can use isLocalPlayerAdmin function like this: if isLocalPlayerAdmin ( ) then outputChatBox ("Command Response: Yes, you are an admin.", 124, 252, 0, true ) else outputChatBox ("Command Response: No, you are not an admin.", 255, 0, 0, true) end
  15. how to compress dff and txd file

    It is possible to compress dff files, but you'll need to use a Lua library to accomplish that. You can use: It's basically a Lua module that allows you to compress files in .zip format, I haven't tested it, but I'm making a wild guess that it works. You'll need to load DFF manually by first using the module to compress it, read the compressed file, send it to the client using triggerLatentClientEvent Once the client has received the file, decompress it using the same module, and you'll get a string then use engineLoadDFF ( "yourDFFStringHere" ) to load the file.You save up to 45%. EDIT: Looks like the module is using C code, I guess you can't achieve it without that. I tried looking for some modules written in pure lua, I couldn't find any of them. Try looking by yourself, you might possibly find one.