Author Topic: Ban Error  (Read 3280 times)

0 Members and 1 Guest are viewing this topic.

Offline Tamas

  • Made Man
  • ***
  • Posts: 127
    • View Profile
    • http://www.tamasnet.eu/
Ban Error
« on: August 03, 2008, 02:56:27 am »
My Ban Alias:

Quote
alias vcmp.ban {
  vcmp.adminchat Admin:[ [ $vcmp.hgetname($1) ] ] Banned Player:[ [ $$vcmp.hgetname($vcmp.nameid($1)) ] ] $iif($2-, $2-,)
  !write vcmp.banned.txt Admin: $vcmp.hgetname($1) Banned: $vcmp.hgetname($vcmp.nameid($1)) IP: $vcmp.hgetip($vcmp.nameid($1)) $iif($2,$2-,)
  .timer. $+ $$vcmp.nameid($1) $+ .ban -m 1 250 vcmp.command ban $$vcmp.nameid($1)
}

Code:
Quote
  elseif (($2 == ban) && ($vcmp.loggedin($1) > 4)) {
    if ($vcmp.nameid($3) == $null) vcmp.adminmsg $1 Error: Invalid ID.
    else {
      if ($hget(vcmp,loggedin. $+ $1) < $hget(vcmp,loggedin. $+ $vcmp.nameid($3))) { vcmp.adminmsg $1 You can't ban someone higher level admin than you... | vcmp.kick $1 }
       else { vcmp.adminchat Kicking $vcmp.hgetname($vcmp.nameid($3)) | vcmp.ban $vcmp.nameid($3) $iif($4-,Reason:[ [ $4-,) ] ] }
    }
  }

The problem is when i type /c ban goldkinght it says:
<@BootRobocop> Admin:[ goldkinght ] Banned Player:[ goldkinght ] Reason:[ test ]

I want to change to this format:
<@BootRobocop> Admin:[ [SRS]Tomi ] Banned Player:[ goldkinght ] Reason:[ test ]
Dont know why its showing the banned person name in the  Admin: section.

Offline TanaX01

  • Made Man
  • ***
  • Posts: 214
  • BlackList! <3
    • View Profile
Re: Ban Error
« Reply #1 on: August 03, 2008, 03:07:06 am »
use
Code: [Select]
Admin:[ $vcmp.hgetname(%id) ]
Work 100%  ;)

Offline Tamas

  • Made Man
  • ***
  • Posts: 127
    • View Profile
    • http://www.tamasnet.eu/
Re: Ban Error
« Reply #2 on: August 04, 2008, 02:16:45 am »
Its still not work  :(
Not showing the Admin name:

<@BootRobocop> Kicking [SRS]Tomi 
<@BootRobocop> Admin:[ ] Banned Player:[ [SRS]Tomi ] Reason:[ test ]

Code:

Quote
alias vcmp.ban {
  vcmp.adminchat Admin:[ $vcmp.hgetname(%id) ] Banned Player:[ [ $$vcmp.hgetname($vcmp.nameid($1)) ] ] $iif($2-, $2-,)
  !write vcmp.banned.txt Admin: [ $nick ] Banned: $vcmp.hgetname($vcmp.nameid($1)) IP: $vcmp.hgetip($vcmp.nameid($1)) $iif($2,$2-,)
  .timer. $+ $$vcmp.nameid($1) $+ .ban -m 1 250 vcmp.command ban $$vcmp.nameid($1)