UPDATE :
http://pastebin.com/raw.php?i=VpHHBuaW
Log Change : 1.3 : - new option to disable lights at the beginning of the script - new option to disable shadows at the beginning of the script - new option in events to prevent them from being darkened - new option in shadows to setup if they should darken characters or not - new option that allow to create lights/shadows without naming them they will be named automatically with the id of their event - fixed display bug related to scripts that change the game size during game on map even if it's a nonsense - fixed display bug related to shake screenA few details about the new features.
- new option in events to prevent them from being darkened
Before we had no choice all characters were darkened (when in a shadow), now you can change it by using the set_shadowable function in a script.
- set_shadowable(value, chara_id) Defines if a character can be darkened or not. value = true or false Default value is true. chara_id = id of the character on which change this option. If we put nothing it means "this event", which runs the script, as @event_id. Example : set_shadowable(false, -1) # prevent the player from being darkened set_shadowable(false) # prevent "this event" from being darkened
- new option in shadows to setup if they should darken characters or not
Before it was handled automatically, characters were darkened when below shadows associated with the map but not when below those associated with characters, now it's up to us to choose.
- shadow(key).shadowable = true or false Defines whether a shadow should darken characters or not. For shadows linked with characters it's important to make them not darken, otherwise the linked character will be darkened all the time. Default value is true. Example : shadow("shadow 1").shadowable = false
- new option that allow to create lights/shadows without naming them, they will be named automatically with the id of their event
Before we were obliged to name differently each of our lights/shadows, now we can give no name and the script will automatically generate one using the id of the event that created it.That way we can create an unnamed light for example, and make multiple copy/paste without having to change the name each time.
Code:
light("light 1").setup("torch.png") # new light light.setup("torch.png") # new light without name