(MV Version only) Do you think canvas fall-back for this plugin is neccesary?


  • Total voters
    38
  • Poll closed .

Shora

Veteran
Veteran
Joined
Apr 12, 2020
Messages
42
Reaction score
91
First Language
Vietnamese
Primarily Uses
RMMZ
Shora Lighting System


oXxDc0x.png


Version: 1.4.
Itch.io Page.
Wiki Page.
―――――――――――――――――――――
ShoraLightingSystem, written in JavaScript, is a plug-in developed by Shora to provide dynamic lighting to RPG Maker MV/MZ engine, intended to be easiest to start and most flexible when advanced!


Introduction
This is my first graphics plugin for RPG Maker MV/MZ, but i have made it for 9 months~. After lots of failure in quality and performance, now i can finally, introduce to you, Shora Lighting Plugin, with real-time dynamic shadow and statics light!. It have been optimized heavily too focus in quality, and i have rebuild this plugin for 4-5 times. I began this projuct in about 3/2020, and come through a lot from it.

Features
- High-quality lighting plugin for MV/MZ.
- User-friendly Interface, will have a GUI for users to use, but it can originally use just by event’ comment.
- Light from your customized images. But it can be transformed, rotate, scale anytime you want!
- Two custom light sprite types: Dynamic and Static. Static light are generated from dynamic snap-shot for create as much lights as you want, and dynamic light with beautiful animation (especially shadow!).
- Effect are rendered using WebGL shaders for both MV and MZ. So it only have webGL support. Canvas support is not going to be added in the future.
And, the most important, Dynamic Real-time 2.5D Ambient Shadow! It was the feature I put a lots of my efforts into. Including optimizing region, creating shadow on walls, ambient shadow and much more! Ever since Khas Lighting come out, no lighting plugin have the shadow feature so I was thinking, why not? :). It use the region scan for shadow caster, but heavily optimized. Can made it effectively as the Khas Ultra Lighting one in RPG Maker VX Ace, but will (and try to) be better than Khas Advanced Lighting in MV!


Gallery:
light2-min.gif


MV Plugin Commands:
ambient <color (hex)> <time (ticks)>: changing the current ambient color to destination color in tick(s) time. Useful for a simple day/night cycle system and easily compatible with any other plugin. The same syntax apply for changing shadowAmbient and topBlockAmbient, but those are advanced things and I doubt anyone would need it.
offset <eventId*> <X> <Y> <ticks> <transition type>: set the event's lighting offset to (X, Y) in ticks time. The default transition type is easeInOut (1), and you can use the linear one (0). It does not actually set the position of the lighting, only it offset.
tint <eventId*> <color> <ticks>: set the event's lighting tin to color in ticks time.

*: you can shorten the eventId for the current lighting (lighting of the event which call the commands) by using a simple "=" instead of typing it id. This is the same as "leave the id blank for this event" in MZ plugin command.
Example: offset = 48 -48 60 will move this event lighting by right one block and up one block in one second.

Download the demo and see how the dynamic shadow work! :kaoluv:
Link to demo download.

P/S:
This plugin is heavily optimized for RPG Maker MZ, since PIXIJS V5 has a lots of improvement on it renderer. So the performance slightly worsen when used with MV. But don't worry, more optimization are going to be added in the future! :).

