fixed CCColor

This commit is contained in:
yinkaile
2017-12-07 10:29:47 +08:00
parent ae2b31c94a
commit 692e882cd9
+1 -1
View File
@@ -64,7 +64,7 @@ var Color = (function () {
g = g || 0;
b = b || 0;
a = typeof a === 'number' ? a : 255;
this._val = ((~~r << 24) >>> 0) + (~~g << 16) + (~~b << 8) + ~~a;
this._val = ((a<<24) >>> 0) + (b<<16) + (g<<8) + r;
}
JS.extend(Color, ValueType);
require('../platform/CCClass').fastDefine('cc.Color', Color, {r: 0, g: 0, b: 0, a: 255});