State-based dialogue side-images

DontUStareAtMe.png

Seems like an easy one, but I couldn't find anything related. The player character in my game will have dialogue like you can see above, and he will be able to change his outfit pretty much all the time. Meaning that he could wear pretty much everything while having said dialogue. And you can probably already see the problem, especially when there is a lot of dialogue and a lot of outfits.
Is there a function or script to choose the side image based on a variable (state, flag, switch, I'm not choosy)?
The link doesn't work for me...

by side image, if you are referring to the character image, there is an event command to change the character image. If you want to do that based on switches or variables, it's doable, with a common event and a bunch of conditional branches.

I'm not exactly sure how the dialogue part of that fits into what you are asking though. Do you mean that there will be dialogue when the actor changes their outfit? Because then you could use the show text event command. Or if you don't want a regular text box, Yanfly and Galv both have a plugin for pop up text.
The link doesn't work for me...

Fixed the picture and hope that answers your question!
Provided you always update your main character's actor image when his outfit changes (with Change Actor Images), I believe Shaz's MoreEscapeCodes plugin (included in the dlc folder if you have the Steam version) should do what you want.
So the player can choose their appearance anytime they want? That's very random and just variables won't work because it's a mixture of changes (in your example you showed moustache, clothes; no moustache, no clothes... what if the player chooses moustache and no clothes? Get what I mean?) The closest I can find is this plugin: http://sumrndm.site/ccex-dynamic-actors/
(...) The closest I can find is this plugin: http://sumrndm.site/ccex-dynamic-actors/
Stumbled upon that already, and while it's a great plugin it would require me to split my character into at least 15 actors, and I'm not entirely sure how to access the different emotions from the spritesheet. I remember thinking "yes, this could do the trick", but it would come out almost as messy as copypasting the same dialogue 15 times.


(...)I believe Shaz's MoreEscapeCodes plugin (included in the dlc folder if you have the Steam version) should do what you want.

Since there is no escaping in my game I'd never looked into that. :|

This is getting really close to what I need, since it's also accessing the "emotional states" by using simple tags, and *simple* is what I really like about it:

\f[1,2]blah blah blah

Now if there was a plugin to have

\f(x,2) blah blah blah

instead, x being the player's outfit, that would do it. It's not the first time I run into problems with RPG Maker because it somehow seems to hate arrays.

Thinking about it, both suggested plugins together could do the trick. I'll continue experimenting, thank you for your assistance so far!
Have you tried something like \f[\v[1],2]blah blah blah? I.e. use the value of variable 1 (change ID as needed) as the first argument. I'm guessing you already have such a variable, if not then you can set it before the dialogue happens. 🙂

This should work if Shaz's plugin processes the \f code after the default stuff. Hopefully that's the case, I haven't checked. 😴
Since \f is a late-processing code in Window_Message and \v is an early-processing code in Window_Base, I imagine it should be fine?
Yep, just tested and it seems to work OK with variables! 😂
Yep, just tested and it seems to work OK with variables! 😂

I think I gave up too early, normally a syntax like that just results in fun messages like
f[object,object] Well, hello there

Gonna give this a try and report back if it works. It's a shame because I already shifted everything to face-free speech bubbles (using GALVs message styles) which I happen to like a lot, too. On the other hand letting all those faces go to waste would have been... well, a waste🙂
If the escape codes make it hard for you to see whether or not your text fits in the message box, you can always select the message command in the event editor and hit Ctrl+R (or right-click and select Test). That'll show you the message exactly as the game will interpret it... as long as the escape codes don't depend on the current map, at least.
If the escape codes make it hard for you(...)

I just didn't know that the tags where referred to as "escape codes". That's something I experience here more often than I want to admit, I also had no idea what "busts" are supposed to be until I was looking for what I consider "side images"(I still speak Renpy better than RPGMaker😉).

Anyways: Shaz's MoreEscapeCodes plugin is the solution I was looking for. I haven't tested it thoroughly (not exactly a full time developer), but it does what I want without having to copypaste the dialogue for every possible outfit (and resulting bust/side-image).

Original thread: https://forums.rpgmakerweb.com/threads/state-based-dialogue-side-images.122681/