Jump to content
Autentificarea cu Google și Facebook nu mai este disponibilă. ×
  • 0

Nu stiu cum sa pun coordonatele, la sistem safe-zone


Question

Posted

Problema intalnita (descriere):Am un sistem safe-zone si nu stiu cum sa pun coordonatele, sa fie pe o raza de nu stiu cati metrii etc.. 
Ero(area / rile) / warning-(ul / urile):N-am erori/warning
Liniile de cod / sursa / script-ul(obligatoriu):

foreach(Player, i)
    {
        if(IsPlayerInArea(i, 1440.428, -1741.078, 1622.964, -1595.012)) // lspd
         {
             TextDrawShowForPlayer(i, SafeZone[i]);
        }
        else if(IsPlayerInArea(i, 371.8314, -2104.27, 455.4938, -1910.831)) // Fish
         {
             TextDrawShowForPlayer(i, SafeZone[i]);
        }
         else if(IsPlayerInArea(i, -280.269, -420.4035, 81.74512, -163.4902)) // trucker
         {
             TextDrawShowForPlayer(i, SafeZone[i]);
        }
        else if(IsPlayerInArea(i, 622.8186, -1405.52, 828.1717, -1330.513)) // cnn
         {
             TextDrawShowForPlayer(i, SafeZone[i]);
        }
        else if(IsPlayerInArea(i, 1622.0375, -2317.7219, 1824.515, -2313.4534)) // spawn & DMV
         {
             TextDrawShowForPlayer(i, SafeZone[i]);
        }
        else if(IsPlayerInArea(i, 1706.627, -1227.872, 1854.937, -1133.126)) // gsls
         {
             TextDrawShowForPlayer(i, SafeZone[i]);
        }
        else if(IsPlayerInArea(i, 1390.991, -1058.119, 1569.725, -951.5297)) // banca
         {
             TextDrawShowForPlayer(i, SafeZone[i]);
         }
         else
         {
             TextDrawHideForPlayer(i, SafeZone[i]);
         }
    }

Imagini / Video (optional):-
Ati incercat sa rezolvati singur?:Da normal

7 answers to this question

Recommended Posts

  • 0
Posted
IsPlayerInArea in loc de asta pune
IsPlayerInRangeOfPoint

Respect acestei comunitati, dar mai presus respect membrilor ei !

  • 0
Posted

IsPlayerInRangeOfPointforeach(Player, i)
    {
        if(IsPlayerInRangeOfPoint(i, 1440.428, -1741.078, 1622.964, -1595.012)) // lspd
         {
             TextDrawShowForPlayer(i, SafeZone);
        }
        else if(IsPlayerInRangeOfPoint(i, 371.8314, -2104.27, 455.4938, -1910.831)) // Fish
         {
             TextDrawShowForPlayer(i, SafeZone);
        }
         else if(IsPlayerInRangeOfPoint(i, -280.269, -420.4035, 81.74512, -163.4902)) // trucker
         {
             TextDrawShowForPlayer(i, SafeZone);
        }
        else if(IsPlayerInRangeOfPoint(i, 622.8186, -1405.52, 828.1717, -1330.513)) // cnn
         {
             TextDrawShowForPlayer(i, SafeZone);
        }
        else if(IsPlayerInRangeOfPoint(i, 1622.0375, -2317.7219, 1824.515, -2313.4534)) // spawn & DMV
         {
             TextDrawShowForPlayer(i, SafeZone);
        }
        else if(IsPlayerInRangeOfPoint(i, 1706.627, -1227.872, 1854.937, -1133.126)) // gsls
         {
             TextDrawShowForPlayer(i, SafeZone);
        }
        else if(IsPlayerInRangeOfPoint(i, 1390.991, -1058.119, 1569.725, -951.5297)) // banca
         {
             TextDrawShowForPlayer(i, SafeZone);
         }
         else
         {
             TextDrawHideForPlayer(i, SafeZone);
         }
    }

Pune asa

                               http://i.imgur.com/NOsIYWt.png

                     Respecta si vei fi respectat. :)

  • 0
Posted

Tu acolo aveai IsPlayerInArea, care folosea patru date de tip numar,

Acum dupa ce ai pus IsPlayerInRangeOffPoint  va trebui sa pui doar 3 date prima fiind distanta in metri faza de cele 3 coordonate,  in timp ce la "area" erau niste coordonate   x y x y   aici va trebui sa pui asa :  metri x y z . Va trebui sa le pui pe fiecare in parte pentru ca difera de celelalte.

 

 

    __  ____      __           
   /  |/  (_)____/ /____  _____
  / /|_/ / / ___/ __/ _ \/ ___/
 / /  / / (__  ) /_/  __/ /    
/_/  /_/_/____/\__/\___/_/     
SERVICII SCRIPTING DE CALITATE
Pagina     Scripting     pawn
Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.