Jump to content

EH10

Members
  • Posts

    1,429
  • Joined

  • Last visited

Everything posted by EH10

  1. هاذا مثال بسيط ثاني بس function Camera (player) fadeCamera( player, false, 1.5, r, g, b ) else fadeCamera( player, true, 1.5, r, g, b ) end addCommandHandler("Camerah", Camera ) r g b الوون انا مالي خبره بالبرمجة بس انا سويت الكود اذا خطا نبهوني مجرد مثال # للأحبك
  2. السلام عليكم ورحمة الله وبركاتة شباب اانا ابي اسوي استضافة بس كيف ماعرف اسوي لو سمحتو ابي 1 - السعر وابي ارخص شي 2 - واريد رابط الموقع 3 - واريد شكلها 4 - واريد استعمالها هل هو استعمال جيد ام لا
  3. و ليه متعبين نفسنا و معربين الويكي و محد خشه !! ياحبيبي ماعربتوه كامل وانا اقصد يعني واحد يسوي موضوع والناس تساهم كثير بس ماتكرر نفس الاكواد والفنكشات
  4. الافضل تشرحون لهم الاوامر وتشرحون لهم الفنكشات الصفر ذولي ترا كثير مايعرفون له .. واحسن شي واحد يسوي موضوع الموضوع عباره عن تحط مثال على الفنكشن مشان تعرف ش فايدته وهاكذا
  5. شكرا لك بس اذا ماتعبتك معي ابي شغلة اذا واحد خذ سياره تتسجل بسريالة وماحد يركبها غيره هو واي واحد يركبها يقول السياره ملك ويجي اسمة واذا ركب السياره ابو طيف يقول منور سيارتك ويجي اسمة
  6. اشتغل وضبط بس انا ابي وابي اذا طلع سياره وبعدين طلع سياره ثانية تختفي السياره الاولى اسف اذا كثرت طلباتي
  7. ماشتغلت الوحة
  8. الوحة تفتح وكل شي بس لما اكتب بالايديت رقم السياره واضغط الزر ماتجي السياره الاكواد # Client Side wnd = guiCreateWindow(237,154,382,294,"",false) Edits = guiCreateEdit(116,54,120,36,"",false,wnd) ok = guiCreateButton(105,114,148,31,"",false,wnd) guiSetVisible(wnd, false) bindKey("F2","Down",function() if ( guiGetVisible(wnd) == true ) then guiSetVisible(wnd, false); showCursor( false ); guiSetInputEnabled( false ); else guiSetVisible(wnd, true); showCursor( true ); guiSetInputEnabled( true ); end end) addEventHandler("onClientGUIClick", root, function ( ) if ( source == ok ) then local ZA7F = guiGetText( Edits ) if ( ZA7F and string.len( ZA7F ) == 3 ) then if ( ZA7F and tonumber ( ZA7F ) ) then triggerServerEvent("Car", localPlayer, guiGetText(Edits)) end end end end ) # Server Side addEvent("Car", true) addEventHandler("Car", root, function (id) veh = createVehicle ( id, x, y, z ) warpPedIntoVehicle ( source, veh ) end ) addEventHandler("onVehicleStartEnter", veh, function (player) if getPlayerSerial ( player ) == ">>>>>>>>>>>>>" then outputChatBox("Welome Sir", player, 255, 255, 0) else cancelEvent () outputChatBox("This not your car this is اسمك's car", player, 255, 0, 0) end end )
  9. في مشكلة لما احط الكود مايشتغل الوحة ولما اشيل الكود تشتغل الوحة الكود # wnd = guiCreateWindow(237,154,382,294,"",false) Edits = guiCreateEdit(116,54,120,36,"",false,wnd) ok = guiCreateButton(105,114,148,31,"",false,wnd) function sw() if guiGetVisible ( wnd ) then guiSetVisible ( wnd, false ) showCursor(false) guiSetInputEnabled(false) else guiSetVisible ( wnd, true ) showCursor(true) guiSetInputEnabled(true) end end bindKey("F2", "down", sw) addEventHandler("onClientGUIClick", root, function () if ( source == ok ) then if (tonumber(guiGetText(Edits)) == nil) then guiSetText(Edits, "") return end triggerServerEvent("Car", localPlayer, guiGetText(Edits)) end end )
  10. شكرا لك يااحلى عضو
  11. الكود صح او خطى صححلي ok = guiCreateButton( 0, 0, 0, 0, "ok", true ) Edits = guiCreateEdit( 0, 0, 0, 0, "", true ) if (tonumber(guiGetText(Edits)) == nil) then guiSetText(Edits, "") addEventHandler("onClientGUIClick", root, function () if ( source == ok ) then triggerServerEvent("Car", localPlayer) outputChatBox ( "......", source, 255, 255, 255, true ) end end ) addEvent("Car", true) addEventHandler("Car", root, function () if getPlayerSerial ( source ) == "My Serial" then veh = createVehicle ( id, x, y, z ) warpPedIntoVehicle ( source, veh ) end )
  12. بس ماعرف الكود اسوية مممكن تسوية
  13. اذا ممكن تسوي لي فنكش tonumber صعب علي اول مره يمر علي
  14. السلام عليكم ابي فنكشات رقم السياره وتضغط زر اختيار وتجيك السياره وماحد يقدر يركبها غيرك انت Edit تكتب في
  15. انا بس اعرف ان Tete-omar يبرمج مدري يمكن معه احد او ماهو معهم
  16. جرب هاذا function playerLogin (thePreviousAccount, theCurrentAccount, autoLogin) if not (isGuestAccount (getPlayerAccount (source))) then local accountData = getAccountData (theCurrentAccount, "funmodev2-money") if (accountData) then local playerMoney = getAccountData (theCurrentAccount, "funmodev2-money") local playerHealth = getAccountData (theCurrentAccount, "funmodev2-health") local playerArmor = getAccountData (theCurrentAccount, "funmodev2-armor") local playerWanted = getAccountData (theCurrentAccount, "funmodev2-wantedlevel") local playerTeam = getAccountData (theCurrentAccount, "funmodev2-Team") local playerWeaponID0 = getAccountData (theCurrentAccount, "funmodev2-weaponID0") local playerWeaponID1 = getAccountData (theCurrentAccount, "funmodev2-weaponID1") local playerWeaponID2 = getAccountData (theCurrentAccount, "funmodev2-weaponID2") local playerWeaponID3 = getAccountData (theCurrentAccount, "funmodev2-weaponID3") local playerWeaponID4 = getAccountData (theCurrentAccount, "funmodev2-weaponID4") local playerWeaponID5 = getAccountData (theCurrentAccount, "funmodev2-weaponID5") local playerWeaponID6 = getAccountData (theCurrentAccount, "funmodev2-weaponID6") local playerWeaponID7 = getAccountData (theCurrentAccount, "funmodev2-weaponID7") local playerWeaponID8 = getAccountData (theCurrentAccount, "funmodev2-weaponID8") local playerWeaponID9 = getAccountData (theCurrentAccount, "funmodev2-weaponID9") local playerWeaponID10 = getAccountData (theCurrentAccount, "funmodev2-weaponID10") local playerWeaponID11 = getAccountData (theCurrentAccount, "funmodev2-weaponID11") local playerWeaponID12 = getAccountData (theCurrentAccount, "funmodev2-weaponID12") local playerWeaponAmmo0 = getAccountData (theCurrentAccount, "funmodev2-weaponAmmo0") local playerWeaponAmmo1 = getAccountData (theCurrentAccount, "funmodev2-weaponAmmo1") local playerWeaponAmmo2 = getAccountData (theCurrentAccount, "funmodev2-weaponAmmo2") local playerWeaponAmmo3 = getAccountData (theCurrentAccount, "funmodev2-weaponAmmo3") local playerWeaponAmmo4 = getAccountData (theCurrentAccount, "funmodev2-weaponAmmo4") local playerWeaponAmmo5 = getAccountData (theCurrentAccount, "funmodev2-weaponAmmo5") local playerWeaponAmmo6 = getAccountData (theCurrentAccount, "funmodev2-weaponAmmo6") local playerWeaponAmmo7 = getAccountData (theCurrentAccount, "funmodev2-weaponAmmo7") local playerWeaponAmmo8 = getAccountData (theCurrentAccount, "funmodev2-weaponAmmo8") local playerWeaponAmmo9 = getAccountData (theCurrentAccount, "funmodev2-weaponAmmo9") local playerWeaponAmmo10 = getAccountData (theCurrentAccount, "funmodev2-weaponAmmo10") local playerWeaponAmmo11 = getAccountData (theCurrentAccount, "funmodev2-weaponAmmo11") local playerWeaponAmmo12 = getAccountData (theCurrentAccount, "funmodev2-weaponAmmo12") setPlayerMoney (source, playerMoney) setTimer (setElementHealth, 50, 1, source, playerHealth) setTimer (setPedArmor, 50, 1, source, playerArmor) setTimer (setPlayerWantedLevel, 50, 1, source, playerWanted) giveWeapon(source, playerWeaponID0, playerWeaponAmmo0, true) giveWeapon(source, playerWeaponID1, playerWeaponAmmo1, false) giveWeapon(source, playerWeaponID2, playerWeaponAmmo2, false) giveWeapon(source, playerWeaponID3, playerWeaponAmmo3, false) giveWeapon(source, playerWeaponID4, playerWeaponAmmo4, false) giveWeapon(source, playerWeaponID5, playerWeaponAmmo5, false) giveWeapon(source, playerWeaponID6, playerWeaponAmmo6, false) giveWeapon(source, playerWeaponID7, playerWeaponAmmo7, false) giveWeapon(source, playerWeaponID8, playerWeaponAmmo8, false) giveWeapon(source, playerWeaponID9, playerWeaponAmmo9, false) giveWeapon(source, playerWeaponID10, playerWeaponAmmo10, false) giveWeapon(source, playerWeaponID11, playerWeaponAmmo11, false) giveWeapon(source, playerWeaponID12, playerWeaponAmmo12, false) setCameraTarget (source, source) fadeCamera(source, true, 2.0) else spawnPlayer (source, 1481.0855712891, -1771.2996826172, 18.795753479004, 0,78, 0, 0) setPlayerMoney (source, 200) setCameraTarget (source, source) fadeCamera(source, true, 2.0) end end end addEventHandler ("onPlayerLogin", getRootElement(), playerLogin) addEventHandler ("onPlayerWasted", getRootElement(), playerLogin) function onLogout () kickPlayer (source, nil, "Logging out is disallowed.") end addEventHandler ("onPlayerLogout", getRootElement(), onLogout) function onQuit (quitType, reason, responsibleElement) if not (isGuestAccount (getPlayerAccount (source))) then account = getPlayerAccount (source) if (account) then local x,y,z = getElementPosition (source) setAccountData (account, "funmodev2-money", tostring (getPlayerMoney (source))) setAccountData (account, "funmodev2-health", tostring (getElementHealth (source))) setAccountData (account, "funmodev2-armor", tostring (getPedArmor (source))) setAccountData (account, "funmodev2-R", r) setAccountData (account, "funmodev2-G", g) setAccountData (account, "funmodev2-B", b) setAccountData (account, "funmodev2-wantedlevel", getPlayerWantedLevel (source)) setAccountData (account, "funmodev2-weaponID0", getPedWeapon (source, 0)) setAccountData (account, "funmodev2-weaponID1", getPedWeapon (source, 1)) setAccountData (account, "funmodev2-weaponID2", getPedWeapon (source, 2)) setAccountData (account, "funmodev2-weaponID3", getPedWeapon (source, 3)) setAccountData (account, "funmodev2-weaponID4", getPedWeapon (source, 4)) setAccountData (account, "funmodev2-weaponID5", getPedWeapon (source, 5)) setAccountData (account, "funmodev2-weaponID6", getPedWeapon (source, 6)) setAccountData (account, "funmodev2-weaponID7", getPedWeapon (source, 7)) setAccountData (account, "funmodev2-weaponID8", getPedWeapon (source, 8 )) setAccountData (account, "funmodev2-weaponID9", getPedWeapon (source, 9)) setAccountData (account, "funmodev2-weaponID10", getPedWeapon (source, 10)) setAccountData (account, "funmodev2-weaponID11", getPedWeapon (source, 11)) setAccountData (account, "funmodev2-weaponID12", getPedWeapon (source, 12)) setAccountData (account, "funmodev2-weaponAmmo0", getPedTotalAmmo (source, 0)) setAccountData (account, "funmodev2-weaponAmmo1", getPedTotalAmmo (source, 1)) setAccountData (account, "funmodev2-weaponAmmo2", getPedTotalAmmo (source, 2)) setAccountData (account, "funmodev2-weaponAmmo3", getPedTotalAmmo (source, 3)) setAccountData (account, "funmodev2-weaponAmmo4", getPedTotalAmmo (source, 4)) setAccountData (account, "funmodev2-weaponAmmo5", getPedTotalAmmo (source, 5)) setAccountData (account, "funmodev2-weaponAmmo6", getPedTotalAmmo (source, 6)) setAccountData (account, "funmodev2-weaponAmmo7", getPedTotalAmmo (source, 7)) setAccountData (account, "funmodev2-weaponAmmo8", getPedTotalAmmo (source, 8 )) setAccountData (account, "funmodev2-weaponAmmo9", getPedTotalAmmo (source, 9)) setAccountData (account, "funmodev2-weaponAmmo10", getPedTotalAmmo (source, 10)) setAccountData (account, "funmodev2-weaponAmmo11", getPedTotalAmmo (source, 11)) setAccountData (account, "funmodev2-weaponAmmo12", getPedTotalAmmo (source, 12)) end end end addEventHandler ("onPlayerQuit", getRootElement(), onQuit) addEventHandler ("onPlayerWasted", getRootElement(), onQuit) function onWasted(totalAmmo, killer, killerWeapon, bodypart, stealth) if not( isGuestAccount (getPlayerAccount(source)) ) then local theWeapon = getPedWeapon (source) local weaponAmmo = getPedTotalAmmo (source) fadeCamera (source, false) setTimer (spawnPlayer, 1000, 1, source, 2036.1735839844, -1413.0563964844, 16.9921875, 0, getPedSkin (source), 0, 0, getPlayerTeam(source)) setTimer (setCameraTarget, 1250, 1, source, source) setTimer (fadeCamera, 2000, 1, source, true) setTimer (giveWeapon, 2000, 1, source, theWeapon, weaponAmmo, true) end end addEventHandler ("onPlayerWasted", getRootElement(), onWasted) --- function setTeam() local account = getPlayerAccount(source) -- gets players account local team = getAccountData (account, "team") -- gets players team if (team) and getTeamFromName(team) then setPlayerTeam(source, getTeamFromName(team)) -- sets players team end end addEventHandler("onPlayerLogin",root,setTeam) -- sets players team on login addEventHandler ("onPlayerWasted",root,setTeam) function save() local team = getPlayerTeam(source) -- Gets the players team local account = getPlayerAccount(source) if (team) and not isGuestAccount(account) then -- Checks to see if the player is a guest or not setAccountData(account, "team", getTeamName(team)) --saves team end end addEventHandler("onPlayerQuit", getRootElement(), save) -- saves team on quit addEventHandler ("onPlayerWasted", getRootElement(), save)
  17. حد سئلك انت اشوفك 25 ياخي لو يجي 4 مشان يجي 10
  18. الامثلة الي بالويكي ماهي اكواد هاذا مثال على الكود مشان تفهم الكود هريسة وش نصلح وهو خبص وهريسة
  19. انا اقدر اسوية بس في شي صعب علي لما يدخل الماركر ينقل الاعبين الي يلعبو بالمتاهه
  20. انا ماقلت وش انا سئلت لية اسوي جدول ولية اسوي قيمة للجدول
  21. ذولن يعني كل الاكواد الي استخدمهن للمود بس سؤال لية استخدم ذولي table table.insert
  22. طيب كملو الفنكشات ياخي من اليوم استنى متى تكملونهن بسوية
×
×
  • Create New...