Skip to content

Commit 8d36956

Browse files
committed
UPBGE: Fix diffuseColor and specularColor getters
1 parent 26f876a commit 8d36956

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

source/gameengine/Ketsji/KX_BlenderMaterial.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -564,15 +564,15 @@ static int mathutils_kxblendermaterial_color_get(BaseMathObject *bmo, int subtyp
564564
case MATHUTILS_COL_CB_MATERIAL_DIFFUSE_COLOR:
565565
{
566566
bmo->data[0] = mat->r;
567-
bmo->data[0] = mat->g;
568-
bmo->data[0] = mat->b;
567+
bmo->data[1] = mat->g;
568+
bmo->data[2] = mat->b;
569569
break;
570570
}
571571
case MATHUTILS_COL_CB_MATERIAL_SPECULAR_COLOR:
572572
{
573573
bmo->data[0] = mat->specr;
574-
bmo->data[0] = mat->specg;
575-
bmo->data[0] = mat->specb;
574+
bmo->data[1] = mat->specg;
575+
bmo->data[2] = mat->specb;
576576
break;
577577
}
578578
}

0 commit comments

Comments
 (0)