
SycroX
Members-
Posts
2,141 -
Joined
-
Last visited
-
Days Won
15
Everything posted by SycroX
-
ما قلت عشان يبرمج قلت عشان يفهم الشرح في الفانكشنات و شرح الأشياء الأخري
-
لازم تعرف انجليزي عشان تفهم شرح الفانكشنات ما هتلاقي كل شي بسهوله + لا حد يقول ويكي العربي - الويكي العربي مسحوب عليه و في اشياء كتيره جدا مو مترجمه
-
ranks = { "Console", "AP" } function cOpen(player) local Account = getPlayerAccount(player) if Account and not isGuestAccount(Account) then local AccountName = getAccountName(Account) for _,value in ipairs(ranks) do if isObjectInACLGroup("user."..AccountName, aclGetGroup(value))) then triggerClientEvent( player, "openadminp", player ) end end end end addCommandHandler( "open", cOpen)
-
اكيد ما تقدر تترجم من جوجل جوجل يعتمد علي القواعد + معاني الأنجليزي في البرمجه تختلف عن معانيه في الحقيقه ما ينفع تعتمد علي ترجمه الكودات ذا هيكون نتيجتو خراب كبير + كيف تبي تصير مبرمج و ما تعرف انجليزي
-
setElementData Shared function This function stores element data under a certain key, attached to an element. Element data set using this is then synced with all clients and the server. The data can contain server created elements, but you should avoid passing data that is not able to be synced such as xmlnodes, acls, aclgroups etc. As element data is synced to all clients, it can generate a lot of network traffic and consume server CPU. Events are much more efficient for sending data from a client to the server only, or from the server to a specific client.
-
ما في في القسم شرح واحد فقط عن الفرق بين روت و سورس :- الشرح الوحيد الي موجود هوا شرح السورس فقط + للأخ صاحب الموضوع شوف الموضوع ذا حق السورس مفيد جدا لازم تعرف وش هوا شرح خاص للسورس | source ثاني شي الروت ما في شرح عنو بالعربي بس تقدر تفهمو من الويكي لانو مفصلو هناك https://wiki.multitheftauto.com/wiki/Element_tree#Tree_elements
-
و ليه يستعمل الداتا @killerProject المفروض يقلل منها + الجداول في الحاله ذي هي اصح طريقه vec = { } for _,player in ipairs(getElementsByType("player")) do if ( isElement( vec[player] ) ) then destroyElement( vec[player] ) end if isPedInVehicle(player) then removePedFromVehicle(player) end local x, y, z = getElementPosition( player ) vec[player] = createVehicle( carid, x, y, z ) warpPedIntoVehicle( player, vec[player] ) end end
-
first request function getSerialDDScore(serial) local result = dbPoll(dbQuery(DerbyDB, "SELECT DDscore FROM DerbyMission WHERE DDserial = ?", serial), -1) if type(result) == "table" and #result ~= 0 then return tonumber(result[1]) end end ican't help you in the second request cause i don't understand what you want :-
-
بكل بسطه else تيجي مع التحققات و فايدتها ان لو حصل عكس التحقق or و and و في طريقه تانيه للتحقق بـ if يعني مثلا انا الحين بدي اتاكد لو اللاعب معه فلوس 500 فلازم اتحقق بـ ifلهيك هنتحقق بـ else بس طبعا انت تبي فالكود هيكون كالتالي addCommandHandler("check", -- نسوي الكومند function(p) -- الفانكشن if getPlayerMoney(p) > 500 then -- نتحقق اذا فلوس اللاعب اكثر من 500 print("player's money is bigger than 500 $") -- اذا النتيجه ايجابيه و فلوسو اكتر من 500 هيطبع الكلام ذا else -- اذا فلوسو اقل او تساوي 500 print("player's money is smaller than or equal 500 $") -- هيطلع الكلام ذا اذا فلوسو اقل او تساوي 500 end -- نهايه التحقق end -- نهايه الفانكشن ) -- اغلاق الكومند
-
ماني فاهمك كويس ؟ الي فهمتو فقط انك تبي لو مثلا اللاعب في دايمنشن 20 و الماركر في دايمنشن 0 و اللاعب عدا علي المركر ما يسوي شي ؟ اذا ذا الي تباه راح يكون كودك هيك marker = createMarker( -2408.00000,-599.00000,132.64844,'corona',1.5,0,220,0,255 ) addEventHandler('onMarkerHit', root, function (thePlayer, matchDim) if source == marker and matchDim then setElementDimension( thePlayer, 3 ) setElementPosition( thePlayer, -2382.64868,-586.77521,132.11719 ) end end ) اما اذا تبي الماركر في دايمنشن 20 فا راح يكون هيك marker = createMarker( -2408.00000,-599.00000,132.64844,'corona',1.5,0,220,0,255 ) setElementDimension(marker, 20) addEventHandler('onMarkerHit', root, function (thePlayer) if source == marker then setElementDimension( thePlayer, 3 ) setElementPosition( thePlayer, -2382.64868,-586.77521,132.11719 ) end end )
-
Settings = { ["Key"] = "F10" } ----- bindKey(Settings["Key"], "down", function() -- end end )
-
get - set = serverside only ! ثاني شي للأخ صاحب الموضوع في واحد فوق قدم لك حل + حط الملف client
-
this is not MTA . that game is SA:MP ( San Andress Multi Player) it's anther game with another programming language
-
can u show me the args of your command ?
-
you'v only put the player name in a table getPlayerFromName -- use this command to get the player from his name setTimer(function () local pTable = {"Alvin_Michael"} for _,player in ipairs(getElementsByType("player")) do if pTable[getPlayerName(player)] then executeCommandHandler("respawnall 10", player) end end end, 5000, 0) or another way setTimer(function () local players = {"Alvin_Michael"} for _,value in ipairs(players) do local player = getPlayerFromName(value) if player then executeCommandHandler("respawnall 10", player) end end end, 5000, 0)
-
wow 116 views and no one can help me ???
-
i've tried many ways but the result it same .. * Note : all weapons are worked exept the sniper and the rifle .. - the code is working with the other weapons this is another way addEventHandler("onPlayerWeaponSwitch", root, function(_, curWep) if curWep == 34 then local stat = getPedStat(source, 79) if stat < 300 then setWeaponProperty(34, "poor", "damage", 1000) elseif stat >= 300 and stat < 999 then setWeaponProperty(34, "std", "damage", 500) elseif stat >= 999 then setWeaponProperty(34, "pro", "damage", 100) end end end ) + i've created a code to check the result but the result always same addCommandHandler("wep", function(player,_,id,s,p) local id = tonumber(id) outputChatBox("Original : "..getOriginalWeaponProperty(id, tostring(s), tostring(p)), player) outputChatBox("Current : "..getWeaponProperty(id, tostring(s), tostring(p)), player) end )
-
i've spent 1 day trying to solve that problem but i failed .. the code is simple and i don't see any mistakes in it so can any one help me ???
-
hello guys. i want to create a levels for weapons. i've created it and it's work well exept 2 weapons the sniper and the rifle idk why buy when i use setWeaponProperty with any weapons it works but when i use it with sniper and rifle nothing happen and the properties of all levels pro - std - poor set to poor that's a simple code for my problem setPedStat to change player weaponSkills the stat of sniper is 79 addEventHandler("onResourceStart", resourceRoot, function() setWeaponProperty("sniper", "pro", "damage", 130) setWeaponProperty("sniper", "pro", "accuracy", 1) setWeaponProperty("sniper", "pro", "flag_move_and_shoot", true) setWeaponProperty("sniper", "pro", "target_range", 350) setWeaponProperty("sniper", "pro", "weapon_range", 400) -- setWeaponProperty("sniper", "std", "damage", 130) setWeaponProperty("sniper", "std", "accuracy", 1) setWeaponProperty("sniper", "std", "flag_move_and_shoot", true) setWeaponProperty("sniper", "std", "target_range", 350) setWeaponProperty("sniper", "std", "weapon_range", 400) -- setWeaponProperty("sniper", "poor", "damage", 130) setWeaponProperty("sniper", "poor", "accuracy", 1) setWeaponProperty("sniper", "poor", "flag_move_and_shoot", true) setWeaponProperty("sniper", "poor", "target_range", 350) setWeaponProperty("sniper", "poor", "weapon_range", 400) end )