Jump to content

Setplace Script Doesnt Work.


WestCoast

Recommended Posts

Hmm. I Made This Script. But When I Do:

!P (Point(s) Set.)

!S (Area Saved As )

!Area (Says The Location)

the problem is that when i do !p and save some points and then do !s to save area then it just says Vice-City :S

this is what i made:

on *:SIGNAL:mta.command: { 
 if (!clear == $3) { 
   !unset %area 
   mta.say $1 Area cleared. 
 }  
 if (!p == $3) { 
   %area = %area $+ $chr(44) $+ $round($mta.location($1,$2,x),4) $+ $chr(44) $+ $round($mta.location($1,$2,y),4) 
   mta.say $1 $calc($count(%area,$chr(44)) /2) point(s) set 
 }  
 if (!s == $3) { 
   var %a 
   if ($did(mta,$1 $+ 33) == GTA:3)  !writeini " $+ $scriptdirmta.data.ini" AREA1 $right(%area,-1) $4- 
   elseif ($did(mta,$1 $+ 22) == Stunt) !writeini " $+ $scriptdirmta.data.ini" AREA2 $right(%area,-1) $4- 
   else { 
     !writeini " $+ $scriptdirmta.data.ini" AREA2 $right(%area,-1) $4- 
     !writeini " $+ $scriptdirmta.data.ini" AREA3 $right(%area,-1) $4- 
   } 
   !unset %area 
   mta.say $1 Area saved as " $+ $4-" 
 } 
 if (!a == $3) { 
   mta.say $1 $mta.area($1,$2) 
 } 

Plz can someone help me.

it doesnt saves the area when i do !p and then !s :S

Link to comment

Man.. wtf, that script is not made by you.. That's Aeron's script :?

however try this

on *:SIGNAL:mta.command: {
 if (!clear == $3) {
   !unset %area
   mta.say $1 Area cleared.
 } 
 if (!p == $3) {
   %area = %area $+ $chr(44) $+ $round($mta.location($1,$2,x),4) $+ $chr(44) $+ $round($mta.location($1,$2,y),4)
   mta.say $1 $calc($count(%area,$chr(44)) /2) point(s) set
 } 
 if (!s == $3) {
   var %a
   if ($did(mta,$1 $+ 33) == GTA:3)  !writeini " $+ $mta.dir $+ mta.data.ini" AREA1 $right(%area,-1) $4-
   elseif ($did(mta,$1 $+ 22) == Stunt) !writeini " $+ $mta.dir $+ mta.data.ini" AREA2 $right(%area,-1) $4-
   else {
     !writeini " $+ $mta.dir $+ mta.data.ini" AREA2 $right(%area,-1) $4-
     !writeini " $+ $mta.dir $+ mta.data.ini" AREA3 $right(%area,-1) $4-
   }
   !unset %area
   mta.say $1 Area saved as " $+ $4-"
 }
 if (!a == $3) mta.say $1 $mta.area($1,$2)
}

Link to comment
  • Recently Browsing   0 members

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