Always snap to grid

Difference between revisions of "UE3:Console (UT3)"

From Unreal Wiki, The Unreal Engine Documentation Site
Jump to: navigation, search
(Talk)
m (1 revision)
 
(One intermediate revision by the same user not shown)
(No difference)

Latest revision as of 02:21, 26 July 2008

UT3 Object >> UIRoot >> Interaction >> Console
Package: 
Engine
Within class: 
GameViewportClient
Direct subclass:
UTConsole
This class in other games:
RTNP, U1, UT, UE2Runtime, U2XMP, U2, UT2003, UT2004, UDK

Console - A quick little command line console that accepts most commands. Copyright 1998-2008 Epic Games, Inc. All Rights Reserved.

Constants[edit]

MaxHistory[edit]

Value: 16

  1. of command history to remember.

Properties[edit]

bCaptureKeyInput[edit]

Type: bool

Modifiers: transient

Indicates that InputChar events should be captured to prevent them from being passed on to other interactions. Reset when the another keydown event is received.

bCtrl[edit]

Type: bool

True while a control key is pressed.

bEnableUI[edit]

Type: bool

Modifiers: config


ConsoleBufferText[edit]

Type: UILabel


ConsoleKey[edit]

Type: name

Modifiers: globalconfig

The key which opens the console.

Default value: 'F10'

ConsoleTargetPlayer[edit]

Type: LocalPlayer

The player which the next console command should be executed in the context of. If NULL, execute in the viewport.

DefaultTexture_Black[edit]

Type: Texture2D


Default value: Texture2D'EngineResources.Black'

DefaultTexture_White[edit]

Type: Texture2D


Default value: Texture2D'EngineResources.White'

History[edit]

Type: string

Array size: 16 (MaxHistory)

Modifiers: config

tracks previously entered console commands

HistoryBot[edit]

Type: int

Modifiers: config

index into the History array for the earliest command that was entered

Default value: -1

HistoryCur[edit]

Type: int

Modifiers: config

the index of the current position in the History array

HistoryTop[edit]

Type: int

Modifiers: config

index into the History array for the latest command that was entered

LargeConsoleInput[edit]

Type: ConsoleEntry


LargeConsoleScene[edit]

Type: UIScene


MaxScrollbackSize[edit]

Type: int

Modifiers: globalconfig

Visible Console stuff

Default value: 1024

MiniConsoleInput[edit]

Type: ConsoleEntry


MiniConsoleScene[edit]

Type: UIScene


SBHead[edit]

Type: int

Where in the scrollback buffer are we

SBPos[edit]

Type: int

Where in the scrollback buffer are we

Scrollback[edit]

Type: array<string>

Holds the scrollback buffer

TypedStr[edit]

Type: string

The command the user is currently typing.

TypedStrPos[edit]

Type: int

Current position in TypedStr

TypeKey[edit]

Type: name

Modifiers: globalconfig

The key which opens the typing bar.

Default value: 'Tab'

Default values[edit]

Property Value
OnReceivedNativeInputChar InputChar
OnReceivedNativeInputKey InputKey

Functions[edit]

Events[edit]

OutputText[edit]

event OutputText (coerce string Text)

Prints a (potentially multi-line) string of text to the console. The text is split into separate lines and passed to OutputTextLine.

Parameters:

  • Text - Text to display on the console.

Other instance functions[edit]

AppendInputText[edit]

function AppendInputText (string Text)

appends the specified text to the string of typed text

ClearOutput[edit]

function ClearOutput ()

Clears the console output buffer.

ConsoleCommand[edit]

function ConsoleCommand (string Command)

Executes a console command.

Parameters:

  • Command - The command to execute.

FlushPlayerInput[edit]

function FlushPlayerInput ()

Clears out all pressed keys from the player's input object.

Initialized[edit]

function Initialized ()

Overrides: Interaction.Initialized

Called when the Console is added to the GameViewportClient's Interactions array.

InputChar[edit]

function bool InputChar (int ControllerId, string Unicode)

Process a character input event (typing) routed through unrealscript from another object. This method is assigned as the value for the OnRecievedNativeInputKey delegate so that native input events are routed to this unrealscript function.

Parameters:

  • ControllerId - the controller that generated this character input event
  • Unicode - the character that was typed

Returns:

True to consume the character, false to pass it on.

InputKey[edit]

function bool InputKey (int ControllerId, name Key, Object.EInputEvent Event, float AmountDepressed, bool bGamepad)

Process an input key event routed through unrealscript from another object. This method is assigned as the value for the OnRecievedNativeInputKey delegate so that native input events are routed to this unrealscript function.

