MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / EndPilot

Method EndPilot

Source/Editor/Windows/EditGameWindow.cs:219–239  ·  view source on GitHub ↗

Ends the actor piloting mode.

()

Source from the content-addressed store, hash-verified

217 /// Ends the actor piloting mode.
218 /// </summary>
219 public void EndPilot()
220 {
221 if (_pilotActor == null)
222 return;
223
224 if (Editor.Undo.Enabled)
225 {
226 ActorNode node = Editor.Scene.GetActorNode(_pilotActor);
227 bool navigationDirty = node.AffectsNavigationWithChildren;
228 var action = new TransformObjectsAction
229 (
230 new List<SceneGraphNode> { node },
231 new List<Transform> { _pilotStart },
232 ref _pilotBounds,
233 navigationDirty
234 );
235 Editor.Undo.AddAction(action);
236 }
237 _pilotActor = null;
238 _pilotWidget.Parent.Visible = false;
239 }
240
241 private void SceneOnActorRemoved(ActorNode actorNode)
242 {

Callers 1

PilotActorMethod · 0.80

Calls 2

GetActorNodeMethod · 0.80
AddActionMethod · 0.80

Tested by

no test coverage detected