Jump to content

تصحيح كود


Recommended Posts

السلام عليكم ورحمة الله وبركاته

مساكم الله بالخير يالربع

ياشباب صححو لي كود

isPlay = false 
addEventHandler ("onClientGUIClick", root, 
    function() 
if ( isPlay == false and source == GUIEditor_Button[2] ) then 
sound = playSound("2.mp3") 
isPlay = true 
else 
stopSound(sound) 
isPlay = false 
        end 
    end 
) 

Link to comment
addEventHandler('onClientGUIClick',root, 
  function () 
   if(source==GUIEditor_Button[2]) 
     if(isElement(sound)then 
       stopSound(sound) 
else 
   sound = playSound('2.mp3') 
       end 
    end 
end) 

×××

addEventHandler ("onClientGUIClick", root, 
function () 
if source == GUIEditor_Button[2] then 
    if isElement(sound) then stopSound(sound) end 
        sound = playSound("2.mp3") 
        end 
    end 
) 

Edited by Guest
Link to comment
السلام عليكم ورحمة الله وبركاته

مساكم الله بالخير يالربع

ياشباب صححو لي كود

isPlay = false 
addEventHandler ("onClientGUIClick", root, 
    function() 
if ( isPlay == false and source == GUIEditor_Button[2] ) then 
sound = playSound("2.mp3") 
isPlay = true 
else 
stopSound(sound) 
isPlay = false 
        end 
    end 
) 

نصحح لك و حنا ما نعرف وش الي تبي تسويه؟

Link to comment
السلام عليكم ورحمة الله وبركاته

مساكم الله بالخير يالربع

ياشباب صححو لي كود

isPlay = false 
addEventHandler ("onClientGUIClick", root, 
    function() 
if ( isPlay == false and source == GUIEditor_Button[2] ) then 
sound = playSound("2.mp3") 
isPlay = true 
else 
stopSound(sound) 
isPlay = false 
        end 
    end 
) 

نصحح لك و حنا ما نعرف وش الي تبي تسويه؟

تابل هو يـبـي يوم يضـغط الزر يشغل صوت ويوم يضغطة ثانية يطفا الصوت ^_^

Link to comment
addEventHandler('onClientGUIClick',root, 
  function () 
   if(source==GUIEditor_Button[2]) 
     if(isElement(sound)then 
       stopSound(sound) 
else 
   sound = playSound('2.mp3') 
       end 
    end 
end) 

×××

addEventHandler ("onClientGUIClick", root, 
function () 
if source == GUIEditor_Button[2] then 
    if isElement(sound) then stopSound(sound) end 
        sound = playSound("2.mp3") 
        end 
    end 
) 

GUIEditor_Window = {} 
GUIEditor_Button = {} 
  
GUIEditor_Window[1] = guiCreateWindow(242,105,350,310,"",false) 
GUIEditor_Button[1] = guiCreateButton(0.3,0.3968,0.3486,0.2097,"",true,GUIEditor_Window[1]) 
  
addEventHandler ("onClientGUIClick", root, 
function () 
if source == GUIEditor_Button[1] then 
    if isElement(sound) then stopSound(sound) end 
        sound = playSound("2.mp3") 
        end 
    end 
) 

Link to comment
addEventHandler('onClientGUIClick',root, 
  function () 
   if(source==GUIEditor_Button[2]) 
     if(isElement(sound)then 
       stopSound(sound) 
else 
   sound = playSound('2.mp3') 
       end 
    end 
end) 

×××

addEventHandler ("onClientGUIClick", root, 
function () 
if source == GUIEditor_Button[2] then 
    if isElement(sound) then stopSound(sound) end 
        sound = playSound("2.mp3") 
        end 
    end 
) 

GUIEditor_Window = {} 
GUIEditor_Button = {} 
  
GUIEditor_Window[1] = guiCreateWindow(242,105,350,310,"",false) 
GUIEditor_Button[1] = guiCreateButton(0.3,0.3968,0.3486,0.2097,"",true,GUIEditor_Window[1]) 
  
addEventHandler ("onClientGUIClick", root, 
function () 
if source == GUIEditor_Button[1] then 
    if isElement(sound) then stopSound(sound) end 
        sound = playSound("2.mp3") 
        end 
    end 
) 

هاذا يعيد مايووقف

انا ابي اذا ضغطت يوقف

Link to comment
هاذا يعيد مايووقف

انا ابي اذا ضغطت يوقف

addEventHandler ("onClientGUIClick", root, 
function () 
    if source == GUIEditor_Button[1] then 
        if isElement(sound) then 
            stopSound(sound) 
        else 
            sound = playSound("2.mp3") 
        end 
    end 
end) 

Link to comment
هاذا يعيد مايووقف

انا ابي اذا ضغطت يوقف

addEventHandler ("onClientGUIClick", root, 
function () 
    if source == GUIEditor_Button[1] then 
        if isElement(sound) then 
            stopSound(sound) 
        else 
            sound = playSound("2.mp3") 
        end 
    end 
end) 

بيض الله وجهك

سلمت يالذيب

Link to comment

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...