Parameters:

  • ControllerId - the controller that generated this input key event
  • Key - the name of the key which an event occured for (KEY_Up, KEY_Down, etc.)
  • EventType - the type of event which occured (pressed, released, etc.)
  • AmountDepressed - for analog keys, the depression percent.

Returns:

true to consume the key event, false to pass it on.

IsUIConsoleOpen[edit]

function bool IsUIConsoleOpen ()


IsUIMiniConsoleOpen[edit]

function bool IsUIMiniConsoleOpen ()


OutputTextLine[edit]

function OutputTextLine (coerce string Text)

Prints a single line of text to the console.

Parameters:

  • Text - A line of text to display on the console.

PostRender_Console[edit]

function PostRender_Console (Canvas Canvas)


ProcessControlKey[edit]

function bool ProcessControlKey (name Key, Object.EInputEvent Event)

looks for Control key presses and the copy/paste combination that apply to both the console bar and the full open console

PurgeCommandFromHistory[edit]

function PurgeCommandFromHistory (string Command)

Searches console command history and removes any entries matching the specified command.

Parameters:

  • Command - The command to search for and purge from the history.

SetCursorPos[edit]

function SetCursorPos (int Position)


SetInputText[edit]

function SetInputText (string Text)


StartTyping[edit]

function StartTyping (coerce string Text)

Opens the typing bar with text already entered.

Parameters:

  • Text - The text to enter in the typing bar.

States[edit]

Open[edit]

Open.BeginState[edit]

event BeginState (name PreviousStateName)

Overrides: Object.BeginState (global)

Called immediately when entering a state, while within the GotoState() call that caused the state change (before any state code is executed).

Open.EndState[edit]

event EndState (name NextStateName)

Overrides: Object.EndState (global)

Called immediately before going out of the current state, while within the GotoState() call that caused the state change, and before BeginState() is called within the new state.

Open.PostRender_Console[edit]

event PostRender_Console (Canvas Canvas)

Overrides: PostRender_Console (global)


Open.InputChar[edit]

function bool InputChar (int ControllerId, string Unicode)

Overrides: InputChar (global)

(Description copied from Console.InputChar)
Process a character input event (typing) routed through unrealscript from another object. This method is assigned as the value for the OnRecievedNativeInputKey delegate so that native input events are routed to this unrealscript function.

Parameters:

  • ControllerId - the controller that generated this character input event
  • Unicode - the character that was typed

Returns:

True to consume the character, false to pass it on.

Open.InputKey[edit]

function bool InputKey (int ControllerId, name Key, Object.EInputEvent Event, float AmountDepressed, bool bGamepad)

Overrides: InputKey (global)

Process an input key event routed through unrealscript from another object. This method is assigned as the value for the OnRecievedNativeInputKey delegate so that native input events are routed to this unrealscript function.

Parameters:

  • ControllerId - the controller that generated this input key event
  • Key - the name of the key which an event occured for (KEY_Up, KEY_Down, etc.)
  • EventType - the type of event which occured (pressed, released, etc.)
  • AmountDepressed - for analog keys, the depression percent.

Returns:

true to consume the key event, false to pass it on.

Typing[edit]

This state is used when the typing bar is open.

Typing.BeginState[edit]

event BeginState (name PreviousStateName)

Overrides: Object.BeginState (global)

Called immediately when entering a state, while within the GotoState() call that caused the state change (before any state code is executed).

Typing.EndState[edit]

event EndState (name NextStateName)

Overrides: Object.EndState (global)

Called immediately before going out of the current state, while within the GotoState() call that caused the state change, and before BeginState() is called within the new state.

Typing.PostRender_Console[edit]

event PostRender_Console (Canvas Canvas)

Overrides: PostRender_Console (global)


Typing.InputChar[edit]

function bool InputChar (int ControllerId, string Unicode)

Overrides: InputChar (global)

Process a character input event (typing) routed through unrealscript from another object. This method is assigned as the value for the OnRecievedNativeInputKey delegate so that native input events are routed to this unrealscript function.

Parameters:

  • ControllerId - the controller that generated this character input event
  • Unicode - the character that was typed

Returns:

True to consume the character, false to pass it on.

Typing.InputKey[edit]

function bool InputKey (int ControllerId, name Key, Object.EInputEvent Event, float AmountDepressed, bool bGamepad)

Overrides: InputKey (global)

Process an input key event routed through unrealscript from another object. This method is assigned as the value for the OnRecievedNativeInputKey delegate so that native input events are routed to this unrealscript function.

Parameters:

  • ControllerId - the controller that generated this input key event
  • Key - the name of the key which an event occured for (KEY_Up, KEY_Down, etc.)
  • EventType - the type of event which occured (pressed, released, etc.)
  • AmountDepressed - for analog keys, the depression percent.

Returns:

true to consume the key event, false to pass it on.