Jump to content

=[ مساعدة خطأ بسيط ]= New


Mr.R

Recommended Posts

مشكورين كل من علق

لبى قلوبكم :$

افدتوني وتعلمت من اخطأي , شكر خاص ابو شنب وكنق و shweaki

ظبط كل شيء اشكركم

+ تمت الافاده ^_^

آلشكر لله

:D ولبى قلبك آنت بعد

انشآء الله نشوفك من كبآر آلمبرمجين عن قريب

Link to comment
حياكـ الله # :wink:

ابو شنب :mrgreen:

فيه خطا لما اضغط زر انتقال يقول تم الانتقال وماينقلني

الخطا في setElementPosition :lol:

في سطر 69 ><

صلحلي الكود لاهنت <3

وحطلي اضافه حلوه من عندك :$

الازرار واسم النافذه تتلون عدة الوان ورى بعض واذا ضغط زر انتقال بدون مايحدد على الرو يطلع له في الشات

Please Select Place

انتظرك <3

Link to comment
مشكورين كل من علق

لبى قلوبكم :$

افدتوني وتعلمت من اخطأي , شكر خاص ابو شنب وكنق و shweaki

ظبط كل شيء اشكركم

+ تمت الافاده ^_^

آلشكر لله

:D ولبى قلبك آنت بعد

انشآء الله نشوفك من كبآر آلمبرمجين عن قريب

بأذن الله :$

Link to comment
حياكـ الله # :wink:

ابو شنب :mrgreen:

فيه خطا لما اضغط زر انتقال يقول تم الانتقال وماينقلني

الخطا في setElementPosition :lol:

في سطر 69 ><

صلحلي الكود لاهنت <3

وحطلي اضافه حلوه من عندك :$

الازرار واسم النافذه تتلون عدة الوان ورى بعض واذا ضغط زر انتقال بدون مايحدد على الرو يطلع له في الشات

Please Select Place

انتظرك <3

جربها الان , م اضفت لك التلوين حاول تسويه بنفسك واساعدك :P

Link to comment

كل شيء تمام

مشكور والله :$

وسويت كود الاوان ذا بس جربته بتايمر وبدون تايمر

اذا حطيت التايمر , يختفي الكلام الي ع الزر واذا اشرت عليه بمؤشر الماوس يطلع

واذا شلت التايمر اللون ابيض مثل ماهو , مادري وش المشكله

وهذا الكود الي طلع معي شوف مشكلة الالوان لاهنت :$

--[[------------------------------------------------- 
Created By Mr.R 
Skype : Httttt7_Ksa 
--]]------------------------------------------------- 
  
GUIEditor = { label = {}, staticimage = {} } 
WarpTaple = { -- تيبل للانتقالات 
    { "الدائــــــــــري -1", "d.png", 1815.40515, 870.14069, 10.53743 }, 
    { "النــــخــــيــــل -2", "n.png", 2077.17993, 868.93744, 6.86413  }, 
    { "الــــــغــــــروب -3", "g.png", 674.92969, 1931.07874, 5.53906  }, 
} 
  
addEventHandler("onClientResourceStart", resourceRoot, 
    function (  ) 
        outputChatBox ( "=[ Panel Places By Mr.R ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        outputChatBox ( "=[ Press 'F3' To Open It ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        wnd = guiCreateWindow(181, 109, 426, 360, "=[ Panel Places v1.0 By Mr.R ]=", false) 
        guiSetVisible (wnd, false ) 
        guiWindowSetSizable(wnd, false) 
  
        GridList = guiCreateGridList(9, 22, 202, 328, false, wnd) 
        guiGridListAddColumn(GridList, "Places ...", 0.9) 
        for _,v in ipairs ( WarpTaple ) do 
            local row = guiGridListAddRow ( GridList ) 
            guiGridListSetItemText ( GridList, row, 1, v[1], false, false ) 
            guiGridListSetItemData ( GridList, row, 1, { v[3], v[4], v[5] } ) 
        end 
        Button1 = guiCreateButton(250, 247, 134, 39, "=[ Warp ]=", false, wnd) 
        guiSetProperty(Button1, "NormalTextColour", "FFAAAAAA") 
        Button2 = guiCreateButton(250, 296, 134, 39, "=[ X ]=", false, wnd) 
        setElementData(Button1, "tooltip-text", "انتقال", false) 
        setElementData(Button2, "tooltip-text", "اغلاق", false) 
        guiSetProperty(Button2, "NormalTextColour", "FFAAAAAA") 
        GUIEditor.staticimage[1] = guiCreateStaticImage(221, 28, 178, 155, "MTA.png", false, wnd) 
        GUIEditor.label[1] = guiCreateLabel(264, 188, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[1], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[1], 245, 7, 46) 
        GUIEditor.label[2] = guiCreateLabel(343, 209, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[2], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[2], 191, 25, 226) 
    end 
) 
  
bindKey ( "F3", "down", function (   )-- وظيفة قفل+فتح النافذه 
      guiSetVisible ( wnd, not guiGetVisible ( wnd ) ) 
      showCursor ( guiGetVisible ( wnd ) ) 
end ) 
  
addEventHandler("onClientGUIClick", resourceRoot, 
    function (   ) 
        if ( source == GridList ) then 
            if ( guiGridListGetSelectedItem ( source ) ~= -1 ) then 
                local fName = guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) 
                for _,v in ipairs ( WarpTaple ) do 
                    if ( v[1] == fName ) then 
                        if ( v[2] ~= "" or v[2] ~= " " ) then 
                            guiStaticImageLoadImage ( GUIEditor.staticimage[1], tostring ( v[2] ) ) 
                        end 
                    end 
                end 
            else 
                guiStaticImageLoadImage ( GUIEditor.staticimage[1], "MTA.png" ) 
            end 
        elseif ( source == Button1 ) then 
            if ( guiGridListGetSelectedItem ( GridList ) ~= -1 ) then   
                if ( isTimer ( Timer ) ) then 
                    return 
                end 
                Timer = setTimer ( function (  ) end, 4000, 1 ) 
                setElementPosition ( localPlayer, unpack ( guiGridListGetItemData ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) ) ) 
                outputChatBox ( " تــم الإنــتقــال إلــى".. guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) .."", 255, 255, 0, true ) 
            else 
                outputChatBox ( "الرجــاء اخـتـيـار مـكـاناً للإنـتقـال إلـيه !", 255, 0, 0, true ) 
            end 
        elseif ( source == Button2 ) then 
            guiSetVisible ( wnd, false ) 
            showCursor ( false ) 
        end 
    end 
) 
  
    function lon() 
        guiSetProperty(wnd, "CaptionColour", math.random(255), math.random(255), math.random(255)) 
        guiSetProperty(Button1, "NormalTextColour", math.random(255), math.random(255), math.random(255)) 
        guiSetProperty(Button2, "NormalTextColour", math.random(255), math.random(255), math.random(255)) 
    end 

