PlayerToPoint
#1

Waddup Dawgs!

Okay, here's what I want.
As I made this boat dealership today, I want to make sure that people won't be able to park their boat the place where the boat spawns when you buy it. So I tried to add this to my /v park commando:
pawn Код:
if(!PlayerToPoint(40.0, playerid,-2234.5803,2468.9119,5.7422))
                {
                return SendClientMessage(playerid,COLOR_RED,"[WARNING]: You cannot park your vehicle here!");
                }
After what I understand about PlayerToPoint, this should make sure, that the is to the point, and if yes, only send the SendClientMessage, and not park the vehicle there. :P
But it doesn't. It doesn't even show the text when you park the vehicle there.
Anyone know how to do this?
Btw my forward:
pawn Код:
forward PlayerToPoint(Float:radi, playerid, Float:x, Float:y, Float:z);
Thanks in advance!

JaloNik =)
Reply
#2

pawn Код:
if(IsPlayerInRangeOfPoint(playerid,40.0,-2234.5803,2468.9119,5.7422)) return SendClientMessage(playerid,COLOR_RED,"[WARNING]: You cannot park your vehicle here!");
i would do it like this...
Reply
#3

Quote:
Originally Posted by selten98
Посмотреть сообщение
pawn Код:
if(IsPlayerInRangeOfPoint(playerid,40.0,-2234.5803,2468.9119,5.7422)) return SendClientMessage(playerid,COLOR_RED,"[WARNING]: You cannot park your vehicle here!");
i would do it like this...
This does create the text, but dosen't returns to 0, and still parks the vehicle? :S
Reply
#4

make a fence? xD or
maybe a samsite
Reply
#5

Quote:
Originally Posted by [DK]JaloNik
Посмотреть сообщение
This does create the text, but dosen't returns to 0, and still parks the vehicle? :S
Its the same as your code only that his code does it correclty

And I think that the radius is to big it has a diameter of 80.0 GTA-SA length units
Reply
#6

Quote:
Originally Posted by Nero_3D
Посмотреть сообщение
Its the same as your code only that his code does it correclty

And I think that the radius is to big it has a diameter of 80.0 GTA-SA length units
Yeah it's too big. :P I know. And I know that was the same code lulz.

@Lolrolf, you're might right.. :P Imma make some roof or smth lulz.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)