I'm a doctor, not a mechanic

UE3:UISceneClient (UT3)

From Unreal Wiki, The Unreal Engine Documentation Site
Jump to: navigation, search
UT3 Object >> UIRoot >> UISceneClient
Package: 
Engine
Direct subclasses:
EditorUISceneClient, GameUISceneClient
This class in other games:
UDK

Serves as the interface between a UIScene and scene owners. Provides scenes with all data necessary for operation and routes rendering to the scenes.

Copyright 1998-2007 Epic Games, Inc. All Rights Reserved.

Properties

ActiveControl

Type: UIObject

Modifiers: const, transient

Represents the widget/scene that is currently under the mouse cursor.

Fixme: splitscreen

ActiveSkin

Type: UISkin

Modifiers: transient

The active UISkin. Only one UISkin can be active at a time. The special data store name 'Styles' always corresponds to the ActiveSkin.

bEnablePostProcess

Type: bool

Modifiers: transient

if TRUE then post processing is enabled using the UIScenePostProcess

CanvasToScreen

Type: Object.Matrix

Modifiers: const, transient

Stores the 3D projection matrix being used to render the UI.

DataStoreManager

Type: DataStoreClient

Modifiers: const, transient

Manager all persistent global data stores. Set by the object that creates the scene client.

InvCanvasToScreen

Type: Object.Matrix

Modifiers: const, transient


MousePosition

Type: Object.IntPoint

Modifiers: const, transient

the location of the mouse

Fixme: splitscreen

OpacityParameter

Type: MaterialInstanceConstant

Modifiers: transient

Material instance parameter for UI widget opacity.

OpacityParameterName

Type: name

Modifiers: const, transient

Name of the opacity parameter.

RenderViewport

Type: pointer{FViewport}

Modifiers: const, transient, native

the viewport to use for rendering scenes

UIScenePostProcess

Type: PostProcessChain

Modifiers: transient

Post process chain to be applied when rendering UI Scenes

Functions

Native functions

ChangeActiveSkin

native final noexport function bool ChangeActiveSkin (UISkin NewActiveSkin)

Changes the active skin to the skin specified, initializes the skin and performs all necessary cleanup and callbacks. This method should only be called from script.

Parameters:

  • NewActiveScene - The skin to activate

Returns:

TRUE if the skin was successfully changed.

ChangeMouseCursor

native final virtual function bool ChangeMouseCursor (name CursorName)

Changes the resource that is currently being used as the mouse cursor. Called by widgets as they changes states, or when some action occurs which affects the mouse cursor.

Parameters:

  • CursorName - the name of the mouse cursor resource to use. Should correspond to a name from the active UISkin's MouseCursorMap

Returns:

TRUE if the cursor was successfully changed.

CloseScene

native function bool CloseScene (UIScene Scene)

Deactivates the specified scene, as well as all scenes which occur after the specified scene in the list of active scenes.

Parameters:

  • Scene - the scene to deactivate

Returns:

true if the scene was successfully deactivated

GetCanvasToScreen

native final function Object.Matrix GetCanvasToScreen (optional const UIObject Widget) const

Returns the current canvas to screen projection matrix.

Parameters:

  • Widget - if specified, the returned matrix will include the widget's tranformation matrix as well.

Returns:

a matrix which can be used to project 2D pixel coordines into 3D screen coordinates. ??

GetInverseCanvasToScreen

native final function Object.Matrix GetInverseCanvasToScreen (optional const UIObject Widget) const

Returns the inverse of the local to world screen projection matrix.

Parameters:

  • Widget - if specified, the returned matrix will include the widget's tranformation matrix as well.

Returns:

a matrix which can be used to transform normalized device coordinates (i.e. origin at center of screen) into into 0,0 based pixel coordinates. ??

InitializeScene

native final noexport function bool InitializeScene (UIScene Scene, optional LocalPlayer SceneOwner, optional out UIScene InitializedScene)

Initializes the specified scene without opening it.

Parameters:

  • Scene - the scene to initialize; if the scene specified is contained in a content package, a copy of the scene will be created, and that scene will be initialized instead.
  • SceneOwner - the player that should be associated with the new scene. Will be assigned to the scene's PlayerOwner property.
  • InitializedScene - the scene that was actually initialized. If Scene is located in a content package, InitializedScene will be the copy of the scene that was created. Otherwise, InitializedScene will be the same as the scene passed in.

Returns:

TRUE if the scene was successfully initialized

Note: noexport to handle the optional out parameter correctly

IsSceneInitialized

native final noexport function bool IsSceneInitialized (UIScene Scene) const

Returns whether the specified scene has been fully initialized. Different from UUIScene::IsInitialized() in that this method returns true only once all objects related to this scene have been created and initialized (e.g. in the UI editor only returns TRUE once the editor window for this scene has finished creation).

Parameters:

  • Scene - the scene to check.

Note: noexport because the C++ version is a pure virtual

IsUIActive

native final noexport function bool IsUIActive (optional int Flags) const

Returns true if there is an unhidden fullscreen UI active

Parameters:

  • Flags - a bitmask of values which alter the result of this method; the bits are derived from the ESceneFilterTypes enum (which is native-only); script callers must pass these values literally

Returns:

TRUE if the UI is currently active

OpenScene

native final noexport function bool OpenScene (UIScene Scene, optional LocalPlayer SceneOwner, optional out UIScene OpenedScene)

Initializes and activates the specified scene.

Parameters:

  • Scene - the scene to open; if the scene specified is contained in a content package, a copy of the scene will be created and the copy will be opened instead.
  • SceneOwner - the player that should be associated with the new scene. Will be assigned to the scene's PlayerOwner property.
  • OpenedScene - the scene that was actually opened. If Scene is located in a content package, OpenedScene will be the copy of the scene that was created. Otherwise, OpenedScene will be the same as the scene passed in.

Returns:

TRUE if the scene was successfully opened

Note: noexport to handle the optional out parameter correctly

SetMousePosition

native final virtual function SetMousePosition (int NewMouseX, int NewMouseY)

Set the mouse position to the coordinates specified

Parameters:

  • NewX - the X position to move the mouse cursor to (in pixels)
  • NewY - the Y position to move the mouse cursor to (in pixels)

UpdateCanvasToScreen

native final function noexport UpdateCanvasToScreen ()

Changes the matrix for projecting local (pixel) coordinates into world screen (normalized device) coordinates. This method should be called anytime the viewport size or origin changes.

Other instance functions

GetActiveScene

function UIScene GetActiveScene ()

Returns the currently active scene