وودي اذا ضغطت انتقال , يطلع تم الانتقال الى المكان الفلاني بدون مايجيب اسمه من التيبل

ومشكور لبى قلبك :mrgreen:

Link to comment

--[[------------------------------------------------- 
Created By Mr.R 
Skype : Httttt7_Ksa 
--]]------------------------------------------------- 
  
GUIEditor = { label = {}, staticimage = {} } 
WarpTaple = { -- تيبل للانتقالات 
    { "الدائــــــــــري -1", "d.png", 1815.40515, 870.14069, 10.53743 }, 
    { "النــــخــــيــــل -2", "n.png", 2077.17993, 868.93744, 6.86413  }, 
    { "الــــــغــــــروب -3", "g.png", 674.92969, 1931.07874, 5.53906  }, 
} 
  
addEventHandler( "onClientResourceStart", resourceRoot, function (  ) 
        outputChatBox ( "=[ Panel Places By Mr.R ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        outputChatBox ( "=[ Press 'F3' To Open It ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        wnd = guiCreateWindow(181, 109, 426, 360, "=[ Panel Places v1.0 By Mr.R ]=", false) 
        guiSetVisible (wnd, false ) 
        guiWindowSetSizable(wnd, false) 
        GridList = guiCreateGridList(9, 22, 202, 328, false, wnd) 
        guiGridListAddColumn(GridList, "Places ...", 0.9) 
        for _,v in ipairs ( WarpTaple ) do 
            local row = guiGridListAddRow ( GridList ) 
            guiGridListSetItemText ( GridList, row, 1, v[1], false, false ) 
            guiGridListSetItemData ( GridList, row, 1, { v[3], v[4], v[5] } ) 
        end 
        Button1 = guiCreateButton(250, 247, 134, 39, "=[ Warp ]=", false, wnd) 
        guiSetProperty(Button1, "NormalTextColour", "FFAAAAAA") 
        Button2 = guiCreateButton(250, 296, 134, 39, "=[ X ]=", false, wnd) 
        setElementData(Button1, "tooltip-text", "انتقال", false) 
        setElementData(Button2, "tooltip-text", "اغلاق", false) 
        guiSetProperty(Button2, "NormalTextColour", "FFAAAAAA") 
        GUIEditor.staticimage[1] = guiCreateStaticImage(221, 28, 178, 155, "MTA.png", false, wnd) 
        GUIEditor.label[1] = guiCreateLabel(264, 188, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[1], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[1], 245, 7, 46) 
        GUIEditor.label[2] = guiCreateLabel(343, 209, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[2], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[2], 191, 25, 226) 
        lon (    ) 
end ) 
  
bindKey ( "F3", "down", function (   )-- وظيفة قفل+فتح النافذه 
      guiSetVisible ( wnd, not guiGetVisible ( wnd ) ) 
      showCursor ( guiGetVisible ( wnd ) ) 
end ) 
  
addEventHandler("onClientGUIClick", resourceRoot, 
    function (   ) 
        if ( source == GridList ) then 
            if ( guiGridListGetSelectedItem ( source ) ~= -1 ) then 
                local fName = guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) 
                for _,v in ipairs ( WarpTaple ) do 
                    if ( v[1] == fName ) then 
                        if ( v[2] ~= "" or v[2] ~= " " ) then 
                            guiStaticImageLoadImage ( GUIEditor.staticimage[1], tostring ( v[2] ) ) 
                        end 
                    end 
                end 
            else 
                guiStaticImageLoadImage ( GUIEditor.staticimage[1], "MTA.png" ) 
            end 
        elseif ( source == Button1 ) then 
            if ( guiGridListGetSelectedItem ( GridList ) ~= -1 ) then   
                if ( isTimer ( Timer ) ) then 
                    return 
                end 
                Timer = setTimer ( function (  ) end, 4000, 1 ) 
                setElementPosition ( localPlayer, unpack ( guiGridListGetItemData ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) ) ) 
                outputChatBox ( " تــم الإنــتقــال إلــى".. string.sub( guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ), 3 ) .."", 255, 255, 0, true ) 
            else 
                outputChatBox ( "الرجــاء اخـتـيـار مـكـاناً للإنـتقـال إلـيه !", 255, 0, 0, true ) 
            end 
        elseif ( source == Button2 ) then 
            guiSetVisible ( wnd, false ) 
            showCursor ( false ) 
        end 
    end 
) 
  
function lon (    ) 
   guiSetProperty(wnd, "CaptionColour", math.random(255), math.random(255), math.random(255)) 
   guiSetProperty(Button1, "NormalTextColour", math.random(255), math.random(255), math.random(255)) 
   guiSetProperty(Button2, "NormalTextColour", math.random(255), math.random(255), math.random(255)) 
end 
Link to comment
--[[------------------------------------------------- 
Created By Mr.R 
Skype : Httttt7_Ksa 
--]]------------------------------------------------- 
  
GUIEditor = { label = {}, staticimage = {} } 
WarpTaple = { -- تيبل للانتقالات 
    { "الدائــــــــــري -1", "d.png", 1815.40515, 870.14069, 10.53743 }, 
    { "النــــخــــيــــل -2", "n.png", 2077.17993, 868.93744, 6.86413  }, 
    { "الــــــغــــــروب -3", "g.png", 674.92969, 1931.07874, 5.53906  }, 
} 
  
