Sets the state of lightning to on or off, plus allows the setting of how often to check for lightning and the randomness at which lightning happens
| 303 | // Sets the state of lightning to on or off, plus allows the setting of how often to check |
| 304 | // for lightning and the randomness at which lightning happens |
| 305 | void SetLightningState(int on, float interval_time, int randval) { |
| 306 | if (on) { |
| 307 | Weather.flags |= WEATHER_FLAGS_LIGHTNING; |
| 308 | Weather.lightning_sequence = 0; |
| 309 | Weather.lightning_rand_value = randval; |
| 310 | Weather.lightning_interval_time = interval_time; |
| 311 | } else { |
| 312 | Weather.flags &= ~WEATHER_FLAGS_LIGHTNING; |
| 313 | } |
| 314 | } |
no outgoing calls
no test coverage detected