- Joined
- Jul 8, 2015
- Messages
- 120
- Reaction score
- 59
- First Language
- French
- Primarily Uses
Also, since many people were confused about the fact that the plugin needs at least one light event to be active, and it isn't very difficult to either get rid of this feature (plugin always active even without light event), or making it a plugin parameter. Would you be interested in such feature?
Changes put on a pull request. It will look like most of the code changed while I just got rid of the useless indentation in the main function (the long if series could easily be replaced by some if not condition return)
JavaScript:
if (options_lighting_on == true) {
[hundreds lines of code]
}
// Become
if (options_lighting_on !== true) return; // Plugin deactivated in the option
[hundreds lines of code]