Kerbal Space Program  1.12.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
Public Member Functions | Public Attributes | Protected Attributes | List of all members
Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo Class Reference
Inheritance diagram for Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo:
Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Area Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_PlaceVessel Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Volume

Public Member Functions

virtual Transform GetFocusTarget ()
 
virtual string GetFooterText ()
 This method will prepara the top section of the text in the gap window. More...
 
override void Initialize (GAPCelestialBody newGapRef)
 Called after the gizmo is instantiated to initialize its corresponding values. More...
 
override bool IsActive ()
 Checks if the gizmo is enabled to be interacted with. More...
 
bool IsDragReady ()
 Checks if there is a gizmo handle selected. More...
 
void OnButtonPressed_FocusTarget ()
 The event executed when the Focus Target button is pressed. More...
 
virtual void OnGAPClick (double newLatitude, double newLongitude)
 Called when GAP window is clicked. More...
 
virtual void OnGAPDrag (double dragStartLatitude, double dragStartLongitude, double dragLatitude, double dragLongitude)
 Called when there is a drag gesture on the GAP window. More...
 
virtual void OnGAPDragEnd ()
 Called when the drag gesture over the gap window has ended. More...
 
virtual void OnGAPOver (double hoverLatitude, double hoverLongitude)
 Called when the mouse is over the GAP window. More...
 
virtual void OnGizmoHandleDrag (double dragStartLatitude, double dragStartLongitude, double dragLatitude, double dragLongitude)
 Called when a handle of the gizmo is getting dragged. More...
 
virtual void OnGizmoHandleDragEnd ()
 Called when the drag gesture over one of the handles has ended. More...
 
virtual void OnGizmoHandleOver (double hoverLatitude, double hoverLongitude)
 Called when the mouse is over a gizmo object. More...
 
virtual void OnGizmoHandleSelected (GAPCelestialBodyGizmoHandle selectedHandle)
 Called when a gizmo has been clicked to be interacted with. More...
 
override void OnLoadPlanet (CelestialBody newCelestialBody)
 Called when a new planet is loaded (To reset any values if needed) More...
 
delegate void OnPointTranslate (double latitude, double longitude)
 
override void OnUpdate ()
 Called every frame. More...
 
override double SetGizmoPosition (double newLatitude, double newLongitude, double newAltitude)
 Sets the GAP gizmo on the celestial body surface from the latitude and longitude values. Altitude is calculated automatically. More...
 
bool TrySelectHandle (Collider handleCollider)
 A method to check the status of the gizmo handles. It will compare a collider to see if its a handle, and if it is it will select it if its intended. It uses a collider since the test method is a raycast to the surface of the planet. More...
 
- Public Member Functions inherited from Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo
virtual void OnDestroy ()
 Called before destroying the gizmo. More...
 

Public Attributes

List< GAPCelestialBodyGizmoHandlegizmoHandles
 
OnPointTranslate OnGAPGizmoTranslate
 
Sprite spriteFocusCelestialBody
 
Sprite spriteFocusTarget
 
- Public Attributes inherited from Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo
Transform gizmoContainer
 

Protected Attributes

GAPCelestialBodyGizmoHandle selectedHandle
 
- Protected Attributes inherited from Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo
double altitude
 
CelestialBody celestialBody
 
GAPCelestialBody gapRef
 
double latitude
 
double longitude
 

Additional Inherited Members

- Protected Member Functions inherited from Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo
void SetInSurfaceFromPoint (Vector3d point)
 Sets a transform on the surface of the celestial body More...
 
void SetInSurfaceFromPointAtSeaLevel (Vector3d point, double seaLevel)
 Sets a transform on the surface of the celestial body More...
 
- Properties inherited from Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo
double Altitude [get]
 Returns the altitude of the terrain under the gizmo position. More...
 
double Latitude [get]
 Returns the latitude of the gizmo in the celestial body. More...
 
double Longitude [get]
 Returns the longitude of the gizmo in the celestial body. More...
 

Member Function Documentation

virtual Transform Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.GetFocusTarget ( )
inlinevirtual
virtual string Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.GetFooterText ( )
inlinevirtual

This method will prepara the top section of the text in the gap window.

Returns
The string to be show on the gap window.

Reimplemented in Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Volume, Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Area, and Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_PlaceVessel.

override void Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.Initialize ( GAPCelestialBody  newGapRef)
inlinevirtual

Called after the gizmo is instantiated to initialize its corresponding values.

Parameters
newGapRefThe reference to the GAPCelestiaBody script, it handles the camera movement etc...

Reimplemented from Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo.

Reimplemented in Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Volume, Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Area, and Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_PlaceVessel.

override bool Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.IsActive ( )
inlinevirtual

Checks if the gizmo is enabled to be interacted with.

Returns
True if there is a selected handle.

Reimplemented from Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo.

