mahmod3 Posted March 2, 2017 Posted March 2, 2017 السلام عليكم شباب انا اريد اسوي لما اكتب رابط ب ميمو واضغط موافق يفتح القرأن او الموسيقى الي في الرابط لجميع اللاعبين واريده لسيريالات معينه
Ahmed Ly Posted March 2, 2017 Posted March 2, 2017 (edited) "onClientGUIClick" guiGetText triggerServerEvent playSound Edited March 2, 2017 by Ahmed Ly
mahmod3 Posted March 2, 2017 Author Posted March 2, 2017 23 hours ago, Ahmed Ly said: "onClientGUIClick" guiGetText playSound addEventHandler("onClientGUIClick",root, function () if source == btn then s = guiGetText(edit) playSound("s") end end ) ما اشتغل
Ahmed Ly Posted March 2, 2017 Posted March 2, 2017 addEventHandler("onClientGUIClick",root, function () if source == btn then s = guiGetText(edit) playSound(""..s..".mp3") end end )
mahmod3 Posted March 2, 2017 Author Posted March 2, 2017 23 hours ago, Ahmed Ly said: addEventHandler("onClientGUIClick",root, function () if source == btn then s = guiGetText(edit) playSound(""..s..".mp3") end end ) خدم لاكن توا لكل الموجودين ولا اني بس نبيه لكل الموجودين ب السيرفر
Ahmed Ly Posted March 2, 2017 Posted March 2, 2017 3 minutes ago, mahmod3 said: خدم لاكن توا لكل الموجودين ولا اني بس نبيه لكل الموجودين ب السيرفر ليك انت بس كود هدا يشغل أغاني لكل الاعبين -- Client addEventHandler("onClientGUIClick",root, function () if source == btn then s = guiGetText(edit) if s ~= "" then triggerServerEvent("play",localPlayer,s) end end end ) -- Server addEvent("play",true) addEventHandler("play",root, function (s) m = s triggerClientEvent("play2",root,m) end ) -- Client addEvent("play2",true) addEventHandler("play2",root, function (m) playSound(""..m..".mp3") end )
mahmod3 Posted March 2, 2017 Author Posted March 2, 2017 تمام به نبيه لما يفتح اغنية ويفتح الاغنية مرة تانيه نبيها تتعاود من البداية ولما يدير رابط تاني تنطفا الاولا وتولع التانيه
mahmod3 Posted March 2, 2017 Author Posted March 2, 2017 23 hours ago, Ahmed Ly said: استخدام isElement stopSound كيف is Element
Ahmed Ly Posted March 2, 2017 Posted March 2, 2017 2 minutes ago, mahmod3 said: كيف is Element https://wiki.multitheftauto.com/wiki/AR/isElement
mahmod3 Posted March 2, 2017 Author Posted March 2, 2017 23 hours ago, Ahmed Ly said: https://wiki.multitheftauto.com/wiki/AR/isElement كلنت addEvent("play2",true) addEventHandler("play2",root, function (m) stopSound(s) s = playSound(""..m..".mp3") end ) سيرفر addEvent("play",true) addEventHandler("play",root, function (s) m = s if isElement(s) then triggerClientEvent("play2",root,m) end )
Ahmed Ly Posted March 2, 2017 Posted March 2, 2017 (edited) -- Client addEventHandler("onClientGUIClick",root, function () if source == btn then s = guiGetText(edit) if s ~= "" then triggerServerEvent("play",localPlayer,s) end end end ) -- Server addEvent("play",true) addEventHandler("play",root, function (s) m = s triggerClientEvent("play2",root,m) end ) -- Client addEvent("play2",true) addEventHandler("play2",root, function (m) if isElement(m) then stopSound(m) end sound = playSound(""..m..".mp3") end ) Edited March 2, 2017 by Ahmed Ly remove sound
mahmod3 Posted March 2, 2017 Author Posted March 2, 2017 23 hours ago, Ahmed Ly said: -- Client addEventHandler("onClientGUIClick",root, function () if source == btn then s = guiGetText(edit) if s ~= "" then triggerServerEvent("play",localPlayer,s) end end end ) -- Server addEvent("play",true) addEventHandler("play",root, function (s) m = s triggerClientEvent("play2",root,m) end ) -- Client addEvent("play2",true) addEventHandler("play2",root, function (m) if isElement(m) then stopSound(m) end sound = playSound(""..m..".mp3") end ) به ولما نبي نسكر الاغنية على اللاعبين كلهم وخلاص معاش بنفتح اغنيه ؟
mahmod3 Posted March 2, 2017 Author Posted March 2, 2017 23 hours ago, Ahmed Ly said: stopSound غير اسمع كودك الاول مخدمش راه قاعده خلاص طلعت هكي addEvent("play2",true) addEventHandler("play2",root, function (m) if isElement(sound) then stopSound(sound) end sound = playSound(""..m..".mp3") end ) 1
Master_MTA Posted March 2, 2017 Posted March 2, 2017 اذا تبيه لكل الموجودين بطريقه سهله بس ما جربتها addEventHandler("onClientGUIClick",root, function () if source == btn then s = guiGetText(edit) for k,v in ipairs(getElementsByType('player'))do if v then playSound(""..s..".mp3") end end end end )
!#NssoR_) Posted March 2, 2017 Posted March 2, 2017 Just now, Master_MTA said: اذا تبيه لكل الموجودين بطريقه سهله بس ما جربتها addEventHandler("onClientGUIClick",root, function () if source == btn then s = guiGetText(edit) for k,v in ipairs(getElementsByType('player'))do if v then playSound(""..s..".mp3") end end end end ) لا اخوي , انت بكذا تكرر تشغيل الصوت علي عدد اللاعبين الموجودين بالسيرفر ومع ذلك محد بيسمع الصوت غيرك 1
Master_MTA Posted March 3, 2017 Posted March 3, 2017 19 hours ago, !#NssoR_) said: لا اخوي , انت بكذا تكرر تشغيل الصوت علي عدد اللاعبين الموجودين بالسيرفر ومع ذلك محد بيسمع الصوت غيرك اها انا فقط ما جربتها يعطيك العافيه على التنبيه +_+ 1
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