How to check if a picture ID is currently in use?

Is there a way you can check, through a script call, if a specific picture ID is drawn/if a picture ID exists? (Meaning that picture ID is currently displaying something and not 'nothing')
retrieve the picture itself.
screen.picture(ID)
or
Game_Screen.prototype.picture(ID)
Close, $gameScreen is the instance object of the Game_Screen class.

The picture function is:
Code:
Game_Screen.prototype.picture = function(pictureId) {
    var realPictureId = this.realPictureId(pictureId);
    return this._pictures[realPictureId];
};
In an 'if' statement, if the picture exists, the result is coerced to true and if the picture does not exist, the result is coerced to false.

In a Conditional Branch event command, you can use the script option and use:
Code:
$gameScreen.picture(4)
which is coerced to true when picture 4 is drawn and coerced to false when picture 4 is not drawn.

Original thread: https://forums.rpgmakerweb.com/threads/how-to-check-if-a-picture-id-is-currently-in-use.104582/