Quasi Simple Shadows

● ARCHIVED · READ-ONLY
Started by Quxios 20 posts View original ↗
  1. Quasi Simple Shadows Version - 1.00


    by Quasi




    About
    This plugin adds a simple shadow casting feature to character sprites. I consider this plugin simple because it is not dynamic, advanced and is not a real shadow casting. Though I do plan on creating a real shadow casting once MV can use pixi v3+. By real shadow casting I mean something like Twitter Video


    Links


    Github - Download


    Setting up a “shadow casting” source



    To set up a shadow source, you will add a note in the event with in one of the following formats:


    <shadowSource>


    or


    <shadowSource:RADIUS,FLICKERSTR,FLICKERDELAY>


    RADIUS: Set to the radius of the source, in pixels.FLOCKERSTR: How strong the flicker should be.FLICKERDELAY: A value for a random wait between flickers.If you use the first one, it will use the default Radius set in the plugin parameters and it will have no flicker.


    Adding / Removing a “shadow casting” source



    To Add a “shadow casting” use the following plugin command:


    quasi addShadowSource CHARAID SHADOWRADIUS FLICKERSTR FLICKERDELAY


    CHARAID: Set to the Event ID or 0 for the playerSHADOWRADIUS: Set to the radius of the shadow source in pixels. If let empty it will use the plugins parameters default value.FLICKERSTR: Set to the flicker strength of the shadow. If let empty there will be no flicker.FLICKERDELAY: Set to the flicker delay of the shadow. If let empty it will have a delay of 1


    To Remove a “shadow casting” use the following plugin command:


    quasi removeShadowSource CHARAID SHADOWRADIUS


    CHARAID: Set to the Event ID or 0 for the playerSHADOWRADIUS: Set to the radius of the shadow source in pixels. If let empty it will use the plugins parameters default value


    Adding / Removing a shadow from a character



    To hide an Events shadow by default add the following note inside the event:


    <noShadow>




    To Hide a characters shadow use the following plugin command:


    quasi hideShadow CHARAID


    CHARAID: Set to the Event ID or 0 for the player


    To Show a characters shadow use the following plugin command:


    quasi showShadow CHARAID


    CHARAID: Set to the Event ID or 0 for the player


    Other


    Again this is just a really simple shadow addon, nothing dynamic.
  2. Always looking forward your stuff. Very good work. Thanks :D !
  3. That's a script i have been waiting for :D


    Combined with a lightning script this can give really improve the atmosphere :)
  4. Thanks! And yeah I didn't really plan on making this, I was going to wait for a pixi v3+ since that make creating a real lighting with dynamic shadows much easier. But I made this out of a request so enjoy!
  5. It will be great as we wait for pixi3, good job!
  6. Hello there Quasi!


    I'm always a fan of masks and so since it could be an overwhelming feat for the shadows and so. In fact, I always encourage you to think about parallaxing even when I know It has to be so hard to implement.

    Anyways, good job as always.
  7. That's not something we can do until pixi v3 + since v2 doesn't have support for masks on sprites.
  8. Stack Level too deep, cant save the game, if the plugin turns on.
  9. Thank you, it works now. :)  
  10. Hello it is me again :).


    Can you add a Command to add Lightsource to an Event? And a region block for a cut off appearance of the shadow would be nicely!


    For Example: i turn a lamp on and i call the command "quasi addlightsource EV ID"  


    At the moment it is like this:


    example.jpeg
  11. This plugin isn't a lighting plugin. It just adds very simple shadows. You can use this together with any existing lighting plugins to make them look nice together. And I won't be adding any masking until mv gets pixi v3+.
  12. I use the Eventcode "Set Event Location" to teleport the lamp with the <lightsource> Note inside to workaround this. But its awkward. An script call would be smarter. 
  13. oh well if you mean the <lightSource> note tag from this plugin, then you can turn on / off a "light source" for an event using a plugin command


    quasi addShadowSource CHARAID


    can also remove them too. I just renamed the command to shadowSource, because lightSource is somewhat incorrect and can be misleading since this isn't a lighting plugin. I just forgot to rename the note tags lol.


    That information is on the plugins instruction page:


    http://quasixi.com/quasi-simple-shadows/
  14. Im am using the following plugin command to add a shadow source on Event ID 002:


    quasi addShadowSource 2


    But it add nothing, i am using the call wrong?
  15. Just looked and you're right, it's a bug ( kind of ) I just forgot to mention that you're suppose to add the shadow radius in the plugin command.


    quasi addShadowSource CHARAID SHADOWRADIUS


    Here's a new version:


    https://github.com/quasixi/Quasi-MV-Master-Demo/blob/master/js/plugins/QuasiSimpleShadows.js


    If you don't include the shadow radius, it will use the plugins default radius.


    I also changed the notetag from <lightSource> to <shadowSource> ( the old one still works, but better to use the new one to avoid confusion )


    But on a side note:


    Doing that would be the same as just having the


    <lightSource>
    note tag inside the event. All it does is add a radius around the event where if characters get close, they will start casting a shadow. The event that is the source of the shadows will not cast a shadow on it self if that's what you mean. So in your case, any event or player near event 2 will have a shadow, but event 2 will not have a shadow because event 2 is the source.
  16. Wow ^^ thank you for the help, but now i am getting an error if i am turn on or off via event xD. I hope youre not annoyed of me. I add you the failure in the console and the eventcode.

    Spoiler
    error.JPG


    Event Page 1


    error2.JPG


    Event Page 2


    error3.JPG
  17. Wow! Thank you so much ^^. Thumbs up!  :rock-left: :D :rock-right: