Overview Package Class Source Class tree Glossary
previous class      next class frames      no frames

Engine.GameplayEventsReader


00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087
/**
 * Copyright 1998-2011 Epic Games, Inc. All Rights Reserved.
 *
 * Streams gameplay events recorded during a session to disk
 */
class GameplayEventsReader extends GameplayEvents
	config(Game)
	native;

/** Array of handlers for this file when it processes */
var transient array<GameplayEventsHandler> RegisteredHandlers;

/** 
 *   Loads a stat file from disk
 * @param Filename - name of the file that will be open for serialization
 * @return TRUE if successful, else FALSE
 */
native function bool OpenStatsFile(string Filename);

/** 
 * Closes and deletes the archive being read from
 * clearing all data stored within
 */
native function CloseStatsFile();

/** Serialize the contents of the file header */
native protected function bool SerializeHeader();

/** Register a handler with this reader */
event RegisterHandler(GameplayEventsHandler NewHandler)
{
	local int AddIndex;
	if (RegisteredHandlers.Find(NewHandler) == INDEX_NONE)
	{
		AddIndex = RegisteredHandlers.Length;
		RegisteredHandlers.Length = RegisteredHandlers.Length + 1;
		RegisteredHandlers[AddIndex] = NewHandler;
		NewHandler.SetReader(self);
	}
}

/** Unregister a handler with this reader */
event UnregisterHandler(GameplayEventsHandler ExistingHandler)
{
	local int RemoveIndex;
	RemoveIndex = RegisteredHandlers.Find(ExistingHandler);
	// Verify that it is in the array
	if (RemoveIndex != INDEX_NONE)
	{
		RegisteredHandlers.Remove(RemoveIndex,1);
		ExistingHandler.SetReader(None);
	}
}

/** Signal start of stream processing */
native private function ProcessStreamStart();

/** Read / process stream data from the file */
native function ProcessStream();

/** Signal end of stream processing */
native private function ProcessStreamEnd();

/** Return the unique session ID */
native function string GetSessionID();

/** Return the title ID of the recorded session */
native function int GetTitleID();

/** Return the platform the data was recorded on */
native function int GetPlatform();

/** Return the timestamp the session started recording */
native function string GetSessionTimestamp();

/** Get the time the session started */
native function float GetSessionStart();

/** Get the time the session ended */
native function float GetSessionEnd();

/** Return the total time the session lasted */
native function float GetSessionDuration();

defaultproperties
{
}

Overview Package Class Source Class tree Glossary
previous class      next class frames      no frames
Class file time: to 6-1-2011 07:10:38.000 - Creation time: ti 22-3-2011 19:57:06.089 - Created with UnCodeX