Jump to content

3NAD

Members
  • Posts

    1,992
  • Joined

  • Last visited

  • Days Won

    4

Everything posted by 3NAD

  1. ماظنتي كودكـ يحتاج لـ سيرفر .. حطه كلنت ولو تسوي اخفاء للماركر ماحد بيشوفه غير العميل نفسه #
  2. refresh جرب تغير أسم المود و تككتب
  3. zero = "" one = "*" two = "**" three = "***" four = "****" five = "*****" six = "******" call ( getResourceFromName ("scoreboard"), "addScoreboardColumn", "Wanted", root, 8, 0.07 ) function getwan ( ) for _, thePlayer in ipairs ( getElementsByType ( "player" ) ) do local wanted = getPlayerWantedLevel ( thePlayer ) if wanted == 0 then setElementData ( thePlayer, "Wanted", zero ) elseif wanted == 1 then setElementData ( thePlayer, "Wanted", one ) elseif wanted == 2 then setElementData ( thePlayer, "Wanted", two ) elseif wanted == 3 then setElementData ( thePlayer, "Wanted", three ) elseif wanted == 4 then setElementData ( thePlayer, "Wanted", four ) elseif wanted == 5 then setElementData ( thePlayer, "Wanted", five ) elseif wanted == 6 then setElementData ( thePlayer, "Wanted", six ) end end end setTimer ( getwan, 3000, 0 )
  4. جرب ذا -- Server Side ID = { { 1 }, { 2 }, { 3 }, } addEventHandler ( "onPlayerSpawn", root, function ( ) local playerID = getElementData ( source, "ID" ) if playerID then if ID [ playerID ] then killPed ( source ) end end end ) وإذا ماضبط عطني الأمر اللي يقتل اللاعب بالبيس مود
  5. ماني متأكد منه جرب ورد خبر ID = { { 1 }, { 2 }, { 3 }, } addEventHandler ( "onResourceStart", resourceRoot, function ( rss ) if getResourceInfo ( rss, "type" ) == "map" then for _, v in ipairs ( getElementsByType ( "player" ) ) do if ID [ getElementData ( v, "ID" ) ] then killPed ( v ) end end end end )
  6. > author="yazan" name="car for yazan" version='1.0.0' type="script" /> ="yazan.lua" type="server" />> [ xml] Text [/ xml] بدون مسافات
  7. viewtopic.php?f=119&t=46670
  8. marker = createMarker ( x, y, z, "cylinder", size, 255, 0, 0, 255 ) timersTable = { } id = 46 addEventHandler ( "onMarkerHit", marker, function ( player ) if ( getElementType ( player ) == "player" ) then timersTable [ player ] = setTimer ( function ( player ) if not isElementWithinMarker ( player, marker ) then if isTimer ( timersTable [ player ] ) then killTimer ( timersTable [ player ] ) return end end if getElementModel ( player ) ~= id then outputChatBox ( "ممنوع تغيير الشخصية", player, 255, 255, 0, true ) killPed ( player, player ) end end , 3000, 0 ) end end , false )
  9. 3NAD

    SetRankDisplay

    So, I guess you removed the Function ! Add this Function at the Same file function setRankDisplay( rank ) if not tonumber(rank) then g_dxGUI.ranknum:text('') g_dxGUI.ranksuffix:text('') return end g_dxGUI.ranknum:text(tostring(rank)) g_dxGUI.ranksuffix:text( (rank < 10 or rank > 20) and ({ [1] = 'st', [2] = 'nd', [3] = 'rd' })[rank % 10] or 'th' ) end
  10. 3NAD

    SetRankDisplay

    I don't know if this ' setRankDisplay ' is available Function !!
  11. 3NAD

    Reload Weapon

    function Reload ( plr ) local player = plr or source reloadPedWeapon ( player ) end addEventHandler ( "onPlayerJoin", root, function ( ) bindKey ( source, "r", "down", Reload ) end ) addEventHandler ( "onResourceStart", resourceRoot, function ( ) for _, plr in ipairs ( getElementsByType ( "player" ) ) do bindKey ( plr, "r", "down", Reload ) end end )
  12. 3NAD

    My Nametags

    local screenX, screenY = guiGetScreenSize ( ) addEventHandler ( "onClientRender", root, function ( ) local cameraX, cameraY, cameraZ = getCameraMatrix() for _, thePlayer in pairs ( getElementsByType ("player") ) do while true do if thePlayer ~= localPlayer then if not isElement ( thePlayer ) then return end if getElementDimension ( thePlayer ) ~= getElementDimension ( localPlayer ) then return end local playerX, playerY, playerZ = getElementPosition ( thePlayer ) local ps = processLineOfSight ( cameraX, cameraY, cameraZ, playerX, playerY, playerZ, true, false, false, true, false, true ) if ps then return end local distance3D = getDistanceBetweenPoints3D ( cameraX, cameraY, cameraZ, playerX, playerY, playerZ) if distance3D <= 10 then local worldX, worldY = getScreenFromWorldPosition ( playerX, playerY, playerZ + 0.95, 0.06 ) if not worldX or not worldY then return end dxDrawText(getPlayerName(thePlayer), worldX, worldY - 0.1, worldX, worldY - 0.1, tocolor(0, 0, 0, 255), 1.64, "bold", "center", "bottom", false, false, false) dxDrawText(getPlayerName(thePlayer), worldX, worldY - 0.1, worldX, worldY - 0.1, tocolor(255, 224, 128, 215), 1.65, "bold", "center", "bottom", false, false, false) end end break end end end )
  13. 3NAD

    Help x2

    local aObjectsName = { [ "Hat 1" ] = createObject ( 2052, x, y, z ), [ "Hat 2" ] = createObject ( 2053, x, y, z ), [ "Hat 3" ] = createObject ( 2054, x, y, z ), [ "Grass Hat" ] = createObject ( 861, x, y, z ), [ "Grass Hat 2" ] = createObject ( 862, x, y, z ), [ "Flag hat" ] = createObject ( 2993, x, y, z ), [ "Pizza Box hat" ] = createObject ( 2814, x, y, z ), [ "Roulete hat" ] = createObject ( 1895, x, y, z ), [ "Ventilator hat" ] = createObject ( 1661, x, y, z ), [ "Model car hat" ] = createObject ( 2485, x, y, z ), }; local aObjectsScale = { { aObjectsName [ "Hat 1" ], 1 }, { aObjectsName [ "Hat 2" ], 5 }, { aObjectsName [ "Hat 3" ], 10 }, { aObjectsName [ "Grass Hat" ], 0.9 }, { aObjectsName [ "Grass Hat 2" ], 0.9 }, { aObjectsName [ "Flag hat" ], 1 }, { aObjectsName [ "Pizza Box hat" ], 1 }, { aObjectsName [ "Roulete hat" ], 0.8 }, { aObjectsName [ "Ventilator hat" ], 0.8 }, { aObjectsName [ "Model car hat" ], 1 }, }; for _, v in ipairs ( aObjectsScale ) do setObjectScale ( v[1], v[2] ) end;
  14. Col = createColSphere ( -2842.7297363281, -329.54904174805,10.10781860352, 20 ) Col1 = createColSphere ( -2953.7856445313,-330.46145629883,4.9000000953674, 20 ) timers = { } addEventHandler( "onColShapeHit", root, function ( player ) if ( source == Col or source == Col1 ) then if ( player and getElementType ( player ) == "player" ) then outputChatBox ( "You , Can,t Get Vehicle Here!!", player, 255, 0, 0, false ) triggerClientEvent ( player, "enableGodMode", player ) toggleControl ( player, "fire", false ) toggleControl ( player, "aim_weapon", false ) toggleControl ( player, "vehicle_fire", false ) timers[player] = setTimer ( function ( player ) if isElement ( player ) then local weaponType = getPedWeapon ( player ) if ( weaponType ) then takeAllWeapons ( player ) end if isPedInVehicle ( player ) then local shape = Col or Col1 local veh = getPedOccupiedVehicle ( player ) if not isElementWithinColShape ( veh, shape ) then if isTimer ( timers[player] ) then killTimer ( timers[player] ) timers[player] = nil end return end outputChatBox ( "You , Can,t Get Vehicle Here!!", player, 255, 0, 0, false ) onhit ( player ) end end end , 1000, 0, player ) end end end ) function onhit ( plr ) if plr and isElement ( plr ) then local veh = getPedOccupiedVehicle ( plr ) if veh then setElementVelocity ( veh, 0, 0, 0 ) setElementPosition ( veh, -3031.3862304688, -194.81304931641, 5 ) setVehicleRotation ( veh, 0,0,270 ) timers[plr] = nil end end end addEventHandler ( "onColShapeLeave", root, function ( player ) if ( source == Col or source == Col1 ) then if getElementType ( player ) == "player" then if isTimer ( timers[player] ) then killTimer ( timers[player] ) timers[player] = nil end triggerClientEvent ( player, "disableGodMode", player ) toggleControl ( player, "fire", true ) toggleControl ( player, "aim_weapon", true ) toggleControl ( player, "vehicle_fire", true ) end end end ) addEventHandler("onPlayerQuit",root, function() if isTimer ( timers[source] ) then killTimer ( timers[source] ) timers[source] = nil end end )
  15. Hmmm, It's my fault Check My Code Again.
  16. -- Server Side local blips = { } local vehicleBlipRoot = createElement ( "vehicleBlipRoot", "vehicleBlipRoot" ) function checkVehicles ( ) local player = getVehicleOccupant ( source ) local controller = getVehicleController ( source ) if blips [ source ] then return end if player ~= controller then if isismafia ( player ) then if getElementHealth ( source ) < 255 then blips [ source ] = createBlipAttachedTo ( source, 0, 1, 150, 150, 150, 255, -10, 300 ) setElementParent ( blips [ source ], vehicleBlipRoot ) end end end end addEventHandler ( "onVehicleDamage", root, checkVehicles ) If does not Work. Put Your Full Code !
  17. Tell me the Results. addEventHandler ( "onClientPlayerDamage", localPlayer, function ( attacker, weapon, bodypart, loss ) if attacker and getElementType ( attacker ) == "player" and weapon == 41 then cancelEvent ( ) local health = getElementHealth ( localPlayer ) if ( health < 99 ) then -- triggerServerEvent("medic:healing", localPlayer, attacker) setElementHealth ( localPlayer, health + 10 ) end end end )
  18. Because this Function will start only one time ' onClientResourceStart ' So, Use : "onVehicleDamage" or setTimer
  19. function acceptj ( thePlayer ) if getElementType ( thePlayer ) == "player" then setCameraInterior ( thePlayer, 10 ) setCameraMatrix ( thePlayer, 377.54309082031, -65.136703491211, 1002.3890991211, 376.56094360352, -65.279510498047, 1002.2667236328 ) end end addCommandHandler ( "ajob", acceptj ) # Note : I guess the Problem at Position or Rotation of Camera.
  20. ================ أخطاء # 1 - أسم الإيفنت 2 - المفروض تكون الوظيفة بدون إسم 3 - Source == The source of this event is the GUI element that was clicked. اللي انضغط Gui يعني ان عنصر الإيفنت هذا هو الـ إستخدم getLocalPlayer
  21. -- Client Side outputChatBox("#F44434لفتح اللوحة اضغط F2", 255, 100, 0, true) GUIEditor_Window = {} GUIEditor_TabPanel = {} GUIEditor_Tab = {} GUIEditor_Label = {} GUIEditor_Image = {} GUIEditor_Window[1] = guiCreateWindow(135,127,542,374,"؟",false) GUIEditor_TabPanel[3] = guiCreateTabPanel(9,24,524,341,false,GUIEditor_Window[1]) GUIEditor_Tab[3] = guiCreateTab("؟",GUIEditor_TabPanel[3]) GUIEditor_TabPanel[4] = guiCreateTabPanel(135,151,5,5,false,GUIEditor_Tab[3]) GUIEditor_Tab[5] = guiCreateTab("؟",GUIEditor_TabPanel[3]) closeButton = guiCreateButton(480,5,36,23,"~[x]~",false,GUIEditor_Tab[3]) addEvent ( "wnd", true ) addEventHandler ( "wnd", root, function ( ) guiSetVisible ( GUIEditor_Window[1], not guiGetVisible ( GUIEditor_Window[1] ) ) showCursor ( guiGetVisible ( GUIEditor_Window[1] ) ) guiSetInputEnabled ( guiGetVisible ( GUIEditor_Window[1] ) ) end ) -- Server Side addEventHandler ( "onResourceStart", resourceRoot, function ( ) for _, v in ipairs ( getElementsByType ( "player" ) ) do bindKey ( v, "F2", "down", givePermissions ) end end ) addEventHandler ( "onPlayerJoin", root, function ( ) bindKey ( source, "F2", "down", givePermissions ) end ) function givePermissions ( ) local playerAccount = getAccountName ( getPlayerAccount ( source ) ) if playerAccount and not isGuestAccount ( playerAccount ) then if isObjectInACLGroup ( "user." .. playerAccount , aclGetGroup ("Police") ) then triggerClientEvent ( source, "wnd", source ) end end end
×
×
  • Create New...