Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions flixel/FlxCamera.hx
Original file line number Diff line number Diff line change
Expand Up @@ -579,14 +579,12 @@ class FlxCamera extends FlxBasic
return startTrianglesBatch(graphic, smooth, colored, blend);
#else
var itemToReturn = null;
var blendInt:Int = FlxDrawBaseItem.blendToInt(blend);

if (_currentDrawItem != null
&& _currentDrawItem.type == FlxDrawItemType.TILES
&& _headTiles.graphics == graphic
&& _headTiles.colored == colored
&& _headTiles.hasColorOffsets == hasColorOffsets
&& _headTiles.blending == blendInt
&& _headTiles.blend == blend
&& _headTiles.antialiasing == smooth
&& _headTiles.shader == shader)
Expand Down Expand Up @@ -614,7 +612,6 @@ class FlxCamera extends FlxBasic
itemToReturn.antialiasing = smooth;
itemToReturn.colored = colored;
itemToReturn.hasColorOffsets = hasColorOffsets;
itemToReturn.blending = blendInt;
itemToReturn.blend = blend;
itemToReturn.shader = shader;

Expand All @@ -640,14 +637,11 @@ class FlxCamera extends FlxBasic
@:noCompletion
public function startTrianglesBatch(graphic:FlxGraphic, smoothing:Bool = false, isColored:Bool = false, ?blend:BlendMode, ?hasColorOffsets:Bool, ?shader:FlxShader):FlxDrawTrianglesItem
{
var blendInt:Int = FlxDrawBaseItem.blendToInt(blend);

if (_currentDrawItem != null
&& _currentDrawItem.type == FlxDrawItemType.TRIANGLES
&& _headTriangles.graphics == graphic
&& _headTriangles.antialiasing == smoothing
&& _headTriangles.colored == isColored
&& _headTriangles.blending == blendInt
&& _headTriangles.blend == blend
#if !flash
&& _headTriangles.hasColorOffsets == hasColorOffsets
Expand All @@ -665,7 +659,6 @@ class FlxCamera extends FlxBasic
public function getNewDrawTrianglesItem(graphic:FlxGraphic, smoothing:Bool = false, isColored:Bool = false, ?blend:BlendMode, ?hasColorOffsets:Bool, ?shader:FlxShader):FlxDrawTrianglesItem
{
var itemToReturn:FlxDrawTrianglesItem = null;
var blendInt:Int = FlxDrawBaseItem.blendToInt(blend);

if (_storageTrianglesHead != null)
{
Expand All @@ -682,7 +675,6 @@ class FlxCamera extends FlxBasic
itemToReturn.graphics = graphic;
itemToReturn.antialiasing = smoothing;
itemToReturn.colored = isColored;
itemToReturn.blending = blendInt;
itemToReturn.blend = blend;
#if !flash
itemToReturn.hasColorOffsets = hasColorOffsets;
Expand Down
7 changes: 6 additions & 1 deletion flixel/graphics/tile/FlxDrawBaseItem.hx
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ class FlxDrawBaseItem<T>
*/
public static var drawCalls:Int = 0;

@:noCompletion
@:deprecated("blendToInt() is deprecated, remove all references to it")
public static function blendToInt(blend:BlendMode):Int
{
return 0; // no blend mode support in drawQuads()
Expand All @@ -29,9 +31,12 @@ class FlxDrawBaseItem<T>
public var antialiasing:Bool = false;
public var colored:Bool = false;
public var hasColorOffsets:Bool = false;
public var blending:Int = 0;
public var blend:BlendMode;

@:noCompletion
@:deprecated("blending is deprecated, remove all references to it")
public var blending:Int = 0;

public var type:FlxDrawItemType;

public var numVertices(get, never):Int;
Expand Down