Reimplemented in Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Volume, and Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Area.

bool Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.IsDragReady ( )
inline

Checks if there is a gizmo handle selected.

Returns
True if there is a gizmo to be dragged or false if there is no handle selected.
void Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.OnButtonPressed_FocusTarget ( )
inline

The event executed when the Focus Target button is pressed.

virtual void Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.OnGAPClick ( double  newLatitude,
double  newLongitude 
)
inlinevirtual

Called when GAP window is clicked.

Parameters
newLatitudeThe latitude position of the mouse corresponding to the surface of the planet.
newLongitudeThe longitude position of the mouse corresponding to the surface of the planet.

Reimplemented in Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Volume, and Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Area.

virtual void Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.OnGAPDrag ( double  dragStartLatitude,
double  dragStartLongitude,
double  dragLatitude,
double  dragLongitude 
)
inlinevirtual

Called when there is a drag gesture on the GAP window.

Parameters
dragStartLatitudeThe latitude position when the drag gesture started.
dragStartLongitudeThe longitude posiion when the drag gesture started.
dragLatitudeThe latitude position of the mouse corresponding to the surface of the planet.
dragLongitudeThe longiutde position of the mouse corresponding to the surface of the planet.

Reimplemented in Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Volume, and Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Area.

virtual void Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.OnGAPDragEnd ( )
inlinevirtual

Called when the drag gesture over the gap window has ended.

Reimplemented in Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Volume, and Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Area.

virtual void Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.OnGAPOver ( double  hoverLatitude,
double  hoverLongitude 
)
inlinevirtual

Called when the mouse is over the GAP window.

Parameters
hoverLatitudeThe latitude position of the mouse corresponding to the surface of the planet.
hoverLongitudeThe longitude position of the mouse corresponding to the surface of the planet.

Reimplemented in Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Volume, and Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Area.

virtual void Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.OnGizmoHandleDrag ( double  dragStartLatitude,
double  dragStartLongitude,
double  dragLatitude,
double  dragLongitude 
)
inlinevirtual

Called when a handle of the gizmo is getting dragged.

Parameters
dragStartLatitudeThe latitude position when the drag gesture started.
dragStartLongitudeThe longitude posiion when the drag gesture started.
dragLatitudeThe latitude position of the mouse corresponding to the surface of the planet.
dragLongitudeThe longiutde position of the mouse corresponding to the surface of the planet.

Reimplemented in Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_PlaceVessel.

virtual void Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.OnGizmoHandleDragEnd ( )
inlinevirtual

Called when the drag gesture over one of the handles has ended.

Reimplemented in Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_PlaceVessel.

virtual void Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.OnGizmoHandleOver ( double  hoverLatitude,
double  hoverLongitude 
)
inlinevirtual

Called when the mouse is over a gizmo object.

Parameters
hoverLatitudeThe latitude position of the mouse corresponding to the surface of the planet.
hoverLongitudeThe longitude position of the mouse corresponding to the surface of the planet.
virtual void Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.OnGizmoHandleSelected ( GAPCelestialBodyGizmoHandle  selectedHandle)
inlinevirtual

Called when a gizmo has been clicked to be interacted with.

Parameters
selectedHandleThe handle that was selected.

Reimplemented in Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Volume, Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Area, and Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_PlaceVessel.

override void Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.OnLoadPlanet ( CelestialBody  newCelestialBody)
inlinevirtual

Called when a new planet is loaded (To reset any values if needed)

Parameters
newCelestialBody

Reimplemented from Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo.

Reimplemented in Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Volume, and Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo_Area.

delegate void Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.OnPointTranslate ( double  latitude,
double  longitude 
)
override void Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.OnUpdate ( )
inlinevirtual
override double Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.SetGizmoPosition ( double  newLatitude,
double  newLongitude,
double  newAltitude 
)
inlinevirtual

Sets the GAP gizmo on the celestial body surface from the latitude and longitude values. Altitude is calculated automatically.

Parameters
latitudeThe latitude value
longitudeThe longitude value

Reimplemented from Expansions.Missions.Editor.GAPCelestialBody_SurfaceGizmo.

bool Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.TrySelectHandle ( Collider  handleCollider)
inline

A method to check the status of the gizmo handles. It will compare a collider to see if its a handle, and if it is it will select it if its intended. It uses a collider since the test method is a raycast to the surface of the planet.

Parameters
handleColliderThe collider to be checked if its a gizmo handle.
Returns
If the gizmo was selected or not.

Member Data Documentation

List<GAPCelestialBodyGizmoHandle> Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.gizmoHandles
OnPointTranslate Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.OnGAPGizmoTranslate
GAPCelestialBodyGizmoHandle Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.selectedHandle
protected
Sprite Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.spriteFocusCelestialBody
Sprite Expansions.Missions.Editor.GAPCelestialBody_InteractiveSurfaceGizmo.spriteFocusTarget

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