Update to work with latest build of SHVDN
This commit is contained in:
21
Client/Loader/Console.cs
Normal file
21
Client/Loader/Console.cs
Normal file
@ -0,0 +1,21 @@
|
||||
using System;
|
||||
|
||||
namespace GTA
|
||||
{
|
||||
internal class Console
|
||||
{
|
||||
private static readonly SHVDN.Console console = AppDomain.CurrentDomain.GetData("Console") as SHVDN.Console;
|
||||
public static void Warning(object format, params object[] objects)
|
||||
{
|
||||
console.PrintInfo("[~o~WARNING~w~] ", format.ToString(), objects);
|
||||
}
|
||||
public static void Error(object format, params object[] objects)
|
||||
{
|
||||
console.PrintError("[~r~ERROR~w~] ", format.ToString(), objects);
|
||||
}
|
||||
public static void Info(object format, params object[] objects)
|
||||
{
|
||||
console.PrintWarning("[~b~INFO~w~] ", format.ToString(), objects);
|
||||
}
|
||||
}
|
||||
}
|
@ -51,50 +51,40 @@ namespace RageCoop.Client.Loader
|
||||
{
|
||||
dir = Path.GetFullPath(dir).ToLower();
|
||||
Directory.CreateDirectory(dir);
|
||||
Exception e = null;
|
||||
// Load domain in main thread
|
||||
Main.QueueToMainThread(() =>
|
||||
|
||||
// Delete API assemblies
|
||||
Directory.GetFiles(dir, "ScriptHookVDotNet*", SearchOption.AllDirectories).ToList()
|
||||
.ForEach(x => File.Delete(x));
|
||||
|
||||
|
||||
newDomain = ScriptDomain.Load(
|
||||
Directory.GetParent(typeof(ScriptDomain).Assembly.Location).FullName, dir);
|
||||
|
||||
newDomain.AppDomain.SetData("Primary", ScriptDomain.CurrentDomain);
|
||||
|
||||
newDomain.AppDomain.SetData("Console",
|
||||
ScriptDomain.CurrentDomain.AppDomain.GetData("Console"));
|
||||
|
||||
// Copy to target domain base directory
|
||||
// Delete loader assembly
|
||||
var loaderPath = Path.Combine(dir, Path.GetFileName(typeof(LoaderContext).Assembly.Location));
|
||||
if (File.Exists(loaderPath))
|
||||
{
|
||||
try
|
||||
{
|
||||
/*
|
||||
var assemblies = new List<string>();
|
||||
assemblies.Add(typeof(DomainLoader).Assembly.Location);
|
||||
assemblies.AddRange(typeof(DomainLoader).Assembly.GetReferencedAssemblies()
|
||||
.Select(x => Assembly.Load(x.FullName).Location)
|
||||
.Where(x => !string.IsNullOrEmpty(x)));
|
||||
*/
|
||||
File.Delete(loaderPath);
|
||||
}
|
||||
|
||||
// Delete API assemblies
|
||||
Directory.GetFiles(dir, "ScriptHookVDotNet*", SearchOption.AllDirectories).ToList()
|
||||
.ForEach(x => File.Delete(x));
|
||||
var ctxAsm = Path.Combine(dir, "RageCoop.Client.Loader.dll");
|
||||
if (File.Exists(ctxAsm)) File.Delete(ctxAsm);
|
||||
var context = (LoaderContext)newDomain.AppDomain.CreateInstanceFromAndUnwrap(
|
||||
typeof(LoaderContext).Assembly.Location,
|
||||
typeof(LoaderContext).FullName, false,
|
||||
BindingFlags.Instance | BindingFlags.NonPublic,
|
||||
null,
|
||||
new object[] { }
|
||||
, null, null);
|
||||
|
||||
newDomain = ScriptDomain.Load(
|
||||
Directory.GetParent(typeof(ScriptDomain).Assembly.Location).FullName, dir);
|
||||
newDomain.AppDomain.SetData("Primary", ScriptDomain.CurrentDomain);
|
||||
newDomain.AppDomain.SetData("Console",
|
||||
ScriptDomain.CurrentDomain.AppDomain.GetData("Console"));
|
||||
var context = (LoaderContext)newDomain.AppDomain.CreateInstanceFromAndUnwrap(
|
||||
typeof(LoaderContext).Assembly.Location,
|
||||
typeof(LoaderContext).FullName, false,
|
||||
BindingFlags.Instance | BindingFlags.NonPublic,
|
||||
null,
|
||||
new object[] { }
|
||||
, null, null);
|
||||
newDomain.AppDomain.SetData("RageCoop.Client.LoaderContext", context);
|
||||
newDomain.Start();
|
||||
_loadedDomains.TryAdd(dir, context);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
e = ex;
|
||||
}
|
||||
});
|
||||
// Wait till next tick
|
||||
Script.Yield();
|
||||
if (e != null) throw e;
|
||||
newDomain.AppDomain.SetData("RageCoop.Client.LoaderContext", context);
|
||||
newDomain.Start();
|
||||
|
||||
_loadedDomains.TryAdd(dir, context);
|
||||
return _loadedDomains[dir];
|
||||
}
|
||||
catch (Exception ex)
|
||||
@ -107,37 +97,55 @@ namespace RageCoop.Client.Loader
|
||||
}
|
||||
}
|
||||
|
||||
private static Assembly ResolveLoader(object sender, ResolveEventArgs args)
|
||||
{
|
||||
Log.Message(Log.Level.Debug, "resolving assembly " + args.Name);
|
||||
if (args.Name == typeof(LoaderContext).Assembly.GetName().Name) return typeof(LoaderContext).Assembly;
|
||||
return null;
|
||||
}
|
||||
|
||||
public static void Unload(LoaderContext domain)
|
||||
{
|
||||
lock (_loadedDomains)
|
||||
{
|
||||
Exception ex = null;
|
||||
var name = domain.CurrentDomain.Name;
|
||||
Console.Info("Unloading domain: " + name);
|
||||
Main.QueueToMainThread(() =>
|
||||
{
|
||||
try
|
||||
{
|
||||
if (!_loadedDomains.TryRemove(domain.BaseDirectory.ToLower(), out _))
|
||||
throw new Exception("Failed to remove domain from list");
|
||||
domain.Dispose();
|
||||
ScriptDomain.Unload(domain.CurrentDomain);
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
ex = e;
|
||||
Notification.Show(ex.ToString());
|
||||
}
|
||||
});
|
||||
Script.Yield();
|
||||
if (ex != null) throw ex;
|
||||
if (!_loadedDomains.TryRemove(domain.BaseDirectory.ToLower(), out _))
|
||||
throw new Exception("Failed to remove domain from list");
|
||||
domain.Dispose();
|
||||
ScriptDomain.Unload(domain.CurrentDomain);
|
||||
Console.Info("Unloaded domain: " + name);
|
||||
}
|
||||
}
|
||||
|
||||
public static void Unload(string dir)
|
||||
{
|
||||
Unload(_loadedDomains[Path.GetFullPath(dir).ToLower()]);
|
||||
lock (_loadedDomains)
|
||||
{
|
||||
Unload(_loadedDomains[Path.GetFullPath(dir).ToLower()]);
|
||||
}
|
||||
}
|
||||
|
||||
public static void TickAll()
|
||||
{
|
||||
lock (_loadedDomains)
|
||||
{
|
||||
foreach (var c in _loadedDomains.Values)
|
||||
{
|
||||
c.DoTick();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static void KeyEventAll(Keys keys, bool status)
|
||||
{
|
||||
lock (_loadedDomains)
|
||||
{
|
||||
foreach (var c in _loadedDomains.Values)
|
||||
{
|
||||
c.DoKeyEvent(keys, status);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static void UnloadAll()
|
||||
@ -152,11 +160,19 @@ namespace RageCoop.Client.Loader
|
||||
|
||||
#region LOAD-CONTEXT
|
||||
|
||||
private readonly Action _domainDoTick;
|
||||
private readonly Action<Keys, bool> _domainDoKeyEvent;
|
||||
private LoaderContext()
|
||||
{
|
||||
AppDomain.CurrentDomain.DomainUnload += (s, e) => Dispose();
|
||||
PrimaryDomain.Tick += Tick;
|
||||
PrimaryDomain.KeyEvent += KeyEvent;
|
||||
|
||||
var tickMethod = typeof(ScriptDomain).GetMethod("DoTick", BindingFlags.Instance | BindingFlags.NonPublic);
|
||||
var doKeyEventMethod = typeof(ScriptDomain).GetMethod("DoKeyEvent", BindingFlags.Instance | BindingFlags.NonPublic);
|
||||
|
||||
// Create delegates to avoid using reflection to call method each time, which is slow
|
||||
_domainDoTick = (Action)Delegate.CreateDelegate(typeof(Action), CurrentDomain, tickMethod);
|
||||
_domainDoKeyEvent = (Action<Keys, bool>)Delegate.CreateDelegate(typeof(Action<Keys, bool>), CurrentDomain, doKeyEventMethod);
|
||||
|
||||
Console.Info(
|
||||
$"Loaded domain: {AppDomain.CurrentDomain.FriendlyName}, {AppDomain.CurrentDomain.BaseDirectory}");
|
||||
}
|
||||
@ -164,7 +180,7 @@ namespace RageCoop.Client.Loader
|
||||
public static ScriptDomain PrimaryDomain => AppDomain.CurrentDomain.GetData("Primary") as ScriptDomain;
|
||||
|
||||
public static LoaderContext CurrentContext =>
|
||||
AppDomain.CurrentDomain.GetData("RageCoop.Client.LoaderContext") as LoaderContext;
|
||||
(LoaderContext)AppDomain.CurrentDomain.GetData("RageCoop.Client.LoaderContext");
|
||||
|
||||
/// <summary>
|
||||
/// Request the current domain to be unloaded
|
||||
@ -173,33 +189,21 @@ namespace RageCoop.Client.Loader
|
||||
{
|
||||
if (PrimaryDomain == null)
|
||||
throw new NotSupportedException(
|
||||
"Current domain not loaded by the loader therfore cannot be unloaded automatically");
|
||||
"Current domain not loaded by the loader therefore cannot be unloaded automatically");
|
||||
CurrentContext.UnloadRequested = true;
|
||||
}
|
||||
|
||||
private void Tick()
|
||||
{
|
||||
CurrentDomain.DoTick();
|
||||
}
|
||||
public override object InitializeLifetimeService() => null;
|
||||
|
||||
private void KeyEvent(Keys keys, bool status)
|
||||
{
|
||||
CurrentDomain.DoKeyEvent(keys, status);
|
||||
}
|
||||
public void DoTick() => _domainDoTick();
|
||||
|
||||
public override object InitializeLifetimeService()
|
||||
{
|
||||
// Return null to avoid lifetime restriction on the marshaled object.
|
||||
return null;
|
||||
}
|
||||
public void DoKeyEvent(Keys key, bool status) => _domainDoKeyEvent(key, status);
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
lock (this)
|
||||
{
|
||||
if (PrimaryDomain == null) return;
|
||||
PrimaryDomain.Tick -= Tick;
|
||||
PrimaryDomain.KeyEvent -= KeyEvent;
|
||||
AppDomain.CurrentDomain.SetData("Primary", null);
|
||||
}
|
||||
}
|
||||
|
@ -2,6 +2,7 @@
|
||||
using System.Collections.Concurrent;
|
||||
using System.IO;
|
||||
using System.Threading;
|
||||
using System.Windows.Forms;
|
||||
using GTA;
|
||||
using GTA.UI;
|
||||
using SHVDN;
|
||||
@ -10,26 +11,26 @@ using Script = GTA.Script;
|
||||
|
||||
namespace RageCoop.Client.Loader
|
||||
{
|
||||
[ScriptAttributes(Author = "RageCoop", NoScriptThread = true,
|
||||
SupportURL = "https://github.com/RAGECOOP/RAGECOOP-V")]
|
||||
public class Main : Script
|
||||
{
|
||||
private static readonly string GameDir = Directory.GetParent(typeof(ScriptDomain).Assembly.Location).FullName;
|
||||
private static readonly string ScriptsLocation = Path.Combine(GameDir, "RageCoop", "Scripts");
|
||||
private static readonly ConcurrentQueue<Action> TaskQueue = new ConcurrentQueue<Action>();
|
||||
private static int MainThreadID;
|
||||
private bool _loaded;
|
||||
|
||||
public Main()
|
||||
{
|
||||
if (LoaderContext.PrimaryDomain != null)
|
||||
throw new InvalidOperationException(
|
||||
"Improperly placed loader assembly, please re-install to fix this issue");
|
||||
if (LoaderContext.PrimaryDomain != null) return;
|
||||
Tick += OnTick;
|
||||
ScriptDomain.CurrentDomain.Tick += DomainTick;
|
||||
KeyDown += (s, e) => LoaderContext.KeyEventAll(e.KeyCode, true);
|
||||
KeyUp += (s, e) => LoaderContext.KeyEventAll(e.KeyCode, false);
|
||||
Aborted += (s, e) => LoaderContext.UnloadAll();
|
||||
}
|
||||
|
||||
private void OnTick(object sender, EventArgs e)
|
||||
{
|
||||
while (Game.IsLoading) Yield();
|
||||
if (!_loaded) { _loaded = !Game.IsLoading; return; }
|
||||
LoaderContext.CheckForUnloadRequest();
|
||||
if (!LoaderContext.IsLoaded(ScriptsLocation))
|
||||
{
|
||||
@ -37,32 +38,11 @@ namespace RageCoop.Client.Loader
|
||||
{
|
||||
Notification.Show("~r~Main assembly is missing, please re-install the client");
|
||||
Abort();
|
||||
return;
|
||||
}
|
||||
|
||||
LoaderContext.Load(ScriptsLocation);
|
||||
}
|
||||
}
|
||||
|
||||
internal static void QueueToMainThread(Action task)
|
||||
{
|
||||
if (Thread.CurrentThread.ManagedThreadId != MainThreadID)
|
||||
TaskQueue.Enqueue(task);
|
||||
else
|
||||
task();
|
||||
}
|
||||
|
||||
private static void DomainTick()
|
||||
{
|
||||
if (MainThreadID == default) MainThreadID = Thread.CurrentThread.ManagedThreadId;
|
||||
while (TaskQueue.TryDequeue(out var task))
|
||||
try
|
||||
{
|
||||
task.Invoke();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Console.Error(ex.ToString());
|
||||
}
|
||||
LoaderContext.TickAll();
|
||||
}
|
||||
}
|
||||
}
|
@ -30,12 +30,14 @@
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="ScriptHookVDotNet">
|
||||
<HintPath>..\..\libs\ScriptHookVDotNet.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="ScriptHookVDotNet3">
|
||||
<Reference Include="ScriptHookVDotNet3, Version=3.5.1.0, Culture=neutral, processorArchitecture=MSIL">
|
||||
<SpecificVersion>True</SpecificVersion>
|
||||
<HintPath>..\..\libs\ScriptHookVDotNet3.dll</HintPath>
|
||||
</Reference>
|
||||
|
||||
<Reference Include="ScriptHookVDotNet">
|
||||
<HintPath>..\..\libs\ScriptHookVDotNet.asi</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
@ -47,6 +49,7 @@
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Console.cs" />
|
||||
<Compile Include="LoaderContext.cs" />
|
||||
<Compile Include="Main.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
|
24
Client/Scripts/Console.cs
Normal file
24
Client/Scripts/Console.cs
Normal file
@ -0,0 +1,24 @@
|
||||
using System;
|
||||
|
||||
namespace GTA
|
||||
{
|
||||
/// <summary>
|
||||
/// Wrapper that provides access to SHVDN's in-game console
|
||||
/// </summary>
|
||||
public class Console
|
||||
{
|
||||
private static SHVDN.Console console => (SHVDN.Console)AppDomain.CurrentDomain.GetData("Console");
|
||||
public static void Warning(object format, params object[] objects)
|
||||
{
|
||||
console.PrintInfo("[~o~WARNING~w~] ", format.ToString(), objects);
|
||||
}
|
||||
public static void Error(object format, params object[] objects)
|
||||
{
|
||||
console.PrintError("[~r~ERROR~w~] ", format.ToString(), objects);
|
||||
}
|
||||
public static void Info(object format, params object[] objects)
|
||||
{
|
||||
console.PrintWarning("[~b~INFO~w~] ", format.ToString(), objects);
|
||||
}
|
||||
}
|
||||
}
|
@ -40,7 +40,7 @@ namespace RageCoop.Client.GUI
|
||||
if (ActiveClient != null)
|
||||
{
|
||||
Game.DisableAllControlsThisFrame();
|
||||
Function.Call(Hash._SET_MOUSE_CURSOR_ACTIVE_THIS_FRAME);
|
||||
Function.Call(Hash.SET_MOUSE_CURSOR_THIS_FRAME);
|
||||
ActiveClient.Tick();
|
||||
}
|
||||
}
|
||||
|
@ -28,7 +28,7 @@ namespace RageCoop.Client
|
||||
/// <summary>
|
||||
/// Don't use it!
|
||||
/// </summary>
|
||||
[ScriptAttributes(Author = "RageCoop", NoDefaultInstance = false,
|
||||
[ScriptAttributes(Author = "RageCoop", NoScriptThread = true,
|
||||
SupportURL = "https://github.com/RAGECOOP/RAGECOOP-V")]
|
||||
internal class Main : Script
|
||||
{
|
||||
@ -61,8 +61,6 @@ namespace RageCoop.Client
|
||||
Util.StartUpCheck();
|
||||
|
||||
Directory.CreateDirectory(DataPath);
|
||||
Console.Info(
|
||||
$"Starting {typeof(Main).FullName}, domain: {AppDomain.CurrentDomain.Id} {AppDomain.CurrentDomain.FriendlyName}");
|
||||
try
|
||||
{
|
||||
Settings = Util.ReadSettings();
|
||||
@ -104,7 +102,6 @@ namespace RageCoop.Client
|
||||
break;
|
||||
}
|
||||
};
|
||||
ScriptDomain.CurrentDomain.Tick += DomainTick;
|
||||
Resources = new Resources();
|
||||
if (Game.Version < GameVersion.v1_0_1290_1_Steam)
|
||||
{
|
||||
@ -123,7 +120,9 @@ namespace RageCoop.Client
|
||||
};
|
||||
return;
|
||||
}
|
||||
|
||||
Logger.Info(
|
||||
$"Starting {typeof(Main).FullName}, domain: {AppDomain.CurrentDomain.Id} {AppDomain.CurrentDomain.FriendlyName}");
|
||||
|
||||
BaseScript.OnStart();
|
||||
SyncedPedsGroup = World.AddRelationshipGroup("SYNCPED");
|
||||
Game.Player.Character.RelationshipGroup.SetRelationshipBetweenGroups(SyncedPedsGroup, Relationship.Neutral,
|
||||
@ -146,7 +145,6 @@ namespace RageCoop.Client
|
||||
{
|
||||
WorldThread.Instance?.Abort();
|
||||
DevTool.Instance?.Abort();
|
||||
ScriptDomain.CurrentDomain.Tick -= DomainTick;
|
||||
CleanUp("Abort");
|
||||
WorldThread.DoQueuedActions();
|
||||
}
|
||||
@ -155,34 +153,6 @@ namespace RageCoop.Client
|
||||
Logger.Error(ex);
|
||||
}
|
||||
}
|
||||
|
||||
private static void DomainTick()
|
||||
{
|
||||
while (TaskQueue.TryDequeue(out var task))
|
||||
{
|
||||
try
|
||||
{
|
||||
task.Invoke();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Logger.Error(ex);
|
||||
}
|
||||
}
|
||||
|
||||
if (Networking.IsOnServer)
|
||||
{
|
||||
try
|
||||
{
|
||||
EntityPool.DoSync();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Logger.Error(ex);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Queue an action to main thread and wait for execution to complete, must be called from script thread.
|
||||
/// </summary>
|
||||
@ -225,9 +195,17 @@ namespace RageCoop.Client
|
||||
#endif
|
||||
}
|
||||
|
||||
#if !NON_INTERACTIVE
|
||||
CoopMenu.MenuPool.Process();
|
||||
#endif
|
||||
while (TaskQueue.TryDequeue(out var task))
|
||||
{
|
||||
try
|
||||
{
|
||||
task.Invoke();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Logger.Error(ex);
|
||||
}
|
||||
}
|
||||
|
||||
if (CefRunning)
|
||||
{
|
||||
@ -239,7 +217,16 @@ namespace RageCoop.Client
|
||||
return;
|
||||
}
|
||||
|
||||
if (Game.TimeScale != 1)
|
||||
try
|
||||
{
|
||||
EntityPool.DoSync();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Logger.Error(ex);
|
||||
}
|
||||
|
||||
if (Game.TimeScale != 1.0f)
|
||||
{
|
||||
Game.TimeScale = 1;
|
||||
}
|
||||
@ -248,13 +235,13 @@ namespace RageCoop.Client
|
||||
{
|
||||
new ScaledText(new PointF(Screen.PrimaryScreen.Bounds.Width / 2, 0),
|
||||
$"L: {Networking.Latency * 1000:N0}ms", 0.5f)
|
||||
{ Alignment = Alignment.Center }.Draw();
|
||||
{ Alignment = Alignment.Center }.Draw();
|
||||
new ScaledText(new PointF(Screen.PrimaryScreen.Bounds.Width / 2, 30),
|
||||
$"R: {NetUtility.ToHumanReadable(Statistics.BytesDownPerSecond)}/s", 0.5f)
|
||||
{ Alignment = Alignment.Center }.Draw();
|
||||
{ Alignment = Alignment.Center }.Draw();
|
||||
new ScaledText(new PointF(Screen.PrimaryScreen.Bounds.Width / 2, 60),
|
||||
$"S: {NetUtility.ToHumanReadable(Statistics.BytesUpPerSecond)}/s", 0.5f)
|
||||
{ Alignment = Alignment.Center }.Draw();
|
||||
{ Alignment = Alignment.Center }.Draw();
|
||||
}
|
||||
|
||||
MainChat.Tick();
|
||||
|
@ -34,6 +34,7 @@
|
||||
<PropertyGroup Condition="'$(Configuration)' == 'Release'">
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Console.cs" />
|
||||
<Compile Include="Debug.cs" />
|
||||
<Compile Include="DevTools\DevTool.cs" />
|
||||
<Compile Include="GUI\CefClient.cs" />
|
||||
|
@ -49,7 +49,7 @@ namespace RageCoop.Client.Scripting
|
||||
var weather1 = default(int);
|
||||
var weather2 = default(int);
|
||||
var percent2 = default(float);
|
||||
Function.Call(Hash._GET_WEATHER_TYPE_TRANSITION, &weather1, &weather2, &percent2);
|
||||
Function.Call(Hash.GET_CURR_WEATHER_STATE, &weather1, &weather2, &percent2);
|
||||
API.SendCustomEvent(CustomEvents.WeatherTimeSync, time.Hours, time.Minutes,
|
||||
time.Seconds, weather1, weather2, percent2);
|
||||
}
|
||||
@ -63,7 +63,7 @@ namespace RageCoop.Client.Scripting
|
||||
private static void WeatherTimeSync(CustomEventReceivedArgs e)
|
||||
{
|
||||
World.CurrentTimeOfDay = new TimeSpan((int)e.Args[0], (int)e.Args[1], (int)e.Args[2]);
|
||||
Function.Call(Hash._SET_WEATHER_TYPE_TRANSITION, (int)e.Args[3], (int)e.Args[4], (float)e.Args[5]);
|
||||
Function.Call(Hash.SET_CURR_WEATHER_STATE, (int)e.Args[3], (int)e.Args[4], (float)e.Args[5]);
|
||||
}
|
||||
|
||||
private static void SetDisplayNameTag(CustomEventReceivedArgs e)
|
||||
|
@ -216,7 +216,7 @@ namespace RageCoop.Client
|
||||
Function.Call(Hash.SET_PED_CAN_BE_TARGETTED_BY_PLAYER, MainPed.Handle, Game.Player, true);
|
||||
Function.Call(Hash.SET_PED_GET_OUT_UPSIDE_DOWN_VEHICLE, MainPed.Handle, false);
|
||||
Function.Call(Hash.SET_CAN_ATTACK_FRIENDLY, MainPed.Handle, true, true);
|
||||
Function.Call(Hash._SET_PED_CAN_PLAY_INJURED_ANIMS, false);
|
||||
// Function.Call(Hash._SET_PED_CAN_PLAY_INJURED_ANIMS, false);
|
||||
Function.Call(Hash.SET_PED_CAN_EVASIVE_DIVE, MainPed.Handle, false);
|
||||
|
||||
MainPed.SetConfigFlag((int)PedConfigFlags.CPED_CONFIG_FLAG_DrownsInWater, false);
|
||||
|
@ -89,11 +89,11 @@ namespace RageCoop.Client
|
||||
if (HasRoof && MainVehicle.RoofState != RoofState) MainVehicle.RoofState = RoofState;
|
||||
|
||||
if (HasRocketBoost && Flags.HasFlag(VehicleDataFlags.IsRocketBoostActive) !=
|
||||
MainVehicle.IsRocketBoostActive())
|
||||
MainVehicle.SetRocketBoostActive(Flags.HasFlag(VehicleDataFlags.IsRocketBoostActive));
|
||||
if (HasParachute && Flags.HasFlag(VehicleDataFlags.IsParachuteActive) !=
|
||||
MainVehicle.IsParachuteActive())
|
||||
MainVehicle.SetParachuteActive(Flags.HasFlag(VehicleDataFlags.IsParachuteActive));
|
||||
MainVehicle.IsRocketBoostActive)
|
||||
MainVehicle.IsRocketBoostActive = Flags.HasFlag(VehicleDataFlags.IsRocketBoostActive);
|
||||
if (HasParachute && Flags.HasFlag(VehicleDataFlags.IsParachuteActive) &&
|
||||
!MainVehicle.IsParachuteDeployed)
|
||||
MainVehicle.StartParachuting(false);
|
||||
if (IsSubmarineCar)
|
||||
{
|
||||
if (Transformed)
|
||||
@ -101,13 +101,13 @@ namespace RageCoop.Client
|
||||
if (!_lastTransformed)
|
||||
{
|
||||
_lastTransformed = true;
|
||||
Function.Call(Hash._TRANSFORM_VEHICLE_TO_SUBMARINE, MainVehicle.Handle, false);
|
||||
Function.Call(Hash.TRANSFORM_TO_SUBMARINE, MainVehicle.Handle, false);
|
||||
}
|
||||
}
|
||||
else if (_lastTransformed)
|
||||
{
|
||||
_lastTransformed = false;
|
||||
Function.Call(Hash._TRANSFORM_SUBMARINE_TO_VEHICLE, MainVehicle.Handle, false);
|
||||
Function.Call(Hash.TRANSFORM_TO_CAR, MainVehicle.Handle, false);
|
||||
}
|
||||
}
|
||||
else if (IsDeluxo)
|
||||
|
@ -29,7 +29,7 @@ namespace RageCoop.Client
|
||||
|
||||
if (Function.Call<bool>(Hash.IS_HORN_ACTIVE, veh.Handle)) flags |= VehicleDataFlags.IsHornActive;
|
||||
|
||||
if (v.IsSubmarineCar && Function.Call<bool>(Hash._GET_IS_SUBMARINE_VEHICLE_TRANSFORMED, veh.Handle))
|
||||
if (v.IsSubmarineCar && Function.Call<bool>(Hash.IS_VEHICLE_IN_SUBMARINE_MODE, veh.Handle))
|
||||
flags |= VehicleDataFlags.IsTransformed;
|
||||
|
||||
if (v.IsAircraft) flags |= VehicleDataFlags.IsAircraft;
|
||||
@ -38,35 +38,15 @@ namespace RageCoop.Client
|
||||
|
||||
if (v.HasRoof) flags |= VehicleDataFlags.HasRoof;
|
||||
|
||||
if (v.HasRocketBoost && veh.IsRocketBoostActive()) flags |= VehicleDataFlags.IsRocketBoostActive;
|
||||
if (v.HasRocketBoost && veh.IsRocketBoostActive) flags |= VehicleDataFlags.IsRocketBoostActive;
|
||||
|
||||
if (v.HasParachute && veh.IsParachuteActive()) flags |= VehicleDataFlags.IsParachuteActive;
|
||||
if (v.HasParachute && veh.IsParachuteDeployed) flags |= VehicleDataFlags.IsParachuteActive;
|
||||
|
||||
if (veh.IsOnFire) flags |= VehicleDataFlags.IsOnFire;
|
||||
|
||||
return flags;
|
||||
}
|
||||
|
||||
public static bool IsRocketBoostActive(this Vehicle veh)
|
||||
{
|
||||
return Function.Call<bool>(Hash._IS_VEHICLE_ROCKET_BOOST_ACTIVE, veh);
|
||||
}
|
||||
|
||||
public static bool IsParachuteActive(this Vehicle veh)
|
||||
{
|
||||
return Function.Call<bool>((Hash)0x3DE51E9C80B116CF, veh);
|
||||
}
|
||||
|
||||
public static void SetRocketBoostActive(this Vehicle veh, bool toggle)
|
||||
{
|
||||
Function.Call(Hash._SET_VEHICLE_ROCKET_BOOST_ACTIVE, veh, toggle);
|
||||
}
|
||||
|
||||
public static void SetParachuteActive(this Vehicle veh, bool toggle)
|
||||
{
|
||||
Function.Call((Hash)0x0BFFB028B3DD0A97, veh, toggle);
|
||||
}
|
||||
|
||||
public static Dictionary<int, int> GetVehicleMods(this VehicleModCollection mods)
|
||||
{
|
||||
var result = new Dictionary<int, int>();
|
||||
@ -170,7 +150,7 @@ namespace RageCoop.Client
|
||||
|
||||
public static void SetDeluxoHoverState(this Vehicle deluxo, bool hover)
|
||||
{
|
||||
Function.Call(Hash._SET_VEHICLE_HOVER_TRANSFORM_PERCENTAGE, deluxo, hover ? 1f : 0f);
|
||||
Function.Call(Hash.SET_SPECIAL_FLIGHT_MODE_TARGET_RATIO, deluxo, hover ? 1f : 0f);
|
||||
}
|
||||
|
||||
public static bool IsDeluxoHovering(this Vehicle deluxo)
|
||||
@ -180,7 +160,7 @@ namespace RageCoop.Client
|
||||
|
||||
public static void SetDeluxoWingRatio(this Vehicle v, float ratio)
|
||||
{
|
||||
Function.Call(Hash._SET_SPECIALFLIGHT_WING_RATIO, v, ratio);
|
||||
Function.Call(Hash.SET_HOVER_MODE_WING_RATIO, v, ratio);
|
||||
}
|
||||
|
||||
public static float GetDeluxoWingRatio(this Vehicle v)
|
||||
@ -190,7 +170,7 @@ namespace RageCoop.Client
|
||||
|
||||
public static float GetNozzleAngel(this Vehicle plane)
|
||||
{
|
||||
return Function.Call<float>(Hash._GET_VEHICLE_FLIGHT_NOZZLE_POSITION, plane);
|
||||
return Function.Call<float>(Hash.GET_VEHICLE_FLIGHT_NOZZLE_POSITION, plane);
|
||||
}
|
||||
|
||||
public static bool HasNozzle(this Vehicle v)
|
||||
|
@ -5,6 +5,7 @@ using System.Threading.Tasks;
|
||||
using GTA;
|
||||
using GTA.Native;
|
||||
using GTA.UI;
|
||||
using RageCoop.Client.Menus;
|
||||
|
||||
namespace RageCoop.Client
|
||||
{
|
||||
@ -33,8 +34,19 @@ namespace RageCoop.Client
|
||||
|
||||
private void OnTick(object sender, EventArgs e)
|
||||
{
|
||||
DoQueuedActions();
|
||||
if (Game.IsLoading || !Networking.IsOnServer) return;
|
||||
if (Game.IsLoading) return;
|
||||
|
||||
try
|
||||
{
|
||||
CoopMenu.MenuPool.Process();
|
||||
DoQueuedActions();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Main.Logger.Error(ex);
|
||||
}
|
||||
|
||||
if (!Networking.IsOnServer) return;
|
||||
|
||||
Game.DisableControlThisFrame(Control.FrontendPause);
|
||||
|
||||
|
@ -102,7 +102,7 @@ namespace RageCoop.Core
|
||||
}
|
||||
|
||||
#region ===== VEHICLE DATA =====
|
||||
|
||||
[Flags]
|
||||
internal enum VehicleDataFlags : ushort
|
||||
{
|
||||
None = 0,
|
||||
|
@ -15,7 +15,7 @@ using System.Resources;
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Version information
|
||||
[assembly: AssemblyVersion("1.6.0.11")]
|
||||
[assembly: AssemblyFileVersion("1.6.0.11")]
|
||||
[assembly: AssemblyVersion("1.6.0.20")]
|
||||
[assembly: AssemblyFileVersion("1.6.0.20")]
|
||||
[assembly: NeutralResourcesLanguageAttribute( "en-US" )]
|
||||
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -4,6 +4,11 @@
|
||||
<name>ScriptHookVDotNet3</name>
|
||||
</assembly>
|
||||
<members>
|
||||
<member name="T:GTA.EulerRotationOrder">
|
||||
<summary>
|
||||
Enums for the order in which to apply rotations in local space, just like how Rockstar Games define <c>EULER_ROT_ORDER</c>.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="T:GTA.Math.Matrix">
|
||||
<summary>
|
||||
Defines a 4x4 matrix.
|
||||
@ -20990,6 +20995,141 @@
|
||||
Gets the native representation of this <see cref="T:GTA.RelationshipGroup"/>.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:GTA.TaskInvoker.StartVehicleMission(GTA.Vehicle,GTA.Vehicle,GTA.VehicleMissionType,System.Single,GTA.VehicleDrivingFlags,System.Single,System.Single,System.Boolean)">
|
||||
<summary>Tells the <see cref="T:GTA.Ped"/> to perform a task when in a <see cref="T:GTA.Vehicle"/> against another <see cref="T:GTA.Vehicle"/>.</summary>
|
||||
<param name="vehicle">The <see cref="T:GTA.Vehicle"/> to use to achieve the task.</param>
|
||||
<param name="target">The target <see cref="T:GTA.Vehicle"/>.</param>
|
||||
<param name="missionType">The vehicle mission type.</param>
|
||||
<param name="cruiseSpeed">The cruise speed for the task.</param>
|
||||
<param name="drivingFlags">The driving flags for the task.</param>
|
||||
<param name="targetReachedDist">The distance at which the AI thinks the target has been reached and the car stops. To pick default value, the parameter can be passed in as <c>-1</c>.</param>
|
||||
<param name="straightLineDist">The distance at which the AI switches to heading for the target directly instead of following the nodes. To pick default value, the parameter can be passed in as <c>-1</c>.</param>
|
||||
<param name="driveAgainstTraffic">if set to <see langword="true" />, allows the car to drive on the opposite side of the road into incoming traffic.</param>
|
||||
</member>
|
||||
<member name="M:GTA.TaskInvoker.StartVehicleMission(GTA.Vehicle,GTA.Ped,GTA.VehicleMissionType,System.Single,GTA.VehicleDrivingFlags,System.Single,System.Single,System.Boolean)">
|
||||
<summary>Tells the <see cref="T:GTA.Ped"/> to target another ped with a vehicle.</summary>
|
||||
<param name="vehicle">The <see cref="T:GTA.Vehicle"/> to use to achieve the task.</param>
|
||||
<param name="target">The target <see cref="T:GTA.Ped"/>.</param>
|
||||
<param name="missionType">The vehicle mission type.</param>
|
||||
<param name="cruiseSpeed">The cruise speed for the task.</param>
|
||||
<param name="drivingFlags">The driving flags for the task.</param>
|
||||
<param name="targetReachedDist">The distance at which the AI thinks the target has been reached and the car stops. To pick default value, the parameter can be passed in as <c>-1</c>.</param>
|
||||
<param name="straightLineDist">The distance at which the AI switches to heading for the target directly instead of following the nodes. To pick default value, the parameter can be passed in as <c>-1</c>.</param>
|
||||
<param name="driveAgainstTraffic">if set to <see langword="true" />, allows the car to drive on the opposite side of the road into incoming traffic.</param>
|
||||
</member>
|
||||
<member name="M:GTA.TaskInvoker.StartVehicleMission(GTA.Vehicle,GTA.Math.Vector3,GTA.VehicleMissionType,System.Single,GTA.VehicleDrivingFlags,System.Single,System.Single,System.Boolean)">
|
||||
<summary>Tells the <see cref="T:GTA.Ped"/> to target a coord with a <see cref="T:GTA.Vehicle"/>.</summary>
|
||||
<param name="vehicle">The <see cref="T:GTA.Vehicle"/> to use to achieve the task.</param>
|
||||
<param name="target">The target coordinates.</param>
|
||||
<param name="missionType">The vehicle mission type.</param>
|
||||
<param name="cruiseSpeed">The cruise speed for the task.</param>
|
||||
<param name="drivingFlags">The driving flags for the task.</param>
|
||||
<param name="targetReachedDist">The distance at which the AI thinks the target has been reached and the car stops. To pick default value, the parameter can be passed in as <c>-1</c>.</param>
|
||||
<param name="straightLineDist">The distance at which the AI switches to heading for the target directly instead of following the nodes. To pick default value, the parameter can be passed in as <c>-1</c>.</param>
|
||||
<param name="driveAgainstTraffic">if set to <see langword="true" />, allows the car to drive on the opposite side of the road into incoming traffic.</param>
|
||||
</member>
|
||||
<member name="M:GTA.TaskInvoker.StartHeliMission(GTA.Vehicle,GTA.Vehicle,GTA.VehicleMissionType,System.Single,System.Single,System.Int32,System.Int32,System.Single,System.Single,GTA.HeliMissionFlags)">
|
||||
<summary>Gives the helicopter a mission.</summary>
|
||||
<param name="heli">The helicopter.</param>
|
||||
<param name="target">The target <see cref="T:GTA.Vehicle"/>.</param>
|
||||
<param name="missionType">The vehicle mission type.</param>
|
||||
<param name="cruiseSpeed">The cruise speed for the task.</param>
|
||||
<param name="targetReachedDist">distance (in meters) at which heli thinks it's arrived. Also used as the hover distance for <see cref="F:GTA.VehicleMissionType.Attack"/> and <see cref="F:GTA.VehicleMissionType.Circle"/></param>
|
||||
<param name="flightHeight">The Z coordinate the heli tries to maintain (i.e. 30 == 30 meters above sea level).</param>
|
||||
<param name="minHeightAboveTerrain">The height in meters that the heli will try to stay above terrain (ie 20 == always tries to stay at least 20 meters above ground).</param>
|
||||
<param name="heliOrientation">The orientation the heli tries to be in (<c>0f</c> to <c>360f</c>). Use <c>-1f</c> if not bothered. <c>-1f</c> Should be used in 99% of the times.</param>
|
||||
<param name="slowDownDistance">In general, get more control with big number and more dynamic with smaller. Setting to <c>-1</c> means use default tuning(<c>100</c>).</param>
|
||||
<param name="missionFlags">The heli mission flags for the task.</param>
|
||||
</member>
|
||||
<member name="M:GTA.TaskInvoker.StartHeliMission(GTA.Vehicle,GTA.Ped,GTA.VehicleMissionType,System.Single,System.Single,System.Int32,System.Int32,System.Single,System.Single,GTA.HeliMissionFlags)">
|
||||
<summary>Gives the helicopter a mission.</summary>
|
||||
<param name="heli">The helicopter.</param>
|
||||
<param name="target">The target <see cref="T:GTA.Ped"/>.</param>
|
||||
<param name="missionType">The vehicle mission type.</param>
|
||||
<param name="cruiseSpeed">The cruise speed for the task.</param>
|
||||
<param name="targetReachedDist">distance (in meters) at which heli thinks it's arrived. Also used as the hover distance for <see cref="F:GTA.VehicleMissionType.Attack"/> and <see cref="F:GTA.VehicleMissionType.Circle"/></param>
|
||||
<param name="flightHeight">The Z coordinate the heli tries to maintain (i.e. 30 == 30 meters above sea level).</param>
|
||||
<param name="minHeightAboveTerrain">The height in meters that the heli will try to stay above terrain (ie 20 == always tries to stay at least 20 meters above ground).</param>
|
||||
<param name="heliOrientation">The orientation the heli tries to be in (<c>0f</c> to <c>360f</c>). Use <c>-1f</c> if not bothered. <c>-1f</c> Should be used in 99% of the times.</param>
|
||||
<param name="slowDownDistance">In general, get more control with big number and more dynamic with smaller. Setting to <c>-1</c> means use default tuning(<c>100</c>).</param>
|
||||
<param name="missionFlags">The heli mission flags for the task.</param>
|
||||
</member>
|
||||
<member name="M:GTA.TaskInvoker.StartHeliMission(GTA.Vehicle,GTA.Math.Vector3,GTA.VehicleMissionType,System.Single,System.Single,System.Int32,System.Int32,System.Single,System.Single,GTA.HeliMissionFlags)">
|
||||
<summary>Gives the helicopter a mission.</summary>
|
||||
<param name="heli">The helicopter.</param>
|
||||
<param name="target">The target coodinate.</param>
|
||||
<param name="missionType">The vehicle mission type.</param>
|
||||
<param name="cruiseSpeed">The cruise speed for the task.</param>
|
||||
<param name="targetReachedDist">distance (in meters) at which heli thinks it's arrived. Also used as the hover distance for <see cref="F:GTA.VehicleMissionType.Attack"/> and <see cref="F:GTA.VehicleMissionType.Circle"/></param>
|
||||
<param name="flightHeight">The Z coordinate the heli tries to maintain (i.e. 30 == 30 meters above sea level).</param>
|
||||
<param name="minHeightAboveTerrain">The height in meters that the heli will try to stay above terrain (ie 20 == always tries to stay at least 20 meters above ground).</param>
|
||||
<param name="heliOrientation">The orientation the heli tries to be in (<c>0f</c> to <c>360f</c>). Use <c>-1f</c> if not bothered. <c>-1f</c> Should be used in 99% of the times.</param>
|
||||
<param name="slowDownDistance">In general, get more control with big number and more dynamic with smaller. Setting to <c>-1</c> means use default tuning(<c>100</c>).</param>
|
||||
<param name="missionFlags">The heli mission flags for the task.</param>
|
||||
</member>
|
||||
<member name="M:GTA.TaskInvoker.StartPlaneMission(GTA.Vehicle,GTA.Vehicle,GTA.VehicleMissionType,System.Single,System.Single,System.Int32,System.Int32,System.Single,System.Boolean)">
|
||||
<summary>Gives the plane a mission.</summary>
|
||||
<param name="plane">The helicopter.</param>
|
||||
<param name="target">The target <see cref="T:GTA.Vehicle"/>.</param>
|
||||
<param name="missionType">The vehicle mission type.</param>
|
||||
<param name="cruiseSpeed">The cruise speed for the task.</param>
|
||||
<param name="targetReachedDist">distance (in meters) at which heli thinks it's arrived. Also used as the hover distance for <see cref="F:GTA.VehicleMissionType.Attack"/> and <see cref="F:GTA.VehicleMissionType.Circle"/></param>
|
||||
<param name="flightHeight">The Z coordinate the heli tries to maintain (i.e. 30 == 30 meters above sea level).</param>
|
||||
<param name="minHeightAboveTerrain">The height in meters that the heli will try to stay above terrain (ie 20 == always tries to stay at least 20 meters above ground).</param>
|
||||
<param name="planeOrientation">The orientation the plane tries to be in (<c>0f</c> to <c>360f</c>). Use <c>-1f</c> if not bothered. <c>-1f</c> Should be used in 99% of the times.</param>
|
||||
</member>
|
||||
<member name="M:GTA.TaskInvoker.StartPlaneMission(GTA.Vehicle,GTA.Ped,GTA.VehicleMissionType,System.Single,System.Single,System.Int32,System.Int32,System.Single,System.Boolean)">
|
||||
<summary>Gives the plane a mission.</summary>
|
||||
<param name="plane">The helicopter.</param>
|
||||
<param name="target">The target <see cref="T:GTA.Ped"/>.</param>
|
||||
<param name="missionType">The vehicle mission type.</param>
|
||||
<param name="cruiseSpeed">The cruise speed for the task.</param>
|
||||
<param name="targetReachedDist">distance (in meters) at which heli thinks it's arrived. Also used as the hover distance for <see cref="F:GTA.VehicleMissionType.Attack"/> and <see cref="F:GTA.VehicleMissionType.Circle"/></param>
|
||||
<param name="flightHeight">The Z coordinate the heli tries to maintain (i.e. 30 == 30 meters above sea level).</param>
|
||||
<param name="minHeightAboveTerrain">The height in meters that the heli will try to stay above terrain (ie 20 == always tries to stay at least 20 meters above ground).</param>
|
||||
<param name="planeOrientation">The orientation the plane tries to be in (<c>0f</c> to <c>360f</c>). Use <c>-1f</c> if not bothered. <c>-1f</c> Should be used in 99% of the times.</param>
|
||||
</member>
|
||||
<member name="M:GTA.TaskInvoker.StartPlaneMission(GTA.Vehicle,GTA.Math.Vector3,GTA.VehicleMissionType,System.Single,System.Single,System.Int32,System.Int32,System.Single,System.Boolean)">
|
||||
<summary>Gives the plane a mission.</summary>
|
||||
<param name="plane">The plane.</param>
|
||||
<param name="target">The target coodinate.</param>
|
||||
<param name="missionType">The vehicle mission type.</param>
|
||||
<param name="cruiseSpeed">The cruise speed for the task.</param>
|
||||
<param name="targetReachedDist">distance (in meters) at which heli thinks it's arrived. Also used as the hover distance for <see cref="F:GTA.VehicleMissionType.Attack"/> and <see cref="F:GTA.VehicleMissionType.Circle"/></param>
|
||||
<param name="flightHeight">The Z coordinate the heli tries to maintain (i.e. 30 == 30 meters above sea level).</param>
|
||||
<param name="minHeightAboveTerrain">The height in meters that the heli will try to stay above terrain (ie 20 == always tries to stay at least 20 meters above ground).</param>
|
||||
<param name="planeOrientation">The orientation the plane tries to be in (<c>0f</c> to <c>360f</c>). Use <c>-1f</c> if not bothered. <c>-1f</c> Should be used in 99% of the times.</param>
|
||||
</member>
|
||||
<member name="M:GTA.TaskInvoker.StartBoatMission(GTA.Vehicle,GTA.Vehicle,GTA.VehicleMissionType,System.Single,GTA.VehicleDrivingFlags,System.Single,GTA.BoatMissionFlags)">
|
||||
<summary>Gives the boat a mission.</summary>
|
||||
<param name="boat">The boat.</param>
|
||||
<param name="target">The target <see cref="T:GTA.Vehicle"/>.</param>
|
||||
<param name="missionType">The vehicle mission type.</param>
|
||||
<param name="cruiseSpeed">The cruise speed for the task.</param>
|
||||
<param name="drivingFlags">The driving flags for the task.</param>
|
||||
<param name="targetReachedDist">distance (in meters) at which boat thinks it's arrived. Also used as the hover distance for <see cref="F:GTA.VehicleMissionType.Attack"/> and <see cref="F:GTA.VehicleMissionType.Circle"/></param>
|
||||
<param name="missionFlags">The boat mission flags for the task.</param>
|
||||
</member>
|
||||
<member name="M:GTA.TaskInvoker.StartBoatMission(GTA.Vehicle,GTA.Ped,GTA.VehicleMissionType,System.Single,GTA.VehicleDrivingFlags,System.Single,GTA.BoatMissionFlags)">
|
||||
<summary>Gives the boat a mission.</summary>
|
||||
<param name="boat">The boat.</param>
|
||||
<param name="target">The target <see cref="T:GTA.Ped"/>.</param>
|
||||
<param name="missionType">The vehicle mission type.</param>
|
||||
<param name="cruiseSpeed">The cruise speed for the task.</param>
|
||||
<param name="drivingFlags">The driving flags for the task.</param>
|
||||
<param name="targetReachedDist">distance (in meters) at which boat thinks it's arrived. Also used as the hover distance for <see cref="F:GTA.VehicleMissionType.Attack"/> and <see cref="F:GTA.VehicleMissionType.Circle"/></param>
|
||||
<param name="missionFlags">The boat mission flags for the task.</param>
|
||||
</member>
|
||||
<member name="M:GTA.TaskInvoker.StartBoatMission(GTA.Vehicle,GTA.Math.Vector3,GTA.VehicleMissionType,System.Single,GTA.VehicleDrivingFlags,System.Single,GTA.BoatMissionFlags)">
|
||||
<summary>Gives the boat a mission.</summary>
|
||||
<param name="boat">The boat.</param>
|
||||
<param name="target">The target coordinate.</param>
|
||||
<param name="missionType">The vehicle mission type.</param>
|
||||
<param name="cruiseSpeed">The cruise speed for the task.</param>
|
||||
<param name="drivingFlags">The driving flags for the task.</param>
|
||||
<param name="targetReachedDist">distance (in meters) at which boat thinks it's arrived. Also used as the hover distance for <see cref="F:GTA.VehicleMissionType.Attack"/> and <see cref="F:GTA.VehicleMissionType.Circle"/></param>
|
||||
<param name="missionFlags">The boat mission flags for the task.</param>
|
||||
</member>
|
||||
<member name="F:GTA.VehicleDrivingFlags.DontSteerAroundPlayerPed">
|
||||
<summary>Don't steer around the player ped even if <see cref="F:GTA.VehicleDrivingFlags.SteerAroundPeds"/> is set.</summary>
|
||||
</member>
|
||||
@ -21020,6 +21160,29 @@
|
||||
Limit the speed based on the road speed if the max cruise speed for driving tasks exceeds the road speed. Only works when the car mission is set to MISSION_CRUISE.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="F:GTA.VehicleDrivingFlags.UseShortCutLinks">
|
||||
<summary>
|
||||
Allow the <see cref="T:GTA.Ped"/> to use short cut links (e.g. the 180? turns on the highways without the direction sign).
|
||||
</summary>
|
||||
</member>
|
||||
<member name="F:GTA.VehicleDrivingFlags.ChangeLanesAroundObstructions">
|
||||
<summary>
|
||||
Make the driver change lanes around obstructions.
|
||||
Without this flag, even small obstacles make the driver completely change lanes.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="F:GTA.VehicleDrivingFlags.UseSwitchedOffNodes">
|
||||
<summary>
|
||||
Allow the <see cref="T:GTA.Ped"/> to drive on switched off nodes, which are usually located at paths whose colors on the map are darker than roads for driving (e.g. some dirt roads), and on parking lots.
|
||||
You can check if some nodes are marked as switched off with <c>GET_VEHICLE_NODE_IS_SWITCHED_OFF</c>.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="F:GTA.VehicleDrivingFlags.PreferNavmeshRoute">
|
||||
<summary>
|
||||
Make <see cref="T:GTA.Ped"/> prefer navigation mesh routes rather than vehicle nodes.
|
||||
Can be useful if you're going to be primarily driving off road.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="F:GTA.VehicleDrivingFlags.PlaneTaxiMode">
|
||||
<summary>
|
||||
Only works for planes using <c>MISSION_GOTO</c>, will cause them to drive along the ground instead of fly.
|
||||
@ -21030,6 +21193,35 @@
|
||||
Force to go to the target directly instead of following the nodes regardless of the distance config for driving or vehicle mission tasks at which the ai switches to heading for the target directly.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="F:GTA.VehicleDrivingFlags.TryToAvoidHighways">
|
||||
<summary>
|
||||
Avoid the highway unless the <see cref="T:GTA.Ped"/> has to drive on it to achieve the vehicle task.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="F:GTA.VehicleDrivingFlags.DrivingModeStopForVehicles">
|
||||
<summary>Standard driving mode. stops for cars, peds, and lights, goes around stationary obstructions, and obey lights.</summary>
|
||||
</member>
|
||||
<member name="F:GTA.VehicleDrivingFlags.DrivingModeStopForVehiclesStrict">
|
||||
<summary>Like <see cref="F:GTA.VehicleDrivingFlags.DrivingModeStopForVehicles"/>, but doesn't steer around anything in its way - will only wait instead (doesn't deviate an inch).</summary>
|
||||
</member>
|
||||
<member name="F:GTA.VehicleDrivingFlags.DrivingModeAvoidVehicles">
|
||||
<summary>Default "alerted" driving mode. Drives around everything, doesn't obey lights.</summary>
|
||||
</member>
|
||||
<member name="F:GTA.VehicleDrivingFlags.DrivingModeAvoidVehiclesReckless">
|
||||
<summary>Very erratic driving. difference between this and <see cref="F:GTA.VehicleDrivingFlags.DrivingModeAvoidVehicles"/> is that it doesn't use the brakes at ALL to help with steering.</summary>
|
||||
</member>
|
||||
<member name="F:GTA.VehicleDrivingFlags.DrivingModePloughThrough">
|
||||
<summary>Smashes through everything.</summary>
|
||||
</member>
|
||||
<member name="F:GTA.VehicleDrivingFlags.DrivingModeStopForVehiclesIgnoreLights">
|
||||
<summary>Drives normally except for the fact that it ignores lights.</summary>
|
||||
</member>
|
||||
<member name="F:GTA.VehicleDrivingFlags.DrivingModeAvoidVehiclesObeyLights">
|
||||
<summary>Try to swerve around everything, but stop for lights if necessary.</summary>
|
||||
</member>
|
||||
<member name="F:GTA.VehicleDrivingFlags.DrivingModeAvoidVehiclesStopForPedsObeyLights">
|
||||
<summary>Swerve around cars, be careful around peds, and stop for lights.</summary>
|
||||
</member>
|
||||
<member name="P:GTA.Projectile.Owner">
|
||||
<summary>
|
||||
Gets the <see cref="T:GTA.Ped"/> this <see cref="T:GTA.Projectile"/> belongs to.
|
||||
@ -21885,6 +22077,32 @@
|
||||
<see langword="true" /> if this <see cref="T:GTA.Vehicle"/> has forks; otherwise, <see langword="false" />.
|
||||
</value>
|
||||
</member>
|
||||
<member name="P:GTA.Vehicle.IsBeingBroughtToHalt">
|
||||
<summary>
|
||||
Checks if this <see cref="T:GTA.Vehicle"/> is being brought to a halt.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:GTA.Vehicle.BringToHalt(System.Single,System.Int32,System.Boolean)">
|
||||
<summary>
|
||||
Starts the task to decelerate this <see cref="T:GTA.Vehicle"/> until it comes to rest, possibly in an unphysically short distance.
|
||||
</summary>
|
||||
<param name="stoppingDistance">The distance from the initial coords at which the vehicle should come to rest.</param>
|
||||
<param name="timeToStopFor">The length of time in seconds to hold the car at rest after stopping.</param>
|
||||
<param name="controlVerticalVelocity">
|
||||
If <see langword="false" />, the task allows gravity to act normally in the Z direction.
|
||||
If <see langword="true" />, the task will also arrest the car's vertical velocity.
|
||||
</param>
|
||||
</member>
|
||||
<member name="M:GTA.Vehicle.StopBringingToHalt">
|
||||
<summary>
|
||||
Stops bringing this <see cref="T:GTA.Vehicle"/> to a halt.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:GTA.Vehicle.GetActiveMissionType">
|
||||
<summary>
|
||||
Gets active vehicle mission type.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:GTA.Vehicle.StartParachuting(System.Boolean)">
|
||||
<summary>
|
||||
Open the vehicle's parachute (if any)
|
||||
@ -22864,6 +23082,21 @@
|
||||
Converts an <see cref="T:GTA.Entity"/> to a native input argument.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="F:GTA.IntersectFlags.PedCapsules">
|
||||
<summary>
|
||||
Detect <see cref="T:GTA.Ped"/> who are not ragdolled (not running any NM tasks) by detecting the simple capsule shape of <see cref="T:GTA.Ped"/>.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="F:GTA.IntersectFlags.Ragdolls">
|
||||
<summary>
|
||||
Detect <see cref="T:GTA.Ped"/>'s ragdoll. Can detect those who are not ragdolled.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="F:GTA.IntersectFlags.Foliage">
|
||||
<summary>
|
||||
Detect foliage, which can be affected by the wind or contacts of <see cref="T:GTA.Entity"/>.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="F:GTA.Language.Chinese">
|
||||
<summary>Traditional Chinese</summary>
|
||||
</member>
|
||||
@ -23767,6 +24000,242 @@
|
||||
<param name="section">The section where the value is.</param>
|
||||
<param name="name">The name of the key the values are saved at.</param>
|
||||
</member>
|
||||
<member name="M:GTA.ShapeTest.StartTestLOSProbe(GTA.Math.Vector3,GTA.Math.Vector3,GTA.IntersectFlags,GTA.Entity,GTA.ShapeTestOptions)">
|
||||
<summary>
|
||||
Start a line-of-sight world probe shape test between 2 points.
|
||||
</summary>
|
||||
<param name="startPosition">The positon where the shape test starts.</param>
|
||||
<param name="endPosition">The positon where the shape test ends.</param>
|
||||
<param name="intersectFlags">What type of objects the shape test should intersect with.</param>
|
||||
<param name="excludeEntity">Specify an <see cref="T:GTA.Entity"/> that the shape test should exclude, leave null for no entities ignored.</param>
|
||||
<param name="options">Specify options for the spape test.</param>
|
||||
<value>
|
||||
The shape test handle.
|
||||
If this method fails to create the shape test request because there are too many ongoing requests, <see cref="P:GTA.ShapeTestHandle.IsRequestFailed"/> will return <see langword="true" /> on the handle struct.
|
||||
</value>
|
||||
</member>
|
||||
<member name="M:GTA.ShapeTest.StartExpensiveSyncTestLOSProbe(GTA.Math.Vector3,GTA.Math.Vector3,GTA.IntersectFlags,GTA.Entity,GTA.ShapeTestOptions)">
|
||||
<summary>
|
||||
Start a expensive synchronous line-of-sight world probe shape test between 2 points and blocks the game until the shape test completes.
|
||||
</summary>
|
||||
<param name="startPosition">The positon where the shape test starts.</param>
|
||||
<param name="endPosition">The positon where the shape test ends.</param>
|
||||
<param name="intersectFlags">What type of objects the shape test should intersect with.</param>
|
||||
<param name="excludeEntity">Specify an <see cref="T:GTA.Entity"/> that the shape test should exclude, leave null for no entities ignored.</param>
|
||||
<param name="options">Specify options for the spape test.</param>
|
||||
<remarks>This method is much more expensive than the asynchronous version (<see cref="M:GTA.ShapeTest.StartTestLOSProbe(GTA.Math.Vector3,GTA.Math.Vector3,GTA.IntersectFlags,GTA.Entity,GTA.ShapeTestOptions)"/>).</remarks>
|
||||
<value>
|
||||
The shape test handle.
|
||||
If this method fails to create the shape test request because there are too many ongoing requests, <see cref="P:GTA.ShapeTestHandle.IsRequestFailed"/> will return <see langword="true" /> on the handle struct.
|
||||
</value>
|
||||
</member>
|
||||
<member name="M:GTA.ShapeTest.StartTestBoundingBox(GTA.Entity,GTA.IntersectFlags,GTA.ShapeTestOptions)">
|
||||
<summary>
|
||||
Start a shape test against the <see cref="T:GTA.Entity"/>'s bounding box.
|
||||
</summary>
|
||||
<param name="entity">The entity to inspect.</param>
|
||||
<param name="intersectFlags">What type of objects the shape test should intersect with.</param>
|
||||
<param name="options">Specify options for the spape test.</param>
|
||||
<value>
|
||||
The shape test handle.
|
||||
If this method fails to create the shape test request because there are too many ongoing requests, <see cref="P:GTA.ShapeTestHandle.IsRequestFailed"/> will return <see langword="true" /> on the handle struct.
|
||||
</value>
|
||||
</member>
|
||||
<member name="M:GTA.ShapeTest.StartTestBox(GTA.Math.Vector3,GTA.Math.Vector3,GTA.Math.Vector3,GTA.EulerRotationOrder,GTA.IntersectFlags,GTA.Entity,GTA.ShapeTestOptions)">
|
||||
<summary>
|
||||
Start a shape test against the <see cref="T:GTA.Entity"/>'s bound where the entity can collide.
|
||||
</summary>
|
||||
<param name="sourcePosition">The source position.</param>
|
||||
<param name="dimension">The dimensions how much the shape test will search from the source position.</param>
|
||||
<param name="rotationAngles">The rotations in degree how much the dimension will be rotated before the shape test starts.</param>
|
||||
<param name="rotationOrder">The rotation order in local space the dimentions will be rotated in.</param>
|
||||
<param name="intersectFlags">What type of objects the shape test should intersect with.</param>
|
||||
<param name="excludeEntity">Specify an <see cref="T:GTA.Entity"/> that the shape test should exclude, leave null for no entities ignored.</param>
|
||||
<param name="options">Specify options for the spape test.</param>
|
||||
<value>
|
||||
The shape test handle.
|
||||
If this method fails to create the shape test request because there are too many ongoing requests, <see cref="P:GTA.ShapeTestHandle.IsRequestFailed"/> will return <see langword="true" /> on the handle struct.
|
||||
</value>
|
||||
</member>
|
||||
<member name="M:GTA.ShapeTest.StartTestBound(GTA.Entity,GTA.IntersectFlags,GTA.ShapeTestOptions)">
|
||||
<summary>
|
||||
Start a shape test against the <see cref="T:GTA.Entity"/>'s bound where the entity can collide.
|
||||
</summary>
|
||||
<param name="entity">The entity to inspect.</param>
|
||||
<param name="intersectFlags">What type of objects the shape test should intersect with.</param>
|
||||
<param name="options">Specify options for the spape test.</param>
|
||||
<value>
|
||||
The shape test handle.
|
||||
If this method fails to create the shape test request because there are too many ongoing requests, <see cref="P:GTA.ShapeTestHandle.IsRequestFailed"/> will return <see langword="true" /> on the handle struct.
|
||||
</value>
|
||||
</member>
|
||||
<member name="M:GTA.ShapeTest.StartTestCapsule(GTA.Math.Vector3,GTA.Math.Vector3,System.Single,GTA.IntersectFlags,GTA.Entity,GTA.ShapeTestOptions)">
|
||||
<summary>
|
||||
Start a shape test against the area where shape test capsule covers.
|
||||
</summary>
|
||||
<param name="startPosition">The positon where the shape test starts.</param>
|
||||
<param name="endPosition">The positon where the shape test ends.</param>
|
||||
<param name="radius">The radius of the shape test capsule.</param>
|
||||
<param name="intersectFlags">What type of objects the shape test should intersect with.</param>
|
||||
<param name="excludeEntity">Specify an <see cref="T:GTA.Entity"/> that the shape test should exclude, leave null for no entities ignored.</param>
|
||||
<param name="options">Specify options for the spape test.</param>
|
||||
<value>
|
||||
The shape test handle.
|
||||
If this method fails to create the shape test request because there are too many ongoing requests, <see cref="P:GTA.ShapeTestHandle.IsRequestFailed"/> will return <see langword="true" /> on the handle struct.
|
||||
</value>
|
||||
</member>
|
||||
<member name="M:GTA.ShapeTest.StartTestSweptSphere(GTA.Math.Vector3,GTA.Math.Vector3,System.Single,GTA.IntersectFlags,GTA.Entity,GTA.ShapeTestOptions)">
|
||||
<summary>
|
||||
Start a shape test against the area where swept sphere (ellipsoid) for shape test covers.
|
||||
</summary>
|
||||
<param name="startPosition">The positon where the shape test starts.</param>
|
||||
<param name="endPosition">The positon where the shape test ends.</param>
|
||||
<param name="radius">The radius of the swept sphere.</param>
|
||||
<param name="intersectFlags">What type of objects the shape test should intersect with.</param>
|
||||
<param name="excludeEntity">Specify an <see cref="T:GTA.Entity"/> that the shape test should exclude, leave null for no entities ignored.</param>
|
||||
<param name="options">Specify options for the spape test.</param>
|
||||
<value>
|
||||
The shape test handle.
|
||||
If this method fails to create the shape test request because there are too many ongoing requests, <see cref="P:GTA.ShapeTestHandle.IsRequestFailed"/> will return <see langword="true" /> on the handle struct.
|
||||
</value>
|
||||
</member>
|
||||
<member name="M:GTA.ShapeTest.StartTestMouseCursorLOSProbe(GTA.Math.Vector3@,GTA.Math.Vector3@,GTA.IntersectFlags,GTA.Entity,GTA.ShapeTestOptions)">
|
||||
<summary>
|
||||
Start a line-of-sight world probe shape test between 2 points calculated based on the mouse cursor position.
|
||||
Works just like <see cref="M:GTA.ShapeTest.StartTestLOSProbe(GTA.Math.Vector3,GTA.Math.Vector3,GTA.IntersectFlags,GTA.Entity,GTA.ShapeTestOptions)"/> only the start and end points of the probe are calculated based on the mouse cursor position projected into the world.
|
||||
</summary>
|
||||
<param name="probeStartPosition">The returned start position of the probe in world space.</param>
|
||||
<param name="probeEndPosition">The returned end position of the probe in world space.</param>
|
||||
<param name="intersectFlags">What type of objects the shape test should intersect with.</param>
|
||||
<param name="excludeEntity">Specify an <see cref="T:GTA.Entity"/> that the shape test should exclude, leave null for no entities ignored.</param>
|
||||
<param name="options">Specify options for the spape test.</param>
|
||||
<value>
|
||||
The shape test handle.
|
||||
If this method fails to create the shape test request because there are too many ongoing requests, <see cref="P:GTA.ShapeTestHandle.IsRequestFailed"/> will return <see langword="true" /> on the handle struct.
|
||||
</value>
|
||||
</member>
|
||||
<member name="M:GTA.ShapeTest.StartTestMouseCursorLOSProbe(GTA.IntersectFlags,GTA.Entity,GTA.ShapeTestOptions)">
|
||||
<summary>
|
||||
Start a shape test between 2 points calculated based on the mouse cursor position.
|
||||
Works just like <see cref="M:GTA.ShapeTest.StartTestLOSProbe(GTA.Math.Vector3,GTA.Math.Vector3,GTA.IntersectFlags,GTA.Entity,GTA.ShapeTestOptions)"/> only the start and end points of the probe are calculated based on the mouse cursor position projected into the world.
|
||||
</summary>
|
||||
<param name="intersectFlags">What type of objects the shape test should intersect with.</param>
|
||||
<param name="excludeEntity">Specify an <see cref="T:GTA.Entity"/> that the shape test should exclude, leave null for no entities ignored.</param>
|
||||
<param name="options">Specify options for the spape test.</param>
|
||||
<value>
|
||||
The shape test handle and the start and end points of the probe are calculated based on the mouse cursor position projected into the world.
|
||||
If this method fails to create the shape test request because there are too many ongoing requests, <see cref="P:GTA.ShapeTestHandle.IsRequestFailed"/> will return <see langword="true" /> on the handle struct.
|
||||
</value>
|
||||
</member>
|
||||
<member name="T:GTA.ShapeTestHandle">
|
||||
<summary>
|
||||
Represents a shape test handle.
|
||||
You need to call <see cref="O:GetResult"/> or <see cref="O:GetResultIncludingMaterial"/> every frame until one of the methods returns <see cref="F:GTA.ShapeTestStatus.Ready"/>.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:GTA.ShapeTestHandle.Handle">
|
||||
<summary>
|
||||
Gets the shape test handle.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:GTA.ShapeTestHandle.NativeValue">
|
||||
<summary>
|
||||
Gets the native representation of this <see cref="T:GTA.Model"/>.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:GTA.ShapeTestHandle.IsRequestFailed">
|
||||
<summary>
|
||||
Gets if the request of <see cref="T:GTA.ShapeTestHandle"/> is failed.
|
||||
There is a limit to the number that can be in the system. Therefore, native functions for shape tests may fail to create the shapetest requests.
|
||||
</summary>
|
||||
<value>
|
||||
<see langword="true" /> if the request is failed; otherwise, <see langword="false" />.
|
||||
</value>
|
||||
</member>
|
||||
<member name="M:GTA.ShapeTestHandle.GetResult(GTA.ShapeTestResult@)">
|
||||
<summary>
|
||||
If status returned is <see cref="F:GTA.ShapeTestStatus.Ready"/>, then returns whether something was hit, and if so nearest hit position and normal.
|
||||
You need to call this method until the result is ready since the shape test result may not be finished in the same frame you start the shape test.
|
||||
</summary>
|
||||
<remarks>
|
||||
The shape test request is destroyed by this call if <see cref="F:GTA.ShapeTestStatus.Ready"/> is returned.
|
||||
If this is not called every frame then the request will be destroyed.
|
||||
</remarks>
|
||||
</member>
|
||||
<member name="M:GTA.ShapeTestHandle.GetResult">
|
||||
<summary>
|
||||
If status returned is <see cref="F:GTA.ShapeTestStatus.Ready"/>, then returns whether something was hit, and if so nearest hit position and normal.
|
||||
You need to call this method until the result is ready since the shape test result may not be finished in the same frame you start the shape test.
|
||||
</summary>
|
||||
<remarks>
|
||||
The shape test request is destroyed by this call if <see cref="F:GTA.ShapeTestStatus.Ready"/> is returned.
|
||||
If this is not called every frame then the request will be destroyed.
|
||||
</remarks>
|
||||
</member>
|
||||
<member name="M:GTA.ShapeTestHandle.GetResultIncludingMaterial(GTA.ShapeTestResult@,GTA.MaterialHash@)">
|
||||
<summary>
|
||||
If status returned is <see cref="F:GTA.ShapeTestStatus.Ready"/>, then returns whether something was hit, and if so nearest hit position, normal, and a hash of the material name.
|
||||
You need to call this method until the result is ready since the shape test result may not be finished in the same frame you start the shape test.
|
||||
</summary>
|
||||
<remarks>
|
||||
The shape test request is destroyed by this call if <see cref="F:GTA.ShapeTestStatus.Ready"/> is returned.
|
||||
If this is not called every frame then the request will be destroyed.
|
||||
</remarks>
|
||||
</member>
|
||||
<member name="M:GTA.ShapeTestHandle.GetResultIncludingMaterial">
|
||||
<summary>
|
||||
If status returned is <see cref="F:GTA.ShapeTestStatus.Ready"/>, then returns whether something was hit, and if so nearest hit position, normal, and a hash of the material name.
|
||||
You need to call this method until the result is ready since the shape test result may not be finished in the same frame you start the shape test.
|
||||
</summary>
|
||||
<remarks>
|
||||
The shape test request is destroyed by this call if <see cref="F:GTA.ShapeTestStatus.Ready"/> is returned.
|
||||
If this is not called every frame then the request will be destroyed.
|
||||
</remarks>
|
||||
</member>
|
||||
<member name="T:GTA.ShapeTestResult">
|
||||
<summary>
|
||||
Represents a shape test result.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:GTA.ShapeTestResult.DidHit">
|
||||
<summary>
|
||||
Gets a value indicating whether this shape test collided with anything.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="M:GTA.ShapeTestResult.TryGetHitEntity(GTA.Entity@)">
|
||||
<summary>
|
||||
Try to get the <see cref="T:GTA.Entity" /> this shape test hit.
|
||||
<remarks>Returns <see langword="false" /> if the shape test didn't hit or what was hit wasn't a <see cref="T:GTA.Entity" />.</remarks>
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:GTA.ShapeTestResult.HitPosition">
|
||||
<summary>
|
||||
Gets the world coordinates where this shape test hit.
|
||||
<remarks>Returns <see cref="P:GTA.Math.Vector3.Zero"/> if the shape test didn't hit anything.</remarks>
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:GTA.ShapeTestResult.SurfaceNormal">
|
||||
<summary>
|
||||
Gets the normal of the surface where this shape test hit.
|
||||
<remarks>Returns <see cref="P:GTA.Math.Vector3.Zero"/> if the shape test didn't hit anything.</remarks>
|
||||
</summary>
|
||||
</member>
|
||||
<member name="F:GTA.ShapeTestStatus.NonExistent">
|
||||
<summary>
|
||||
Shapetest requests are discarded if they are ignored for a frame or as soon as the results are returned.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="F:GTA.ShapeTestStatus.NotReady">
|
||||
<summary>
|
||||
Not ready yet; try again next frame.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="F:GTA.ShapeTestStatus.Ready">
|
||||
<summary>
|
||||
The result is ready and the results have been returned to you.
|
||||
The shape test request has also just been destroyed.
|
||||
</summary>
|
||||
</member>
|
||||
<member name="P:GTA.WeaponAsset.Hash">
|
||||
<summary>
|
||||
Gets the hash for this <see cref="T:GTA.WeaponAsset"/>.
|
||||
|
Reference in New Issue
Block a user