Egret_简单的封装方法

////////////随机颜色***//////////////////////////
private getRdmClr(): number {
return (Math.floor(Math.random() * 0xff) << 16)
+ (Math.floor(Math.random() * 0xff) << 8)
+ Math.floor(Math.random() * 0xff);
}

原文地址:https://www.cnblogs.com/Ms-Sake/p/9978921.html