Skip to content

Commit

Permalink
Revert "Merge pull request #492 from SerG-Y/master"
Browse files Browse the repository at this point in the history
This reverts commit 54e162e, reversing
changes made to 7903e9d.
  • Loading branch information
miltoncandelero committed May 11, 2023
1 parent 54e162e commit 32b8554
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions packages/base/src/SpineBase.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ import { Graphics } from '@pixi/graphics';
import { settings } from './settings';
import type { ISpineDebugRenderer } from './SpineDebugRenderer';

const tempRgb = [0, 0, 0];

/**
* @public
*/
Expand Down Expand Up @@ -320,11 +322,10 @@ export abstract class SpineBase<
// YAY! double - tint!
spriteColor = slot.currentSprite.color;
} else {
slot.currentSprite.tint = utils.rgb2hex([
light[0] * slot.color.r * attColor.r,
light[1] * slot.color.g * attColor.g,
light[2] * slot.color.b * attColor.b
]);
tempRgb[0] = light[0] * slot.color.r * attColor.r;
tempRgb[1] = light[1] * slot.color.g * attColor.g;
tempRgb[2] = light[2] * slot.color.b * attColor.b;
slot.currentSprite.tint = utils.rgb2hex(tempRgb);
}
slot.currentSprite.blendMode = slot.blendMode;
break;
Expand Down Expand Up @@ -379,11 +380,10 @@ export abstract class SpineBase<
// pixi-heaven
spriteColor = slot.currentMesh.color;
} else {
slot.currentMesh.tint = utils.rgb2hex([
light[0] * slot.color.r * attColor.r,
light[1] * slot.color.g * attColor.g,
light[2] * slot.color.b * attColor.b
]);
tempRgb[0] = light[0] * slot.color.r * attColor.r;
tempRgb[1] = light[1] * slot.color.g * attColor.g;
tempRgb[2] = light[2] * slot.color.b * attColor.b;
slot.currentMesh.tint = utils.rgb2hex(tempRgb);
}
slot.currentMesh.blendMode = slot.blendMode;
if (!slot.hackRegion) {
Expand Down

0 comments on commit 32b8554

Please sign in to comment.