How do I reposition the player on the active tile?

Hello again!!

I am trying to reposition the player's model on the tile it is currently on. By default, character sprites are offset 6 pixels up on the y-axis to give the illusion of "standing on the tile". But I would rather have my player (and all other characters too) fully *on* the active tile. I'll show you what I mean.

(sorry for low img quality)
Here is my character before he walks in front of this wall. The tile directly to the right of me is passable, and the tile to the topright is "through".
1.png

Here is what happens when I walk onto the passable tile:
2.png

As you can see, six pixels (or two "big pixels", since it's a 16x sprite) of my player are cut off because they are technically on the tile above me.

I have looked in the .js files and all I could find were the functions Game_Player and Game_Character in rmmz_objects.js. But I didn't find anything to offset the sprite on the active tile.

Does anyone have experience with this, or can anyone give me some recommendations to try? Thank you! <3
You can put a ! at the start of filename of the player's spritesheet, e.g. !Actor1_1.png. This will mark it as an "object character", negating the default 6 px vertical offset: that's why spritesheets of doors etc generally have filenames with a ! at the start. Note that object characters also ignore the "bush" effect (obscures bottom 12 px of character when on tiles marked as bush in the database), which might be undesirable.

Alternatively you could do it with a plugin, e.g. I think this will remove the 6 px vertical offset for all characters:
JavaScript:
Game_CharacterBase.prototype.shiftY = function() { return 0; };
To try it out, save it as a .js file (paste into a text-editor, Save As > File Type: All Files, Filename: whatever.js) and import it as a plugin. This way you don't have to worry about reassigning all your spritesheet references, and it shouldn't affect bush tiles either~ 🙏
EEEE you are lifesaver my friend!
The script worked <3
Also now I know how easy it is to make plugins, tyty!
I was so frustrated wondering why my character was 6 pixels higher than expected. My characters head was always going behind the upper layer of rocks and trees 😩 I thought I was going to have to shift all the "above" layers of my layer maps up slightly and then always have to deal with some weird hack.
This little plugin saved me so much time! Thank you @caethyril!
Great! Try to avoid bumping old support threads, though. Here's the usual spiel:

@patternBlue, please refrain from necro-posting in a thread. Necro-posting is posting in a thread that has not had posting activity in over 30 days. You can review our forum rules here. Thank you.

Happy RPG Making! 😂

This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

Original thread: https://forums.rpgmakerweb.com/threads/how-do-i-reposition-the-player-on-the-active-tile.128445/