Some help with Simple Shadows

Well, I having been trying to make a plugin that adds small shadows below the characters and events. I 've had a parcial success as you can see.

[IMG]http://i.imgur.com/mUGfo5N.png[/IMG]

Sprite_Character.prototype.createShadowSprite = function() { this._shadowSprite = new Sprite(); this._shadowSprite.bitmap = ImageManager.loadSystem('Shadow1'); this._shadowSprite.anchor.x = 0.5; this._shadowSprite.anchor.y = 0.82; this._shadowSprite.y = -2; this.addChild(this._shadowSprite);};Sprite_Character.prototype.initMembers = function() { this.createShadowSprite(); // <-- added this line this.anchor.x = 0.5; this.anchor.y = 1; this._character = null; this._balloonDuration = 0; this._tilesetId = 0; this._upperBody = null; this._lowerBody = null;};But I have two problems to overcome.

1) Put the shadows below the characters. Currently I can only draw then above.

2) Create some kind of mechanism to disable the shadow for some events. I use to do that with a comment on the event page, not sure how I proceeed on MV.
I think you just need to create the shadow sprites before the character sprites to have them below.  If you get stuck, vehicles use shadows, so you could check out how they work.

And use a switch to toggle their visibility, and on update, set their visibility equal to the switch value.
And use a switch to toggle their visibility, and on update, set their visibility equal to the switch value.
Thanks for the reply, Shaz.

With a switch I would be able to disable all the shadows at once, that is not what I want. What I want is to be able to disable the shadows of specific events.

Original thread: https://forums.rpgmakerweb.com/threads/some-help-with-simple-shadows.47730/