Jump to content

problems problems and more god damn problems


Squall

Recommended Posts

i got this problem so the person who activated it is the only 1 to deactivate it but i think its wrong

on *:SIGNAL:mta.command: { 
 if ($3 == !alarm) { 
   if (($mta.vehicle($1,$2).name == foot) || ($mta.vehicle($1,$2).name == Unknown)) mta.msg $1 $2 Error - you need to be in a car 
   elseif ($4 == on) { 
     mta.say $1 Car Alarm Activated 
     !writeini " $+ $scriptdir $+ alarm.ini" alarm $mta.vehicle($1,$2) on 
   } 
   elseif ($4 == off) { 
     mta.say $1 Car Alarm DeActivated 
     !writeini " $+ $scriptdir $+ alarm.ini" alarm $mta.vehicle($1,$2) off 
   } 
 } 
} 
on *:SIGNAL:mta.enter:{ 
 if ($readini($scriptdir $+ alarm.ini,alarm,$mta.vehicle($1,$2)) == on) { 
   mta.say $1 $mta.name($1,$2) Has Triggered An Car Alarm 
   $+(.timer,$1,.,$2) 1 1 bla.kill $1 $2 
 } 
} 
on *:SIGNAL:mta.exit: { 
 $+(.timer,$1,.,$2) off 
} 
alias bla.kill .timer 1 0 mta.slap $1 $2

it hits me when i try and deactivate it

Link to comment
on *:SIGNAL:mta.command: { 
 if ($3 == !alarm) {
   %a = $readini($scriptdir $+ alarm.ini,alarm,$mta.vehicle($1,$2))  
   if (($mta.vehicle($1,$2).name == foot) || ($mta.vehicle($1,$2).name == Unknown)) mta.msg $1 $2 Error - you need to be in a car 
   elseif (($4 == on) && (%a == $null)) { 
     mta.say $1 Car Alarm Activated 
     !writeini " $+ $scriptdir $+ alarm.ini" alarm $mta.vehicle($1,$2) $mta.name($1,$2) 
   } 
   elseif (($4 == off) && (%a == $mta.name($1,$2)) { 
     mta.say $1 Car Alarm Deactivated 
     !remini " $+ $scriptdir $+ alarm.ini" alarm $mta.vehicle($1,$2) 
   } 
 } 
} 
on *:SIGNAL:mta.enter:{
 %a =  $readini($scriptdir $+ alarm.ini,alarm,$mta.vehicle($1,$2)) 
 if ((%a != $null) && (%a != $mta.name($1,$2)) { 
   mta.say $1 $mta.name($1,$2) Has triggered an car alarm 
   $+(!.timeralarm.,$1,.,$2) 1 1 mta.slap $1 $2
 } 
} 
on *:SIGNAL:mta.exit: { 
 $+(!.timeralarm.,$1,.,$2) off 
}

Link to comment
  • Recently Browsing   0 members

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