Jump to content

Static-X

Members
  • Posts

    128
  • Joined

  • Last visited

About Static-X

  • Birthday 22/02/1987

Details

  • Gang
    Full Metal Jacket
  • Location
    Alexandra, VIC, Australia

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Static-X's Achievements

Poot-butt

Poot-butt (14/54)

0

Reputation

  1. Have been using this host for almost 9 months now. Really cheap, reliable and has a very good support. Not even a single day of downtime ( I faced ). Thank you No1Servers.
  2. You can change the first six lines according to your needs, adminTag = "[ADMIN]" sModTag = "[sMOD]" modTag = "[MOD]" adminColor = "#FF0000" -- leave blank if you dont want pre defined color sModColor = "#FF0000" -- leave blank if you dont want pre defined color modColor = "#FF0000" -- leave blank if you dont want pre defined color function chatbox( message ) cancelEvent ( ) local account = getAccountName ( getPlayerAccount ( source ) ) if ( isAccountInGroup ( account, "Admin" ) ) then tag = adminColor .. adminTag .. " " elseif ( isAccountInGroup ( account, "SuperModerator" ) ) then tag = sModColor .. sModTag .. " " elseif ( isAccountInGroup ( account, "Moderator" ) ) then tag = modColor .. modTag .. " " else tag = "" -- no tag end output ( tag, source, message ) end addEventHandler("onPlayerChat", root, chatbox) function output ( tag, player, text ) if ( getPlayerTeam ( player) ) then r,g,b = getTeamColor ( getPlayerTeam ( player) ) else r,g,b = getPlayerNametagColor ( player ) end outputChatBox ( tag .. "" .. getPlayerName ( player ) .. ":#FFFFFF " .. text, root, r, g, b, true ) tag = string.gsub( tag, "#%x%x%x%x%x%x", "" ) outputServerLog ( tag .. "" .. getPlayerName ( player ) .. ": " .. text ) end function isAccountInGroup ( _acc, _group ) if ( isObjectInACLGroup ( "user." .. _acc, aclGetGroup ( _group ) ) ) then return true end end
  3. 'player' should be defined as the first parameter Use isGuestAccount to avoid errors ( check if the player is logged in the account before getting the account name ). setPedSkin is deprecated, use setElementModel. function militarySkin( player ) if ( isGuestAccount ( getPlayerAccount ( getPlayerAccount ( player ) ) ) ) then return end local account = getAccountName(getPlayerAccount(player)) if isObjectInACLGroup("user." .. account, aclGetGroup("Military")) then setElementModel(player, 287) outputChatBox("You are now on duty as a Military Soldier!", player, 0, 255, 0, false) else outputChatBox("You must be in Military to use this command!", player, 255, 0, 0, false) end end addCommandHandler("mduty", militarySkin)
  4. playerName isn't defined, you can use this function onAdminJoin(_,account) local account = getAccountName ( account ) if ( isObjectInACLGroup ( "user." .. account, aclGetGroup ( "Admin" ) ) ) then local team = getTeamFromName ( "Admins" ) setPlayerTeam( source, team ) end end addEventHandler("onPlayerLogin", getRootElement(), onAdminJoin)
  5. onPlayerWeaponFire, there is no such event. You can use onClientPlayerWeaponFire and make the script client sided or use triggering
  6. Yep. It seems to be working fine.
  7. *Bump* Same error on 1.1.1 too, I can't stay on 1.0.5 forever ... Any idea of how I could fix this? (anyone ?)
  8. outputChatBox("text",getRootElement())
  9. Static-X

    problem oO

    function setPlayerID( id,player ) Here, id is the first parameter and player is second, @line 163 setPlayerID(source,1) Use setPlayerID(1,source)
  10. Static-X

    problem oO

    This code seems to work fine, could you please mention the part/function where are you using this?
  11. Static-X

    Taken vehicle

    You can create a marker on player vehicle enter and clone the car or create it (use getElementPosition to get the params) when the player leaves that marker.
  12. PS: It works, if there is no player in range of it, try v = createVehicle(500, 0, 0, 0) setVehicleIdleRespawnDelay(v, 5000) toggleVehicleRespawn(v, true)
  13. Those are colored 'corona' markers.
  14. Use this handler addEventHandler("onClientResourceStart",getResourceRootElement(getThisResource()),lol)
×
×
  • Create New...