addEventHandler( "onClientResourceStart", resourceRoot, function (  ) 
        outputChatBox ( "=[ Panel Places By Mr.R ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        outputChatBox ( "=[ Press 'F3' To Open It ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        wnd = guiCreateWindow(181, 109, 426, 360, "=[ Panel Places v1.0 By Mr.R ]=", false) 
        guiSetVisible (wnd, false ) 
        guiWindowSetSizable(wnd, false) 
        GridList = guiCreateGridList(9, 22, 202, 328, false, wnd) 
        guiGridListAddColumn(GridList, "Places ...", 0.9) 
        for _,v in ipairs ( WarpTaple ) do 
            local row = guiGridListAddRow ( GridList ) 
            guiGridListSetItemText ( GridList, row, 1, v[1], false, false ) 
            guiGridListSetItemData ( GridList, row, 1, { v[3], v[4], v[5] } ) 
        end 
        Button1 = guiCreateButton(250, 247, 134, 39, "=[ Warp ]=", false, wnd) 
        guiSetProperty(Button1, "NormalTextColour", "FFAAAAAA") 
        Button2 = guiCreateButton(250, 296, 134, 39, "=[ X ]=", false, wnd) 
        setElementData(Button1, "tooltip-text", "انتقال", false) 
        setElementData(Button2, "tooltip-text", "اغلاق", false) 
        guiSetProperty(Button2, "NormalTextColour", "FFAAAAAA") 
        GUIEditor.staticimage[1] = guiCreateStaticImage(221, 28, 178, 155, "MTA.png", false, wnd) 
        GUIEditor.label[1] = guiCreateLabel(264, 188, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[1], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[1], 245, 7, 46) 
        GUIEditor.label[2] = guiCreateLabel(343, 209, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[2], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[2], 191, 25, 226) 
        lon (    ) 
end ) 
  
bindKey ( "F3", "down", function (   )-- وظيفة قفل+فتح النافذه 
      guiSetVisible ( wnd, not guiGetVisible ( wnd ) ) 
      showCursor ( guiGetVisible ( wnd ) ) 
end ) 
  
addEventHandler("onClientGUIClick", resourceRoot, 
    function (   ) 
        if ( source == GridList ) then 
            if ( guiGridListGetSelectedItem ( source ) ~= -1 ) then 
                local fName = guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) 
                for _,v in ipairs ( WarpTaple ) do 
                    if ( v[1] == fName ) then 
                        if ( v[2] ~= "" or v[2] ~= " " ) then 
                            guiStaticImageLoadImage ( GUIEditor.staticimage[1], tostring ( v[2] ) ) 
                        end 
                    end 
                end 
            else 
                guiStaticImageLoadImage ( GUIEditor.staticimage[1], "MTA.png" ) 
            end 
        elseif ( source == Button1 ) then 
            if ( guiGridListGetSelectedItem ( GridList ) ~= -1 ) then   
                if ( isTimer ( Timer ) ) then 
                    return 
                end 
                Timer = setTimer ( function (  ) end, 4000, 1 ) 
                setElementPosition ( localPlayer, unpack ( guiGridListGetItemData ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) ) ) 
                outputChatBox ( " تــم الإنــتقــال إلــى".. string.sub( guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ), 3 ) .."", 255, 255, 0, true ) 
            else 
                outputChatBox ( "الرجــاء اخـتـيـار مـكـاناً للإنـتقـال إلـيه !", 255, 0, 0, true ) 
            end 
        elseif ( source == Button2 ) then 
            guiSetVisible ( wnd, false ) 
            showCursor ( false ) 
        end 
    end 
) 
  
function lon (    ) 
   guiSetProperty(wnd, "CaptionColour", math.random(255), math.random(255), math.random(255)) 
   guiSetProperty(Button1, "NormalTextColour", math.random(255), math.random(255), math.random(255)) 
   guiSetProperty(Button2, "NormalTextColour", math.random(255), math.random(255), math.random(255)) 
end 

مثل المشكله !!

الكلام الي على الازرار مختفي مايطلع الا اذا حطيت مؤشر الماوس عليه !

صلحها لي لاهنت :$

وابي خدمه بسيطه جدأ وهي مخرج نص اذا ركب سياره وسوى انتقال مثلا الغروب

يقول له ماتقدر لانك داخل سياره انا اعرف اسوي كودها بس مادري وين احطه بالضبط

انتظرك <3

Link to comment

RGB اها توني انتبه .. بالفنكشن حق اللون مستخدم 3 ارقمنات وهو ارقمنت اللون واحد وارقمنت اللون ليس

لاكن اللي بصناعة النافذة صحيح .. لاكن وش تقصد انت ؟ تقصد تبيه زي الفلأش ؟

--[[------------------------------------------------- 
Created By Mr.R 
Skype : Httttt7_Ksa 
--]]------------------------------------------------- 
  
GUIEditor = { label = {}, staticimage = {} } 
WarpTaple = { -- تيبل للانتقالات 
    { "الدائــــــــــري -1", "d.png", 1815.40515, 870.14069, 10.53743 }, 
    { "النــــخــــيــــل -2", "n.png", 2077.17993, 868.93744, 6.86413  }, 
    { "الــــــغــــــروب -3", "g.png", 674.92969, 1931.07874, 5.53906  }, 
} 
  
