UE3:GameReplicationInfo (UT3)
Object >> Actor >> Info >> ReplicationInfo >> GameReplicationInfo |
- Package:
- Engine
- Direct subclass:
- UTGameReplicationInfo
- This class in other games:
Since GameInfo only exists on the server in network games, this class handles all game-specific data clients need to know about.
Properties
Property group 'GameReplicationInfo'
AdminEmail
Type: string
Modifiers: databinding, globalconfig
Email address of the server admin.
AdminName
Type: string
Modifiers: databinding, globalconfig
Name of the server admin.
MessageOfTheDay
Type: string
Modifiers: databinding, globalconfig
Default value: "Welcome to a UT3 Server!"
ServerName
Type: string
Modifiers: databinding, globalconfig
Name of the server, i.e.: Bob's Server.
ServerRegion
Type: int
Modifiers: databinding, globalconfig
Region of the game server.
ShortName
Type: string
Modifiers: databinding, globalconfig
Abbreviated name of server, i.e.: B's Serv (stupid example)
Default value: "UT3 Server"
Internal variables
bIsArbitrated
Type: bool
Used to determine who handles session ending
bMatchHasBegun
Type: bool
Modifiers: repnotify
bMatchIsOver
Type: bool
Modifiers: repnotify
bNeedsOnlineCleanup
Type: bool
Used to determine if the end of match/session clean up is needed. Game invites might have already cleaned up the match/session so doing so again would break the traveling to the invited game
bStopCountDown
Type: bool
Default value: True
bTrackStats
Type: bool
CurrentGameData
Type: CurrentGameDataStore
Modifiers: private
The data store instance responsible for presenting state data for the current game session.
ElapsedTime
Type: int
Modifiers: databinding
GameClass
Class of the server's gameinfo, assigned by GameInfo.
GoalScore
Type: int
Modifiers: databinding
InactivePRIArray
Type: array<PlayerReplicationInfo>
This list mirror's the GameInfo's list of inactive PRI objects
MatchID
Type: int
MaxLives
Type: int
Modifiers: databinding
PRIArray
Type: array<PlayerReplicationInfo>
RemainingMinute
Type: int
Modifiers: databinding
RemainingTime
Type: int
Modifiers: databinding
SecondCount
Type: float
Modifiers: databinding
Teams
Modifiers: databinding
TimeLimit
Type: int
Modifiers: databinding
Winner
Type: Actor
Modifiers: databinding
set by gameinfo when game ends
Default values
Property | Value |
---|---|
TickGroup | TG_DuringAsyncWork |
Functions
Native functions
OnSameTeam
Checks to see if two actors are on the same team.
Returns:
- True if both actors are on the same team, False otherwise.
Native implementation:
UBOOL AGameReplicationInfo::OnSameTeam(AActor *A, AActor *B)
{
if ( !A || !B )
{
return FALSE;
}
if ( GameClass )
{
AGameInfo *DefaultGameActor = GameClass->GetDefaultObject<AGameInfo>();
if ( DefaultGameActor && !DefaultGameActor->bTeamGame )
{
return FALSE;
}
}
BYTE ATeamIndex = A->GetTeamNum();
if ( ATeamIndex == 255 )
{
return FALSE;
}
BYTE BTeamIndex = B->GetTeamNum();
if ( BTeamIndex == 255 )
{
return FALSE;
}
return ( ATeamIndex == BTeamIndex );
}
Events
Destroyed
Overrides: Actor.Destroyed
Called when this actor is destroyed
OnlineSession_EndMatch
Signal that this match is over.
NETWORK - Both Client and Server
OnlineSession_EndSession
Signal that this session is over. Called natively
NETWORK - Both Client and Server
OnlineSession_StartMatch
Signal that this match has begun
NETWORK - Both Client and Server
PostBeginPlay
Overrides: Actor.PostBeginPlay
ReplicatedEvent
Overrides: Actor.ReplicatedEvent
Reset
Overrides: Actor.Reset
Timer
Overrides: Actor.Timer
Other instance functions
AddPRI
CleanupGameDataStore
Unregisters the data store for the current game session.
EndGame
Called on the server when the match is over
Network - Server and Client (Via ReplicatedEvent)
FindPlayerByID
GetOnlineGameInterface
Returns:
- a reference to the OnlineGameInterface if one exists. Network: Client and Server
GetPRIArray
InitializeGameDataStore
Creates and registers a data store for the current game session.
InOrder
returns true if P1 should be sorted before P2
IsCoopMultiplayerGame
Is the current gametype a coop multiplayer game?
IsMultiplayerGame
Is the current gametype a multiplayer game?
PreventPause
hook to allow the GRI to prevent pausing; used when it's performing asynch tasks that must be completed
RemovePRI
SetTeam
Assigns the specified TeamInfo to the location specified.
Parameters:
- Index - location in the Teams array to place the new TeamInfo.
- TI - the TeamInfo to assign
SortPRIArray
StartMatch
Called on the server when the match has begin
Network - Server and Client (Via ReplicatedEvent)