SA-MP Forums Archive
Detect vehicle entering pay n spray - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Detect vehicle entering pay n spray (/showthread.php?tid=604605)



Detect vehicle entering pay n spray - NeXoR - 07.04.2016

Is there a way to do it ?
I wan't to improve the mechanic system and allow PayNSpray fixing only when no mechs are available
Is there a way to detect it ?


Re: Detect vehicle entering pay n spray - Konstantinos - 07.04.2016

https://sampforum.blast.hk/showthread.php?tid=360865


Re: Detect vehicle entering pay n spray - NeXoR - 07.04.2016

Quote:
Originally Posted by Konstantinos
Посмотреть сообщение
Well I have a few vehicles that I have a vehicle upgrade system which you can buy 1500 HP to your vehicle ...
Is there any other way to detect ?

P.S:
Thanks


Re: Detect vehicle entering pay n spray - Doubdoud - 07.04.2016

Why you not just create some checkpoint in that garage, and make a system like this.

PHP код:
if (TotalMechPlayer 0)
{
    new 
VehicleID GetPlayerVehicleID(playerid);
    
RepairVehicle(VehicleID);
    
SendClientMessage(playerid0xFF0000AA"[SYSTEM] If you want to change your vehicle colour, ask to Mechanic.");
    return 
1;

i have try to get in pay&spray garage in SA-MP, it just fix the vehicle, not change the colour.


Re: Detect vehicle entering pay n spray - NeXoR - 07.04.2016

Quote:
Originally Posted by Ralfie
Посмотреть сообщение
Get every pay n spray, save its coords as a square and create a dynamic cuboid using streamer. The when someone enters this area the OnPlayerEnterDynamicArea callback is called.
There isn't any public for such thing ? Like OnPlayerEnterPayNSpray or something?


Re: Detect vehicle entering pay n spray - NeXoR - 07.04.2016

Anyone ?


Re: Detect vehicle entering pay n spray - Vanter - 07.04.2016

I'd just use
PHP код:
if(IsPlayerInRangeOfPoint(playerid5xyz)) 
and make the coordinates inside the pay n spray itself.

don't complicate things up


Re: Detect vehicle entering pay n spray - NeXoR - 08.04.2016

Quote:
Originally Posted by Vanter
Посмотреть сообщение
I'd just use
PHP код:
if(IsPlayerInRangeOfPoint(playerid5xyz)) 
and make the coordinates inside the pay n spray itself.

don't complicate things up
Yes I would use it
But how can I prevent the freeze and the garage door closing and the repair itself