Describe the bug
Creating a new Vox file in MagicaVoxel leads to emissive materials not appearing as emissive in game.
To Reproduce
Steps to reproduce the behavior:
Open a new blank MagicaVoxel Project.
Create a simple material with emissive properties (Emission > 50 and Power >= 3) and assign it to a few voxels.
Import the Vox file into a Teardown level.
The imported model will not have any emissive voxels.
Expected behavior
The voxels using the emissive material should glow in the dark as normal.
Screenshots
Environment
Teardown 0.6.2 [patch 1]
OS: Windows
Analysis
After investigating the problem myself, I found the issue is tied to the fact that MagicaVoxel does not create the _g property in the MATL dictionary associated with the emissive palette index.
Upon modifying the entry to contain a _g value of 0.41 (making sure of course that the file stays coherent), the new file starts behaving as expected, with its emissive material now glowing.
I don't know the purpose of this _g key and why it is necessary for the game to recognize the material as emissive, but it seems to be the only thing causing this bug.
Describe the bug Creating a new Vox file in MagicaVoxel leads to emissive materials not appearing as emissive in game.
To Reproduce Steps to reproduce the behavior:
Expected behavior The voxels using the emissive material should glow in the dark as normal.
Screenshots
Environment
Analysis After investigating the problem myself, I found the issue is tied to the fact that MagicaVoxel does not create the
_g
property in the MATL dictionary associated with the emissive palette index. Upon modifying the entry to contain a_g
value of 0.41 (making sure of course that the file stays coherent), the new file starts behaving as expected, with its emissive material now glowing.I don't know the purpose of this
_g
key and why it is necessary for the game to recognize the material as emissive, but it seems to be the only thing causing this bug.