mirror of
https://github.com/vcmi/vcmi.git
synced 2025-01-24 03:47:18 +02:00
Fixed blue tint for clones
This commit is contained in:
parent
d157735846
commit
21196e822f
@ -225,7 +225,7 @@ void BattleStacksController::stackAdded(const CStack * stack, bool instant)
|
||||
{
|
||||
addNewAnim(new ColorTransformAnimation(owner, stack, "summonFadeIn", nullptr));
|
||||
if (stack->isClone())
|
||||
addNewAnim(new ColorTransformAnimation(owner, stack, "cloning", nullptr));
|
||||
addNewAnim(new ColorTransformAnimation(owner, stack, "cloning", SpellID(SpellID::CLONE).toSpell() ));
|
||||
});
|
||||
}
|
||||
}
|
||||
@ -816,7 +816,7 @@ void BattleStacksController::removeExpiredColorFilters()
|
||||
{
|
||||
if (filter.persistent)
|
||||
return false;
|
||||
if (filter.effect == ColorFilter::genEmptyShifter())
|
||||
if (filter.effect != ColorFilter::genEmptyShifter())
|
||||
return false;
|
||||
if (filter.source && filter.target->hasBonus(Selector::source(Bonus::SPELL_EFFECT, filter.source->id), Selector::all))
|
||||
return false;
|
||||
|
@ -34,6 +34,11 @@ SDL_Color ColorFilter::shiftColor(const SDL_Color & in) const
|
||||
};
|
||||
}
|
||||
|
||||
bool ColorFilter::operator != (const ColorFilter & other) const
|
||||
{
|
||||
return !(this->operator==(other));
|
||||
}
|
||||
|
||||
bool ColorFilter::operator == (const ColorFilter & other) const
|
||||
{
|
||||
return
|
||||
|
@ -35,6 +35,7 @@ public:
|
||||
SDL_Color shiftColor(const SDL_Color & in) const;
|
||||
|
||||
bool operator == (const ColorFilter & other) const;
|
||||
bool operator != (const ColorFilter & other) const;
|
||||
|
||||
/// Generates empty object that has no effect on image
|
||||
static ColorFilter genEmptyShifter();
|
||||
|
Loading…
x
Reference in New Issue
Block a user