nanos-world / issues

Issue Tracker for nanos world
9 stars 1 forks source link

impossible to create a dynamic sky #1002

Closed Suukaaa closed 4 months ago

Suukaaa commented 4 months ago

Prerequisites

Your Environment

Description

I wanted to implement the dynamic sky system so I ran the Sky.Spawn() command on the client side so far no error except that when I decided to change the weather this error appeared ‘[2024-04-26 18:54:00] WARNING UltraDynamicSky entity not found! If you want to change weather properties please use 'Sky.Spawn()' to replace this map's Sky entities with the UltraDynamicSky Sun and Weather Actors, which are able to have their properties changed. ‘ I don't know where it came from or how it happened and I'm not the only one to have fallen victim to this bug.

Steps to reproduce the behavior

go to client (Index) in your package

enter the Sky.Spawn() command

and then try to change the weather

Sky.ChangeWeather(WeatherType.Rain, 1)

in the code it looks like this

  1. Sky.Spawn()
  2. Sky.ChangeWeather(WeatherType.Rain, 1)

Expected behavior

I imagine that nothing in particular will happen with this bug, apart from the fact that the dynamic sky won't work and just the classic sky will remain.

Actual behavior

[2024-04-26 18:54:00] WARNING UltraDynamicSky entity not found! If you want to change weather properties please use 'Sky.Spawn()' to replace this map's Sky entities with the UltraDynamicSky Sun and Weather Actors, which are able to have their properties changed.

gtnardy commented 4 months ago

You need to run Sky.Spawn(true) to spawn the Weather actor internally as well. I will improve the error to mention this.