Helper object for holding beginning minimum/maximum and ending minimum/maximum values of FlxPoints, which have both an x and y component. This would extends Range> but this allows a more practical use of set().

Constructor

new(startMinX:Float, ?startMinY:Float, ?startMaxX:Float, ?startMaxY:Float, ?endMinX:Float, ?endMinY:Float, ?endMaxX:Float, ?endMaxY:Float)

Create a new FlxPointRangeBounds object.

Parameters:

startMinX

The minimum possible initial value of X for this property for particles launched from this emitter.

startMinY

The minimum possible initial value of Y for this property for particles launched from this emitter. Optional, will be set equal to startMinX if ignored.

startMaxX

The maximum possible initial value of X for this property for particles launched from this emitter. Optional, will be set equal to startMinX if ignored.

startMaxY

The maximum possible initial value of Y for this property for particles launched from this emitter. Optional, will be set equal to startMinY if ignored.

endMinX

The minimum possible final value of X for this property for particles launched from this emitter. Optional, will be set equal to startMinX if ignored.

endMinY

The minimum possible final value of Y for this property for particles launched from this emitter. Optional, will be set equal to startMinY if ignored.

endMaxX

The maximum possible final value of X for this property for particles launched from this emitter. Optional, will be set equal to endMinX if ignored.

endMaxY

The maximum possible final value of Y for this property for particles launched from this emitter. Optional, will be set equal to endMinY if ignored.

Returns:

This FlxPointRangeBounds instance (nice for chaining stuff together).

Variables

@:value(true)active:Bool = true

A flag that can be used to toggle the use of this property.

end:FlxBounds<FlxPoint>

The ending X and Y values of this property.

start:FlxBounds<FlxPoint>

The beginning X and Y values of this property.

Methods

inlineequals(OtherFlxPointRangeBounds:FlxPointRangeBounds):Bool

Function to compare this FlxPointRangeBounds to another.

Parameters:

OtherFlxPointRangeBounds

The other FlxPointRangeBounds to compare to this one.

Returns:

True if the FlxPointRangeBounds have the same min and max value, false otherwise.

set(startMinX:Float, ?startMinY:Float, ?startMaxX:Float, ?startMaxY:Float, ?endMinX:Float, ?endMinY:Float, ?endMaxX:Float, ?endMaxY:Float):FlxPointRangeBounds

Handy function to set the the beginning and ending range of values for a FlxPoint in one line.

Parameters:

startMinX

The minimum possible initial value of X for this property for particles launched from this emitter.

startMinY

The minimum possible initial value of Y for this property for particles launched from this emitter. Optional, will be set equal to startMinX if ignored.

startMaxX

The maximum possible initial value of X for this property for particles launched from this emitter. Optional, will be set equal to startMinX if ignored.

startMaxY

The maximum possible initial value of Y for this property for particles launched from this emitter. Optional, will be set equal to startMinY if ignored.

endMinX

The minimum possible final value of X for this property for particles launched from this emitter. Optional, will be set equal to startMinX if ignored.

endMinY

The minimum possible final value of Y for this property for particles launched from this emitter. Optional, will be set equal to startMinY if ignored.

endMaxX

The maximum possible final value of X for this property for particles launched from this emitter. Optional, will be set equal to endMinX if ignored.

endMaxY

The maximum possible final value of Y for this property for particles launched from this emitter. Optional, will be set equal to endMinY if ignored.

Returns:

This FlxPointRangeBounds instance (nice for chaining stuff together).

toString():String

Convert object to readable string name. Useful for debugging, save games, etc.