Moon sun rays help?

Hello everyone. I’v been wondering how to make the moon give off the sunrays effect. I’v been many games before use this trick and I’v wonder how. Could anyone tell me? :sweat_smile:

10 Likes

Skyboxes have a property named SunTextureId which you can use to change the texture of the sun to that of the moon. You can find the moon texture by locating yourself to the MoonTextureId property. Good luck!

Edit: @kinkocat provides a very simple solution to this question, see post below.

8 Likes

This is actually really easy! You place the sun there using a plugin and position it over the moon on a given skybox. Disable celestial bodies in the properties of the skybox and set the lighting properties so it looks like night (Mainly with ambient, outdoorambient and brightness). Then add yourself a nice little SunRaysEffect to lighting and tinker it to how you want it to look! You could also update the texture of the sun itself to have a moon but that would be heavily dependent on the nighttime skybox you decide to use. (don’t want two moons)

Plugin: https://www.roblox.com/library/213664111/Celestial-Body-Dragger

14 Likes

I created a simple example for anyone else that is curious without wanting to get the plugin.
MoonRaysExample.rbxl (39.1 KB)

8 Likes

Thank you so much. This helps a lot

1 Like