addEventHandler( "onClientResourceStart", resourceRoot, function (  ) 
        outputChatBox ( "=[ Panel Places By Mr.R ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        outputChatBox ( "=[ Press 'F3' To Open It ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        wnd = guiCreateWindow(181, 109, 426, 360, "=[ Panel Places v1.0 By Mr.R ]=", false) 
        guiSetVisible (wnd, false ) 
        guiWindowSetSizable(wnd, false) 
        GridList = guiCreateGridList(9, 22, 202, 328, false, wnd) 
        guiGridListAddColumn(GridList, "Places ...", 0.9) 
        for _,v in ipairs ( WarpTaple ) do 
            local row = guiGridListAddRow ( GridList ) 
            guiGridListSetItemText ( GridList, row, 1, v[1], false, false ) 
            guiGridListSetItemData ( GridList, row, 1, { v[3], v[4], v[5] } ) 
        end 
        Button1 = guiCreateButton(250, 247, 134, 39, "=[ Warp ]=", false, wnd) 
        Button2 = guiCreateButton(250, 296, 134, 39, "=[ X ]=", false, wnd) 
        setElementData(Button1, "tooltip-text", "انتقال", false) 
        setElementData(Button2, "tooltip-text", "اغلاق", false) 
        guiSetProperty(Button1, "NormalTextColour", "FFAAAAAA") 
        guiSetProperty(Button2, "NormalTextColour", "FFAAAAAA") 
        GUIEditor.staticimage[1] = guiCreateStaticImage(221, 28, 178, 155, "MTA.png", false, wnd) 
        GUIEditor.label[1] = guiCreateLabel(264, 188, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[1], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[1], 245, 7, 46) 
        GUIEditor.label[2] = guiCreateLabel(343, 209, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[2], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[2], 191, 25, 226) 
end ) 
  
bindKey ( "F3", "down", function (   )-- وظيفة قفل+فتح النافذه 
      guiSetVisible ( wnd, not guiGetVisible ( wnd ) ) 
      showCursor ( guiGetVisible ( wnd ) ) 
end ) 
  
addEventHandler("onClientGUIClick", resourceRoot, 
    function (   ) 
        if ( source == GridList ) then 
            if ( guiGridListGetSelectedItem ( source ) ~= -1 ) then 
                local fName = guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) 
                for _,v in ipairs ( WarpTaple ) do 
                    if ( v[1] == fName ) then 
                        if ( v[2] ~= "" or v[2] ~= " " ) then 
                            guiStaticImageLoadImage ( GUIEditor.staticimage[1], tostring ( v[2] ) ) 
                        end 
                    end 
                end 
            else 
                guiStaticImageLoadImage ( GUIEditor.staticimage[1], "MTA.png" ) 
            end 
        elseif ( source == Button1 ) then 
            if ( guiGridListGetSelectedItem ( GridList ) ~= -1 ) then   
                if ( isTimer ( Timer ) ) then 
                    return 
                end 
                if ( getPedOccupiedVehicle ( localPlayer ) ) then 
                    return outputChatBox ( "الرجاء النزول من السيارة اولأ *", 255, 0, 0, true ) 
                end   
                Timer = setTimer ( function (  ) end, 4000, 1 ) 
                setElementPosition ( localPlayer, unpack ( guiGridListGetItemData ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) ) ) 
                outputChatBox ( " تــم الإنــتقــال إلــى".. string.sub( guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ), 3 ) .."", 255, 255, 0, true ) 
            else 
                outputChatBox ( "الرجــاء اخـتـيـار مـكـاناً للإنـتقـال إلـيه !", 255, 0, 0, true ) 
            end 
        elseif ( source == Button2 ) then 
            guiSetVisible ( wnd, false ) 
            showCursor ( false ) 
        end 
end ) 
Link to comment
RGB اها توني انتبه .. بالفنكشن حق اللون مستخدم 3 ارقمنات وهو ارقمنت اللون واحد وارقمنت اللون ليس

لاكن اللي بصناعة النافذة صحيح .. لاكن وش تقصد انت ؟ تقصد تبيه زي الفلأش ؟

--[[------------------------------------------------- 
Created By Mr.R 
Skype : Httttt7_Ksa 
--]]------------------------------------------------- 
  
GUIEditor = { label = {}, staticimage = {} } 
WarpTaple = { -- تيبل للانتقالات 
    { "الدائــــــــــري -1", "d.png", 1815.40515, 870.14069, 10.53743 }, 
    { "النــــخــــيــــل -2", "n.png", 2077.17993, 868.93744, 6.86413  }, 
    { "الــــــغــــــروب -3", "g.png", 674.92969, 1931.07874, 5.53906  }, 
} 
  
addEventHandler( "onClientResourceStart", resourceRoot, function (  ) 
        outputChatBox ( "=[ Panel Places By Mr.R ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        outputChatBox ( "=[ Press 'F3' To Open It ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        wnd = guiCreateWindow(181, 109, 426, 360, "=[ Panel Places v1.0 By Mr.R ]=", false) 
        guiSetVisible (wnd, false ) 
        guiWindowSetSizable(wnd, false) 
        GridList = guiCreateGridList(9, 22, 202, 328, false, wnd) 
        guiGridListAddColumn(GridList, "Places ...", 0.9) 
        for _,v in ipairs ( WarpTaple ) do 
            local row = guiGridListAddRow ( GridList ) 
            guiGridListSetItemText ( GridList, row, 1, v[1], false, false ) 
            guiGridListSetItemData ( GridList, row, 1, { v[3], v[4], v[5] } ) 
        end 
        Button1 = guiCreateButton(250, 247, 134, 39, "=[ Warp ]=", false, wnd) 
        Button2 = guiCreateButton(250, 296, 134, 39, "=[ X ]=", false, wnd) 
        setElementData(Button1, "tooltip-text", "انتقال", false) 
        setElementData(Button2, "tooltip-text", "اغلاق", false) 
        guiSetProperty(Button1, "NormalTextColour", "FFAAAAAA") 
        guiSetProperty(Button2, "NormalTextColour", "FFAAAAAA") 
        GUIEditor.staticimage[1] = guiCreateStaticImage(221, 28, 178, 155, "MTA.png", false, wnd) 
        GUIEditor.label[1] = guiCreateLabel(264, 188, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[1], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[1], 245, 7, 46) 
        GUIEditor.label[2] = guiCreateLabel(343, 209, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[2], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[2], 191, 25, 226) 
end ) 
  
bindKey ( "F3", "down", function (   )-- وظيفة قفل+فتح النافذه 
      guiSetVisible ( wnd, not guiGetVisible ( wnd ) ) 
      showCursor ( guiGetVisible ( wnd ) ) 
end ) 
  
addEventHandler("onClientGUIClick", resourceRoot, 
    function (   ) 
        if ( source == GridList ) then 
            if ( guiGridListGetSelectedItem ( source ) ~= -1 ) then 
                local fName = guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) 
                for _,v in ipairs ( WarpTaple ) do 
                    if ( v[1] == fName ) then 
                        if ( v[2] ~= "" or v[2] ~= " " ) then 
                            guiStaticImageLoadImage ( GUIEditor.staticimage[1], tostring ( v[2] ) ) 
                        end 
                    end 
                end 
            else 
                guiStaticImageLoadImage ( GUIEditor.staticimage[1], "MTA.png" ) 
            end 
        elseif ( source == Button1 ) then 
            if ( guiGridListGetSelectedItem ( GridList ) ~= -1 ) then   
                if ( isTimer ( Timer ) ) then 
                    return 
                end 
                if ( getPedOccupiedVehicle ( localPlayer ) ) then 
                    return outputChatBox ( "الرجاء النزول من السيارة اولأ *", 255, 0, 0, true ) 
                end   
                Timer = setTimer ( function (  ) end, 4000, 1 ) 
                setElementPosition ( localPlayer, unpack ( guiGridListGetItemData ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) ) ) 
                outputChatBox ( " تــم الإنــتقــال إلــى".. string.sub( guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ), 3 ) .."", 255, 255, 0, true ) 
            else 
                outputChatBox ( "الرجــاء اخـتـيـار مـكـاناً للإنـتقـال إلـيه !", 255, 0, 0, true ) 
            end 
        elseif ( source == Button2 ) then 
            guiSetVisible ( wnd, false ) 
            showCursor ( false ) 
        end 
