Jump to content

Stranger

Members
  • Posts

    710
  • Joined

  • Last visited

Everything posted by Stranger

  1. وعليكم السلام local Object = createObject ( 980,x,y,z ) -- نسوي الباب local Marker = createMarker ( x,y,z, "cylinder", 2, 255, 0, 0, 0 ) -- نسوي الماركر function OpenObject ( player ) if isElementWithinMarker ( player, Marker ) then -- اذا كان الاعب في الماركر if not Open then -- اذا الباب ما فتح moveObject ( Object, 1500, x,y,z ) -- يفتح else -- لو فتح moveObject ( Object, 1500, x, y, z ) -- يقفل end -- اغلاق Open = not Open end -- اغلاق end -- اغلاق addEventHandler ( "onResourceStart", resourceRoot, -- اول ما يشتغل المود function ( ) for _, v in ipairs ( getElementsByType ( "player" ) ) do -- نجيب كل الاعبين bindKey ( v, "tab", "down", OpenObject ) -- ونسوي لهم زر end -- اغلاق end -- اغلاق ) -- اغلاق addEventHandler ( "onPlayerJoin", root, -- اول ما يدخل الاعب function ( ) bindKey ( source, "tab", "down", OpenObject ) -- نسوي زر end -- اغلاق ) -- اغلاق
  2. Stranger

    stats

    جرب exports.scoreboard:addScoreboardColumn("WepPoints",getRootElement(),6,60) function PlayerKill ( killer, weapon, bodypart, stat) local slot = getPedWeapon(killer) for _,player in ipairs(getElementsByType("player")) do bindKey(player,"next_weapon",PlayerKill) bindKey(player,"previous_weapon",PlayerKill) if (killer and killer ~= source) then if ( bodypart == 9) then setPedStat(killer, stat, getPedStat(killer, stat)+5) setElementData(killer,"WepPoints",tonumber(getPedStat(killer,stat))) elseif (killer and killer ~= source) then setPedStat(killer, stat, getPedStat(killer, stat)+1) setElementData(killer,"WepPoints",tonumber(getPedStat(killer,stat))) elseif (killer and killer ~= source) then if ( bodypart == 7) then setPedStat(killer, stat, getPedStat(killer, stat)+1) setElementData(killer,"WepPoints",tonumber(getPedStat(killer,stat))) elseif (killer and killer ~= source) then if ( bodypart == 6) then setPedStat(killer, stat, getPedStat(killer, stat)+1) setElementData(killer,"WepPoints",tonumber(getPedStat(killer,stat))) elseif (killer and killer ~= source) then if ( bodypart == 5) then setPedStat(killer, stat, getPedStat(killer, stat)+1) setElementData(killer,"WepPoints",tonumber(getPedStat(killer,stat))) elseif (killer and killer ~= source) then if ( bodypart == 4) then setPedStat(killer, stat, getPedStat(killer, stat)+1) setElementData(killer,"WepPoints",tonumber(getPedStat(killer,stat))) elseif (killer and killer ~= source) then if ( bodypart == 3) then setPedStat(killer, stat, getPedStat(killer, stat)+1) setElementData(killer,"WepPoints",tonumber(getPedStat(killer,stat))) end end end end end end end end end addEventHandler("onPlayerWasted",getRootElement(),PlayerKill) + كان عندك end زايده
  3. Stranger

    stats

    مش فاهم يعني مثلا هذا setPedStat(killer, stat, getPedStat(killer, stat)+5) stat المتغير وين معرف؟ مو معرف
  4. createColCuboid getElementsWithinColShape
  5. it's work fine thank you
  6. Stranger

    [Qutestion]

    hello guys, i was wondering : how to make fire does not hurt me ? i try this code but didn't work : isPedOnFire
  7. ما يحتاج اجرب لأني عارف انه اقدر احفظ بدون بلاي ,, مدري عنك وش سويت انت بس موب لازم بلاي عشان يحفظ #_#
  8. مو مصدق جرب يقول المثل لا يصدق الـ**** حتى يرى وش الي جرب ,, وش دخل البلاي في الحفظ ؟؟؟؟ فهمني
  9. اححححح توك ترد الموضوع ذا مر عليه وقت طويل + انتهى امره ,, وش وداك ورا |--___--|"
  10. ضبط بس ودي اعرف ليه الاوبجككت يجي مخفي interior لانك انت في عالم
  11. جرب local Time,Repate = 60000,1 function move() GATE = createObject(5422, 1302,-783.40002441406,1085,0,0,90) setElementInterior(GATE, 5) GATEmove(1) GATEc = createObject(5422, 1282.5,-783.79998779297,1090.9000244141,0,0,90) setElementInterior(GATEc, 5) GATEmove(2) end function GATEmove(position) if position == 1 then moveObject(GATE, 3000, 1302.3000488281,-783.40002441406,1087.5) local Sound = playSound3D("alarm.mp3", 1302, -783.40002441406, 1085, true) setTimer(GATEmove, 30000+30000, 1, 2) setTimer(function() destroySo() end,Time,Repate) end end addEventHandler("onClientResourceStart", getResourceRootElement(getThisResource()), move) function GATEmove(position) if position == 1 then moveObject(GATEc, 3000, 1282.3000488281,-783.79998779297,1093.4000244141) local Sound = playSound3D("alarm.mp3", 1282.5, -783.79998779297, 1090.9000244141, true) setTimer(GATEmove, 30000+30000, 1, 2) setTimer(function() destroySo() end,Time,Repate) end end addEventHandler("onClientResourceStart", getResourceRootElement(getThisResource()), move) function destroySo( ) if ( isElement( Sound ) ) then destroyElement ( Sound ) end end
  12. hello guys i have problem with this code, i don't know what the problem but the debug says : " ERROR: Loading script failed: spawn\client.lua:58: unexpected symbol near ')' " the code : addEvent("open", true) local Manster = { "spawn", "bank", } local screX, screY = guiGetScreenSize() Wind = guiCreateWindow(screX / 2 - 100, screY / 2 - 150, 200, 350, "By Manster", false) guiWindowSetSizable(Wind, false) guiSetVisible(Wind, false) GRID = guiCreateGridList(0, 0.07, 1, 0.66, true, Wind) guiGridListAddColumn(GRID, "spawn :", 0.9) for i = 1, 15 do guiGridListAddRow(GRID) end guiGridListSetItemText(GRID, 1, 1, "spawn", false, false) guiGridListSetItemText(GRID, 2, 1, "bank", false, false) Select = guiCreateButton(0.05, 0.75, 1, 0.1, "Select!", true, Wind) guiSetProperty(Select, "NormalTextColour", "FFAAAAAA") Close = guiCreateButton(0.05, 0.86, 1, 0.1, "Close", true, Wind) guiSetProperty(Close, "NormalTextColour", "FFAAAAAA") addEventHandler("onClientGUIClick", root, function () if(source == Select)then local row, col = guiGridListGetSelectedItem(GRID) local SS = guiGridListGetItemText(GRID, row, col) if (SS) then guiSetVisible(Wind, false) guiSetInputEnabled(false) if(SS == "spawn")then triggerServerEvent("spawn", localPlayer, "spawns") elseif(SS == "bank")then triggerServerEvent("spawn2", localPlayer, "spawns2") elseif(source == Close)then guiSetVisible(Wind, false) guiSetInputEnabled(false) end end end ) function showGui () guiSetVisible (Wind, true) showCursor (true) end bindKey ( "F2", "down", showGui ) addEventHandler("open", root, function(state) if(state == "true")then guiSetVisible(Wind, true) guiSetInputEnabled(true) elseif(state == "false")then guiSetVisible(Wind, false) guiSetInputEnabled(false) end end )
  13. حياك الله @ مشكور يا احمد على تنبيهي ,, صراحه ما انتبهت
  14. Defalut فيه قروب اسل اسمه false هذا فيه كل الخصائص بس كلها true انت ممكن تاخذ منه الخصائص وتحطها في قروب ثاني وتخليها يب صادق ضبططتةة سوال بسيط اذا كانك تذكر كود المخدرات توصيل المخدرات الاي ققلت لك مشكلته ان الاعب لا نزل سياره و رراح للماركر و نزل سياره م تختفى الاولى ي بعد حيي الحين معي كود ثاني لا نزلت سياره و رجعت للماركر نزلت سياره م تختفي الاولى نفس مشكله الكود الاي قبل الاي ضبططته المهم ذا الكود local tractorjobmarker= createMarker (-381.25811767578, -1438.8836669922, 25.7265625-1, "cylinder", 2,255, 200, 0, 150) function startMMmiIssion (player) if getElementType(player) == "vehicle" or getPedOccupiedVehicle(player) then return end fadeCamera(player,false,1 ) setTimer(fadeCamera,1000,1,player,true,5 ) setTimer(setElementPosition,1500,1,player, -383.4,-1406.6,25.2 ) Theplace = createVehicle ( 531, -386.2,-1405.9,25.0 ) outputChatBox ( "Hello ! I need to keep the engine of my tractor good...", player,255, 200, 0, 150 ) outputChatBox ( "Normal i drive it around san andreas for the fun of it, but i'm scared", player,255, 200, 0, 150 ) outputChatBox ( "to get infected by the zombies, would you do it for me? i will give 25000$", player,255, 200, 0, 150 ) outputChatBox ( "Follow the raceflag, you get a total of 25000$ at the end STOP AT GASTSTATIONS", player,255, 200, 0, 150 ) outputChatBox ( "DONT GET OUT OF THE VEHICLE OR YOU NEED TO RESTART", player,255, 200, 0, 150 ) end addEventHandler( "onMarkerHit", tractorjobmarker, startMMmiIssion ) local blip = createBlip(-380.74340820313,-1436.0946044922,25.7265625, 53, 0, 0, 0, 0, 0, 0, 250) outputDebugString("Blip visible distance: "..getBlipVisibleDistance(blip)) --50 setBlipVisibleDistance(blip, 350) outputDebugString("Blip visible distance: "..getBlipVisibleDistance(blip)) --100 ياليت الحل منكك او من احد الشباب جرب ذا local tractorjobmarker= createMarker (-381.25, -1438.88, 25.72-1, "cylinder", 2,255, 200, 0, 150) vehicle = { } function startMMmiIssion (player) if vehicle[source] and isElement( vehicle[source] ) then destroyElement(vehicle[source]) vehicle[source] = nil end vehicle[source] = createVehicle (531, -386.2,-1405.9,25.0) if getElementType(player) == "vehicle" or getPedOccupiedVehicle(player) then return end fadeCamera(player,false,1 ) setTimer(fadeCamera,1000,1,player,true,5 ) setTimer(setElementPosition,1500,1,player, -383.4,-1406.6,25.2 ) outputChatBox ( "Hello ! I need to keep the engine of my tractor good...", player,255, 200, 0, 150 ) outputChatBox ( "Normal i drive it around san andreas for the fun of it, but i'm scared", player,255, 200, 0, 150 ) outputChatBox ( "to get infected by the zombies, would you do it for me? i will give 25000$", player,255, 200, 0, 150 ) outputChatBox ( "Follow the raceflag, you get a total of 25000$ at the end STOP AT GASTSTATIONS", player,255, 200, 0, 150 ) outputChatBox ( "DONT GET OUT OF THE VEHICLE OR YOU NEED TO RESTART", player,255, 200, 0, 150 ) end addEventHandler( "onMarkerHit", tractorjobmarker, startMMmiIssion ) local blip = createBlip(-380.74340820313,-1436.0946044922,25.7265625, 53, 0, 0, 0, 0, 0, 0, 250) outputDebugString("Blip visible distance: "..getBlipVisibleDistance(blip)) --50 setBlipVisibleDistance(blip, 350) outputDebugString("Blip visible distance: "..getBlipVisibleDistance(blip)) --100
  15. Defalut فيه قروب اسل اسمه false هذا فيه كل الخصائص بس كلها true انت ممكن تاخذ منه الخصائص وتحطها في قروب ثاني وتخليها
  16. Stranger

    [Question]

    thank you but this is for all groups i want it only console can unmute i tried to do this: if ( hasObjectPermissionTo ( player, "general.tab_resources" ) ) then but didn't work else if the time of mute end, the mute will not removed, this is a big problem so i have to put this if ( isPlayerMuted ( player ) ) then action = "un"..action end
  17. Stranger

    [Question]

    yes i know, but if he was a moderator, he can open the admin panel and unmute himself, and i don't want to use a custom command i want it to be in admin panel but it's impossible to do that
  18. استخدم "onClientPlayerDamage" getElementData cancelEvent
×
×
  • Create New...