Fix blip duplication and name issue
This commit is contained in:
parent
52cc9b647c
commit
3a088ddbfc
@ -90,17 +90,17 @@ namespace RageCoop.Client
|
||||
{
|
||||
p.FakeBlip=World.CreateBlip(p.Position);
|
||||
}
|
||||
if (p.Position.DistanceTo(Main.PlayerPosition)>500)
|
||||
if (p.Character?.MainPed != null && p.Character.MainPed.Exists())
|
||||
{
|
||||
p.FakeBlip.Color=Scripting.API.Config.BlipColor;
|
||||
p.FakeBlip.Scale=Scripting.API.Config.BlipScale;
|
||||
p.FakeBlip.Sprite=Scripting.API.Config.BlipSprite;
|
||||
p.FakeBlip.DisplayType=BlipDisplayType.Default;
|
||||
p.FakeBlip.Position=p.Position;
|
||||
p.FakeBlip.DisplayType = BlipDisplayType.NoDisplay;
|
||||
}
|
||||
else
|
||||
{
|
||||
p.FakeBlip.DisplayType=BlipDisplayType.NoDisplay;
|
||||
p.FakeBlip.Color = Scripting.API.Config.BlipColor;
|
||||
p.FakeBlip.Scale = Scripting.API.Config.BlipScale;
|
||||
p.FakeBlip.Sprite = Scripting.API.Config.BlipSprite;
|
||||
p.FakeBlip.DisplayType = BlipDisplayType.Default;
|
||||
p.FakeBlip.Position = p.Position;
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -16,7 +16,7 @@ using System.Resources;
|
||||
|
||||
|
||||
// Version informationr(
|
||||
[assembly: AssemblyVersion("1.5.1.13")]
|
||||
[assembly: AssemblyFileVersion("1.5.1.13")]
|
||||
[assembly: AssemblyVersion("1.5.1.14")]
|
||||
[assembly: AssemblyFileVersion("1.5.1.14")]
|
||||
[assembly: NeutralResourcesLanguageAttribute( "en-US" )]
|
||||
|
||||
|
@ -115,7 +115,7 @@ namespace RageCoop.Client
|
||||
|
||||
internal override void Update()
|
||||
{
|
||||
if (Owner==null) { return; }
|
||||
if (Owner==null) { OwnerID=OwnerID;return; }
|
||||
if (IsPlayer)
|
||||
{
|
||||
RenderNameTag();
|
||||
@ -155,11 +155,7 @@ namespace RageCoop.Client
|
||||
{
|
||||
PedBlip=MainPed.AddBlip();
|
||||
|
||||
if (IsPlayer)
|
||||
{
|
||||
// Main.Logger.Debug("blip:"+Player.Username);
|
||||
Main.QueueAction(() => { PedBlip.Name=Owner.Username; });
|
||||
}
|
||||
|
||||
PedBlip.Color=BlipColor;
|
||||
PedBlip.Sprite=BlipSprite;
|
||||
PedBlip.Scale=BlipScale;
|
||||
@ -174,6 +170,10 @@ namespace RageCoop.Client
|
||||
{
|
||||
PedBlip.Sprite=BlipSprite;
|
||||
}
|
||||
if (IsPlayer && PedBlip.Name!=Owner.Username)
|
||||
{
|
||||
PedBlip.Name = Owner.Username;
|
||||
}
|
||||
}
|
||||
|
||||
if (!Clothes.SequenceEqual(_lastClothes))
|
||||
|
Loading…
x
Reference in New Issue
Block a user