end ) 

انا ابي اسم النافذه والازرار تتلون ورى بعض مثلآ ,

احمر اخضر ازرق في 3 ثواني

يعني يتلون الزر عدة الوان

والاشياء الي ابغيها , الي انا سويتها وماظبطت واهم شيء اني حاولت

ان اخلي الازرار تتلون عدة الوان ورى بعض

واذا اخترت مكان وانتقلت له يقول : تم الانتقال الى المكان الفلاني بدون مايجيب الاسم من التيبل

يعني انا اكتب بنفسي تم الانتقال الى المكان الفلاني بدون مايجيب اسمه المود تلقائي

ومشكور يالذيب ذي الناقصه :$

Link to comment

--[[------------------------------------------------- 
Created By Mr.R 
Skype : Httttt7_Ksa 
--]]------------------------------------------------- 
  
GUIEditor = { label = {}, staticimage = {} } 
WarpTaple = { -- تيبل للانتقالات 
    { "الدائــــــــــري -1", "d.png", 1815.40515, 870.14069, 10.53743 }, 
    { "النــــخــــيــــل -2", "n.png", 2077.17993, 868.93744, 6.86413  }, 
    { "الــــــغــــــروب -3", "g.png", 674.92969, 1931.07874, 5.53906  }, 
} 
  
addEventHandler( "onClientResourceStart", resourceRoot, function (  ) 
        outputChatBox ( "=[ Panel Places By Mr.R ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        outputChatBox ( "=[ Press 'F3' To Open It ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        wnd = guiCreateWindow(181, 109, 426, 360, "=[ Panel Places v1.0 By Mr.R ]=", false) 
        guiSetVisible (wnd, false ) 
        guiWindowSetSizable(wnd, false) 
        GridList = guiCreateGridList(9, 22, 202, 328, false, wnd) 
        guiGridListAddColumn(GridList, "Places ...", 0.9) 
        for _,v in ipairs ( WarpTaple ) do 
            local row = guiGridListAddRow ( GridList ) 
            guiGridListSetItemText ( GridList, row, 1, v[1], false, false ) 
            guiGridListSetItemData ( GridList, row, 1, { v[3], v[4], v[5] } ) 
        end 
        Button1 = guiCreateButton(250, 247, 134, 39, "=[ Warp ]=", false, wnd) 
        Button2 = guiCreateButton(250, 296, 134, 39, "=[ X ]=", false, wnd) 
        setElementData(Button1, "tooltip-text", "انتقال", false) 
        setElementData(Button2, "tooltip-text", "اغلاق", false) 
        GUIEditor.staticimage[1] = guiCreateStaticImage(221, 28, 178, 155, "MTA.png", false, wnd) 
        GUIEditor.label[1] = guiCreateLabel(264, 188, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[1], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[1], 245, 7, 46) 
        GUIEditor.label[2] = guiCreateLabel(343, 209, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[2], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[2], 191, 25, 226) 
end ) 
  
bindKey ( "F3", "down", function (   )-- وظيفة قفل+فتح النافذه 
     if ( isTimer ( timerColor ) ) then killTimer ( timerColor ) end 
     timerColor = setTimer ( function (   ) 
       local RandomColor = string.format( "%.2X%.2X%.2X%.2X", 255, math.random( 255 ), math.random( 255 ), math.random( 255 ) ) 
       guiSetProperty ( Button1, "NormalTextColour", RandomColor ) 
       guiSetProperty ( Button2, "NormalTextColour", RandomColor ) 
       guiSetProperty ( wnd, "CaptionColour", RandomColor ) 
      end, 300, 0 ) 
      guiSetVisible ( wnd, not guiGetVisible ( wnd ) ) 
      showCursor ( guiGetVisible ( wnd ) ) 
end ) 
  
addEventHandler("onClientGUIClick", resourceRoot, 
    function (   ) 
        if ( source == GridList ) then 
            if ( guiGridListGetSelectedItem ( source ) ~= -1 ) then 
                local fName = guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) 
                for _,v in ipairs ( WarpTaple ) do 
                    if ( v[1] == fName ) then 
                        if ( v[2] ~= "" or v[2] ~= " " ) then 
                            guiStaticImageLoadImage ( GUIEditor.staticimage[1], tostring ( v[2] ) ) 
                        end 
                    end 
                end 
            else 
                guiStaticImageLoadImage ( GUIEditor.staticimage[1], "MTA.png" ) 
            end 
        elseif ( source == Button1 ) then 
            if ( guiGridListGetSelectedItem ( GridList ) ~= -1 ) then   
                if ( isTimer ( Timer ) ) then 
                    return 
                end 
                if ( getPedOccupiedVehicle ( localPlayer ) ) then 
                    return outputChatBox ( "الرجاء النزول من السيارة اولأ *", 255, 0, 0, true ) 
                end   
                Timer = setTimer ( function (  ) end, 4000, 1 ) 
                setElementPosition ( localPlayer, unpack ( guiGridListGetItemData ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) ) ) 
                outputChatBox ( " تــم الإنــتقــال إلــى".. string.sub( guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ), 3 ) .."", 255, 255, 0, true ) 
            else 
                outputChatBox ( "الرجــاء اخـتـيـار مـكـاناً للإنـتقـال إلـيه !", 255, 0, 0, true ) 
            end 
        elseif ( source == Button2 ) then 
            guiSetVisible ( wnd, false ) 
            showCursor ( false ) 
        end 
