Jump to content

Una duda con onClientGUIClick


Arsilex

Recommended Posts

Posted

bueno tengo esto

    Teams = guiCreateGridList(1044, 298, 314, 409, false) 
    local NTeam = guiGridListAddColumn( Teams, "No Team", 0.4 ) 
    local XNN = guiGridListAddColumn( Teams, "XN", 0.3 ) 
    local Admins = guiGridListAddColumn( Teams, "Admins", 0.3 ) 
  
        addEventHandler ( "onClientGUIClick", Teams, click ) 
  
function click ( button, state, sx, sy, x, y, z, elem, gui ) 
        local playerName = guiGridListGetItemText ( Teams, guiGridListGetSelectedItem ( Teams ), 1 ) 
        outputChatBox ( playerName ) 
end 

me gustaria saber si es posible que la columna de abajo osea el 1 si se puede sacar de alguna manera es que cuando presiona en un texto de la columna 3 me sale el texto de la 1 :S

rsilex.png.0e6ad382b3fdc3cbe6390e3e847572c9.png
Posted

No entiendo de que hablas.

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

Posted
Teams = guiCreateGridList(1044, 298, 314, 409, false) 
local NTeam = guiGridListAddColumn( Teams, "No Team", 0.4 ) 
local XNN = guiGridListAddColumn( Teams, "XN", 0.3 ) 
local Admins = guiGridListAddColumn( Teams, "Admins", 0.3 ) 
  
function click ( ) 
    local row, col = guiGridListGetSelectedItem ( source ) 
    if ( row and col and row ~= -1 and col ~= -1 ) then 
        local playerName = guiGridListGetItemText ( source, row, 1 ) 
        outputChatBox ( playerName ) 
    end 
end 
addEventHandler ( "onClientGUIClick", Teams, click, false ) 

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

Posted
Teams = guiCreateGridList(1044, 298, 314, 409, false) 
local NTeam = guiGridListAddColumn( Teams, "No Team", 0.4 ) 
local XNN = guiGridListAddColumn( Teams, "XN", 0.3 ) 
local Admins = guiGridListAddColumn( Teams, "Admins", 0.3 ) 
  
function click ( ) 
    local row, col = guiGridListGetSelectedItem ( source ) 
    if ( row and col and row ~= -1 and col ~= -1 ) then 
        local playerName = guiGridListGetItemText ( source, row, 1 ) 
        outputChatBox ( playerName ) 
    end 
end 
addEventHandler ( "onClientGUIClick", Teams, click, false ) 

ok thx castillo :D

rsilex.png.0e6ad382b3fdc3cbe6390e3e847572c9.png
  • Recently Browsing   0 members

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