OcRam - Lights plugin (MZ/MV)
JS Plugin Releases (RMMV)Awesome plugin, just letting you know that I found a possible bug: if your map's scroll type is set to loop in either direction, light sources near where the map loops turn off and then turn back on once you get far enough away from the loop point. This also happens with the light source around the player.
Cant wait for it! 🙂
Is it foreseeable whether the feature with the shadow will be included in the next version?
Shadows are not in next version. Still figuring how I do it with minimal performance impact.
Okay, I hope you find a solution 🙂
First off, just wanted to say that you've made an exceptional mod -- I'm definitely looking forward to using this in my future projects.
I wanted to reiterate the bug reported on Dec 21st. I had set up a scene where the player is a car, consistently moving towards the left on a scroll looped map while text plays (they just drive indefinitely). The light kept turning off and back on, so I believe it's the same issue as described by jaxcap.
As an aside, is there an ability to use the extra parameters on the player's light as well, or is that events only?
I wanted to reiterate the bug reported on Dec 21st. I had set up a scene where the player is a car, consistently moving towards the left on a scroll looped map while text plays (they just drive indefinitely). The light kept turning off and back on, so I believe it's the same issue as described by jaxcap.
As an aside, is there an ability to use the extra parameters on the player's light as well, or is that events only?
Hi OCram, your lighting plugin is awesome! Thank you, it has allowed me to implement a core mechanic that I otherwise wouldn't be able to do. I have one issue though... When using the light_player plugin command I can't turn the player light back on after turning it off.
I get the error:
TypeError: Cannot read property 'r' of null
the command that I am using is:
light_player 1 100 color:#444444ff
Thanks,
I get the error:
TypeError: Cannot read property 'r' of null
the command that I am using is:
light_player 1 100 color:#444444ff
Thanks,
Thank you for the report,
I think I've already fixed this on upcoming new update (v2.04). I hope I can release new version soon (need to to test it first).
New features so far:
- OcRam core v1.04
- Fixed bugs on load, when event/player lights were controlled via plugin commands
- Done some optimizations >> pre-calculations + RMMV core function optimization (Game_Map.adjustX/Y and Game_CharacterBase.screenX/Y)
- Battle light-ex plugin command (battle_light_ex)
- Right light source offsetX in battle scene now works as intended (reversed offsetX)
- Looped map bug is now fixed
Thanks OcRam,
I went through the plugin code with a friend who knows javascript (as I have no idea) and he found that it was the color: which didn't need to be there.
this appears to work:
light_player 1 100 #444444ff
maybe if you can put an example after each definition in the documentation that would help
like what you did for battle_light
appreciate all your efforts, amazing work!
I went through the plugin code with a friend who knows javascript (as I have no idea) and he found that it was the color: which didn't need to be there.
this appears to work:
light_player 1 100 #444444ff
maybe if you can put an example after each definition in the documentation that would help
like what you did for battle_light
appreciate all your efforts, amazing work!
Thank you for the message,
Glad to hear you got it working! I have added examples in help section (examples will be in next version).
Latest version - v2.04 (released 2020/03/14)
- OcRam core v1.04 (requirement for all of my latest plugins)
...And prepares this plugin for OcRam demo project
- Fixed bugs on load, when event/player lights were controlled via plugin commands.
- Done some optimizations >> pre-calculations + RMMV core function optimization
(Game_Map.adjustX/Y and Game_CharacterBase.screenX/Y) - Battle light-ex plugin command
- Right light source offsetX in battle scene now works as intended (reversed offsetX)
- Looped map bug is now fixed (Credits to: @jaxcap & @Faelim )
Hey dude, I can't find your core plugin anywhere to try this out. How does one get that.
Thank you for the message,
Core is included in Lights plugin itself. Just make sure if you use other my plugins that top most plugin has latest core.
Some people don't like to download any core plugins that's the only reason each of my plugins will include core also (only down-side is that you need to make sure top most plugin will have latest core code section).
yes I don't like to download core
but doesn't this solution will cause bug or something
when it is too old version on top?
Ah cool I'll pop the plugin in and give it a try. Dunno why I never thought to try.
Yes as said on previous post "only down-side is that you need to make sure top most plugin will have latest core code section"
Really nice script. I'm using it in every way i can. Always loved light effects. By far the more performatic i've used - comparing to those in VxAce i've used.
By the way, i have a question: what script call can i use to check if a player or event is now absent of light? I'm trying to create a horror cave in which the player must keep adding fuel to her light source. If it runs out, something bad happens.
Two more things: can a player have light-ex effects? I checked in your code and it doesn't seem to allow, only to events. And what's the purpose of light's comentary last parameter?
If i get it right, you only use 3 parameters to build your light class. As shown in:
By the way, i have a question: what script call can i use to check if a player or event is now absent of light? I'm trying to create a horror cave in which the player must keep adding fuel to her light source. If it runs out, something bad happens.
Two more things: can a player have light-ex effects? I checked in your code and it doesn't seem to allow, only to events. And what's the purpose of light's comentary last parameter?
<light:5:300:#ffdd00ff:360>If i get it right, you only use 3 parameters to build your light class. As shown in:
ev._lightData = new Light_Data(ev, parseInt(args[1]), args[3], parseInt(args[2]) * 0.5);
Hi, I'm trying to figure out how to make your plugin work
I disabled how my plugins except yours, and I pasted this :
In a comment of a torch event :
But it doesnt work. The map's still dark 🙁
EDIT : If it can help, I'm using RPGMV 1.5.1 (Tried to update my project and it ended very bad)
EDIT 2 : I just updated RPGMV to 1.6.1, created a fresh project, and pasted your plugin, but it still doesn't work 🙁
EDIT 3 : Solved the problem thanks to this post :
My question now is : Is there a way to replace the "tint screen" event function by OcRam's ?
Also, is there a way to easily understand how to go from RPGM format to Hex format ?
For example, What is -160,-160, -100, 0 in hex ? I have trouble with negative values which aren't a thing when dealing with hex colors
I disabled how my plugins except yours, and I pasted this :
Code:
<light:5:300:#ffdd00ff:360>
In a comment of a torch event :
But it doesnt work. The map's still dark 🙁
EDIT : If it can help, I'm using RPGMV 1.5.1 (Tried to update my project and it ended very bad)
EDIT 2 : I just updated RPGMV to 1.6.1, created a fresh project, and pasted your plugin, but it still doesn't work 🙁
EDIT 3 : Solved the problem thanks to this post :
My question now is : Is there a way to replace the "tint screen" event function by OcRam's ?
Also, is there a way to easily understand how to go from RPGM format to Hex format ?
For example, What is -160,-160, -100, 0 in hex ? I have trouble with negative values which aren't a thing when dealing with hex colors
Hi,
You need to use "light_bg" command (see help section for more information) to darken environment bg light then you can use <light...> tags.
Original thread: https://forums.rpgmakerweb.com/threads/ocram-lights-plugin-mz-mv.108614/