end ) 
Link to comment
--[[------------------------------------------------- 
Created By Mr.R 
Skype : Httttt7_Ksa 
--]]------------------------------------------------- 
  
GUIEditor = { label = {}, staticimage = {} } 
WarpTaple = { -- تيبل للانتقالات 
    { "الدائــــــــــري -1", "d.png", 1815.40515, 870.14069, 10.53743 }, 
    { "النــــخــــيــــل -2", "n.png", 2077.17993, 868.93744, 6.86413  }, 
    { "الــــــغــــــروب -3", "g.png", 674.92969, 1931.07874, 5.53906  }, 
} 
  
addEventHandler( "onClientResourceStart", resourceRoot, function (  ) 
        outputChatBox ( "=[ Panel Places By Mr.R ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        outputChatBox ( "=[ Press 'F3' To Open It ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        wnd = guiCreateWindow(181, 109, 426, 360, "=[ Panel Places v1.0 By Mr.R ]=", false) 
        guiSetVisible (wnd, false ) 
        guiWindowSetSizable(wnd, false) 
        GridList = guiCreateGridList(9, 22, 202, 328, false, wnd) 
        guiGridListAddColumn(GridList, "Places ...", 0.9) 
        for _,v in ipairs ( WarpTaple ) do 
            local row = guiGridListAddRow ( GridList ) 
            guiGridListSetItemText ( GridList, row, 1, v[1], false, false ) 
            guiGridListSetItemData ( GridList, row, 1, { v[3], v[4], v[5] } ) 
        end 
        Button1 = guiCreateButton(250, 247, 134, 39, "=[ Warp ]=", false, wnd) 
        Button2 = guiCreateButton(250, 296, 134, 39, "=[ X ]=", false, wnd) 
        setElementData(Button1, "tooltip-text", "انتقال", false) 
        setElementData(Button2, "tooltip-text", "اغلاق", false) 
        GUIEditor.staticimage[1] = guiCreateStaticImage(221, 28, 178, 155, "MTA.png", false, wnd) 
        GUIEditor.label[1] = guiCreateLabel(264, 188, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[1], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[1], 245, 7, 46) 
        GUIEditor.label[2] = guiCreateLabel(343, 209, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[2], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[2], 191, 25, 226) 
end ) 
  
bindKey ( "F3", "down", function (   )-- وظيفة قفل+فتح النافذه 
     if ( isTimer ( timerColor ) ) then killTimer ( timerColor ) end 
     timerColor = setTimer ( function (   ) 
       local RandomColor = string.format( "%.2X%.2X%.2X%.2X", 255, math.random( 255 ), math.random( 255 ), math.random( 255 ) ) 
       guiSetProperty ( Button1, "NormalTextColour", RandomColor ) 
       guiSetProperty ( Button2, "NormalTextColour", RandomColor ) 
       guiSetProperty ( wnd, "CaptionColour", RandomColor ) 
      end, 300, 0 ) 
      guiSetVisible ( wnd, not guiGetVisible ( wnd ) ) 
      showCursor ( guiGetVisible ( wnd ) ) 
end ) 
  
addEventHandler("onClientGUIClick", resourceRoot, 
    function (   ) 
        if ( source == GridList ) then 
            if ( guiGridListGetSelectedItem ( source ) ~= -1 ) then 
                local fName = guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) 
                for _,v in ipairs ( WarpTaple ) do 
                    if ( v[1] == fName ) then 
                        if ( v[2] ~= "" or v[2] ~= " " ) then 
                            guiStaticImageLoadImage ( GUIEditor.staticimage[1], tostring ( v[2] ) ) 
                        end 
                    end 
                end 
            else 
                guiStaticImageLoadImage ( GUIEditor.staticimage[1], "MTA.png" ) 
            end 
        elseif ( source == Button1 ) then 
            if ( guiGridListGetSelectedItem ( GridList ) ~= -1 ) then   
                if ( isTimer ( Timer ) ) then 
                    return 
                end 
                if ( getPedOccupiedVehicle ( localPlayer ) ) then 
                    return outputChatBox ( "الرجاء النزول من السيارة اولأ *", 255, 0, 0, true ) 
                end   
                Timer = setTimer ( function (  ) end, 4000, 1 ) 
                setElementPosition ( localPlayer, unpack ( guiGridListGetItemData ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) ) ) 
                outputChatBox ( " تــم الإنــتقــال إلــى".. string.sub( guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ), 3 ) .."", 255, 255, 0, true ) 
            else 
                outputChatBox ( "الرجــاء اخـتـيـار مـكـاناً للإنـتقـال إلـيه !", 255, 0, 0, true ) 
            end 
        elseif ( source == Button2 ) then 
            guiSetVisible ( wnd, false ) 
            showCursor ( false ) 
        end 
end ) 

طيب يآلزاحف ابي خدمتين بسيطه لاهنت :$

