Turning a flashlight into a lantern?

Snarkyfork

Veteran
Veteran
Joined
Oct 29, 2015
Messages
312
Reaction score
32
First Language
English
Primarily Uses
If anyone could help out with this I would greatly appreciate it. I am using the terrax lighting plugin and in the plugin there is a torch and a flashlight item. First of all, I cannot seem to figure out how to "shut off" the torch by using a command. See what I want to do is have a "lantern" which uses the radius like a torch but you can shut it on and off like the flashlight.


So basically I am trying to turn the flashlight "beam" into a "radius", more or less. But I don't know if this is something that can be done easily or if I need to actually change the script (and I know nothing of js). Again, any help is very welcome, thanks.
 

sabao

Veteran
Veteran
Joined
Apr 10, 2012
Messages
832
Reaction score
299
First Language
Filipino
Primarily Uses
RMVXA
Why not just use multiple commands in succession? I tried the script out and executed the commands via events. Here's what I did:


Turn on flashlight:


  • Fire radius 0 #FFFFFF - Turns off the lantern flickering, should one be on.

  • Light radius 10 #FFFFFF - Creates a small light radius around the player. Having this at 0 kills the flashlight, for some reason.

  • Flashlight on 8 12 #FFFFFF 3 - Turns on the flashlight

Turn off flashlight:


  • Flashlight off - Turns off the flashlight beam.

  • Fire radius 200 #FFFFFF - Turns on lantern flickering.

For a better looking transition, I think it may be possible to play with the radiusgrow command too, but the decay/growth speed does not appear to be configurable except through the source code. A quick look of it tells me there's no way to individually edit the growth/decay rate, but I'm basing this solely on a quick read-through and with the limited comprehension of script that I have.


Hope this helps!
 
Last edited by a moderator:

Ghost of Christmas Kloe

The Icecream Princess
Veteran
Joined
Nov 15, 2015
Messages
1,548
Reaction score
957
First Language
English
Primarily Uses
RMMZ
Um... Why don't you look though the demo and look how it's done there?
 

Snarkyfork

Veteran
Veteran
Joined
Oct 29, 2015
Messages
312
Reaction score
32
First Language
English
Primarily Uses
Um... Why don't you look though the demo and look how it's done there?


I have been looking through it for what I am trying to do and don't see it. So um... perhaps you could point me in the right direction. Would be appreciated.


I really just need a command to turn off torch light and I can take it from there. I see the "light off" command but it doesn't seem to be working for me.


Here is what it says in the demo for turning the light off:


"Light off with (Death)Selfswitch C.


You can set a deathswitch in the parameters."


I am not sure what this means, however. What does (Death)Selfswitch C mean or how do I make one that works on the player character?
 
Last edited by a moderator:

Snarkyfork

Veteran
Veteran
Joined
Oct 29, 2015
Messages
312
Reaction score
32
First Language
English
Primarily Uses
Why not just use multiple commands in succession? I tried the script out and executed the commands via events. Here's what I did:


Turn on flashlight:


  • Fire radius 0 #FFFFFF - Turns off the lantern flickering, should one be on.

  • Light radius 10 #FFFFFF - Creates a small light radius around the player. Having this at 0 kills the flashlight, for some reason.

  • Flashlight on 8 12 #FFFFFF 3 - Turns on the flashlight

Turn off flashlight:


  • Flashlight off - Turns off the flashlight beam.

  • Fire radius 200 #FFFFFF - Turns on lantern flickering.

For a better looking transition, I think it may be possible to play with the radiusgrow command too, but the decay/growth speed does not appear to be configurable except through the source code. A quick look of it tells me there's no way to individually edit the growth/decay rate, but I'm basing this solely on a quick read-through and with the limited comprehension of script that I have.


Hope this helps!
I tried making a flashlight with a beam radius/length of 1/1 then adding the light radius 200 (for a lantern light) to the flashlight on command in the flashlight "common event". It worked for turning the lantern on but adding "light off" to the flashlight off area of the common event doesn't work. Any suggestions?
 

Snarkyfork

Veteran
Veteran
Joined
Oct 29, 2015
Messages
312
Reaction score
32
First Language
English
Primarily Uses
Yeah, I found that but its for the flashlight on/off. What I am trying to do is create a "lantern effect" that shuts on and off by using the item in the players inventory (like the flashlight but with a "radius" and not a "beam").


I actually figured out how to do it in a satisfactory way, there may be other ways but this seems to work:







I then added an event switch to one of the map lights that turns off the player light because for some reason it is on by default and when I clicked on the torch/lantern for the first time it turned them off (no idea why).



 This way I can add as many light sources (like different colored crystals, etc) as I want and they will all work together correctly. Took me a lot of trial and error to get this, sadly.


Also, Yanfly has a plugin that lets you use skills/spells on the map menu (I think)... It would be cool to make a "night vision" spell that could be used from the map menu that triggers a "shader change" plugin command. But that will have to wait for another day I think.
 
Last edited by a moderator:

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Profile Posts

Day 9 of giveaways! 8 prizes today :D
He mad, but he cute :kaopride:

Our latest feature is an interview with... me?!

People4_2 (Capelet off and on) added!

Just beat the last of us 2 last night and starting jedi: fallen order right now, both use unreal engine & when I say i knew 80% of jedi's buttons right away because they were the same buttons as TLOU2 its ridiculous, even the same narrow hallway crawl and barely-made-it jump they do. Unreal Engine is just big budget RPG Maker the way they make games nearly identical at its core lol.

Forum statistics

Threads
106,040
Messages
1,018,476
Members
137,824
Latest member
dobratemporal
Top