Jump to content

Gamemode Ban player help


ShadowRAZE

Recommended Posts

Hey guys, I'm currently working on my server(zombies). Long story short:

I edited the "play gamemode" to ban the player for 5 minutes if he/she gets killed.

However its not going very well, this is what im doing

addEventHandler("onPlayerWasted", root, 
    function() 
    ban banPlayer ( player bannedPlayer, [ bool IP = true, bool Username = false, bool Serial = false,  
player responsiblePlayer = nil, string reason = "Sorry, You have died, To make the game fun, any player that dies gets banned for 5 minutes :)", int seconds = 300 ] ) 
    end 
) 

When i die in the game, it just brings up the map. Any help!?

Link to comment

That's because you've copied the whole function syntax, which is wrong.

addEventHandler ( "onPlayerWasted", root, 
    function ( ) 
        banPlayer ( source, true, true, true, nil, "Sorry, You have died, To make the game fun, any player that dies gets banned for 5 minutes :)", 300 ) 
    end 
) 

Link to comment
That's because you've copied the whole function syntax, which is wrong.

addEventHandler ( "onPlayerWasted", root, 
    function ( ) 
        banPlayer ( source, true, true, true, nil, "Sorry, You have died, To make the game fun, any player that dies gets banned for 5 minutes :)", 300 ) 
    end 
) 

how can i make it work? srry im new to scripting :)

do i just do this:

  
 ban banPlayer ( player bannedPlayer, [ bool IP = true, bool Username = false, bool Serial = false, 
player responsiblePlayer = nil, string reason = "REASON HERE", int seconds = TIME HERE ] ) 
  

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