You may not use this plugin for any commercial project. If you wanna do so, please inbox me though above e-mail, or DM me via this forum/discord (Shora#3835).

Change-logs:
Update v.1.1b (13/9/2021): First public beta version released for MZ!.
Update v.1.2b (15/9/2021):
- Now included MV versions! :D

- Add new parameters: Shadow Ambient and Top Block Ambient. These two color are default choice for all light that not specified this setting. Allow user to control their light shadow ambient color and the ambient color affect top-block. Included two new plugin command to change these but only take effect on the next map.
- The MV version now will be merged to the MZ version and share their development in one plugin file. MZ version have the higher priority though, because PIXI V5 have better optimization for this plugin. MV Demo is completely converted from MZ's one.
- Fix various bugs.
Update v.1.3b (4/11/2021):
- Change the code structure to handling save/load functionality (aka fix my past suckness). Thanks @Shiko for the feedback.
- Fix some bugs include @VaiJack8 report of fps drop when changing game variables each frame.
- Get the light layer to draw above the upper layer (everything), intended to use with parallax mapping, as suggest from @Decinbr. Still need tested though (I don't know how to do parallax mapping).
This is a small update since i came back to plugin coding after my personal issues, just fixing feedbacked bugs and adding suggested feature. I'm pretty dis-motivation now so i hope eveyone can give me more feedback and suggestion :) I really appreciate that <3.
Update v.1.4b (1/10/2022):
- Re-written the shadow polygon optimization, which both fixed most weird lighting box when drawing unusual shadow shapes, and drastically reduce the shadow segments numbers by roughly 10% (which lead to faster performance).
- Re-organized the region id usage, counting from zero height so that mean now you can draw 0-height shadow caster block, or can be call as top-down-2D-block. You will need to increase the old region id by 1 though. Also now you can limited the region id block by a range instead of only start index like before (default is from 1 to 10).
- Introduce two more special block that can be specified its id (default is 50 and 51): top-roof block and ignore-shadows block. Top-roof block serve the purpose of draw top roof, which no light can be cast on it (useful when you drawing a gate, etc.) and ignore-shadow block will NOT let any shadow ray to be cast on it (can be use when you want to make the illusion of a wall that is higher than the light ray, which the shadow cannot cast to).
- Fixed some minor bugs.

Term of Use:
If you want to use this plugin with a free RPG Maker game, you can do it for free and there's no need to contact me. I only ask you to give credit to "Shora" or "Shora Lighting Plugin" somewhere in your game.

This plugin is NOT FREE for COMMERCIAL use. If you want to use it on a commercial title (any game that you may sell), you must pay a one-time $24.99 USD fee (via PayPal only: kieudung.c11212@gmail.com - please send me an e-mail/DMs). This license covers commercial use for your current and future projects, and it allows you to use all my plugins.

Please note that this plugin is provided “as is”, without warranty of any kind. You are responsible for testing it and checking if it’s compatible with your game. In no event shall the author of this plugin be liable for any claim, damages or other liability, whether in an action of contract, tort or otherwise, arising from, out of or in connection with the software or the use or other dealings in the software.
[\SPOILER]

If you want to support me, I would suggest using PayPal instead of itch.io :kaoluv:
 

Attachments

  • 1631697555013.png
    1631697555013.png
    43.2 KB · Views: 794
  • 1631697615437.png
    1631697615437.png
    19.9 KB · Views: 773
Last edited:

ShadowDragon

Realist
Veteran
Joined
Oct 8, 2018
Messages
4,854
Reaction score
1,865
First Language
Dutch
Primarily Uses
RMMV
if it become better than khas one, it will be amazing, khas is good with the only shadow
feature, ocram has a nice lightning plugin but community lighting does a pretty awesome
job too.

while dynamic shadows looks awesome, I would like to test it how it works out =)
very nice job indeed :)

I know another one with a GUI and has a plugin command for closing and open doors on
specific time system that can change from morning to night with the light plugin.

this looks very promising as well, if you can overcome khas plugin, you become nr 1 :p
so it can become a wild plugin ^^
 

Hyouryuu-Na

Very very lazy
Veteran
Joined
Jun 15, 2017
Messages
1,105
Reaction score
2,902
First Language
Not English
Primarily Uses
RMMV
Just in time! I've been having trouble with Khas' plugin lately. Hopefully this one's smoother and less laggy ^^ It's so good to see someone try something so complicated like this with the realtime shadows and all. Keep up the good work!
 

Shora

Veteran
Veteran
Joined
Apr 12, 2020
Messages
42
Reaction score
91
First Language
Vietnamese
Primarily Uses
RMMZ
if it become better than khas one, it will be amazing, khas is good with the only shadow
feature, ocram has a nice lightning plugin but community lighting does a pretty awesome
job too.

while dynamic shadows looks awesome, I would like to test it how it works out =)
very nice job indeed :)

I know another one with a GUI and has a plugin command for closing and open doors on
specific time system that can change from morning to night with the light plugin.

this looks very promising as well, if you can overcome khas plugin, you become nr 1 :p
so it can become a wild plugin ^^

Thanks for your reply ;). I am trying to make this plugin more quality and effective (it already user-friendly enough xd). The GUI is just a feature i quickly make to help tester easier to decoration their map (you can find out the fittest configuration to your lighting event ;D. If you want to test how it work out, just leave me a message ;). Everyone is very welcome to test my plugin :D
 

Shora

Veteran
Veteran
Joined
Apr 12, 2020
Messages
42
Reaction score
91
First Language
Vietnamese
Primarily Uses
RMMZ
Just in time! I've been having trouble with Khas' plugin lately. Hopefully this one's smoother and less laggy ^^ It's so good to see someone try something so complicated like this with the realtime shadows and all. Keep up the good work!
Happy to hear that ^^. This plugin is originally made for MV, but now i'm focusing it into MZ through (MZ have optimized more for WebGL stuffs). MV is still good through, and if you want to test out how the plugin work, just contact me xD. The shadow part may still have bug and doesn't optmized enough, but its can be improved with you guys feedback :D.
 

GmOcean

