Packageorg.flixel.system.replay
Classpublic class FrameRecord
InheritanceFrameRecord Inheritance Object

Helper class for the new replay system. Represents all the game inputs for one "frame" or "step" of the game loop.



Public Properties
 PropertyDefined By
  frame : int
Which frame of the game loop this record is from or for.
FrameRecord
  keys : Array
An array of simple integer pairs referring to what key is pressed, and what state its in.
FrameRecord
  mouse : MouseRecord
A container for the 4 mouse state integers.
FrameRecord
Public Methods
 MethodDefined By
  
Instantiate array new frame record.
FrameRecord
  
create(Frame:Number, Keys:Array = null, Mouse:MouseRecord = null):FrameRecord
Load this frame record with input data from the input managers.
FrameRecord
  
destroy():void
Clean up memory.
FrameRecord
  
load(Data:String):FrameRecord
Load the frame record data from array simple ASCII string.
FrameRecord
  
save():String
Save the frame record data to array simple ASCII string.
FrameRecord
Property Detail
frameproperty
public var frame:int

Which frame of the game loop this record is from or for.

keysproperty 
public var keys:Array

An array of simple integer pairs referring to what key is pressed, and what state its in.

mouseproperty 
public var mouse:MouseRecord

A container for the 4 mouse state integers.

Constructor Detail
FrameRecord()Constructor
public function FrameRecord()

Instantiate array new frame record.

Method Detail
create()method
public function create(Frame:Number, Keys:Array = null, Mouse:MouseRecord = null):FrameRecord

Load this frame record with input data from the input managers.

Parameters

Frame:Number — What frame it is.
 
Keys:Array (default = null) — Keyboard data from the keyboard manager.
 
Mouse:MouseRecord (default = null) — Mouse data from the mouse manager.

Returns
FrameRecord — A reference to this FrameRecord object.
destroy()method 
public function destroy():void

Clean up memory.

load()method 
public function load(Data:String):FrameRecord

Load the frame record data from array simple ASCII string.

Parameters

Data:String — A String object containing the relevant frame record data.

Returns
FrameRecord
save()method 
public function save():String

Save the frame record data to array simple ASCII string.

Returns
String — A String object containing the relevant frame record data.