Jump to content

que esta mal? ["GUI"]


Plate

Recommended Posts

Posted

Hola alguien me podria decir que esta mal en esto

GUIEditor_Window = {} 
GUIEditor_Button = {} 
GUIEditor_Grid = {} 
  
panel = guiCreateWindow(217,172,327,240,"Panel",false) 
Players = guiCreateGridList(24,46,133,162,false,Players) 
guiGridListSetSelectionMode(GUIEditor_Grid[1],2) 
  
guiGridListAddColumn(GUIEditor_Grid[1],"Players",0.2) 
add = guiCreateButton(189,58,112,35,"Add Player",false,panel) 
remove = guiCreateButton(188,125,113,41,"Remove Player",false,panel) 
guiWindowSetMovable(panel,false) 
guiWindowSetSizable(panel,false) 
guiSetVisible(panel,false) 
  
function addP() 
guiSetVisible (panel,true) 
showCursor(true) 
end 
addCommandHandler("AFP",getRootElement(),addP) 
  
function closePanel() 
if guiGetVisible(panel) then  
        guiSetVisible(panel,false) 
        showCursor(false) 
    end 
end 
addCommandHandler("CFP",getRootElement(),closePanel) 
  

Visita Full GameZ DayZ Mod

Server IP: mtasa://158.69.125.144:29015

Posted
panel = guiCreateWindow(217,172,327,240,"Panel",false) 
Players = guiCreateGridList(24,46,133,162,false,Players) 
guiGridListSetSelectionMode(Players,2) 
guiGridListAddColumn(Players,"Players",0.2) 
add = guiCreateButton(189,58,112,35,"Add Player",false,panel) 
remove = guiCreateButton(188,125,113,41,"Remove Player",false,panel) 
guiWindowSetMovable(panel,false) 
guiWindowSetSizable(panel,false) 
guiSetVisible(panel,false) 
  
function addP() 
guiSetVisible (panel,true) 
showCursor(true) 
end 
addCommandHandler("AFP",addP) -- getRootElement() esta de mas. 
  
function closePanel() 
    if guiGetVisible(panel) then 
        guiSetVisible(panel,false) 
        showCursor(false) 
    end 
end 
addCommandHandler("CFP",closePanel) -- getRootElement() esta de mas. 

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

listo solid exellente igual hize otro gui jaja necesito que en la columna Players in F aparescan los players con grupo acl especial

y me falta hacer el serverside con tiggerServerEvent

Visita Full GameZ DayZ Mod

Server IP: mtasa://158.69.125.144:29015

Posted

De nada.

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

que esta mal de esto solid

addEvent ("addST", true) 
addEventHandler ("addST", getRootElement(), 
function (playerSource, commandName, accountName) 
 local usuario = getAccountName ( getPlayerAccount ( playerSource ) ) 
     if isObjectInACLGroup ("user."..usuario, aclGetGroup ( "LiderFTFP" ) )  then 
          if accountName then 
local pname = getPlayerName( playerSource ) 
          aclGroupAddObject (aclGetGroup("FTFP"), "user."..accountName) 
         outputChatBox(tostring(pname) .." agrego a  '"..accountName.."' a S.T.A.R.S", getRootElement(), 0, 255, 255, true ) 
        end 
    end 
 ) 

function STARS() 
triggerServerEvent ("addST", getRootElement(), playerSource, commandName, accountName) 
end 
addEventHandler ("onClientGUIClick", Add, STARS, false) 

Visita Full GameZ DayZ Mod

Server IP: mtasa://158.69.125.144:29015

Posted

-- server side:

addEvent ( "addST", true ) 
addEventHandler ( "addST", getRootElement(), 
    function ( accountName ) 
        local usuario = getAccountName ( getPlayerAccount ( source ) ) 
        if isObjectInACLGroup ( "user.".. usuario, aclGetGroup ( "LiderFTFP" ) )  then 
            if ( accountName ) then 
                local pname = getPlayerName ( source ) 
                aclGroupAddObject ( aclGetGroup ( "FTFP" ), "user.".. accountName ) 
                outputChatBox ( tostring ( pname ) .." agrego a  '".. accountName .."' a S.T.A.R.S", getRootElement(), 0, 255, 255, true ) 
            end 
        end 
    end 
) 

-- client side:

function STARS ( ) 
    triggerServerEvent ( "addST", localPlayer, accountName ) 
end 
addEventHandler ( "onClientGUIClick", Add, STARS, 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

no funciona u.u

expect to close "("at line 14 near end 

Visita Full GameZ DayZ Mod

Server IP: mtasa://158.69.125.144:29015

  • Recently Browsing   0 members

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