Jump to content

Max+

Members
  • Posts

    1,363
  • Joined

  • Last visited

Everything posted by Max+

  1. طيب ادري قلت لك شوف ردي تقدر تستخدم بكتابة او بدون . .. استخدم التحقق وكمل زي ماقلت لك ..
  2. كود اذا كان اللاعب ( في )الماركر1 يعطيه جواب O واذا كان في ماركر 2 يعطيه جواب X فهمت تقصد اذا هو من الاساس داخل الماركر 1 يعطيه صح واذا داخل ماركر 2 يعطيه خطأ طيب استخدم isElementWithinMarker وسوي تحقق بالفنكشن ذا لكل لاعب اذا كان في ماركر 1 واختار اجابة ماركر 2 = خطأ + لازم تستخدم Event : 'onPlayerChat' اذا تبيه كتابة اذا تبيه تلقائي استخدم مثلا امر او زر تضغطه او عند تشغيل السكربت .. وتايمر يتحقق ويغلق وقت المسابقة وتيبل فيه الاسئلة ويطلع مثلا كتابة بالشات او dx بالاعبين اللي فازو وبعد 7 ثواني يطلع الخاسرين وكل فريق وش فاز به ..
  3. --- سيرفر addEventHandler("onPlayerChat",resourceRoot, function( messageType ) if ( messageType ) == 0 then local acc = getPlayerAccount(source) if ( acc )then if ( isObjectInACLGroup("user."..getAccountName(acc), aclGetGroup("Admin")) ) then triggerClientEvent ( 'PlaySound', root ) end end end end ) --- كلينت addEvent ('PlaySound', true ) addEventHandler( 'PlaySound', root, function ( ) playSoundFrontEnd ( 16 ) end ) اللي بقروب ادمن ويكتب بالشات يطلع صوت . ..
  4. Max+

    countdown

    --ClientSide , function justForTest() end function msToTimeStr( ms ) if not ms then return '' end local s = math.floor( ms / 1000 ) local seconds = tostring( math.fmod( s, 60 ) ) if #seconds == 1 then seconds = '0' .. seconds end local minutes = tostring( math.floor( s / 60 ) ) if #minutes == 1 then minutes = '0' .. minutes end return minutes .. ':' .. seconds end myTimer = setTimer( justForTest, 180*1000, 1 ) addEventHandler( "onClientRender", root, function( ) if isTimer( myTimer ) then remaining, _, _ = getTimerDetails(myTimer) remaining = msToTimeStr( remaining ) if remaining then dxDrawText( remaining, 120, 442, 350, 300, tocolor(255, 255, 255, 255), 1.0, "pricedown", "left", "top", false, false, true, false, false) end end end ) local Bscore = 0 local Wscore = 0 addEventHandler("onClientPlayerWasted",root, function ( killer ) if ( killer and killer ~= source ) then if (getTeamName(getPlayerTeam(killer)) == "Team1") then Wscore = Wscore + 1 elseif (getTeamName(getPlayerTeam(killer)) == "Team2") then Bscore = Bscore + 1 end end end ) function onRender() local team = getPlayerTeam(localPlayer) if(getTeamName(team) == "Team1" or getTeamName(team) == "Team2") then dxDrawText("Team1:"..tostring(Bscore), 0, 500, 319, 426, tocolor(0, 0, 0, 255), 1.00, "pricedown", "center", "center", true, true, true, true, false) dxDrawText("Team2:"..tostring(Wscore), 0, 600, 319, 426, tocolor(255, 255, 255, 255), 1.00, "pricedown", "center", "center", true, true, true, true, false) end end addEventHandler("onClientRender", root, onRender) # Edited /debugscript 3
  5. Max+

    countdown

    you mean it's add +1 for team 1 only and team 2 dont ?
  6. --ClientSide , Marker = createMarker(-1456.7243652344, 532.509765625, 18.010332107544, "cylinder", 7, 100, 100, 100) addCommandHandler ( 'attach', function ( ) local nMax = getPedOccupiedVehicle ( localPlayer ) if ( nMax ) then attachElements (Marker, nMax ) end end )
  7. Max+

    countdown

    please be more clear i didn't get what you mean .
  8. marker = createMarker ( x, y, z, "cylinder", 1.5, 255, 255, 0, 170 ) addEventHandler ( 'onMarkerHit', marker, function ( nMax ) if ( getElementType ( nMax ) == 'player' ) then ---- code end end )
  9. ردودك على المواضيع تكفي لبى,$ بس انا حصلت كود وخايف اجيب العيد في المود كامل isElementWithinMarker هذا تحقق اذا اللاعب في الماركر؟ This function is used to determine if an element is within a marker. يب ذا نفس الشي . . يتحقق
  10. ---ClientSide function toggleGUI() if guiGetVisible(Name) == true then guiSetVisible(Name,false) showCursor(false) else guiSetVisible(Name,true) showCursor(true) end end addEvent("toggleGUI",true) addEventHandler("toggleGUI",root,toggleGUI) ---ServerSide addEventHandler("onPlayerJoin",root, function () bindKey(source,"F3","down",showGUI) end) addEventHandler("onResourceStart",resourceRoot, function () for index, player in ipairs(getElementsByType("player")) do bindKey(player,"F3","down",showGUI) end end) function showGUI(thePlayer) if isObjectInACLGroup("user."..getAccountName(getPlayerAccount(thePlayer)),aclGetGroup("Admin")) then triggerClientEvent(thePlayer,"toggleGUI",thePlayer) else outputChatBox(" You Dont Have Access to This Panel",thePlayer,255,0,0) end end Name -- غيرها لاسم النافذة اللي عندك F3 --- ذا زر الفتح . .
  11. show image of the file and the txd files + /debugscript 3 ?
  12. then change the dir to "Swat2014/skins/swat.txd"
  13. سويت لك طريقة عشانك addCommandHandler('Make', function ( ) nHeight = 10 nWidth = 10 nDepth = 10 local x, y, z = getElementPosition ( localPlayer ) createColCuboid(x, y, z, nHeight, nWidth, nDepth ) outputChatBox ( ' * Cuboid Created / nMax to get Height , Width, Depth ', 255, 255, 0 ) end ) addCommandHandler ('nMax', function ( ) outputChatBox("* Height : " .. nHeight .. " " .. " * Width :".. nWidth .. " ".. " * Depth :" .. nDepth .. " " , 255, 0, 0 ) end )
  14. yeb the code is correct and the meta.xml is correct , the problem is with the skin files .. txd , dff need to fined a working ones ..
  15. that becuase your txd , dff files is not good ( corrupted ) make sure you have a good txd , dff files
  16. i edited my Post , copy it again , also /debugscript 3 to see if there is any erros ...
  17. تسوي كول شيب ومن ثم تجلب الاحداثيات -__-[/quote ] مثال اعرف قصدك يازاحف انا ابي اوضح له فقط يقدر يحط ذا اول وذاك ثاني وانتهينا . . + تم التعديل
  18. fWidth: عرض المكعب fDepth: عمق المكعب fHeight: طول المكعب ---- fx, fy , fz = هي نفسها x, y , z local fx, fy, fz = getElementPosition ( col ) اذا تبي تجيب احداثيات المكعب .. مثال انشاء المكعب . . local x, y , z = getElementPosition ( localPlayer ) local col = createColCuboid ( x, y, z , 10, 10, 10 )
  19. addEventHandler('onClientResourceStart', resourceRoot, function ( ) txd = engineLoadTXD( "skins/swat.txd") engineImportTXD (txd, 285 ) dff= engineLoadDFF ("skins/swat.dff", 285) engineReplaceModel ( dff, 285 ) outputChatBox ( ' * Swat Skin Replaced * ', 255, 255, 0 ) end ) Make sure the skins are in folder skins .. Meta.xml <meta> <info author="Name" type="script" version="1.0" name="Skin" /> <script src="sskinc.lua" type="client" /> <files src="skins/swat.txd"/> <files src="skins/swat.dff"/> </meta> Edited @
  20. show your , script + meta.xml
  21. طيب ماعندك خاصية تكشف من مركب لوحة مفكوكه ؟ ويتعرض للايقاف من الاستضافة ؟ اما بالنسبة للفك هل مبرمج Php / html ?
  22. طيب , تحقق اذا الاعب في الماركر 1 --- يسوي شي واذا في الماركر 2 --- يسوي شي ماتوقع صعبه عليك ؟
×
×
  • Create New...