Kerbal Space Program  1.12.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
Public Member Functions | Protected Member Functions | Properties | List of all members
Expansions.Missions.Editor.GAPCelestialBody Class Reference
Inheritance diagram for Expansions.Missions.Editor.GAPCelestialBody:
Expansions.Missions.Editor.ActionPaneDisplay_CelestialBody Expansions.Missions.Editor.ActionPaneDisplay

Public Member Functions

override void Clean ()
 This method will reset everything on how it was by default More...
 
override void Destroy ()
 Destroy this GAP Display More...
 
bool DoLocalSpaceRay (Vector2 cameraPoint, out RaycastHit rayHit)
 This will do a Raycast to the PQS Sphere collider More...
 
RaycastHit[] DoLocalSpaceRayAll (Vector2 cameraPoint)
 
void Load (CelestialBody celestialBody)
 Loads the specified celestial body in the GAP More...
 
override void OnDisplayClickUp (RaycastHit?hit)
 The event when a mouse is clicked and then released More...
 
override void OnDisplayDragEnd (RaycastHit?hit)
 The event when the mouse button is released after dragging More...
 
void SetFooterText (string newText)
 Sets the string on the footer of the GAP More...
 
void SetState (GAPCelestialBodyState newState)
 This will set the GAP in the selected State, More...
 
void SliderAction_LightCycle (float value)
 
void SliderAction_Zoom (float value)
 The event fired when the zoom slider is being interacted with. More...
 
void SuscribeToLeftButton (UnityEngine.Events.UnityAction action)
 Suscribes an event to the left arrow button in the GAP More...
 
void SuscribeToRightButton (UnityEngine.Events.UnityAction action)
 Suscribes an event to the right arrow button in the GAP More...
 
void TogglePQS (bool usePQS)
 If set to true, it will enable PQS on the next CB Load More...
 
void UpdateScroll ()
 
- Public Member Functions inherited from Expansions.Missions.Editor.ActionPaneDisplay
Button AddToolbarButton (string id, string icon, string toolTip)
 Creates a gap toolbar button control More...
 
Toggle AddToolbarToggle (string id, string icon, string toolTip, bool startState=false)
 Creates a gap toolbar toggle control More...
 
void ClearToolbar ()
 Clean the GAP tool bar controls More...
 
bool GetMousePointOnCamera (Vector2 mousePosition, Camera canvasCamera, ref Vector2 point)
 Gets the mouse position relative to the GAP display camera, used for ray cast objects displayed in the render texture More...
 
Button GetToolbarButton (string id)
 Get a tool bar button More...
 
virtual void OnBeginDrag (PointerEventData eventData)
 Event triggered on drag begin More...
 
override void OnDeselect (BaseEventData eventData)
 Event triggered on UI selectable deselect More...
 
virtual void OnDrag (PointerEventData eventData)
 Event triggered on pointer drag More...
 
virtual void OnEndDrag (PointerEventData eventData)
 Event triggered on drag end More...
 
virtual void OnPointerClick (PointerEventData eventData)
 Event triggered on pointer click this gameobject rect More...
 
override void OnPointerEnter (PointerEventData eventData)
 Event triggered on pointer enter this gameobject rect More...
 
override void OnPointerExit (PointerEventData eventData)
 Event triggered on pointer exit this gameobject rect More...
 
override void OnPointerUp (PointerEventData eventData)
 
override void OnSelect (BaseEventData eventData)
 Event triggered on UI selecteable select More...
 
bool Raycast (Vector3 cameraPoint, out RaycastHit hit, int layerMask=-1)
 Help function, makes a ray cast from the supplied camera point using the gap display camera, layer mask and hit distance values More...
 
virtual void Setup (Camera displayCamera, int layerMask)
 Setups the Action Pane display More...
 
void UpdateDisplayArea ()
 Updates the render texture display area maintaining the game aspect ratio More...
 

Protected Member Functions

void DisplayResource (int resourceIndex)
 
void Initialize ()
 Starts up the GAP component variables and instantiates any neccesary extra prefabs More...
 
virtual void LateUpdate ()
 
override void OnDisplayClick (RaycastHit?hit)
 The event when a mouse is clicked More...
 
override void OnDisplayDrag (PointerEventData.InputButton arg0, Vector2 arg1)
 Receives on drag events on the viewport and sends them to the camera to be tranlated in the orbit movement. More...
 
override void OnMouseOver (Vector2 cameraPoint)
 The event when the mouse is over the GAP window More...
 
override void Update ()
 
- Protected Member Functions inherited from Expansions.Missions.Editor.ActionPaneDisplay_CelestialBody
override void Awake ()
 
- Protected Member Functions inherited from Expansions.Missions.Editor.ActionPaneDisplay
override void Awake ()
 
void ClearToolbarEvents ()
 Clear the tool bar controls events More...
 

Properties