Veteran
Veteran
Joined
Nov 29, 2020
Messages
73
Reaction score
62
First Language
English
Primarily Uses
RMMZ
This looks really good. I love the dynamic shadow effects it has. I do have a couple questions if you don't mind.
1. Can lights be placed anywhere or is it only attached to the player? I'm under the assumption they're attached to events but clarification on how they can be applied would be nice.
2. Do players/NPCs cast shadows or just terrain?
3. Expanding on #2, do objects cast shadows, for instance a statue on B/C tileset?
4. How do dynamic lights interact with each other? For example, if I have a wall in the middle (3 tiles tall), and a light on the right and left of the wall, in reality the shadow would be darkest at the top and bottom. My question is does this accurately project that, or does one light have higher priority such as being a layer above? Sorry if the question is confusing, just woke up hard to iterate what I mean.

Again though, this looks amazing. If I wasn't so new to the RM series as a whole I'd love to test it out, but I wouldn't be able to give you useful feedback for development purposes.
 

Shora

Veteran
Veteran
Joined
Apr 12, 2020
Messages
42
Reaction score
91
First Language
Vietnamese
Primarily Uses
RMMZ
This looks really good. I love the dynamic shadow effects it has. I do have a couple questions if you don't mind.
1. Can lights be placed anywhere or is it only attached to the player? I'm under the assumption they're attached to events but clarification on how they can be applied would be nice.
2. Do players/NPCs cast shadows or just terrain?
3. Expanding on #2, do objects cast shadows, for instance a statue on B/C tileset?
4. How do dynamic lights interact with each other? For example, if I have a wall in the middle (3 tiles tall), and a light on the right and left of the wall, in reality the shadow would be darkest at the top and bottom. My question is does this accurately project that, or does one light have higher priority such as being a layer above? Sorry if the question is confusing, just woke up hard to iterate what I mean.

Again though, this looks amazing. If I wasn't so new to the RM series as a whole I'd love to test it out, but I wouldn't be able to give you useful feedback for development purposes.
Hello :D Thanks for your compliment!
As your question:
1. Yes, light can be placed anywhere. For user-friendly, it mainly use event to place light, but for advanced user you cam freely customize it offset :)
2. For user-friendly purpose, assume that just region-tile work on being a shadow caster. But, it will have the option to create any shape of caster you want, because it will cast at the bottom of the object :D. Still, this is very beta feature (I need to load the object image itself to overlay with the shadow, and user need to figure out the "line" of the object bottom root), so it will not included in the first release. Stil, i will certainly include this in future update, or a addition advanced-feature plugin ;).
3. I have answered in #2 :D.
4. I still cannot certainly understand your question :(. But to classify, the light haven't have the layer feature yet. Still, the shadow already have the visual that darkening the top walls, and you can change how it dark :). And, every lights have the ambient shadow color, which change how darken it is in the shadow part. If you want to have priority ambient light, just cleverly configuration the light ;)
 

GmOcean

Veteran
Veteran
Joined
Nov 29, 2020
Messages
73
Reaction score
62
First Language
English
Primarily Uses
RMMZ
Hello :D Thanks for your compliment!
As your question:
1. Yes, light can be placed anywhere. For user-friendly, it mainly use event to place light, but for advanced user you cam freely customize it offset :)
2. For user-friendly purpose, assume that just region-tile work on being a shadow caster. But, it will have the option to create any shape of caster you want, because it will cast at the bottom of the object :D. Still, this is very beta feature (I need to load the object image itself to overlay with the shadow, and user need to figure out the "line" of the object bottom root), so it will not included in the first release. Stil, i will certainly include this in future update, or a addition advanced-feature plugin ;).
3. I have answered in #2 :D.
4. I still cannot certainly understand your question :(. But to classify, the light haven't have the layer feature yet. Still, the shadow already have the visual that darkening the top walls, and you can change how it dark :). And, every lights have the ambient shadow color, which change how darken it is in the shadow part. If you want to have priority ambient light, just cleverly configuration the light ;)
Thanks for the detailed answers. And you answered #4 in the last couple sentences. That's what I was trying to ask. Would shadows overlap with each other. Now that I've had coffee it's so much easier to state. Thanks again, and good luck on future development.
 

Shora

Veteran
Veteran
Joined
Apr 12, 2020
Messages
42
Reaction score
91
First Language
Vietnamese
Primarily Uses
RMMZ
Hello everyone!. It a few days from i posted this, but a survey is needed for releasing the plugin :). Do you think that canvas fallback for MV version is necessary?. From the beginning when i created this plugin, i always add canvas as a option (fallback is cool!). But now, since the release of MZ with the only-WebGL feature, i want to make a decision on this problem :). Canvas is possible, but it is slower (of course), and do not as beautiful as WebGL was (It doe NOT have the ambient shadow, which made the shadow to be back like default. Also, a lots of realistic visual will be gone.). So, what do you prefer?
 
Last edited:

Siul

