Jump to content

[HELP] Bans


1LoL1

Recommended Posts

SolidSnake14 I just found this here but I do not know what to put there instead Unknown?

if ( nick ) then nick = xmlNodeGetValue ( nick ) else nick = "Unknown" end 
            if ( banner ) then banner = xmlNodeGetValue ( banner ) else banner = "Unknown" end 
            if ( reason ) then reason = xmlNodeGetValue ( reason ) else reason = "Unknown" end 
            if ( date ) then date = xmlNodeGetValue ( date ) else date = "Unknown" end 
            if ( time ) then time = xmlNodeGetValue ( time ) else time = "Unknown" end 

Sorry for the triple post but it did not have to delete the previous post

Link to comment
  • 2 weeks later...

So at least there poradte what should I supplement? Terribly need it ..

if ( aBans["IP"][ip] ) then 
        guiSetText ( aBanIP, "IP: "..ip ) 
        guiSetText ( aBanNick, "Nickname: "..iif ( aBans["IP"][ip]["nick"], aBans["IP"][ip]["nick"], "Unknown" ) ) 
        guiSetText ( aBanDate, "Date: "..iif ( aBans["IP"][ip]["date"], aBans["IP"][ip]["date"], "Unknown" ) ) 
        guiSetText ( aBanTime, "Time: "..iif ( aBans["IP"][ip]["time"], aBans["IP"][ip]["time"], "Unknown" ) ) 
        guiSetText ( aBanBanner, "Banned by: "..iif ( aBans["IP"][ip]["banner"], aBans["IP"][ip]["banner"], "Unknown" ) ) 
        if ( aBanReason ) then destroyElement ( aBanReason ) end 
        aBanReason = guiCreateLabel ( 0.03, 0.60, 0.80, 0.30, "Reason: "..iif ( aBans["IP"][ip]["reason"], aBans["IP"][ip]["reason"], "Unknown" ), true, aBanForm ) 
        guiLabelSetHorizontalAlign ( aBanReason, "left", true ) 
        guiSetVisible ( aBanForm, true ) 
        guiBringToFront ( aBanForm ) 
    elseif ( aBans["Serial"][ip] ) then 
        guiSetText ( aBanIP, "Serial: "..ip ) 
        guiSetText ( aBanNick, "Nickname: "..iif ( aBans["Serial"][ip]["nick"], aBans["Serial"][ip]["nick"], "Unknown" ) ) 
        guiSetText ( aBanDate, "Date: "..iif ( aBans["Serial"][ip]["date"], aBans["Serial"][ip]["date"], "Unknown" ) ) 
        guiSetText ( aBanTime, "Time: "..iif ( aBans["Serial"][ip]["time"], aBans["Serial"][ip]["time"], "Unknown" ) ) 
        guiSetText ( aBanBanner, "Banned by: "..iif ( aBans["Serial"][ip]["banner"], aBans["Serial"][ip]["banner"], "Unknown" ) ) 
        if ( aBanReason ) then destroyElement ( aBanReason ) end 
        aBanReason = guiCreateLabel ( 0.03, 0.60, 0.80, 0.30, "Reason: "..iif ( aBans["Serial"][ip]["reason"], aBans["Serial"][ip]["reason"], "Unknown" ), true, aBanForm ) 
        guiLabelSetHorizontalAlign ( aBanReason, "left", true ) 
        guiSetVisible ( aBanForm, true ) 
        guiBringToFront ( aBanForm ) 

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