| Home Page | Recent Changes

Viewport

Object >> Player >> ViewPort

See UnrealEd Viewport for the viewports in the UnrealEd interface.

This class represents a real Player playing on this (where unreal is running that is) computer. Useful if you wish to detect if a PlayerPawn or PlayerController is controlled locally.

This is a native class without any UnrealScript source code.

Usage

Here's how you can check the type of connection of a player:

if ( Viewport(SomePlayerPawn.Player) != None ) {
  //This player is controlled locally.
}
else if ( NetConnection(SomePlayerPawn.Player) != None ) {
  // This player is controlled remotely.
}
else {
  // This player is not controlled by anybody.
  // The player might be in the process of connecting or this
  // could be a script-spawned PlayerPawn/PlayerController.
}

Category Class (UT)
Category Class (UT2003)
Category Class (UT2004)

The Unreal Engine Documentation Site

Wiki Community

Topic Categories

Recent Changes

Offline Wiki

Unreal Engine

Console Commands

Terminology

FAQs

Help Desk

Mapping Topics

Mapping Lessons

UnrealEd Interface

UnrealScript Topics

UnrealScript Lessons

Making Mods

Class Tree

Modeling Topics

Chongqing Page

Log In