Mr.Hugin Posted December 31, 2019 Share Posted December 31, 2019 لو سمحتو يا شباب يلي بيعرف للبرمجة والكواد انا بدي كود برمجة شات الخاص من حرب n يعني مثلPM: ضروري شباب الكود انتمنة الرد باسرع وقت Link to comment
Guest Posted January 3, 2020 Share Posted January 3, 2020 On 31/12/2019 at 11:50, JoKerSyria said: لو سمحتو يا شباب يلي بيعرف للبرمجة والكواد انا بدي كود برمجة شات الخاص من حرب n يعني مثلPM: ضروري شباب الكود انتمنة الرد باسرع وقت https://community.multitheftauto.com/index.php?p=resources&s=details&id=8020 في هالمود منشور لكن لازم تكتب /pm لو لك خبرة في البرمجة شوي حاول تعدلها والمود ماهو مشفر Link to comment
iiv03 Posted January 3, 2020 Share Posted January 3, 2020 On 31/12/2019 at 11:50, JoKerSyria said: لو سمحتو يا شباب يلي بيعرف للبرمجة والكواد انا بدي كود برمجة شات الخاص من حرب n يعني مثلPM: ضروري شباب الكود انتمنة الرد باسرع وقت 2 hours ago, .TiGGeR said: https://community.multitheftauto.com/index.php?p=resources&s=details&id=8020 في هالمود منشور لكن لازم تكتب /pm لو لك خبرة في البرمجة شوي حاول تعدلها والمود ماهو مشفر لو يبغى زر يضغطه عشان يسوي الحدث يستخدم bindKey 1 Link to comment
Mr.Hugin Posted January 3, 2020 Author Share Posted January 3, 2020 اشكركم يا اخواني والله انكم كفووو الله يسعدكم Link to comment
Mr.Hugin Posted January 4, 2020 Author Share Posted January 4, 2020 (edited) شباب شلون ابرمج كود زر يفتح الوحة اتمنة ارد بأسرع وقت Edited January 4, 2020 by JoKerSyria Link to comment
Mr.Hugin Posted January 4, 2020 Author Share Posted January 4, 2020 يعني شباب لمن بدي اكتب بلخاص يكتب بحرفL او مثلن اي حرف بس علموني على الكودات وين احطها وشكرأ Link to comment
Scripting Moderators xLive Posted January 4, 2020 Scripting Moderators Share Posted January 4, 2020 5 hours ago, JoKerSyria said: يعني شباب لمن بدي اكتب بلخاص يكتب بحرفL او مثلن اي حرف بس علموني على الكودات وين احطها وشكرأ .ماراح تلقى كل شيء تحتاجه أو تبيه بالجاهز, تعلم البرمجة وإذا احتجت مساعدة أو ماعرفت شيء بنساعدك وبنعلمك 1 Link to comment
Guest Posted January 4, 2020 Share Posted January 4, 2020 5 hours ago, Do_De<3 said: تقصد لوكل شات ؟ يبغى يسوي سكربت الخاص بإستخدام زر Link to comment
Mr.Hugin Posted January 4, 2020 Author Share Posted January 4, 2020 (edited) لا اخوي انا قصدي انو بس بدي زر يعني لمن يجي يكتب شخص يكبس حرف n مثلان ويكتب فهمتوني شباب يعني بدي ابرمج زر بلختصار بس لو واحد يبرمجلي زر 31 minutes ago, .TiGGeR said: يبغى يسوي سكربت الخاص بإستخدام زرا اخوي الله يعطيك العافية لكن انا قصدي بدي برمجة زر يعني بس يعني مثلن لاعب اسمو مثلن انا انسخ اسمو وحط قدام اسمو PMJokerSyria مثلن هيك ورسل في اف٨ ويكتب قدامو كلام واقدراتكلم بحرف عرفت اخوي شو قصدي Edited January 4, 2020 by JoKerSyria Link to comment
Scripting Moderators xLive Posted January 4, 2020 Scripting Moderators Share Posted January 4, 2020 17 minutes ago, JoKerSyria said: لا اخوي انا قصدي انو بس بدي زر يعني لمن يجي يكتب شخص يكبس حرف n مثلان ويكتب فهمتوني شباب يعني بدي ابرمج زر بلختصار بس لو واحد يبرمجلي زر اخوي الله يعطيك العافية لكن انا قصدي بدي برمجة زر يعني بس يعني مثلن لاعب اسمو مثلن انا انسخ اسمو وحط قدام اسمو PMJokerSyria مثلن هيك ورسل في اف٨ ويكتب قدامو كلام واقدراتكلم بحرف عرفت اخوي شو قصدي استخدم فنكشن bindKey عشان تربط تنفيذ أمر بزر ذا الأمر يلي تحتاجه chatbox [اسم الأمر يلي تقدر ترسل منه] بالنسبة لطلبك الثاني ماوضحت كثير لكن يلي فهمته تبي تكتب أمر وكلام ويطلع الاسم والكلام بالشات؟ تحتاج هذي الوظايف سهل جدًا تسويه addCommandHandler -- تسوي وتربطه بفنكشن getPlayerName -- تجيب اسم الاعب outputChatBox -- ترسل رسالة بالشات بوكس Link to comment
Mr.Hugin Posted January 4, 2020 Author Share Posted January 4, 2020 (edited) ما فهمتني طيب انا قصتي شفت الشات الخاص انا بدي نفسو بس يعني بزر عرفت شلون تعبتك معاي لكن اشكرك على تواجدك معي Edited January 4, 2020 by JoKerSyria Link to comment
Scripting Moderators xLive Posted January 4, 2020 Scripting Moderators Share Posted January 4, 2020 (edited) 4 minutes ago, JoKerSyria said: ما فهمتني طيب انا قصتي شفت الشات الخاص انا بدي نفسو بس يحرق يعني بزر عرفت شلون تعبتك معاي لكن اشكرك على تواجدك معي -- Client-side bindKey ("key","down","chatbox","الأمر") Edited January 4, 2020 by Live Link to comment
Mr.Hugin Posted January 4, 2020 Author Share Posted January 4, 2020 طيب اسمع الان عرفت الأمر لكن وين احطو بلكودات شوف الرابط المود فوق لأن شفتو معقد شوي مافهمت عرفت Link to comment
Scripting Moderators xLive Posted January 4, 2020 Scripting Moderators Share Posted January 4, 2020 1 minute ago, JoKerSyria said: طيب اسمع الان عرفت الأمر لكن وين احطو بلكودات شوف الرابط المود فوق ضيفه لملف كلينت إذا مافيه سوي واحد وضيفه بملف الـ ميتا وياليت تتعلم البرمجة وتساعدك نفسك لأن إذا احتجت حاجة بعدين ماراح تلقاه جاهز كذا او أحد يساعدك 1 Link to comment
Mr.Hugin Posted January 4, 2020 Author Share Posted January 4, 2020 طيب شلو ارسل الكودات الكلاننت عشان تعرف شو قصدي local mycrpmpartner = {} function thePM(thePlayer,commandName,sendToName,...) local pmWords = { ... } local pmMessage = table.concat( pmWords, " " ) if sendToName then if getPlayerFromNamePart2(sendToName) then local toPlayer = getPlayerFromNamePart2(sendToName) if not (toPlayer == thePlayer) then --that () needed if not (pmMessage == "") then outputChatBox("#757575[PM] Message to #ff00ff" .. getPlayerName(toPlayer) .. ":#ffffff " .. pmMessage, thePlayer, 255, 255, 255, true) outputChatBox("#757575[PM] Message from #ff00ff" .. getPlayerName(thePlayer) .. ":#ffffff " .. pmMessage, toPlayer, 255, 255, 255, true) mycrpmpartner[thePlayer]=toPlayer mycrpmpartner[toPlayer]=thePlayer else outputChatBox("#757575[PM]Use:#ff9900 /pm [part of name] [message]", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM] You cannot PM yourself #ff9900!", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM] Player not found! #FFFF00[#ff9900"..sendToName.."#FFFF00]", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM]Use:#ff9900 /pm [part of name] [message]", thePlayer, 255, 255, 255, true) end end addCommandHandler("pm", thePM) function reply(thePlayer,commandName,...) local pmWords = { ... } local pmMessage = table.concat( pmWords, " " ) local toPlayer = mycrpmpartner[thePlayer] if toPlayer and isElement(toPlayer) then if not (pmMessage == "") then outputChatBox("#757575[PM] Message to #ff00ff" .. getPlayerName(toPlayer) .. ":#ffffff " .. pmMessage, thePlayer, 255, 255, 255, true) outputChatBox("#757575[PM] Message from #ff00ff" .. getPlayerName(thePlayer) .. ":#ffffff " .. pmMessage, toPlayer, 255, 255, 255, true) else outputChatBox("#757575[PM]Use:#ff9900 /repm [message]", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM]There is no pm partner", thePlayer, 255, 255, 255, true) end end addCommandHandler("repm", reply) function getPlayerFromNamePart2 ( name ) --MY EPIC PLAYER FIND PART if ( name ) then for _, player in ipairs ( getElementsByType ( "player" ) ) do local name_ = getPlayerName ( player ):gsub ( "#%x%x%x%x%x%x", "" ):lower ( ) if name_:find ( tostring ( name ):lower ( ), 1, true ) then return player end end end end addEventHandler ( "onPlayerQuit", getRootElement(), function() mycrpmpartner[source]=nil end) هاذ هو يلي انا اقلك بدي ابرمج زر علية هاذا الكود طرحتو اتمنة تقدر تساعدني اخوي فيه اسمع شو دسكورد تبعك طيب ارسل الدسكورد نتكلم 18 minutes ago, Live said: ضيفه لملف كلينت إذا مافيه سوي واحد وضيفه بملف الـ ميتا وياليت تتعلم البرمجة وتساعدك نفسك لأن إذا احتجت حاجة بعدين ماراح تلقاه جاهز كذا او أحد يساعدك ارسل الدسكورد تبعك Link to comment
Mr.Hugin Posted January 4, 2020 Author Share Posted January 4, 2020 شباب يلي بيعرف للبرمجة انا محتاج حد يعدلي شوي هاذا الكود عجزت هاذا الكود local mycrpmpartner = {} function thePM(thePlayer,commandName,sendToName,...) local pmWords = { ... } local pmMessage = table.concat( pmWords, " " ) if sendToName then if getPlayerFromNamePart2(sendToName) then local toPlayer = getPlayerFromNamePart2(sendToName) if not (toPlayer == thePlayer) then --that () needed if not (pmMessage == "") then outputChatBox("#757575[PM] Message to #ff00ff" .. getPlayerName(toPlayer) .. ":#ffffff " .. pmMessage, thePlayer, 255, 255, 255, true) outputChatBox("#757575[PM] Message from #ff00ff" .. getPlayerName(thePlayer) .. ":#ffffff " .. pmMessage, toPlayer, 255, 255, 255, true) mycrpmpartner[thePlayer]=toPlayer mycrpmpartner[toPlayer]=thePlayer else outputChatBox("#757575[PM]Use:#ff9900 /pm [part of name] [message]", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM] You cannot PM yourself #ff9900!", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM] Player not found! #FFFF00[#ff9900"..sendToName.."#FFFF00]", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM]Use:#ff9900 /pm [part of name] [message]", thePlayer, 255, 255, 255, true) end end addCommandHandler("pm", thePM) function reply(thePlayer,commandName,...) local pmWords = { ... } local pmMessage = table.concat( pmWords, " " ) local toPlayer = mycrpmpartner[thePlayer] if toPlayer and isElement(toPlayer) then if not (pmMessage == "") then outputChatBox("#757575[PM] Message to #ff00ff" .. getPlayerName(toPlayer) .. ":#ffffff " .. pmMessage, thePlayer, 255, 255, 255, true) outputChatBox("#757575[PM] Message from #ff00ff" .. getPlayerName(thePlayer) .. ":#ffffff " .. pmMessage, toPlayer, 255, 255, 255, true) else outputChatBox("#757575[PM]Use:#ff9900 /repm [message]", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM]There is no pm partner", thePlayer, 255, 255, 255, true) end end addCommandHandler("repm", reply) function getPlayerFromNamePart2 ( name ) --MY EPIC PLAYER FIND PART if ( name ) then for _, player in ipairs ( getElementsByType ( "player" ) ) do local name_ = getPlayerName ( player ):gsub ( "#%x%x%x%x%x%x", "" ):lower ( ) if name_:find ( tostring ( name ):lower ( ), 1, true ) then return player end end end end addEventHandler ( "onPlayerQuit", getRootElement(), function() mycrpmpartner[source]=nil end) بدية يفتح بحرف ميم الشات الخاص Link to comment
Mr.Hugin Posted January 4, 2020 Author Share Posted January 4, 2020 local mycrpmpartner = {} function thePM(thePlayer,commandName,sendToName,...) local pmWords = { ... } local pmMessage = table.concat( pmWords, " " ) if sendToName then if getPlayerFromNamePart2(sendToName) then local toPlayer = getPlayerFromNamePart2(sendToName) if not (toPlayer == thePlayer) then --that () needed if not (pmMessage == "") then outputChatBox("#757575[PM] Message to #ff00ff" .. getPlayerName(toPlayer) .. ":#ffffff " .. pmMessage, thePlayer, 255, 255, 255, true) outputChatBox("#757575[PM] Message from #ff00ff" .. getPlayerName(thePlayer) .. ":#ffffff " .. pmMessage, toPlayer, 255, 255, 255, true) mycrpmpartner[thePlayer]=toPlayer mycrpmpartner[toPlayer]=thePlayer else outputChatBox("#757575[PM]Use:#ff9900 /pm [part of name] [message]", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM] You cannot PM yourself #ff9900!", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM] Player not found! #FFFF00[#ff9900"..sendToName.."#FFFF00]", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM]Use:#ff9900 /pm [part of name] [message]", thePlayer, 255, 255, 255, true) end end addCommandHandler("pm", thePM) function reply(thePlayer,commandName,...) local pmWords = { ... } local pmMessage = table.concat( pmWords, " " ) local toPlayer = mycrpmpartner[thePlayer] if toPlayer and isElement(toPlayer) then if not (pmMessage == "") then outputChatBox("#757575[PM] Message to #ff00ff" .. getPlayerName(toPlayer) .. ":#ffffff " .. pmMessage, thePlayer, 255, 255, 255, true) outputChatBox("#757575[PM] Message from #ff00ff" .. getPlayerName(thePlayer) .. ":#ffffff " .. pmMessage, toPlayer, 255, 255, 255, true) else outputChatBox("#757575[PM]Use:#ff9900 /repm [message]", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM]There is no pm partner", thePlayer, 255, 255, 255, true) end end addCommandHandler("repm", reply) function getPlayerFromNamePart2 ( name ) --MY EPIC PLAYER FIND PART :D if ( name ) then for _, player in ipairs ( getElementsByType ( "player" ) ) do local name_ = getPlayerName ( player ):gsub ( "#%x%x%x%x%x%x", "" ):lower ( ) if name_:find ( tostring ( name ):lower ( ), 1, true ) then return player end end end end addEventHandler ( "onPlayerQuit", getRootElement(), function() mycrpmpartner[source]=nil end) هاذا الكود شباب طبعن هذة الكود جنني بدي شباب يفتح بحرف يعني بدي فتح بحرف L هو شات خاص انا بدي يفتح بحرف L طبعن هو شات خاص PM: فاتمنة تلاقولي حل شباب يلي يعرف برمجة مضبوط Link to comment
Do_De<3 Posted January 4, 2020 Share Posted January 4, 2020 (edited) function isPlayerInRangeOfPoint(player,x,y,z,range) local px,py,pz=getElementPosition(player) return ((x-px)^2+(y-py)^2+(z-pz)^2)^0.5<=range end addCommandHandler getPlayerName getElementPosition ipairs getElementsByType("player") isPlayerInRangeOfPoint outputChatBox For Local Chat ~ Edited January 4, 2020 by Do_De<3 Link to comment
iiv03 Posted January 4, 2020 Share Posted January 4, 2020 10 hours ago, JoKerSyria said: local mycrpmpartner = {} function thePM(thePlayer,commandName,sendToName,...) local pmWords = { ... } local pmMessage = table.concat( pmWords, " " ) if sendToName then if getPlayerFromNamePart2(sendToName) then local toPlayer = getPlayerFromNamePart2(sendToName) if not (toPlayer == thePlayer) then --that () needed if not (pmMessage == "") then outputChatBox("#757575[PM] Message to #ff00ff" .. getPlayerName(toPlayer) .. ":#ffffff " .. pmMessage, thePlayer, 255, 255, 255, true) outputChatBox("#757575[PM] Message from #ff00ff" .. getPlayerName(thePlayer) .. ":#ffffff " .. pmMessage, toPlayer, 255, 255, 255, true) mycrpmpartner[thePlayer]=toPlayer mycrpmpartner[toPlayer]=thePlayer else outputChatBox("#757575[PM]Use:#ff9900 /pm [part of name] [message]", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM] You cannot PM yourself #ff9900!", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM] Player not found! #FFFF00[#ff9900"..sendToName.."#FFFF00]", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM]Use:#ff9900 /pm [part of name] [message]", thePlayer, 255, 255, 255, true) end end addCommandHandler("pm", thePM) function reply(thePlayer,commandName,...) local pmWords = { ... } local pmMessage = table.concat( pmWords, " " ) local toPlayer = mycrpmpartner[thePlayer] if toPlayer and isElement(toPlayer) then if not (pmMessage == "") then outputChatBox("#757575[PM] Message to #ff00ff" .. getPlayerName(toPlayer) .. ":#ffffff " .. pmMessage, thePlayer, 255, 255, 255, true) outputChatBox("#757575[PM] Message from #ff00ff" .. getPlayerName(thePlayer) .. ":#ffffff " .. pmMessage, toPlayer, 255, 255, 255, true) else outputChatBox("#757575[PM]Use:#ff9900 /repm [message]", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM]There is no pm partner", thePlayer, 255, 255, 255, true) end end addCommandHandler("repm", reply) function getPlayerFromNamePart2 ( name ) --MY EPIC PLAYER FIND PART :D if ( name ) then for _, player in ipairs ( getElementsByType ( "player" ) ) do local name_ = getPlayerName ( player ):gsub ( "#%x%x%x%x%x%x", "" ):lower ( ) if name_:find ( tostring ( name ):lower ( ), 1, true ) then return player end end end end addEventHandler ( "onPlayerQuit", getRootElement(), function() mycrpmpartner[source]=nil end) هاذا الكود شباب طبعن هذة الكود جنني بدي شباب يفتح بحرف يعني بدي فتح بحرف L هو شات خاص انا بدي يفتح بحرف L طبعن هو شات خاص PM: فاتمنة تلاقولي حل شباب يلي يعرف برمجة مضبوط جرب local mycrpmpartner = {} function thePM(thePlayer,commandName,sendToName,...) local pmWords = { ... } local pmMessage = table.concat( pmWords, " " ) if sendToName then if getPlayerFromNamePart2(sendToName) then local toPlayer = getPlayerFromNamePart2(sendToName) if not (toPlayer == thePlayer) then --that () needed if not (pmMessage == "") then outputChatBox("#757575[PM] Message to #ff00ff" .. getPlayerName(toPlayer) .. ":#ffffff " .. pmMessage, thePlayer, 255, 255, 255, true) outputChatBox("#757575[PM] Message from #ff00ff" .. getPlayerName(thePlayer) .. ":#ffffff " .. pmMessage, toPlayer, 255, 255, 255, true) mycrpmpartner[thePlayer]=toPlayer mycrpmpartner[toPlayer]=thePlayer else outputChatBox("#757575[PM]Use:#ff9900 /pm [part of name] [message]", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM] You cannot PM yourself #ff9900!", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM] Player not found! #FFFF00[#ff9900"..sendToName.."#FFFF00]", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM]Use:#ff9900 /pm [part of name] [message]", thePlayer, 255, 255, 255, true) end end addCommandHandler("pm", thePM) function reply(thePlayer,commandName,...) local pmWords = { ... } local pmMessage = table.concat( pmWords, " " ) local toPlayer = mycrpmpartner[thePlayer] if toPlayer and isElement(toPlayer) then if not (pmMessage == "") then outputChatBox("#757575[PM] Message to #ff00ff" .. getPlayerName(toPlayer) .. ":#ffffff " .. pmMessage, thePlayer, 255, 255, 255, true) outputChatBox("#757575[PM] Message from #ff00ff" .. getPlayerName(thePlayer) .. ":#ffffff " .. pmMessage, toPlayer, 255, 255, 255, true) else outputChatBox("#757575[PM]Use:#ff9900 /repm [message]", thePlayer, 255, 255, 255, true) end else outputChatBox("#757575[PM]There is no pm partner", thePlayer, 255, 255, 255, true) end end addCommandHandler("repm", reply) addEventHandler("onResourceStart", getResourceRootElement(getThisResource()), function() for i,player in pairs(getElementsByType("player")) do bindKey(player,"l","down","chatbox","pm") end for i,player in pairs(getElementsByType("player")) do bindKey(player,"i","down","chatbox","repm") end end) function getPlayerFromNamePart2 ( name ) --MY EPIC PLAYER FIND PART :D if ( name ) then for _, player in ipairs ( getElementsByType ( "player" ) ) do local name_ = getPlayerName ( player ):gsub ( "#%x%x%x%x%x%x", "" ):lower ( ) if name_:find ( tostring ( name ):lower ( ), 1, true ) then return player end end end end addEventHandler ( "onPlayerQuit", getRootElement(), function() mycrpmpartner[source]=nil end) Link to comment
Mr.Hugin Posted January 5, 2020 Author Share Posted January 5, 2020 تمام اخوي شكرأ والله يعطيك العافية كفوو ضبط 1 Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now