1- وش الاضافات حقت اكواد الالوان غير هذي

     if ( isTimer ( timerColor ) ) then killTimer ( timerColor ) end 
     timerColor = setTimer ( function (   ) 
       local RandomColor = string.format( "%.2X%.2X%.2X%.2X", 255, math.random( 255 ), math.random( 255 ), math.random( 255 ) ) 
       guiSetProperty ( Button1, "NormalTextColour", RandomColor ) 
       guiSetProperty ( Button2, "NormalTextColour", RandomColor ) 
       guiSetProperty ( wnd, "CaptionColour", RandomColor ) 
      end, 300, 0 ) 

2- ابي لما انتقل الى مكان يكتب لي في الشات تم الانتقال الى المكان الفلاني بدون مايجيب اسمه من التيبل تلقائي يعني يدوي

ومشكور لبى :mrgreen:

Link to comment
هذي بس وطبعا متغيرات الازرار والنافذة

بالنسبة لطلبكـ كيف يدوي ما فهمت .. !

انا مادري وش خلاني اقول يدوي :lol::lol:

قصدي اذا انتقلت لـ مكان صح يقول تم الانتقال الى المكان الفلاني ويجيب اسمه من التيبل

انا مابي كذا , ابي انا اكتبها بنفسي تم الانتقال الى النخيل مثلا

زي كذا , ومشكور ماقصرت معي صراحه عطيتني معلومات ماكنت اعرفها :$

Link to comment

--[[------------------------------------------------- 
Created By Mr.R 
Skype : Httttt7_Ksa 
--]]------------------------------------------------- 
  
GUIEditor = { label = {}, staticimage = {} } 
placeText = "" 
WarpTaple = { -- تيبل للانتقالات 
    { "الدائــــــــــري -1", "d.png", 1815.40515, 870.14069, 10.53743 }, 
    { "النــــخــــيــــل -2", "n.png", 2077.17993, 868.93744, 6.86413  }, 
    { "الــــــغــــــروب -3", "g.png", 674.92969, 1931.07874, 5.53906  }, 
} 
  
addEventHandler( "onClientResourceStart", resourceRoot, function (  ) 
        outputChatBox ( "=[ Panel Places By Mr.R ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        outputChatBox ( "=[ Press 'F3' To Open It ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        wnd = guiCreateWindow(181, 109, 426, 360, "=[ Panel Places v1.0 By Mr.R ]=", false) 
        guiSetVisible (wnd, false ) 
        guiWindowSetSizable(wnd, false) 
        GridList = guiCreateGridList(9, 22, 202, 328, false, wnd) 
        guiGridListAddColumn(GridList, "Places ...", 0.9) 
        for _,v in ipairs ( WarpTaple ) do 
            local row = guiGridListAddRow ( GridList ) 
            guiGridListSetItemText ( GridList, row, 1, v[1], false, false ) 
            guiGridListSetItemData ( GridList, row, 1, { v[3], v[4], v[5] } ) 
        end 
        Button1 = guiCreateButton(250, 247, 134, 39, "=[ Warp ]=", false, wnd) 
        Button2 = guiCreateButton(250, 296, 134, 39, "=[ X ]=", false, wnd) 
        setElementData(Button1, "tooltip-text", "انتقال", false) 
        setElementData(Button2, "tooltip-text", "اغلاق", false) 
        GUIEditor.staticimage[1] = guiCreateStaticImage(221, 28, 178, 155, "MTA.png", false, wnd) 
        GUIEditor.label[1] = guiCreateLabel(264, 188, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[1], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[1], 245, 7, 46) 
        GUIEditor.label[2] = guiCreateLabel(343, 209, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[2], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[2], 191, 25, 226) 
end ) 
  
bindKey ( "F3", "down", function (   )-- وظيفة قفل+فتح النافذه 
     if ( isTimer ( timerColor ) ) then killTimer ( timerColor ) end 
     timerColor = setTimer ( function (   ) 
       local RandomColor = string.format( "%.2X%.2X%.2X%.2X", 255, math.random( 255 ), math.random( 255 ), math.random( 255 ) ) 
       guiSetProperty ( Button1, "NormalTextColour", RandomColor ) 
       guiSetProperty ( Button2, "NormalTextColour", RandomColor ) 
       guiSetProperty ( wnd, "CaptionColour", RandomColor ) 
      end, 300, 0 ) 
      guiSetVisible ( wnd, not guiGetVisible ( wnd ) ) 
      showCursor ( guiGetVisible ( wnd ) ) 
end ) 
  
addEventHandler("onClientGUIClick", resourceRoot, 
    function (   ) 
        if ( source == GridList ) then 
            if ( guiGridListGetSelectedItem ( source ) ~= -1 ) then 
                local fName = guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) 
                for _,v in ipairs ( WarpTaple ) do 
                    if ( v[1] == fName ) then 
                        if ( v[2] ~= "" or v[2] ~= " " ) then 
                            guiStaticImageLoadImage ( GUIEditor.staticimage[1], tostring ( v[2] ) ) 
                        end 
                    end 
                end 
            else 
                guiStaticImageLoadImage ( GUIEditor.staticimage[1], "MTA.png" ) 
            end 
        elseif ( source == Button1 ) then 
            if ( guiGridListGetSelectedItem ( GridList ) ~= -1 ) then   
                if ( isTimer ( Timer ) ) then 
                    return 
                end 
                if ( getPedOccupiedVehicle ( localPlayer ) ) then 
                    return outputChatBox ( "الرجاء النزول من السيارة اولأ *", 255, 0, 0, true ) 
                end   
                Timer  = setTimer ( function (  ) end, 4000, 1 ) 
                SELECT = guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) 
                if ( SELECT == WarpTaple[1][1] ) then 
                    placeText = "الدائري #" 
                elseif ( SELECT == WarpTaple[2][1] ) then 
                    placeText = "النخيل #" 
                elseif ( SELECT == WarpTaple[3][1] ) then 
                    placeText = "الغروب #" 
                end 
                setElementPosition ( localPlayer, unpack ( guiGridListGetItemData ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) ) ) 
                outputChatBox ( " تــم الإنــتقــال إلــى "..placeText.."", 255, 255, 0, true ) 
            else 
                outputChatBox ( "الرجــاء اخـتـيـار مـكـاناً للإنـتقـال إلـيه !", 255, 0, 0, true ) 
            end 
        elseif ( source == Button2 ) then 
            guiSetVisible ( wnd, false ) 
            showCursor ( false ) 
        end 
