Cloned Light doesn't Receive its Assigned Name

Repro: Babylon.js Playground
As one may see, all cloned lights have the same name (the name of the light from which they are cloned).

Solution (tested and works in local environment):
Add to the light.ts (after line 590) the same condition for the name as for the newParent

        if (name) {
            clonedLight.name = name;
        }

Should I make a PR?

3 Likes

Please do :slight_smile:
Highly appreciated!

3 Likes

PR made!

UPD. Merged, so I mark this as solution :slight_smile:

UPD 2. It works :slight_smile:

4 Likes