forked from bartvdbraak/blender
BGE: Object color channels can now be animated separately without zeroing out the other channels. Problem reported by Dalai via IRC.
This commit is contained in:
parent
31e6af92c8
commit
c00191dbe3
@ -45,10 +45,10 @@ bool KX_ObColorIpoSGController::Update(double currentTime)
|
|||||||
{
|
{
|
||||||
if (m_modified)
|
if (m_modified)
|
||||||
{
|
{
|
||||||
m_rgba[0]=0;
|
SG_Spatial* ob = (SG_Spatial*)m_pObject;
|
||||||
m_rgba[1]=0;
|
KX_GameObject* kxgameobj= (KX_GameObject*) ob->GetSGClientObject();
|
||||||
m_rgba[2]=0;
|
|
||||||
m_rgba[3]=0;
|
m_rgba = kxgameobj->GetObjectColor();
|
||||||
|
|
||||||
T_InterpolatorList::iterator i;
|
T_InterpolatorList::iterator i;
|
||||||
for (i = m_interpolators.begin(); !(i == m_interpolators.end()); ++i) {
|
for (i = m_interpolators.begin(); !(i == m_interpolators.end()); ++i) {
|
||||||
@ -56,9 +56,6 @@ bool KX_ObColorIpoSGController::Update(double currentTime)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
SG_Spatial* ob = (SG_Spatial*)m_pObject;
|
|
||||||
KX_GameObject* kxgameobj= (KX_GameObject*) ob->GetSGClientObject();
|
|
||||||
|
|
||||||
kxgameobj->SetObjectColor(m_rgba);
|
kxgameobj->SetObjectColor(m_rgba);
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user