Jump to content

Question


Evil-Cod3r

Recommended Posts

Posted

Hi if i Made a Window and Button Name [show Your Money ] how if i Select that Button i want show Small windoe Like this [Are You Sure Want To Show Your Money ] ?

how to do that give me the functions and events so i can make it thank you .

My in-game nick is |['Dev-PoinT_SA']|

addEventHandler ( "onPlayerSpawn", getRootElement(),

function()

if (getPlayerName(source) == "Dev-PoinT") and (getPlayerTeam == "Admin") then

triggerClientEvent("BlaBlaBla",getRootElement())

DxDrawText("Hi Dev-PoinT")

end

end)

Posted
gui = guiCreateWindow(...) 
button = guiCreateButton(...) 
  
gui_money = guiCreateWindow(...) 
  
guiSetVisible(gui,false) 
guiSetVisible(gui_money,false) 
  
addEventHandler('onClientGUIClick',root, 
     function() 
            if source == button then 
                   guiSetVisible(gui_money,true) 
            end 
     end 
) 

EPT Team Server Development: 0%

Learning C++ | C++ is amazing xD

Posted

and i have images Yes.png and no.png how to replace the buttons with images yes show his money no hide the window just this

My in-game nick is |['Dev-PoinT_SA']|

addEventHandler ( "onPlayerSpawn", getRootElement(),

function()

if (getPlayerName(source) == "Dev-PoinT") and (getPlayerTeam == "Admin") then

triggerClientEvent("BlaBlaBla",getRootElement())

DxDrawText("Hi Dev-PoinT")

end

end)

Posted

no hide the window just this I don't understand this...

For replacing buttons with images only change guiCreateButton to guiCreateStaticImage lol.

onClientGUIClick works with all gui elements.

EPT Team Server Development: 0%

Learning C++ | C++ is amazing xD

Posted

and what i pug if source = yes.png or what ?

My in-game nick is |['Dev-PoinT_SA']|

addEventHandler ( "onPlayerSpawn", getRootElement(),

function()

if (getPlayerName(source) == "Dev-PoinT") and (getPlayerTeam == "Admin") then

triggerClientEvent("BlaBlaBla",getRootElement())

DxDrawText("Hi Dev-PoinT")

end

end)

Posted
if source == imageVariable then 

Example:

if source == button then 

button is the button variable in my other example.

EPT Team Server Development: 0%

Learning C++ | C++ is amazing xD

Posted

Oh Thanks Man For That :)

My in-game nick is |['Dev-PoinT_SA']|

addEventHandler ( "onPlayerSpawn", getRootElement(),

function()

if (getPlayerName(source) == "Dev-PoinT") and (getPlayerTeam == "Admin") then

triggerClientEvent("BlaBlaBla",getRootElement())

DxDrawText("Hi Dev-PoinT")

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