Jump to content

The gui show upp for all when a player die


villr

Recommended Posts

We have a working code now BUT when a player die it dont show up again but it dont show upp for all

Here is the code

addEventHandler( "onClientPedWasted", getLocalPlayer( ), 
  function( ) 
    if source == getLocalPlayer( ) then -- Wojak forgot about "then" here 
      local name = getPlayerName(source) 
      outputDebugString("player that died: "..name..", local player: "..getPlayerName(getLocalPlayer())) 
      guiSetVisible (spawnmenugrid, true ) 
      guiSetVisible(spawnmenumemo,true) 
      showCursor ( true ) 
      showPlayerHudComponent("radar",false) 
      showChat(false) 
    end 
  end 
) 
  

What is wrong now? :?::?:

Link to comment
  • 3 weeks later...

Right now code is

addEventHandler( "onClientPlayerWasted", getLocalPlayer( ), 
  function( ) 
    if source == getLocalPlayer( ) then -- Wojak forgot about "then" here 
      local name = getPlayerName(source) 
         outputDebugString("ped died") 
      outputDebugString("player that died: "..name..", local player: "..getPlayerName(getLocalPlayer())) 
      guiSetVisible (spawnmenugrid, true ) 
      guiSetVisible(spawnmenumemo,true) 
      showCursor ( true ) 
      showPlayerHudComponent("radar",false) 
      showChat(false) 
    end 
  end 
) 

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