Jump to content

!Suspect And !Wanted Script. Plz Help Me


WestCoast

Recommended Posts

I'm Not So Gooed In Scripting.

Sorry If I Disturb You Guys.

What I Need Is:

1) Only Cops Can Do !Suspect

2) If A Cop Kills The Suspected Person They Get $1000 Cash

3) Ppl Can Watch Who Is Wanted.

I already wro this.

its a bit hard to make it lol

 if ($3 == !Suspect) {
mta.say $1 $4 Is Suspected For: $5
!writeini " $+ $scriptdir $+ wanted.ini" $mta.nick($1,$2) Is Wanted
}
 if ($3 = !Wanted) {
($readini($scriptdir $+ wanted.ini,Wanted Peoples,$mta.ip($1,$2)) == 2)
}

its realy hard for me to make this :P but thnx.

Link to comment

on *:SIGNAL:mta.command:{
 if (!suspect == $3) {
   var %a = $iif($4,$iif($mta.name($1,$4) != Unknown,$4,$mta.getid($1,$4)),$2)
   if (Cop* iswm $mta.skin($1,$2).name) {
     if (%a == -1) mta.msg $1 $2 Error - Absent ID/Name
     if (%a == $2) mta.msg $1 $2 Error - Can't suspect yourself
     else {
       !writeini " $+ $scriptdir $+ suspectlist.ini" List $mta.name($1,%a) 1
       mta.say $1 $mta.name($1,%a) has been added to the wanted list. Reason: $iif($5,$5-,None)
     }     
   }
   else mta.msg $1 $2 Sorry, you are not a cop.
 }
 elseif (!wanted == $3) {
   var %a = 0,%b
   while (%a <= $mta.maxplayers($1)) {
     if ($readini($scriptdir $+ suspectlist.ini,list,$mta.name($1,%a)) == 1) {
       if (!%b) %b = $mta.name($1,%a)
       elseif (%b) %b = %b $+ , $mta.name($1,%a)
     }
     inc %a
   }
   mta.say $1 Wanted Players: $iif(%b,%b,None)
 }
}
on *:SIGNAL:mta.kill:{
 if ($readini($scriptdir $+ suspectlist.ini,list,$mta.name($1,$2)) == 1) {
   if (Cop* iswm $mta.skin($1,$3).name) {
     mta.msg $1 $3 Killed a wanted player and u get 1000$ of his bounty.
     !remini " $+ $scriptdir $+ suspectlist.ini" List $mta.name($1,$2)
     !writeini rpg.ini cash $mta.name($1,$3) $calc($readini(rpg.ini,cash,$mta.name($1,$3)) + 1000)
   }
 }
}

only change the ini here

!writeini rpg.ini cash $mta.name($1,$3) $calc($readini(rpg.ini,cash,$mta.name($1,$3)) + 1000)

to the ini you use to store cash

Link to comment
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...