Table of Contents

Class InGamePresenter

Namespace
FrameOfReference.Presentation
Assembly
FrameOfReference.Presentation.dll

Main in-game interaction

public sealed class InGamePresenter : InteractivePresenter, IDisposable, IInputReceiver
Inheritance
InGamePresenter
Implements
Inherited Members
Extension Methods

Constructors

InGamePresenter(Engine, Universe)

Creates a new presenter for the actual running game

public InGamePresenter(Engine engine, Universe universe)

Parameters

engine Engine

The engine to use for rendering

universe Universe

The universe to display

Methods

HookIn()

Hooks the View into Views

public override void HookIn()

Remarks

Will internally call Initialize() first, if you didn't

HookOut()

Hooks the View out of Views

public override void HookOut()

LockOn(string)

Sets SelectedPositionables to a single specific Entity and forces the Camera to stay close to it.

public void LockOn(string name)

Parameters

name string

The Name of a Entity stored in the Universe.

MovePositionables(IEnumerable<Positionable<Vector2>>, Vector2)

Moves one or more Positionable<TCoordinates>s to a new position.

protected override void MovePositionables(IEnumerable<Positionable<Vector2>> positionables, Vector2 target)

Parameters

positionables IEnumerable<Positionable<Vector2>>

The Positionable<TCoordinates>s to be moved.

target Vector2

The terrain position to move the positionables to.

PickPositionables(IEnumerable<Positionable<Vector2>>, bool)

protected override void PickPositionables(IEnumerable<Positionable<Vector2>> positionables, bool accumulate)

Parameters

positionables IEnumerable<Positionable<Vector2>>

The selected Positionable<TCoordinates>s.

accumulate bool

true when the user wants the new selection to be added to the old one.

PrepareSave()

Writes back data to Universe so that state gets stored in savegames.

public void PrepareSave()

ReleaseLock()

Releases a camera lock applied by LockOn(string).

public void ReleaseLock()

SwingCameraTo(string)

Switches from the current camera view to a new view using a cinematic effect.

public void SwingCameraTo(string name)

Parameters

name string

The Name of a CameraState<TCoordinates> stored in the Universe.