|
@@ -578,7 +578,7 @@ export class MaterialHelper {
|
|
|
*/
|
|
|
public static PrepareAttributesForInstances(attribs: string[], defines: any): void {
|
|
|
// Check if we are handling a MaterialDefine or an Array containing the #define
|
|
|
- if (defines["INSTANCES"] || (defines instanceof Array && defines.indexOf("#define INSTANCES") > -1)) {
|
|
|
+ if (defines["INSTANCES"] || Array.isArray(defines)) {
|
|
|
attribs.push("world0");
|
|
|
attribs.push("world1");
|
|
|
attribs.push("world2");
|