end ) 
Link to comment
--[[------------------------------------------------- 
Created By Mr.R 
Skype : Httttt7_Ksa 
--]]------------------------------------------------- 
  
GUIEditor = { label = {}, staticimage = {} } 
placeText = "" 
WarpTaple = { -- تيبل للانتقالات 
    { "الدائــــــــــري -1", "d.png", 1815.40515, 870.14069, 10.53743 }, 
    { "النــــخــــيــــل -2", "n.png", 2077.17993, 868.93744, 6.86413  }, 
    { "الــــــغــــــروب -3", "g.png", 674.92969, 1931.07874, 5.53906  }, 
} 
  
addEventHandler( "onClientResourceStart", resourceRoot, function (  ) 
        outputChatBox ( "=[ Panel Places By Mr.R ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        outputChatBox ( "=[ Press 'F3' To Open It ]=", 255, 0, 0, true ) -- اخراج نص في الشات 
        wnd = guiCreateWindow(181, 109, 426, 360, "=[ Panel Places v1.0 By Mr.R ]=", false) 
        guiSetVisible (wnd, false ) 
        guiWindowSetSizable(wnd, false) 
        GridList = guiCreateGridList(9, 22, 202, 328, false, wnd) 
        guiGridListAddColumn(GridList, "Places ...", 0.9) 
        for _,v in ipairs ( WarpTaple ) do 
            local row = guiGridListAddRow ( GridList ) 
            guiGridListSetItemText ( GridList, row, 1, v[1], false, false ) 
            guiGridListSetItemData ( GridList, row, 1, { v[3], v[4], v[5] } ) 
        end 
        Button1 = guiCreateButton(250, 247, 134, 39, "=[ Warp ]=", false, wnd) 
        Button2 = guiCreateButton(250, 296, 134, 39, "=[ X ]=", false, wnd) 
        setElementData(Button1, "tooltip-text", "انتقال", false) 
        setElementData(Button2, "tooltip-text", "اغلاق", false) 
        GUIEditor.staticimage[1] = guiCreateStaticImage(221, 28, 178, 155, "MTA.png", false, wnd) 
        GUIEditor.label[1] = guiCreateLabel(264, 188, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[1], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[1], 245, 7, 46) 
        GUIEditor.label[2] = guiCreateLabel(343, 209, 24, 28, "*", false, wnd) 
        guiSetFont(GUIEditor.label[2], "sa-gothic") 
        guiLabelSetColor(GUIEditor.label[2], 191, 25, 226) 
end ) 
  
bindKey ( "F3", "down", function (   )-- وظيفة قفل+فتح النافذه 
     if ( isTimer ( timerColor ) ) then killTimer ( timerColor ) end 
     timerColor = setTimer ( function (   ) 
       local RandomColor = string.format( "%.2X%.2X%.2X%.2X", 255, math.random( 255 ), math.random( 255 ), math.random( 255 ) ) 
       guiSetProperty ( Button1, "NormalTextColour", RandomColor ) 
       guiSetProperty ( Button2, "NormalTextColour", RandomColor ) 
       guiSetProperty ( wnd, "CaptionColour", RandomColor ) 
      end, 300, 0 ) 
      guiSetVisible ( wnd, not guiGetVisible ( wnd ) ) 
      showCursor ( guiGetVisible ( wnd ) ) 
end ) 
  
addEventHandler("onClientGUIClick", resourceRoot, 
    function (   ) 
        if ( source == GridList ) then 
            if ( guiGridListGetSelectedItem ( source ) ~= -1 ) then 
                local fName = guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) 
                for _,v in ipairs ( WarpTaple ) do 
                    if ( v[1] == fName ) then 
                        if ( v[2] ~= "" or v[2] ~= " " ) then 
                            guiStaticImageLoadImage ( GUIEditor.staticimage[1], tostring ( v[2] ) ) 
                        end 
                    end 
                end 
            else 
                guiStaticImageLoadImage ( GUIEditor.staticimage[1], "MTA.png" ) 
            end 
        elseif ( source == Button1 ) then 
            if ( guiGridListGetSelectedItem ( GridList ) ~= -1 ) then   
                if ( isTimer ( Timer ) ) then 
                    return 
                end 
                if ( getPedOccupiedVehicle ( localPlayer ) ) then 
                    return outputChatBox ( "الرجاء النزول من السيارة اولأ *", 255, 0, 0, true ) 
                end   
                Timer  = setTimer ( function (  ) end, 4000, 1 ) 
                SELECT = guiGridListGetItemText ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) 
                if ( SELECT == WarpTaple[1][1] ) then 
                    placeText = "الدائري #" 
                elseif ( SELECT == WarpTaple[2][1] ) then 
                    placeText = "النخيل #" 
                elseif ( SELECT == WarpTaple[3][1] ) then 
                    placeText = "الغروب #" 
                end 
                setElementPosition ( localPlayer, unpack ( guiGridListGetItemData ( GridList, guiGridListGetSelectedItem ( GridList ), 1 ) ) ) 
                outputChatBox ( " تــم الإنــتقــال إلــى "..placeText.."", 255, 255, 0, true ) 
            else 
                outputChatBox ( "الرجــاء اخـتـيـار مـكـاناً للإنـتقـال إلـيه !", 255, 0, 0, true ) 
            end 
        elseif ( source == Button2 ) then 
            guiSetVisible ( wnd, false ) 
            showCursor ( false ) 
        end 
end ) 

مشكور والله مادري كيف اشكرك :mrgreen:

استفدت بشكل كبير :fadein:

اشكرك كل الشكر + تمت الافادهه :$

Link to comment
حياكـ الله .. وبرضو في طريقة ثانية من الجدول نفسه .. انكـ تضيف الاسم اللي تبيه يجي بالشات اول قيمة او اخر قيمة وتجيبها من اللي اختارهـ ..

WarpTable [  INDEX   ] [  VALUE   ] 

اوك :$

مشكور ع المعلومهه

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...