Author Topic: Change Commands !cmd to /c cmd  (Read 3482 times)

0 Members and 1 Guest are viewing this topic.

Offline TanaX01

  • Made Man
  • ***
  • Posts: 214
  • BlackList! <3
    • View Profile
Change Commands !cmd to /c cmd
« on: July 26, 2008, 05:08:20 am »
Hello  :D

Please help my in change commnads !ban To /c ban

Code: [Select]
    elseif ($2 == !ban) {
      if ($hget(vcmp,loggedin. $+ %id) < 3) { vcmp.adminmsg %id You Must Be Admin Level 2 Or Higher To Attempt This Command. }
      else {
        if ($vcmp.nameid($3) == $null) vcmp.adminmsg %id Error: Invalid ID.
        else {
          if ($hget(vcmp,loggedin. $+ %id) < $hget(vcmp,loggedin. $+ $vcmp.nameid($3))) { vcmp.adminmsg %id You can't ban someone higher level admin than you... }
          else { vcmp.ban2 $3 $4- | vcmp.adminchat ** Admin $vcmp.hgetname(%id) Banned player:[ $vcmp.hgetname($vcmp.nameid($3)) ] Reason:[ $4- ]
          }
        }
      }
    }

Change a

Code: [Select]
    elseif ($2 == ban) {
      if ($hget(vcmp,loggedin. $+ %id) < 3) { vcmp.adminmsg %id You Must Be Admin Level 2 Or Higher To Attempt This Command. }
      else {
        if ($vcmp.nameid($3) == $null) vcmp.adminmsg %id Error: Invalid ID.
        else {
          if ($hget(vcmp,loggedin. $+ %id) < $hget(vcmp,loggedin. $+ $vcmp.nameid($3))) { vcmp.adminmsg %id You can't ban someone higher level admin than you... }
          else { vcmp.ban2 $3 $4- | vcmp.adminchat ** Admin $vcmp.hgetname(%id) Banned player:[ $vcmp.hgetname($vcmp.nameid($3)) ] Reason:[ $4- ]
          }
        }
      }
    }

??? please help my in game /c ban = Error Invalid Commands.  :-\

Offline ReVilo

  • Wiseguy
  • **
  • Posts: 64
  • Master of All that is Holy
    • View Profile
Re: Change Commands !cmd to /c cmd
« Reply #1 on: July 26, 2008, 07:01:44 am »
try changing the required level to one less than the user who will use the cmd.
so youd change it to 2

Offline Mattz

  • VC:MP Lead Tester
  • Made Man
  • *
  • Posts: 192
  • BK-201
    • View Profile
Re: Change Commands !cmd to /c cmd
« Reply #2 on: July 26, 2008, 07:15:57 am »
Just delete

 
Code: [Select]
elseif ($2 == !ban) {
      if ($hget(vcmp,loggedin. $+ %id) < 3) { vcmp.adminmsg %id You Must Be Admin Level 2 Or Higher To Attempt This Command. }
      else {
        if ($vcmp.nameid($3) == $null) vcmp.adminmsg %id Error: Invalid ID.
        else {
          if ($hget(vcmp,loggedin. $+ %id) < $hget(vcmp,loggedin. $+ $vcmp.nameid($3))) { vcmp.adminmsg %id You can't ban someone higher level admin than you... }
          else { vcmp.ban2 $3 $4- | vcmp.adminchat ** Admin $vcmp.hgetname(%id) Banned player:[ $vcmp.hgetname($vcmp.nameid($3)) ] Reason:[ $4- ]
          }
        }
      }
    }

Because you already have /c ban in on *:SIGNAL:vcmp.event.command:{


Offline TanaX01

  • Made Man
  • ***
  • Posts: 214
  • BlackList! <3
    • View Profile
Re: Change Commands !cmd to /c cmd
« Reply #3 on: July 26, 2008, 08:12:25 pm »
yea mattz thx nice  :o          8)