-ffs-Sniper

Members
  • Content Count

    253
  • Joined

  • Last visited

Everything posted by -ffs-Sniper

  1. -ffs-Sniper

    I'm confused..

    function getRaceAlivePlayers() local result = {} local _getAlivePlayers = getElementsByType("player") for i, v in ipairs(_getAlivePlayers) do if getElementData(v, "state") == "alive" then table.insert(result, v) end end return result end function get() local ap = 0 local _getAlivePlayers = getElementsByType("player") for index, player in ipairs(_getAlivePlayers) do if getElementData(player, "state") == "alive" then ap = ap + 1 end end return ap end -- -- addEventHandler("onPlayerWasted", root, function() if get() == 1 then outputChatBox(getPlayerName(getRaceAlivePlayers()[1]) .. " has won") end end )
  2. If you will install it properly you will be able to edit all scripts in-game.
  3. Another stolen script, made by Bauss: http://community.mtasa.com/index.php?p= ... ls&id=2025
  4. Stolen client side script by vEnom (see the comments): http://community.mtasa.com/index.php?p= ... ls&id=3931
  5. This one here is great: http://community.mtasa.com/index.php?p= ... ls&id=1821
  6. This script i made from standart jounquit This is the default joinquit resource, yes, but you are using functions like "getNormalCountryName" that require Wesseb's php joinquit to work properly.
  7. This is a part of Wesseb's php joinquit script, you don't own it, you don't know how to script. Close this, thanks.
  8. Uploading without author's permission (my scripts): http://community.mtasa.com/index.php?p= ... ls&id=3964 http://community.mtasa.com/index.php?p= ... ls&id=1530
  9. Are you sure the scoreboards resource name is "scoreboard", not "tfscoreboard" or "dxscoreboard"?
  10. EDIT: Someone was faster than me... There isn't any mistake in that line. There is probably a syntax error in one of the previous lines. Please post them here.
  11. Sorry, but that is really nothing that special. In fact you've used the hard way to add 3-2-1-go sound files to the race resource. You can also use your own sound files with the default race resource just by editing 4 lines in the race_server.lua file.
  12. You need to increase the weapon skill level with the setPedStat function to Ganster or Hitman. http://wiki.multitheftauto.com/wiki/Weapon_skill_levels
  13. No, this is not normal for a Linux server. Please consult the server logs located in "/mods/deathmatch/logs/" after using one of the commands and post it right here.
  14. EDIT: Someone was faster than me... Myyusuf, since you don't know the SQL syntax I recommend you to use setAccountData which good enough for the beginning. The best solution is MySQL ofcourse but for you account data is way faster than XML. Functions: (http://wiki.multitheftauto.com/wiki/Ser ... _functions) addAccount copyAccountData getAccount getAccountData getAccountName getAccountPlayer getAccounts isGuestAccount logIn logOut removeAccount setAccountData setAccountPassword
  15. -ffs-Sniper

    Tag

    Well, then, as I said you will need to check the player's team in every single resource that outputs a name.
  16. Feche is right about the fact that getTickCount is not the same client and server side due to the way it works. The tick count is actually the uptime or cputime (don't know exactly) of the machine the script is running at in miliseconds. So there is no way to sync those two functions directly. The only way to "sync" it would be starting the tick count server and client side at the same time and save that time difference. Although it won't be 100% exact since triggerEvents would delay the syncing progress.
  17. -ffs-Sniper

    Tag

    You would need to edit every single resource that displays the player's name, there is no other way to do that. Normally you are changing the nicks. What gamemode are you using?
  18. This script is missing a client side ("triggerClientEvent") so I highly doubt he has the persmission to use that script until he proves he is allowed to. Somehow that script reminds me of some server, don't know which exactly.
  19. Open mtaserver.conf -> none Update to the latest nightly -> http://nightly.mtasa.com Download the latest resources -> http://code.google.com/p/mtasa-resources/downloads/list
  20. Use that function for colored dxTexts: function dxDrawColorText(str, ax, ay, bx, by, color, scale, font, left, top, clip, wordbreak, postGUI) local pat = "(.-)#(%x%x%x%x%x%x)" local s, e, cap, col = str:find(pat, 1) local last = 1 while s do if cap == "" and col then color = tocolor( tonumber( "0x"..col:sub( 1, 2 ) ), tonumber( "0x"..col:sub( 3, 4 ) ), tonumber( "0x"..col:sub( 5, 6 ) ), 255 ) end if s ~= 1 or cap ~= "" then local w = dxGetTextWidth(cap, scale, font) dxDrawText( cap, ax, ay, ax + w, by, color, scale, font ) ax = ax + w color = tocolor( tonumber( "0x"..col:sub( 1, 2 ) ), tonumber( "0x"..col:sub( 3, 4 ) ), tonumber( "0x"..col:sub( 5, 6 ) ), 255 ) end last = e + 1 s, e, cap, col = str:find( pat, last ) end if last <= #str then cap = str:sub( last ) local w = dxGetTextWidth( cap, scale, font ) dxDrawText( cap, ax, ay, ax + w, by, color, scale, font, left, top, clip, wordbreak, postGUI ) end end
  21. You need to reattach to the screen, use "screen -r" to reattach to a screen and then type "quit" into the MTA console What OS are you using? Btw: the command "shutdown" turns off your VPS.
  22. http://community.mtasa.com/index.php?p= ... ls&id=4044 Vehicle mod
  23. Sorry, but what have you done so far? A small login GUI with setAccountData? I would accept a scripter to have problems with object orientated programming but MySQL is an obligatory skill for anybody who calls himself a "scripter". In addition to that PHP becomes more and more important in MTA, so do you have any PHP skills? Nevermind, good luck finding someone who is going to give you 15% of his donations.
  24. The rights are being checked client side inside of the "/admin/client/admin_gui.lua" file. _guiCreateTab = guiCreateTab function guiCreateTab ( name, parent, right ) local tab = _guiCreateTab ( name, parent ) if ( tab ) then if ( right ) then right = "general.tab_"..right if ( not hasPermissionTo ( right ) ) then guiSetEnabled ( tab, false ) _guiprotected[right] = tab end end return tab end return false end
  25. Happy birthday from the |FFS|Gaming community!