blips for dealerships
This commit is contained in:
@@ -18,6 +18,8 @@ namespace ReallifeGamemode.Server.Business
|
||||
|
||||
public override float CarSpawnHeading => 356.6f;
|
||||
|
||||
public override int? BlipSprite => 307;
|
||||
|
||||
public override void Load()
|
||||
{
|
||||
|
||||
|
||||
@@ -17,6 +17,8 @@ namespace ReallifeGamemode.Server.Business
|
||||
|
||||
public override float CarSpawnHeading => 356.6f;
|
||||
|
||||
public override int? BlipSprite => 226;
|
||||
|
||||
public override void Load()
|
||||
{
|
||||
|
||||
|
||||
@@ -17,6 +17,8 @@ namespace ReallifeGamemode.Server.Business
|
||||
|
||||
public override float CarSpawnHeading => 356.6f;
|
||||
|
||||
public override int? BlipSprite => 410;
|
||||
|
||||
public override void Load()
|
||||
{
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
using GTANetworkAPI;
|
||||
using GTANetworkAPI;
|
||||
using ReallifeGamemode.Server.Entities;
|
||||
using ReallifeGamemode.Server.Extensions;
|
||||
using ReallifeGamemode.Server.Models;
|
||||
@@ -11,8 +11,13 @@ namespace ReallifeGamemode.Server.Business
|
||||
{
|
||||
private TextLabel _informationLabel;
|
||||
private ColShape _colShape;
|
||||
private Blip _blip;
|
||||
private Marker _marker;
|
||||
|
||||
public virtual int? BlipSprite { get; } = null;
|
||||
|
||||
public abstract int Id { get; }
|
||||
|
||||
public abstract string Name { get; }
|
||||
|
||||
public abstract Vector3 Position { get; }
|
||||
@@ -35,7 +40,12 @@ namespace ReallifeGamemode.Server.Business
|
||||
public void Setup()
|
||||
{
|
||||
_informationLabel = NAPI.TextLabel.CreateTextLabel(Name, Position.Add(new Vector3(0, 0, 0.5)), 20.0f, 1.3f, 0, new Color(255, 255, 255));
|
||||
NAPI.Marker.CreateMarker(MarkerType.VerticalCylinder, Position.Subtract(new Vector3(0, 0, 1.5)), new Vector3(), new Vector3(), 1f, new Color(255, 255, 255));
|
||||
_marker = NAPI.Marker.CreateMarker(MarkerType.VerticalCylinder, Position.Subtract(new Vector3(0, 0, 1.5)), new Vector3(), new Vector3(), 1f, new Color(255, 255, 255));
|
||||
|
||||
if (BlipSprite != null)
|
||||
{
|
||||
_blip = NAPI.Blip.CreateBlip(BlipSprite.Value, Position, 1f, 4, Name, shortRange: true);
|
||||
}
|
||||
|
||||
_colShape = NAPI.ColShape.CreateSphereColShape(Position.Subtract(new Vector3(0, 0, 1.5)), 3f);
|
||||
_colShape.OnEntityEnterColShape += EntityEnterBusinessColShape;
|
||||
|
||||
@@ -9,5 +9,7 @@ namespace ReallifeGamemode.Server.Business
|
||||
{
|
||||
public abstract Vector3 CarSpawnPositon { get; }
|
||||
public abstract float CarSpawnHeading { get; }
|
||||
|
||||
public override int? BlipSprite => 225;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -17,6 +17,8 @@ namespace ReallifeGamemode.Server.Business
|
||||
|
||||
public override float CarSpawnHeading => 356.6f;
|
||||
|
||||
public override int? BlipSprite => 43;
|
||||
|
||||
public override void Load()
|
||||
{
|
||||
|
||||
|
||||
Reference in New Issue
Block a user