GAPCelestialBodyState_Biomes Biomes [get]
 Returns a reference to the Biome state (if active), otherwise returns null More...
 
Orbit BodyOrbit [get, set]
 Returns the displayed orbit, return null if there is none More...
 
CelestialBody CelestialBody [get]
 Returns the displayed celestialbody, returns null if there is none More...
 
GAPCelestialBodyCamera CelestialCamera [get]
 Returns a reference to the camera looking at LocalSpace of a Celestial Body More...
 
Camera DisplayCamera [get]
 Returns the camara that holds the RenderTexture of the GAP More...
 
double DistanceToSurface [get]
 Returns the distance from the center of the GAP screen to the surface of the celestial body (Only when PQS is active) More...
 
bool IsSelected [get]
 Returns true if the GAP is currently being interacted with More...
 
GAPCelestialBodyState_Orbit Orbits [get]
 Returns a reference to the orbit state (if active), otherwise returns null More...
 
bool PQSActive [get]
 Returns true if the gap will use PQS when zoomed in. More...
 
bool PQSLoaded [get]
 Returns true if the gap will use PQS when zoomed in. More...
 
float StartingZoomValue [get, set]
 
Quaternion StoredCBRotation [get]
 Returns the orginal rotation of the planet, since it will be rotated to 0 when using the GAP More...
 
GAPCelestialBodyState_SurfaceGizmo SurfaceGizmo [get]
 Returns a reference to the Point state (if active), otherwise returns null More...
 
double SurfaceHeight [get]
 Returns the height of the surface at the center of the GAP screen (Only when PQS is active) More...
 
- Properties inherited from Expansions.Missions.Editor.ActionPaneDisplay_CelestialBody
GAPUtil_CelestialBody Selector [get]
 
- Properties inherited from Expansions.Missions.Editor.ActionPaneDisplay
RenderTexture DisplayTexture [get]
 

Additional Inherited Members

- Public Attributes inherited from Expansions.Missions.Editor.ActionPaneDisplay
RaycastEvent DisplayClick
 Event that triggers on the display click, sends a hitinfo if an object was clicked on More...
 
RaycastEvent DisplayClickUp
 Event that triggers on the display click when the button is up, sends a hitinfo if an object was clicked on More...
 
DragEvent DisplayDrag
 Event that triggers a mouse drag, sends the button and mouse delta information More...
 
RaycastEvent DisplayDragEnd
 Event that triggers on the display click when the button is up, sends a hitinfo if an object was clicked on More...
 
RawImage displayImage
 Raw image that displays the render texture More...
 
MouseOverEvent MouseOver
 Event that trigger when the mouse is over the GAP display image More...
 
RectTransform rectTransform
 Rect transform cache More...
 
- Protected Attributes inherited from Expansions.Missions.Editor.ActionPaneDisplay_CelestialBody
GAPUtil_CelestialBody selector
 
- Protected Attributes inherited from Expansions.Missions.Editor.ActionPaneDisplay
Camera displayCamera
 
RenderTexture displayTexture
 
float hitDistance
 
bool isDragging = false
 
bool isMouseOver = false
 
bool isSelected = false
 
int layerMask
 
DictionaryValueList< string,
MonoBehaviour > 
toolbarControls
 

Member Function Documentation

override void Expansions.Missions.Editor.GAPCelestialBody.Clean ( )
inlinevirtual

This method will reset everything on how it was by default

Reimplemented from Expansions.Missions.Editor.ActionPaneDisplay.

override void Expansions.Missions.Editor.GAPCelestialBody.Destroy ( )
inlinevirtual

Destroy this GAP Display

Reimplemented from Expansions.Missions.Editor.ActionPaneDisplay.

void Expansions.Missions.Editor.GAPCelestialBody.DisplayResource ( int  resourceIndex)
inlineprotected
bool Expansions.Missions.Editor.GAPCelestialBody.DoLocalSpaceRay ( Vector2  cameraPoint,
out RaycastHit  rayHit 
)
inline

This will do a Raycast to the PQS Sphere collider

Parameters
cameraPointThe mouse point clicked on the GAP
rayHitThe raycast that will return the hit results
Returns
If the ray was succesful or not
RaycastHit [] Expansions.Missions.Editor.GAPCelestialBody.DoLocalSpaceRayAll ( Vector2  cameraPoint)
inline
void Expansions.Missions.Editor.GAPCelestialBody.Initialize ( )
inlineprotected

Starts up the GAP component variables and instantiates any neccesary extra prefabs

virtual void Expansions.Missions.Editor.GAPCelestialBody.LateUpdate ( )
inlineprotectedvirtual
void Expansions.Missions.Editor.GAPCelestialBody.Load ( CelestialBody  celestialBody)
inline

Loads the specified celestial body in the GAP

override void Expansions.Missions.Editor.GAPCelestialBody.OnDisplayClick ( RaycastHit?  hit)
inlineprotectedvirtual

The event when a mouse is clicked

