Installation

Installing Pegasus will create the following folder structure:

Pegasus:

  • Demo: A simple demo scene
  • Documentation: Pegasus documentation
  • Scripts: Pegasus source code

Concepts

Pegasus allows any object to be driven through a scene and provides fine grained control of its speed, location and what it is looking at.

While Pegasus was designed to create fly throughs and cut scenes, it can drive any object that drop into its Target Object slot.

The main Pegasus components are:

  • Pegasus Manager – Pegasus manager controls the position, location and direction of an object over time within the scene.
  • Pegasus POI – Pegasus POI or points of interest are the locations that the flythrough will pass through as it is executed.

 

Workflow

Main workflow:

  1. Add a Pegasus Manager to your scene by selecting GameObject->Pegasus->Add Pegasus Manager.
  2. Drag your camera or target object into the Target Object slot on the Pegasus Manager – this is the thing that will be controlled by Pegasus when Play is pressed.
  3. Add Pegasus POI to your scene by clicking Ctrl + Left Mouse Button at each location you would like your target to pass through.
    1. You will see a Gizmo place at every location on which you click, and when you place two or more, they will be joined up by a path visualisation spline.
    2. The path visualisation spline allows you to visualise where Pegasus will drive your target.
  4. Press Play to start your scene. Pegasus will start playback when you start your scene.

From here:

  1. Change the settings in your manager to change the way the overall flythrough operates.
  2. Customise individual POI segments to change the way the flythrough operates thought that POI segment.

Pegasus Manager Settings

The Pegasus Manager orchestrates and controls a Pegasus flythrough. You can have as many managers as you like in your scene.

These settings can also be viewed by hovering over the setting in the editor.

Target Object: The object that will be controlled by Pegasus manager. You would typically drop a game object with a camera attached to it – but this could just as easily be any game object you wanted to drive through the scene.

Flythrough Type: The type of flythrough - a single shot or a connected loop.

Flythrough End: What to do at the end of the flythrough - quit the application or stop the flythrough. Only shows when a single shot flythrough is selected.

Play on Start: Plays the flythrough on start up when selected.

Advanced: Shows advanced options when selected.

Framerate: The framerate that the game will be controlled at. Set V Sync Count to Don't Sync in your project Quality settings or Unity will ignore this setting.

Check Height: Used to control how poi, lookat target and flythrough path heights are constrained. Collision - use whatever it collides with, Terrain - use the terrain height, None - don't constrain.

Min POI Height: The minimum height that POI and collisions will be tested for.

Rotation Damping: The amount of damping or smoothing to apply to the rotation of the target. Larger values mean slower rotations.

Position Damping: The amount of damping or smoothing to apply to the position of the target. Larger values will do smoother flythroughs, but with less precision through POIs so it should be used with care.

Gizmo Size: The size of the Gizmos. Larger Gizmos are easier to see.

Statistics: Handy statistics about the current flythrough.

Distance: The distance of the flythrough.

Duration: The duration of one loop of the flythrough.

Visualisation: Allows the trajectory of the flythrough to be visualised in editor. If using a target object that has a camera then click on the game view to see what the camera looks at and how it progresses through the scene.

Scrubber: Drag this control to move the target along the timeline - designed for edit mode visualisation. Select the Game View to get the best effect.

Step Backward: Step backwards through the flythrough.

Step Forward: Step forwards through the flythrough.

Show Debug: Show flythrough debug messages.

Utilities: Some simple and handy utilities to aid in flythrough creation and visualisation.

Go To First POI: Select the first POI in the scene editor.

Set POI To Min Height: Sets all POI to the Min POI Height shown in the editor.

Show Debug on POI: Displays a cross centred on the POI.

Hide Debug on POI: Hides the cross centred on the POI.

 

Pegasus POI Settings

The Pegasus POI controls where and how the target will travel through the segment controlled by the POI.

When selected in the editor, the segment changes colour so that you can see its path.

These settings can also be viewed by hovering over the setting in the editor.

 

Target Lookat: These settings control what the target will look at when passing through this segment.

Target: Where the target should look. Path - the target will look along the path of the flythrough. Target - the target will look at a custom target.

Angle: The angle from the POI to the camera target.

Distance: The distance from the POI to the camera target.

Height: The height of the POI above the terrain or collider at the target location.

Target Speed: These settings control how fast the target will travel along this segment.

Type: Change the flythrough speed in common units.

Speed: Manually control the flythrough speed.

Height Constraint: How the target will be height constrained. Stops the target from going under the things it shouldn’t e.g. the terrain.

Min Height From: Used to control how poi, lookat target and flythrough path heights are constrained. Manager - use the managers settings, collision - use whatever it collides with, terrain - use the terrain height, none - don't constrain.

Statistics: Handy statistics about the current POI’s segment.

Distance: The distance of the segment.

Start Time: The time after the start of the playback that this segment will start.

End Time: The time after the start of the playback that this segment will end.

Total Time: The duration of one loop of the flythrough.

Utilities: Some simple and handy utilities to aid in flythrough creation and visualisation.

Select Manager: Selects the POI manager in the scene editor.

Select First POI: Select the first POI in the scene editor.

Select Previous POI: Select the previous POI in the scene editor.

Select Next POI: Select the next POI in the scene editor.

Add POI Before: Add a POI before this POI in the scene editor.

Add POI After: Add a POI after this POI in the scene editor.

 

Deleting POI can be done by simply deleting the POI object that has been parented under the Pegasus Manager object in the scene hierarchy.

Re-Ordering POI can be done by simply dragging the POI object to a different location underneath the Pegasus Manager object in the scene hierarchy. To complete the re-organisation just click on the Pegasus Manager.

Click here for the Pegasus Forums. Click here to get Pegasus on the Unity Asset Store.