Possible to tin an event?

Discussion in 'RPG Maker MV' started by S_Rank_Crazy, Sep 21, 2016.

    Tags:
  1. S_Rank_Crazy

    S_Rank_Crazy Veteran Veteran

    Messages:
    78
    Likes Received:
    47
    Location:
    The Other Batcave, UK
    First Language:
    English
    Primarily Uses:
    RMMV
    I had a cool idea to be able to highlight objects (events) in an environment but I had a look through the event commands, did a little bit of googling and hit a bit of a dead end. So. Basically, what I'm looking for is a way to apply a tint to the event sprite which fades over a set period of time. From the looks of it there's no way to do this via the standard event commands, right? Or have I missed something?


    Alternately I though of maybe taking a code approach, but I suspect it's not as easy as doing:


    event._image.tint(myColour);


    Or simply doing an adjustment on the colour matrix (since I'll need to ensure I get back to my initial state). I'm thinking the path of least resistance is to copy the canvas' sprite in to a secondary Bitmap and add to the event container, then set all non-alpha pixels to my desired colour, then over time just adjust the alpha of the entire bitmap. When alpha === 0 then remove the 'tint' image. Open to suggestions though. Doesn't seem like the most performant of solutions though.
     
    #1
    Jonforum likes this.
  2. mlogan

    mlogan Global Moderators Global Mod

    Messages:
    13,737
    Likes Received:
    7,586
    Location:
    Texas
    First Language:
    English
    Primarily Uses:
    RMMV
    Probably the easiest way would be to create a character graphic of the item. In the graphic you can have the different frames tinted differently so that when you play a stepping animation it will change tint.


    If you're not sure how to do this, I'd be glad to elaborate.
     
    #2
  3. Vox Novus

    Vox Novus Knight of Whispers Veteran

    Messages:
    3,309
    Likes Received:
    2,478
    Location:
    The Voicelands
    First Language:
    English
    Primarily Uses:
    N/A
    Alternative suggestion: You could play an animation on the event that has a tint to the target for a number of frames.
     
    #3
    S_Rank_Crazy likes this.
  4. S_Rank_Crazy

    S_Rank_Crazy Veteran Veteran

    Messages:
    78
    Likes Received:
    47
    Location:
    The Other Batcave, UK
    First Language:
    English
    Primarily Uses:
    RMMV
    ooh. Hadn't thought of that. I'll give it a go. Might look at how MV handles in in the code and maybe make a plugin for it to be able to highlight things dynamically based on some event-define parameters. thanks guys. I'll let you know how if I run in to any issues :)
     
    #4
    Vox Novus likes this.
  5. Ossra

    Ossra Formerly Exhydra Veteran

    Messages:
    725
    Likes Received:
    529
    First Language:
    English
    Primarily Uses:
    RMMV
    If you are alright using a plugin, you can grab Character Control from my plugin thread. Character Control will allow you to alter all kinds of character sprite attributes.


    [​IMG]
     
    #5
    S_Rank_Crazy and Jonforum like this.
  6. Jonforum

    Jonforum Veteran Veteran

    Messages:
    1,577
    Likes Received:
    1,350
    Location:
    Canada / Québec
    First Language:
    French
    Primarily Uses:
    RMMV


    Hey it's a good idea, and I thought something.


    here step is working i test it.


    1: create animation in database


    2: make flash the (target) in the animation editor, ex: flash target for 5 sec (255 255 255 255) for white


    3: call the animation on specific event.


    For event:


    $gameMap.event(ID).requestAnimation(id);


    ex: for play animation 9 on event 16. 


    $gameMap.event(16).requestAnimation(9);


    Is work and give good resulte to make example item on map Flashing.
     
    #6
  7. S_Rank_Crazy

    S_Rank_Crazy Veteran Veteran

    Messages:
    78
    Likes Received:
    47
    Location:
    The Other Batcave, UK
    First Language:
    English
    Primarily Uses:
    RMMV
    Thanks for the help guys. @Exhydra that plugin looks amazing but I couldn't think of a good way to handle cases with event pages changing affecting the highlighting mechanism whilst still on the map. I started looking at the animation code for setting the tones and how that works and I came up with this:
     
    #7
  8. Ossra

    Ossra Formerly Exhydra Veteran

    Messages:
    725
    Likes Received:
    529
    First Language:
    English
    Primarily Uses:
    RMMV
    @S_Rank_Crazy I am getting a message that says I do not have permission to show the content you posted.   o:
     
    #8
  9. S_Rank_Crazy

    S_Rank_Crazy Veteran Veteran

    Messages:
    78
    Likes Received:
    47
    Location:
    The Other Batcave, UK
    First Language:
    English
    Primarily Uses:
    RMMV
    Dammit, pending approval. That's what I get for being enthusiastic.
     
    #9

Share This Page