Parameters
hit

Reimplemented from Expansions.Missions.Editor.ActionPaneDisplay.

override void Expansions.Missions.Editor.GAPCelestialBody.OnDisplayClickUp ( RaycastHit?  hit)
inlinevirtual

The event when a mouse is clicked and then released

Parameters
hit

Reimplemented from Expansions.Missions.Editor.ActionPaneDisplay.

override void Expansions.Missions.Editor.GAPCelestialBody.OnDisplayDrag ( PointerEventData.InputButton  arg0,
Vector2  arg1 
)
inlineprotectedvirtual

Receives on drag events on the viewport and sends them to the camera to be tranlated in the orbit movement.

Reimplemented from Expansions.Missions.Editor.ActionPaneDisplay.

override void Expansions.Missions.Editor.GAPCelestialBody.OnDisplayDragEnd ( RaycastHit?  hit)
inlinevirtual

The event when the mouse button is released after dragging

Parameters
hit

Reimplemented from Expansions.Missions.Editor.ActionPaneDisplay.

override void Expansions.Missions.Editor.GAPCelestialBody.OnMouseOver ( Vector2  cameraPoint)
inlineprotectedvirtual

The event when the mouse is over the GAP window

Reimplemented from Expansions.Missions.Editor.ActionPaneDisplay.

void Expansions.Missions.Editor.GAPCelestialBody.SetFooterText ( string  newText)
inline

Sets the string on the footer of the GAP

void Expansions.Missions.Editor.GAPCelestialBody.SetState ( GAPCelestialBodyState  newState)
inline

This will set the GAP in the selected State,

void Expansions.Missions.Editor.GAPCelestialBody.SliderAction_LightCycle ( float  value)
inline
void Expansions.Missions.Editor.GAPCelestialBody.SliderAction_Zoom ( float  value)
inline

The event fired when the zoom slider is being interacted with.

Parameters
value
void Expansions.Missions.Editor.GAPCelestialBody.SuscribeToLeftButton ( UnityEngine.Events.UnityAction  action)
inline

Suscribes an event to the left arrow button in the GAP

void Expansions.Missions.Editor.GAPCelestialBody.SuscribeToRightButton ( UnityEngine.Events.UnityAction  action)
inline

Suscribes an event to the right arrow button in the GAP

void Expansions.Missions.Editor.GAPCelestialBody.TogglePQS ( bool  usePQS)
inline

If set to true, it will enable PQS on the next CB Load

override void Expansions.Missions.Editor.GAPCelestialBody.Update ( )
inlineprotectedvirtual
void Expansions.Missions.Editor.GAPCelestialBody.UpdateScroll ( )
inline

Property Documentation

GAPCelestialBodyState_Biomes Expansions.Missions.Editor.GAPCelestialBody.Biomes
get

Returns a reference to the Biome state (if active), otherwise returns null

Orbit Expansions.Missions.Editor.GAPCelestialBody.BodyOrbit
getset

Returns the displayed orbit, return null if there is none

CelestialBody Expansions.Missions.Editor.GAPCelestialBody.CelestialBody
get

Returns the displayed celestialbody, returns null if there is none

GAPCelestialBodyCamera Expansions.Missions.Editor.GAPCelestialBody.CelestialCamera
get

Returns a reference to the camera looking at LocalSpace of a Celestial Body

Camera Expansions.Missions.Editor.GAPCelestialBody.DisplayCamera
get

Returns the camara that holds the RenderTexture of the GAP

double Expansions.Missions.Editor.GAPCelestialBody.DistanceToSurface
get

Returns the distance from the center of the GAP screen to the surface of the celestial body (Only when PQS is active)

bool Expansions.Missions.Editor.GAPCelestialBody.IsSelected
get

Returns true if the GAP is currently being interacted with

GAPCelestialBodyState_Orbit Expansions.Missions.Editor.GAPCelestialBody.Orbits
get

Returns a reference to the orbit state (if active), otherwise returns null

bool Expansions.Missions.Editor.GAPCelestialBody.PQSActive
get

Returns true if the gap will use PQS when zoomed in.

bool Expansions.Missions.Editor.GAPCelestialBody.PQSLoaded
get

Returns true if the gap will use PQS when zoomed in.

float Expansions.Missions.Editor.GAPCelestialBody.StartingZoomValue
getset
Quaternion Expansions.Missions.Editor.GAPCelestialBody.StoredCBRotation
get

Returns the orginal rotation of the planet, since it will be rotated to 0 when using the GAP

GAPCelestialBodyState_SurfaceGizmo Expansions.Missions.Editor.GAPCelestialBody.SurfaceGizmo
get

Returns a reference to the Point state (if active), otherwise returns null

double Expansions.Missions.Editor.GAPCelestialBody.SurfaceHeight
get

Returns the height of the surface at the center of the GAP screen (Only when PQS is active)


The documentation for this class was generated from the following file: