Terrax Lighting system

Discussion in 'JS Plugin Releases (RMMV)' started by Terrax, Nov 5, 2015.

  1. Terrax

    Terrax Veteran Veteran

    Messages:
    304
    Likes Received:
    223
    First Language:
    English
    So the problem is that lag seems to increase very time the menu is opened and closed, ill see if i can replicate that (on average how many lightsources are on your map?)

    Ah yes, your using the Puzzle plugin, i have not looked at that plugin for a long long time.. no worries though it whould be easy enough to fix,


    ill upload a new version soon.
     
    KaYsEr likes this.
  2. padr81

    padr81 Guy whose game is taking too long. Veteran

    Messages:
    642
    Likes Received:
    640
    First Language:
    english
    Primarily Uses:
    N/A
    If you put say 6 on 2 maps and just transfer over and back between them you'll get the effect, or just on one map.  Its a similar issue to what happens with parallax maps etc..  Don't think its specific to your plugin.
     
  3. Terrax

    Terrax Veteran Veteran

    Messages:
    304
    Likes Received:
    223
    First Language:
    English
    I've build in some timers in the plugin for testing, but unless i use tile-tags or region-tags i cannot replicate a slowing effect when running in and out of maps.


    (are you using tile or region tags?)
     
  4. Gonor

    Gonor Veteran Veteran

    Messages:
    140
    Likes Received:
    67
    Location:
    Switzerland (but originally from Germany)
    First Language:
    German
    Primarily Uses:
    RMMV
    Hey, Terrax.


    Happy New Year!


    Just a quick question (not a problem this time ;) ).


    I was thinking about (mis)using the flashlight as a beam of light, coming in through a window.


    But I'm not quite satisfied with the result, as the flashlight itself is composed of several circles. This makes it look a bit odd. Is there any way to change the shape of the flashlight (or any light source for that matter)?


    Cheers.


    Gonor
     
  5. Terrax

    Terrax Veteran Veteran

    Messages:
    304
    Likes Received:
    223
    First Language:
    English
    I've look at the posibilities in javascript, and a window beam looks possible, but will require some fiddling around with canvas, paths and gradient fills.


    I'm first gonna finish changing lights, after that it might be a nice next thing to do :)


    It's probably a good upgrade for the flashlight shape as well.
     
  6. Azkarath

    Azkarath Warper Member

    Messages:
    3
    Likes Received:
    0
    Hi Torrax


    I have tried to get your lovely plugin to work, but when I put Light 250 #FFFFFF in an event on an map, the time in Mog Time System goes crazy fast, both months, days and the time it self. Can you please help me out here =)
     
  7. Terrax

    Terrax Veteran Veteran

    Messages:
    304
    Likes Received:
    223
    First Language:
    English
    I can :)


    When you install the lighting plugin there is an option thats called 'save daylighthours', It defaults to variable 10. Variable 10 is also used by the Mog Time system.


    So in the ligthing plugin, set 'save daynighthours' to 0 ;) (If thats not it, you are probably using variable 10 yourself for something else)


    Hope that fixes your problem.
     
  8. Zaen

    Zaen Find Me on YouTube Veteran

    Messages:
    115
    Likes Received:
    30
    Location:
    Tejas
    First Language:
    English


    Sooo, I set out to make a YouTube video where I address specifically you, Terrax, and attempt to show in total what is causing my problem, and what I found shocked me. I'll go ahead and tell you right up front that I discovered the problem I have can still be made to happen even when your plugin is off. I went through various things, showing you my lights, my common events that use the lights, and some of the maps in the area. But... it turns out, unless I'm missing something, it can't be your plugin after what I've proved in the video. It's something else, which baffles me because I'm not sure where to start.


    I'll probably get some rest since I'm over excited in general today + exhaustion and I'll wake up with a problem solving mind. But... to be honest, I'm still not optimistic about how easy it will be to find on my own. It's a bit discouraging, to be honest.


    You don't owe me anything, but I did address you in the video and it would be cool if you'd check it out for me. Maybe you'll see something that occurs to you what my problem could be. But... I'm pretty sure now that it's not you. Thanks man.
     
     
  9. TakaDynasty

    TakaDynasty Apologetic Lurker Veteran

    Messages:
    41
    Likes Received:
    8
    Location:
    Somewhere between Eorzea and Nythia
    First Language:
    English
    A bit fiddly to get working the way I wanted it to for specific scenes only at first (for my little brain, anyway), but now that I have, it looks wonderful. Really adds character and depth to a map. :) Very good plugin indeed!


    Note to any newcomers to the plugin who want unlit areas to be dim instead of black (as this was the most fiddly part for me until I figured out the way that was most intuitive for me): It's as simple as setting up an autorun event on the map to be lit which changes the player's light to something pretty dim. Say #444444. Then in the plugin options, set the player's radius to 900 or more and bam, brighter unlit areas.
     
    Last edited by a moderator: Jan 4, 2017
    Terrax likes this.
  10. Terrax

    Terrax Veteran Veteran

    Messages:
    304
    Likes Received:
    223
    First Language:
    English
    It's a very interesting problem. With only the default files and the lighting plugin i can access the menu 200 times without any lag.


    For starters i would test shutting off addon's that have to do with the main menu. (Yanflys main menu manager for instance) and see if that has any effect.


    Terraxz.
     
  11. padr81

    padr81 Guy whose game is taking too long. Veteran

    Messages:
    642
    Likes Received:
    640
    First Language:
    english
    Primarily Uses:
    N/A


    Hey dude,  I'm not using any of those just regular lighting events.  I think the problem is with mv and not your script, parrallax maps do the same.  Also seems to only happen certain users.


    @Zaen - just curious but as its a problem we both have. I'm wondering what kind of graphics card and processor etc... you are running.  There has to be a reason why so many of us are experiencing this and so many others aren't.  Not to take the thread off topic so maybe by pm.
     
    Last edited by a moderator: Jan 3, 2017
  12. TakaDynasty

    TakaDynasty Apologetic Lurker Veteran

    Messages:
    41
    Likes Received:
    8
    Location:
    Somewhere between Eorzea and Nythia
    First Language:
    English
    @padr81 @Zaen A while back I had an issue where RTP screen tints would cause me tremendous lag, despite having a very powerful rig. It's been so long I've forgotten the exact cause, but it was a technical issue some others had experienced that I fixed with a solution I found online. It's a shot in the dark (no pun intended), but it could be possible your lighting issue is vaguely related. If all else fails, it might be worth looking into that issue on Google and see if any fixes solve your lighting issue as well.
     
    Last edited by a moderator: Jan 4, 2017
  13. Terrax

    Terrax Veteran Veteran

    Messages:
    304
    Likes Received:
    223
    First Language:
    English
    There is a much better option to create slightly lighter maps.


    Plugin command : Tint set #444444


    or if you want to fade in/out the darkness : Plugin command : Tint fade #444444
     
    TakaDynasty likes this.
  14. TakaDynasty

    TakaDynasty Apologetic Lurker Veteran

    Messages:
    41
    Likes Received:
    8
    Location:
    Somewhere between Eorzea and Nythia
    First Language:
    English
    @Terrax Ah, this is excellent to know! Thanks. :) The player method worked, but there was always a slight fade as it got further from the player, so I was hoping I'd discover something like this.
     
  15. TakaDynasty

    TakaDynasty Apologetic Lurker Veteran

    Messages:
    41
    Likes Received:
    8
    Location:
    Somewhere between Eorzea and Nythia
    First Language:
    English
    @Terrax Greetings, o ye who didst author this wonderful thing which plugged in unto mine game doth bring beauty and great joy.

    Quick question: Is it possible to darken specific areas? Specifically, I have a dim tint on the map; a #333333. But one back room, I'd like to have almost completely black until the player flips on a light.

    Is it possible to apply like a counterlight? Something that "lights with darkness", as it were?


    Edit: Second quick question. Is it/would it be possible to make specific tiles block off light? In this case, I have a D1 light in a room, but while the wall it's sitting on cuts the light, it illuminates over every other wall in the room. I wonder if there's a way to, say, bind a specific region to "block" light, then let the developer draw that region over walls meant to block light?
     
    Last edited by a moderator: Jan 4, 2017
  16. Terrax

    Terrax Veteran Veteran

    Messages:
    304
    Likes Received:
    223
    First Language:
    English


    I think you can achieve this with region block.


    Draw a region over the area you want to block (lets say region 5)


    The call plugin command : RegionBlock 5 ON  will darken the area completly


    Plugin command : RegionBlock 5 OFF will remove the darkness from the area.


    (Don't overuse the region block, i'm still looking for an improvement to this function, more then 3 regions will start to cause lag)
     
    KaYsEr likes this.
  17. Zaen

    Zaen Find Me on YouTube Veteran

    Messages:
    115
    Likes Received:
    30
    Location:
    Tejas
    First Language:
    English


    It's not my computer. No matter what I delete from the project, I can't remove the bug. But also, no matter what I add from the project to a new project, I can't replicate the problemi n a new project. This leads me to believe that, something changed when I updated RPG Maker. I started this project on a quite old version. My only advice to anyone having this problem is to be careful when you update and make sure you begin your project on a stable build. That should close out this line of discussion,

    Thanks Terrax for abiding it, the great plugin, and the assumption that your plugin was the cause of my problem.


    EDIT


    Do you suspect it would be possible to add two lights on the player, for example... one with a small radius of full FFFFFF light, but a larger one that surrounded the outside and had dimmer light?
     
    Last edited by a moderator: Jan 10, 2017
  18. bgillisp

    bgillisp Global Moderators Global Mod

    Messages:
    12,408
    Likes Received:
    12,640
    Location:
    USA
    First Language:
    English
    Primarily Uses:
    RMVXA
    @Zaen: I do think there's something off in the update steps, as when I went from 1.1 to 1.3.1 I had to create a new project, then copy all my old data to the new project for things to work right. Doing it any other way (even updating the .js files as stated in the directions) did not work. I wonder if there is a hidden file that has to be copied that we are not seeing or something?


    So yes, it might be a case of needing to use a new project for it to work right.
     
  19. Zaen

    Zaen Find Me on YouTube Veteran

    Messages:
    115
    Likes Received:
    30
    Location:
    Tejas
    First Language:
    English
    Definitely had the same experience. There is no way (that I found) to update cleanly from 1.1. Just start a new project.
     
    Last edited by a moderator: Jan 11, 2017
  20. DarkSearinox92

    DarkSearinox92 Veteran Veteran

    Messages:
    257
    Likes Received:
    30
    Location:
    Italy
    First Language:
    Italian
    @Terrax Hi Terrax, a small and innocent thing: Can you insert in the plugin, the possibility to change the text for the function in the menu, that you've added? (Lightning Effects).


    Just like Yanfly. You can change the language words that display the function.


    Can you?
     

Share This Page