Vice City: Multiplayer

Server Development => Scripting and Server Management => Script and Content Requests => Topic started by: Pejson on Oct 31, 2016, 10:47 PM

Title: markes/blips on radar in close/near
Post by: Pejson on Oct 31, 2016, 10:47 PM
I need help. I need markes/blips on radar in close/near. If I am more than 100m it automatically hide.

I want only finished example and a working script.


Edit:

Someone can move topic here http://forum.vc-mp.org/?board=37.0
I noticed too late
Title: Re: markes/blips on radar in close/near
Post by: kennedyarz on Nov 02, 2016, 03:24 PM
I know what you really want. good and never tried it, but I think it is so.
1) should be something related to OnPlayerMove ... Example:

http://wiki.vc-mp.org/wiki/File:Polydiagram.png
create and destroy marker marker
Title: Re: markes/blips on radar in close/near
Post by: Luis_Labarca on Nov 02, 2016, 11:39 PM
function onScriptLoad()
{
Marker1 <- array(100, null );
}
function onPlayerStateChange( player, oldState, newState )
{
if(DistanceFromPoint( player.Pos.x, player.Pos.y,-945.305, 1332.61)<100)
{
if(Marker1[player.ID]==null)Marker1[player.ID]=CreateMarker(player.UniqueWorld, Vector(-945.305, 1332.61, 11.13463), 1, RGB(0, 0, 0),8);
}
if(DistanceFromPoint( player.Pos.x, player.Pos.y,-945.305, 1332.61)>100)
{
if(Marker1[player.ID]!=null)DestroyMarker(Marker1[player.ID]),Marker1[player.ID]=null;
}
}
@Pejson  ;)
Title: Re: markes/blips on radar in close/near
Post by: kennedyarz on Nov 03, 2016, 10:38 AM
mmm well that spoke