Jump to content

Go Go (===


Recommended Posts

Posted

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

عندي ثريد ليست وابي لما اشغل المود يجيب اسماء اللعبين الي في السيرفر

Posted

قبل لا تطرح اي موضوع ابحث فـ المنتدى .. ثانيا انت بقسم عربي ليه تكتب انجليزي ! وغير كذا اسم الموضوع ماله اي دخل بالمحتوى حقه !

بالنسبة لطلبكـ ابحث بس وبتلقى 15135235 موضوع زي طلبكـ !!

Posted (edited)

سوي لوب

  
guiGridListAddColumn 
getElementsByType 
guiGridListAddRow 
guiGridListSetItemText 
getPlayerName 

   
addEventHandler("onClientResourceStart", resourceRoot, 
    function () 
        GridPlayer = guiCreateGridList(23, 59, 188, 346, false, PlayerList) -- يسوي قريد ليست 
        guiGridListAddColumn(GridPlayer, "Player", 0.9) -- يضيف عامو بالقريد ليست 
              for _,player in ipairs ( getElementsByType("player") ) do  -- هنا بسوي لوب لكل الاعبين بالسيرفر 
                local row = guiGridListAddRow(GridPlayer) -- هذا الفنكشن يضيف لك سطر بالقريد  
                guiGridListSetItemText(GridPlayer,row,1,getPlayerName(player),false,false) هذا بحط لك الاعبين بالقريد ليست 
                end 
end) 

Edited by Guest
Posted
وظيفة تغيير قيَم القريد لست إلى أسماء اللاعبين ..
changeGridListItemToPlayersName = function ( GridList, Column ) 
    if GridList and Column then -- Check Parematers 
        if getElementType ( GridList ) == "gui-gridlist" then -- Check The Type of ' GridList ' 
            if guiGridListClear ( GridList ) then -- Clear GridList 
                for i, v in next, getElementsByType ( "player" ) do -- Get Everything by Type ' player '  
                    local Row = guiGridListAddRow ( GridList ) -- Add Row 
                    guiGridListSetItemText ( GridList, Row, Column, getPlayerName ( v ), false, false ); -- Set New Values 
                end; -- end of ' for ' 
            end; -- end of ' clear gridlist ' 
        end; -- end of ' check gridlist type ' 
    end; -- end of ' check parematers 
end; -- end of ' function ' 

مثآل :

wnd = guiCreateWindow ( 100, 100, 400, 400, "Test", false ); -- Create Window 
grid = guiCreateGridList ( 25, 30, 350, 350, false, wnd ); -- Create Gridlist 
col = guiGridListAddColumn ( grid, "Players", 0.9 ); -- Create Column 
changeGridListItemToPlayersName ( grid, col ); -- Set Gridlist Values 

Posted
عطوك الاكواد جاهزين أختار الي يعجبك

يا عم ذي اكواد اللوحه جقتي

GUIEditor = { 
    gridlist = {}, 
    window = {}, 
    button = {}, 
    memo = {} 
} 
addEventHandler("onClientResourceStart", resourceRoot, 
    function() 
        GUIEditor.window[1] = guiCreateWindow(0.30, 0.23, 0.35, 0.43, "", true) 
        guiWindowSetMovable(GUIEditor.window[1], false) 
        guiSetAlpha(GUIEditor.window[1], 0.87) 
  
        GUIEditor.button[1] = guiCreateButton(334, 29, 138, 30, "ارسال رساله للادمن", false, GUIEditor.window[1]) 
        GUIEditor.button[2] = guiCreateButton(334, 69, 138, 30, "", false, GUIEditor.window[1]) 
        GUIEditor.button[3] = guiCreateButton(186, 29, 138, 30, "تحديد الموقع", false, GUIEditor.window[1]) 
        GUIEditor.button[4] = guiCreateButton(186, 69, 138, 30, "الليــزر", false, GUIEditor.window[1]) 
        GUIEditor.button[5] = guiCreateButton(334, 109, 138, 30, "", false, GUIEditor.window[1]) 
        GUIEditor.button[6] = guiCreateButton(186, 109, 138, 30, "", false, GUIEditor.window[1]) 
        GUIEditor.button[7] = guiCreateButton(334, 149, 138, 30, "", false, GUIEditor.window[1]) 
        GUIEditor.button[8] = guiCreateButton(186, 149, 138, 30, "", false, GUIEditor.window[1]) 
        GUIEditor.button[9] = guiCreateButton(334, 189, 138, 30, "", false, GUIEditor.window[1]) 
        GUIEditor.button[10] = guiCreateButton(186, 189, 138, 30, "", false, GUIEditor.window[1]) 
        GUIEditor.button[11] = guiCreateButton(186, 229, 138, 30, "", false, GUIEditor.window[1]) 
        GUIEditor.gridlist[1] = guiCreateGridList(9, 70, 167, 233, false, GUIEditor.window[1]) 
        guiGridListAddColumn(GUIEditor.gridlist[1], "", 0.9) 
        GUIEditor.memo[1] = guiCreateMemo(9, 20, 167, 39, "", false, GUIEditor.window[1])     
    end 
) 
  

Posted

GUIEditor = { 
    window = {}, 
    button = {}, 
    memo = {} 
} 
addEventHandler("onClientResourceStart", resourceRoot, 
    function() 
        GUIEditor.window[1] = guiCreateWindow(0.30, 0.23, 0.35, 0.43, "", true); 
        guiWindowSetMovable(GUIEditor.window[1], false); 
        guiSetAlpha(GUIEditor.window[1], 0.87); 
        setBindKeyWindowShow ( GUIEditor.window[1], "F1" ); -- هنا غير مكان زر 
        GUIEditor.button[1] = guiCreateButton(334, 29, 138, 30, "ارسال رساله للادمن", false, GUIEditor.window[1]); 
        GUIEditor.button[2] = guiCreateButton(334, 69, 138, 30, "", false, GUIEditor.window[1]); 
        GUIEditor.button[3] = guiCreateButton(186, 29, 138, 30, "تحديد الموقع", false, GUIEditor.window[1]); 
        GUIEditor.button[4] = guiCreateButton(186, 69, 138, 30, "الليــزر", false, GUIEditor.window[1]); 
        GUIEditor.button[5] = guiCreateButton(334, 109, 138, 30, "", false, GUIEditor.window[1]); 
        GUIEditor.button[6] = guiCreateButton(186, 109, 138, 30, "", false, GUIEditor.window[1]); 
        GUIEditor.button[7] = guiCreateButton(334, 149, 138, 30, "", false, GUIEditor.window[1]); 
        GUIEditor.button[8] = guiCreateButton(186, 149, 138, 30, "", false, GUIEditor.window[1]); 
        GUIEditor.button[9] = guiCreateButton(334, 189, 138, 30, "", false, GUIEditor.window[1]); 
        GUIEditor.button[10] = guiCreateButton(186, 189, 138, 30, "", false, GUIEditor.window[1]); 
        GUIEditor.button[11] = guiCreateButton(186, 229, 138, 30, "", false, GUIEditor.window[1]); 
        GridList = guiCreateGridList(9, 70, 167, 233, false, GUIEditor.window[1]); 
        guiGridListAddColumn(GridList, "Player", 0.9); 
        changeGridListItemToPlayersName (GridList, col ); 
        GUIEditor.memo[1] = guiCreateMemo(9, 20, 167, 39, "", false, GUIEditor.window[1]);     
    end 
) 
  
--Grid Player 
  
changeGridListItemToPlayersName = function ( GridList, Column ) 
    if GridList and Column then 
        if getElementType ( GridList ) == "gui-gridlist" then 
            if guiGridListClear ( GridList ) then 
                for i, v in next, getElementsByType ( "player" ) do 
                    local Row = guiGridListAddRow ( GridList ) 
                    guiGridListSetItemText ( GridList, Row, Column, getPlayerName ( v ), false, false ); 
                end; 
            end; 
        end; 
    end; 
end; 
  
--Gui Open 
  
setBindKeyWindowShow = function ( guiWindow, key ) 
    if guiWindow and key then 
        if getElementType ( guiWindow ) == "gui-window" then 
            guiSetVisible ( guiWindow, false ); 
            local setBindKey_ = function ( key ) 
                guiSetVisible ( guiWindow, not guiGetVisible ( guiWindow ) ); 
                showCursor ( guiGetVisible ( guiWindow ) ); 
            end 
            return bindKey ( key, "down", setBindKey_ ); 
        else 
            return false; 
        end 
    else 
        return false; 
    end 
end 

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