mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
Add local position to reference frame
This commit is contained in:
parent
02845778bd
commit
648f9b7068
@ -41,6 +41,13 @@ namespace NewHorizons.Builder.General
|
||||
RFV._isPrimaryVolume = true;
|
||||
RFV._isCloseRangeVolume = false;
|
||||
|
||||
if (module.localPosition != null)
|
||||
{
|
||||
rfGO.transform.localPosition = module.localPosition;
|
||||
RV._localPosition = module.localPosition;
|
||||
RV._useCenterOfMass = false;
|
||||
}
|
||||
|
||||
owrb.SetAttachedReferenceFrameVolume(RFV);
|
||||
|
||||
if (!module.enabled) GameObject.Destroy(rfGO);
|
||||
|
||||
@ -39,5 +39,10 @@ namespace NewHorizons.External.Modules
|
||||
/// The radius of the sphere around the planet which you can click on to target it. Defaults to twice the sphere of influence.
|
||||
/// </summary>
|
||||
public float targetColliderRadius;
|
||||
|
||||
/// <summary>
|
||||
/// Position that the reference frame relative to the object.
|
||||
/// </summary>
|
||||
public MVector3 localPosition;
|
||||
}
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user