Lighting and Time Editor - Continued!

Discussion in 'JS Plugin Releases (RMMV)' started by Feelzor, Oct 30, 2017.

    Tags:
  1. definite_lee

    definite_lee Veteran Veteran

    Messages:
    53
    Likes Received:
    21
    First Language:
    English
    What are the note tags to put in a specific tint for a map?
     
  2. Discordian

    Discordian Villager Member

    Messages:
    7
    Likes Received:
    1
    First Language:
    English
    Primarily Uses:
    RMMV
    Hey, I edited LNM_GameEditorCore.js to add in an option to disable "tab" functionality. Is there another way to do this? If not I recommend adding it, it's really easy:

    Code:
     * @param Enabled
     * @desc Enables or disables "tab" functionality.
     * Set this to false before release.
     * @default true
    
    Code:
    GameEditor.TOOLS.Enabled = JSON.parse(GameEditor.Parameters["Enabled"] || false);
    
    Code:
    //-----------------------------------------------------------------------------
    // Graphics._onKeyDown
    //
    // Toggle the editor by pressing Tab.
    
    Graphics._callEditor_onKeyDown = Graphics._onKeyDown;
    Graphics._onKeyDown = function(event) {
        if (GameEditor.TOOLS.Enabled && !event.ctrlKey && !event.altKey) {
    [...]
    
    I made the parsing default "false" so developers don't accidentally release the game with the editor enabled because of a typo, while making the normal default "true" for better flow for developers when they're first checking out the plugin.
     
  3. BlueZircon

    BlueZircon Villager Member

    Messages:
    10
    Likes Received:
    3
    First Language:
    English
    Primarily Uses:
    RMMV
    I recently added these plugins to my project, but have some questions about the plugins and how to achieve my lighting goals.

    My main goal is to just have a simple torch toggle where the player can use a Torch item, and it activates the Player Torch. This would be relevant in dark areas such as caves or dungeons and possibly also during combat. Currently, I'm modifying the screen tint for those dark areas using events.

    With these plugins, my idea was to suspend the time tint when the player was in the dark areas, but the screen tint events I have already setup use a gray factor, whereas the time tint configurations do not. I also found the the time tints seemed very overpowering (for example, at midnight everything was almost solid blue), and I don't see an alpha configuration that allows me to control how dominant the time tints are.

    So then I thought that I could just disable the time plugin so I could just use the lighting with my existing screen tints, but after I set the time feature flag to false, the player torch no longer seemed to function. Does the lighting only work with the tint effects that originate from these plugins?

    Any insight would be appreciated.
     
  4. Discordian

    Discordian Villager Member

    Messages:
    7
    Likes Received:
    1
    First Language:
    English
    Primarily Uses:
    RMMV
    You can change the time tint for each hour in the plugin settings. Not sure about an alpha option, don't think I saw one. But 255,255,255 is the same as no tint at all IIRC, but with this plugin, you're pretty much surrendering your tints to the plugin while it's enabled I believe.

    As for your torch issue, I haven't implemented lamps yet so I don't have something I can just jot down real quick and I'm sure someone here (or a previous post) can help you.

    Edit: FeelZor has been away since November. I'll likely be making some changes to this plugin, albeit minor, but if I do, I'll submit them here so others can use them.
     
    Last edited: Jan 5, 2019
  5. KaitoKuroba

    KaitoKuroba Villager Member

    Messages:
    5
    Likes Received:
    1
    First Language:
    German
    Primarily Uses:
    N/A
    Hello,

    first of all: Thanks for this plugin. Excellent work.
    I have just two questions that hopefully you can answer.

    1.) When pressing TAB ingame nothing happens. No onscreen editor, nothing. Not even in the demo. What do I do wrong?
    2.) How can I define new hue lights via event?-> Okay, found it in the original thread.

    Thanks so much.

    Best regards
    Kaito

    Edit: Another question: Is it possible to use different playertorches? I mean: Normal (little) sight without item and increased sight with lantern, torch, eg. Of course I know I can switch on and off the playerlight, but when being in a dungeon I would like the option of having at least a little area of sight even without an item.
     
    Last edited: Jan 6, 2019
  6. Discordian

    Discordian Villager Member

    Messages:
    7
    Likes Received:
    1
    First Language:
    English
    Primarily Uses:
    RMMV
    1. No idea how that can happen, are you sure you have all 3 plugins enabled and in order? Do you get any errors?
    2. Awesome!
    3. Not sure, but you might be able to attach a light to an event, and have it mimic player movements. I'm not 100% sure on that idea, but I believe it should work.

    I hope this helps!
     
  7. KaitoKuroba

    KaitoKuroba Villager Member

    Messages:
    5
    Likes Received:
    1
    First Language:
    German
    Primarily Uses:
    N/A
    Thanks for your answer.
    Regarding 1.) I even tried it with the demo. Didn't work at all. :( Maybe because of my german keyboard layout? I didn't have any error notification.
    2.) Thanks. :D
    3.) I was thinking of this, too. But I am not sure if this is possible in a way to make it even look good. I was even trying to configure another player torch via the javascript, but this didn't work at all. Is it maybe possible to change the parameters of the player torch ingame via event? This would maybe help.

    Best regards
    Kaito
     
  8. Discordian

    Discordian Villager Member

    Messages:
    7
    Likes Received:
    1
    First Language:
    English
    Primarily Uses:
    RMMV
    1. Hmm I haven't tried with very many layouts so that could be the issue! Usually the error console (F12) has something. I'm really not sure, I'm just a user and it's been working for me!

    3. It doesn't appear to be possible to change player torch via in-game event (unless someone programs the feature in). Is it choppy if you use an event that mirrors the user? I haven't tried it myself yet, that was just the first idea I had. I recommend you keep playing with the Javascript if you can't do in-game events.

    I might take up development of this plugin but only in a minor capacity. I still hope the developer comes back.

    Sorry I couldn't be of more help :).
     
  9. SoulOfRock

    SoulOfRock Veteran Veteran

    Messages:
    38
    Likes Received:
    6
    First Language:
    Spanish
    Hi, im using himework custom page conditions and im trying to make an event that appear only when the time is 6:00, so i need a script call for the game time, and i dont know what to put.
    this is my event page.

    <page condition>
    if : Script $gameTime(6:00) <------------- This is only an example, i really dont know what to put here.
    plugin comand: activate_page
    end
    </page condition>

    help me pls,ty :)
     
  10. KaitoKuroba

    KaitoKuroba Villager Member

    Messages:
    5
    Likes Received:
    1
    First Language:
    German
    Primarily Uses:
    N/A
    1. No error visible in the console. Pressing Tab just does nothing. :(

    3. Actually I am pretty good with using events. But a mirror to the user seems a bit difficult and maybe slows game even down.

    I found your answer very helpful. So thank you. I think, the players of my actual game should just be ok with the fact that the world is very dark, when they don't collect torches then. ^^

    Best regards
    Kaito
     
    Discordian likes this.
  11. Discordian

    Discordian Villager Member

    Messages:
    7
    Likes Received:
    1
    First Language:
    English
    Primarily Uses:
    RMMV
    See first post:

    Before doing check, run that plugin command to save the time to variables, then check those.
     
  12. SoulOfRock

    SoulOfRock Veteran Veteran

    Messages:
    38
    Likes Received:
    6
    First Language:
    Spanish
    I try with save time,and the event now have this page condition.

    <page condition>
    if : Variable hour = 6
    plugin comand: activate_page
    end
    </page condition>

    But the variable dont change
    automatically,and the event dont disappear at the 6am. Help TnT.
     
    Last edited: Jan 14, 2019
  13. Prescott

    Prescott argggghhh Veteran

    Messages:
    412
    Likes Received:
    207
    Location:
    USA
    First Language:
    English
    Primarily Uses:
    RMMV
    I intend to create my game with only two times: day and night. Just to simplify things. Is there any way to configure this plugin to make it have only two times of day instead of a dynamic clock, and do a screen fade out then fade in when the time of day changes (to account for NPCs moving)? I really want the ease of placing lights like in the video rather than going through every event and customizing it, but my game does not have this dynamic clock.

    Worst case, I'll change the game to accommodate this plugin though, because it's pretty amazing being able to place lighting effects like that.
     
  14. Discordian

    Discordian Villager Member

    Messages:
    7
    Likes Received:
    1
    First Language:
    English
    Primarily Uses:
    RMMV
    Yeah you can simply use plugin commands to set the time with an event that does the fades when you want, or even let the time run normally, and have an event run at a certain time. You can also configure the colours for each time of day. My game I keep time paused at all times, and advance it after the player triggers certain events that advance the day.

    Hope that helps, good luck!
     
    Prescott likes this.
  15. Prescott

    Prescott argggghhh Veteran

    Messages:
    412
    Likes Received:
    207
    Location:
    USA
    First Language:
    English
    Primarily Uses:
    RMMV
    Oh I see, so you just keep it paused until a certain condition is met and then manually change it, awesome! It'll be much easier to set up a time system that way, right now I'm doing it with just eventing.

    Now I just have to figure out how to make my game not freeze while a parallel process event throws out a wait command if it's a common event rather than a normal event put on every single map.
     

Share This Page