Veteran
Veteran
Joined
Nov 19, 2012
Messages
92
Reaction score
20
First Language
Spanish
Primarily Uses
OMG this is AWESOME!

Even more once Khas is kinda retired.

Shora, any chances to have a MZ port for this? WHERE IS YOUR ******* TO MAKE IT REAL?!! :D:D
 

Shora

Veteran
Veteran
Joined
Apr 12, 2020
Messages
42
Reaction score
91
First Language
Vietnamese
Primarily Uses
RMMZ
OMG this is AWESOME!

Even more once Khas is kinda retired.

Shora, any chances to have a MZ port for this? WHERE IS YOUR ******* TO MAKE IT REAL?!! :D:D
Hello :D. I'm glad to hear that you are interested in the plugin. As your question, if you read the post carefully (and the title), this plugin supported both MV and MZ. However, MZ is more focused in, since it the latest version of RPG Maker, and PIXIJS V5 is more optimized for this plugin, both in performance and quality. If you want to try it out, just contact by discord! I always appreciate feedback and suggestion :).
 

MasterTenchi

Veteran
Veteran
Joined
Nov 2, 2019
Messages
44
Reaction score
23
First Language
English
Primarily Uses
RMMZ
Dropped a Discord Friend Request:: I'll put the plugin through some serious test paces if you'd like.
 

Shora

Veteran
Veteran
Joined
Apr 12, 2020
Messages
42
Reaction score
91
First Language
Vietnamese
Primarily Uses
RMMZ
Dropped a Discord Friend Request:: I'll put the plugin through some serious test paces if you'd like.
I'm happy to hear that ;). Accepted your friend request. Also, the test you said look promising. I'm currently focusing a lot on furthermore improving the performance (like using a quadtree data structure, make spatial grid on the map, ...), so seeing the improvement by some test is really good (i'm working on that right now). Check of your discord message :) !
 

Sinister

Warper
Member
Joined
Jan 14, 2018
Messages
2
Reaction score
1
First Language
english
Primarily Uses
RMMV
Hey I'd like to give it a test! I'm KJ#2628 I sent a Discord request. :)
 

Shora

Veteran
Veteran
Joined
Apr 12, 2020
Messages
42
Reaction score
91
First Language
Vietnamese
Primarily Uses
RMMZ
Hey I'd like to give it a test! I'm KJ#2628 I sent a Discord request. :)
Thanks to your intention :D. However, i haven't seen any friend request from you though. I sent you a friend request, check it out!
 

Hyouryuu-Na

Very very lazy
Veteran
Joined
Jun 15, 2017
Messages
1,105
Reaction score
2,902
First Language
Not English
Primarily Uses
RMMV
I don't use discord (is that weird?)... Anyways, that's why I sent you a mail ^^
 

Sinister

Warper
Member
Joined
Jan 14, 2018
Messages
2
Reaction score
1
First Language
english
Primarily Uses
RMMV
Thanks to your intention :D. However, i haven't seen any friend request from you though. I sent you a friend request, check it out!
I sent another just to be sure, you're Shora#7020 right? Make sure your message requests are open to everyone. Mine's KJ#2628 But I haven't seen one yet.
 

Shora

Veteran
Veteran
Joined
Apr 12, 2020
Messages
42
Reaction score
91
First Language
Vietnamese
Primarily Uses
RMMZ
I sent another just to be sure, you're Shora#7020 right? Make sure your message requests are open to everyone. Mine's KJ#2628 But I haven't seen one yet.
I'm sure that my message opening for everyone though, because there are some people testing the plugin right now from discord. Please check again :).
1609661254549.png
 

Underserial

Veteran
Veteran
Joined
Dec 9, 2015
Messages
143
Reaction score
32
First Language
German
is there a option that u do also shadows for the characters?
Like if i have a fireplace it throws a shadow for the char and events ?!

like:
1609868167977.png
 
Last edited:

Latest Profile Posts

Been playing through Skies of Arcadia again, and it really makes me wanna see someone try to implement how ship battles were done in the game into RPG Maker (or really just in general).
split.png
split view of both versions of the pocket city you traverse through. there's differences like areas only being accessible in one version of Autumn Bay. or events that only happen in one or the other.
theortically if there were a developer who spied on people's game playthroughs and changed things in real time to make it harder for them, what might be said game developer's motivation?
Hi everyone! Enjoying this nice long weekend. How are you all doing? :)
I just successfully tested having events check if specific actors are in a particular party slot and then changing image to match. This will let me make scenes take into account who is in the party at the time and arrange them accordingly - this is important since I'll have extra actors beyond current party. The script used is the same from MV and is compatible with my current core plugin setup in MZ. Thank goodness.

Forum statistics

Threads
118,433
Messages
1,115,915
Members
155,391
Latest member
dndrself
Top