Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 12/05/17 in all areas

  1. addCommandHandler ( "rg" , function ( player , cmd , username , password ) if ( cmd and username and password ) then local aNewAccount = addAccount ( username , password ); if ( aNewAccount ) then outputChatBox ( "* Done",player,0,255,0,true); setAccountData ( aNewAccount , "Password" , tostring ( password ) ); end end end ); addCommandHandler ( "gap" , function ( player , cmd , account ) local data = getAccountData ( getAccount ( account ) , "Password" ); if ( data ) then outputChatBox(data,player); else outputChatBox("Error",player); end end ); جرب المثال وشوف النتيجة
    2 points
  2. السلام عليكم ورحمة الله وبركاته اذا كنت تريد ان تشارك صورك , فيديوهاتك , قصصك , الخ ... فتم تأسيس هذا الموضوع لهذه الاشياء فـ اذا كنت تريد ان ترفه عن نفسك او تضع صور , فيديوهات , ترفيه الخ ... فضع ما تريد هنا قوانين الموضوع هناك عدة قوانين للموضوع يجب الالتزام بها حتى لا يتم حذف مشاركتك عدم السب والقذف واهانة الآخرين -1 2- عدم نشر صور/فيديوهات بذيئة 3- لا مشاركات المزدوجة 4- عدم طلب مساعدة في كودات 5- يمنع كثرة الإعلانات في الموضوع بمعنى انه لا يجب نشر اعلانات اكثر من مشاركتين متتاليتين في وقت واحد ...استمتعوا بآوقاتكم ملاحظة بسيطة : هذا الموضوع موجود قبل انشاء هذا القسم حيث كان الموضوع الوحيد الذي يشارك الاعضاء فيه قصصهم وصورهم وفيديوهاتهم والخ
    1 point
  3. أعذرني , م إجت ع بالي شكرا ع المعلومة
    1 point
  4. @#_iMr.[E]coo تضبط الطريقة register لكن راح يحتاج يعدل لوحة الادمنية على الامر ويضيف على الحساب اكونت داتا وتكون القيمة الباسسورد او يعدل على لوحة التسجيل حقته وزي الطريقة يحط على الحساب اكونت داتا وتكون القيمة الباسسورد وحتى لو كانت بالسكل راح يحتاج لحساب الاعب
    1 point
  5. !! ياخوي ماعليك منه , اصلا السرفر صيانه و الرجال م شافه بس ناوي يتفلسف عشان يبي الزوار يطيرون ع سيرفره والمصيبة ان سيرفره م فيه ولا موتر حصري وموداتهم كلها يوتيوب ومع ذلك يتفلسف ههههههه
    1 point
  6. @Sia Because addEventHandler is a function and you're writing the function within it. The argument in addEventHandler requires a function. You can either add a reference to your function or you can directly write your function as the argument. function printMessage() outputChatBox(getPlayerName(source).." Has Spawned") end addEventHandler("onClientPlayerSpawn", root, printMessage) -- put the function in here Or you could write it directly like so: addEventHandler( "onClientPlayerSpawn", root, function() -- write the function here directly outputChatBox( getPlayerName(source).." Has Spawned " ) end) -- or addEventHandler( "onClientPlayerSpawn", root, function() outputChatBox( getPlayerName(source).." Has Spawned " ) end ) -- however you prefer You see, it's an argument so you have to close the addEventHandler function with a ) .
    1 point
  7. وانا عطيته حل فهمت قصدي +_+
    1 point
  8. يوم يسجل ، تحط له في حسابه داتا ويوم تجي تسو الفنكشن حقك تجيب الداتا وخلصنا والله كنت اكتبها بس سبقني @@ ض
    1 point
  9. @iMr.WiFi..! : مو شرط يسويها بـ SQLite يقدر يسويها بالاكوانت داتا setAccountData getAccount getAccountData
    1 point
  10. This is a client-side script, make sure you set the type="client" in your meta.xml
    1 point
  11. That doesn't make sense, you are trying to disable the collision for player1 with player1. What I would do is: local colsEnabled = true addEventHandler( "onClientElementStreamIn", getRootElement( ), function ( ) if getElementType( source ) == "player" and not colsEnabled then setElementCollidableWith(localPlayer, source, false) end end ) function toggleCollisionsForPlayer(p, enabled) for k, v in ipairs(getElementsByType("player")) do setElementCollidableWith(p, v, enabled) end end addCommandHandler("toggle_col", function() toggleCollisionsForPlayer(localPlayer, not colsEnabled) colsEnabled = not colsEnabled end) Not tested, but should work. Basically when you enter "/toggle_col", if it is enabled, it calls toggleCollisionsForPlayer that will loop thru each player and disable the collisions between them. But if a player connects to the server, the collision with that player will still be enabled, that is why I added the event onClientElementStreamIn. When that event runs, it checks if the colsEnabled = false (so collisions are disabled) and disables the collision with the source element (the element that got streamed in)
    1 point
  12. yes make sure u set it to 50ms so your server gets lagged it would be like setTimer(function() do what you wanted to do end, 250, 0) the 250 is delay, it will check that every 250ms, you probably can make it longer so that's less performance impact, and 0 means that it's infinite.
    1 point
  13. قبل لا تفتح السيرفر ... شفر الملفات عشان ما تنسرق #
    1 point
  14. Why don't you start with learning how to create an infinity timer? Just create it for fun and let it say something in the chat! https://wiki.multitheftauto.com/wiki/SetTimer https://wiki.multitheftauto.com/wiki/OutputChatBox
    1 point
  15. https://forum.multitheftauto.com/forum/135-المساهمات/
    1 point
  16. اول شي هدا مو قسم نشر سيرفرات بنسبة للحصريات ما اشوف اي شي حصري 1 - مواتر حصريه بالكامل موديلات 2017 و 2016 2 - المودات حصريه 3 - ماب التفتيش بالدايري 4 - السباون بالنخيل 5 - السيرفر شبه خالي من اللاق 6 - مود المسابقات اف9 اولا مواتر مو حقك تاني شي مودات اين صور مودات ماب تفتيش بدايري فكرة مستهلكة حاول تجيب افكار جديدة السيرفر شبه خالد من لاق على اساس كل سيرفرات فيها لاق سباون بنخيل ما اشوف فيه شي جديد مود المسابقات اف 9 ارفق معاه صورة ردي لا يعتر اهانة لك مع فائق كل احترامي لاي واحد ينشر بمنتدى اتمنى تتقبل ردي السريع وبتوفيق لك
    1 point
  17. Loops are not meant to check if something has changed, they will keep running and delay all other processes until the system stops it. Loops are for processing multiple pieces of data during one action. How about you use a timer instead? (if serverside) https://wiki.multitheftauto.com/wiki/SetTimer Or 'onClientRender' (if clientside) https://wiki.multitheftauto.com/wiki/OnClientRender
    1 point
  18. Se você for permitir que os membros fiquem em diferentes facções ao mesmo tempo, você vai precisar de algum sistema onde o jogador decida qual skin deseja pegar. Por exemplo: O jogador está no Exército e na Yakuza ao mesmo tempo. (EB e YKZ). Ele quer ter acesso às duas skins, mas ao executar o comando /skin, ele só recebe do exército mas queria poder receber da Yakuza também. Para resolver esse problema, será necessário que o jogador informe de alguma maneira ao resource, qual das skins ele quer pegar. Existem dois jeitos diferentes, a primeira é a mais simples, onde vc faz um comando diferente para cada skin. function darSkinEB (thePlayer) local nomeAcc = getAccountName (getPlayerAccount (thePlayer)) if isObjectInACLGroup ("user."..nomeAcc, aclGetGroup("EB")) then setElementModel (thePlayer, 287) else outputChatBox ("Você não tem permissão para usar a skin do #00BB00Exército.", thePlayer, 255, 0, 0, true) end end addCommandHandler ("skineb", darSkinEB) function darSkinYKZ (thePlayer) local nomeAcc = getAccountName (getPlayerAccount (thePlayer)) if isObjectInACLGroup ("user."..nomeAcc, aclGetGroup("YKZ")) then setElementModel (thePlayer, 140) else outputChatBox ("Você não tem permissão para usar a skin da #BB0000Yakuza.", thePlayer, 255, 0, 0, true) end end addCommandHandler ("skinykz", darSkinYKZ) Outro jeito, um pouco mais complexo porém mais leve do que criar várias funções, é você criar um parâmetro junto ao comando. Este parâmetro informará ao script qual a skin que o jogador quer pegar. Exemplo: "/skin exercito" ou "/skin yakuza" function darSkin (thePlayer, commandName, faction) -- Função geral, o faction é o que o jogador vai informar após o comando. local nomeAcc = getAccountName (getPlayerAccount (thePlayer)) if faction == "exercito" then -- Se o jogador der o comando "/skin exercito", faz o seguinte: if isObjectInACLGroup ("user."..nomeAcc, aclGetGroup("EB")) then setElementModel (thePlayer, 287) else outputChatBox ("Você não tem permissão para usar a skin do #00BB00Exército.", thePlayer, 255, 0, 0, true) end elseif faction == "yakuza" then -- Se o jogador der o comando "/skin yakuza", faz o seguinte: if isObjectInACLGroup ("user."..nomeAcc, aclGetGroup("YKZ")) then setElementModel (thePlayer, 140) else outputChatBox ("Você não tem permissão para usar a skin da #BB0000Yakuza.", thePlayer, 255, 0, 0, true) end elseif faction == nil then -- Se o jogador der o comando "/skin", faz o seguinte: outputChatBox ("Erro de sintaxe, use /skin <nome da facção>", thePlayer) else -- Se o jogador der o comando "/skin" seguido de qualquer coisa que não esteja programada aqui, faz o seguinte: outputChatBox ("Erro: Não existe skin dessa facção.", thePlayer) end end addCommandHandler ("skin", darSkin, false, false) --Esse penúltimo false indica que o comando não é restrito. O último false indica que o comando não diferencia maiúsculas de minúsculas. Ou seja, se ele usar /SkIN EXerciTO, vai funcionar mesmo assim. Espero ter ajudado. Caso possua mais dúvidas, estamos aqui para ajudar.
    1 point
  19. Não é recomendável vc colocar o mesmo comando para funções diferentes. O ideal é vc colocar os dois na mesma função. function darSkin (thePlayer) local nomeAcc = getAccountName (getPlayerAccount (thePlayer)) if isObjectInACLGroup ("user."..nomeAcc, aclGetGroup("EB")) then setElementModel (thePlayer, 287) elseif isObjectInACLGroup ("user."..nomeAcc, aclGetGroup("YKZ")) then setElementModel (thePlayer, 140) end end addCommandHandler ("skin", darSkin) Obs: Se o jogador estiver nas duas ACLs ao mesmo tempo, ele vai colocar a skin do EB, pois é a condição que ele vai entrar primeiro. Ao entrar em um IF, ele não vai entrar em um ELSE, mesmo se a condição dele também for verdadeira.
    1 point
  20. It has come to our attention that our response to support related forum threads can be sometimes rather slow. This is due to the fact that most of our staff team has work, college or school to attend and therefore we're not able to respond that fast on the forum. However, due to us having access to our phones we tend to answer support related questions on Discord a lot faster than the forums, therefore if you have an issue that you would like to resolve quicker please use the Discord to which link you can find on the original post. Ofcourse, as the answers tend to usually come from our phones we'd like to apologize for any grammar mistakes in advance.
    1 point
  21. صراحة فكرة حلوه واتمنى لو يصلحون الاخطاء الي فيه ويكون شبيه للعبة 100 % 100 بيكون شي خرافي
    1 point
  22. Making comments like that doesn't exactly get it "on par" with MTA:SA. Killing off anyone's interest would only kill development for the project.
    1 point
×
×
  • Create New...