• Do not use Discord to host any images you post, these links expire quickly! You can learn how to add images to your posts here.
Resource icon

Resource Mid battle dialogue for v20+ 3.0

LinKazamine

Champion
Member
Joined
May 24, 2023
Posts
674
1699720350686.png
Delete this end. As you see with the dots that are over it, it conects with nothing.
 

grogro

Cooltrainer
Member
Joined
Mar 6, 2021
Posts
120
It was probably me going too fast when writing the tutorial. It's fixed
 

Ozander

Ozander
Member
Joined
Jul 28, 2020
Posts
101
Anyone has an idea how to show player sprite in battle with mid battle dialogue? I mean this one that shows on the begining of the battle.
 

grogro

Cooltrainer
Member
Joined
Mar 6, 2021
Posts
120
battle.scene.pbShowOpponent(0,true)
if you are talking about just showing the sprite.
If you want an intro, it's not a mbd thing
 

Ozander

Ozander
Member
Joined
Jul 28, 2020
Posts
101
battle.scene.pbShowOpponent(0,true)
if you are talking about just showing the sprite.
If you want an intro, it's not a mbd thing
I mean showing player sprite, I wanna make dialogue where firstly the opposing trainer is shown and he says something and then the player sprite is shown
 

grogro

Cooltrainer
Member
Joined
Mar 6, 2021
Posts
120
oh, it would require some coding probably. A good substitute is showing the picture of your face just above the text
 

grogro

Cooltrainer
Member
Joined
Mar 6, 2021
Posts
120
pbMessage("\\f[IintroOak]OK \\PN, let's see if you can beat this Pikachu!")
where what's in the brackets is the filename in your pictures folder
 

schmonday

Rookie
Member
Joined
Dec 13, 2023
Posts
3
Is this actually compatible with 21.1? I get an error in MBD.rb saying "pbCanSwitchLax" is an unknown method.
Nothing seems to set "checkLaxOnly" to true, but I'm not familiar with how the Ruby compiler works. Does it check things in an entire method only when that method is called?

It appeared when attempting to switch in a pokemon when one fainted (with two pokemon in party).
 

grogro

Cooltrainer
Member
Joined
Mar 6, 2021
Posts
120
can I get the full error message? (and check that you have the v21 version). Because I don't see pbCanSwitchLax in my script
 

nosferatu123

Rookie
Member
Joined
Dec 26, 2023
Posts
1
I'm not sure if this is a bug but when I set trainer's battle order, it works however, when using moves like baton pass or u-turn, the same Pokemon always comes back out rather than changing. Anyone knows if there's a fix?
 

grogro

Cooltrainer
Member
Joined
Mar 6, 2021
Posts
120
It requires to make an exception for those moves in the mbd version of pbSwitchInBetween. If someone has a clean solution, I would be happy to hear it, else, I will find a crappy one
 

nomists

Novice
Member
Joined
Sep 2, 2023
Posts
39
Just wanted to leave this bit of encouragement:

On a whim, I had previously archived the old version of this post with all your commands and copied a bunch over and commented them out on my own plugin. Let me just say: Best decision ever. These past couple months I've done so much with your script and used that archive frequently. This is great.


Anyway, I had one possible improvement you might consider, but feel free to ignore completely. So, I use your script to change the trainer's sprite when they talk. To this end, I'll have multiple sprites of a trainer and then change it for each line of dialogue. For instance, I do something like this:
Ruby:
Expand Collapse Copy
    TrainerDialogue.changeTrainerSprite("RIVAL_flex",battle.scene)
    pbMessage("\\c[11]Rival GARY wants to fight!\\1")
    TrainerDialogue.changeTrainerSprite("RIVAL_snark_laugh",battle.scene)
    pbMessage("\\c[20]Well,\\.\\. well,\\.\\. well!\\.\\. Look what the Pikachu hacked up!\\1")
    TrainerDialogue.changeTrainerSprite("RIVAL_forward_talk",battle.scene)
    pbMessage("\\c[20]\\PN!\\.\\. I'm impressed you managed to crawl out of your mom's basement!\\1")
    TrainerDialogue.changeTrainerSprite("RIVAL_snark_laugh",battle.scene)
    pbMessage("\\c[20]But it doesn't matter!\\.\\. Because I'm going to murder your stupid waifu!\\1")

However, one minor nuisance I've found is that you can't just swap sprites because this throws an error. Rather, you have to swap to the sprite of a predefined trainer type. As a result, if one wants to use a bunch of sprites for one trainer, they have to define a lot of dummy trainer classes. Hence, my trainer_types.txt has this corresponding section:

Ruby:
Expand Collapse Copy
[RIVAL_shock]
[RIVAL_point]
[RIVAL_forward_talk]
[RIVAL_snark_laugh]
[RIVAL_laugh]
[RIVAL_chide]
[RIVAL_flex]
Name = Rival
Gender = Male
BaseMoney = 16
BattleBGM = Plok SNES Boss Theme  Ultra HD Remastered

That said, if you do make any tweaks in the future, it might be nice to find a way for the player to switch to sprites that aren't in pre-defined trainer classes. However, I also know this may break some things between the versions and might be a little complicated, when there's otherwise a simple fix. So, feel free to ignore this if you want. But at very least, thanks again for the wonderful resource!
 
Last edited:

grogro

Cooltrainer
Member
Joined
Mar 6, 2021
Posts
120
You are totally right about this. It was like this in the original version of Golisopod User, it's still working so I never put my nose into this part of the code, except for minor compatibility changes. If I have some time for it, I'll see what I can do
 

grogro

Cooltrainer
Member
Joined
Mar 6, 2021
Posts
120
after looking at it, it's not something I can change without breaking existing battlesprites. But you can do it for your copy of the plugin. Look for the changeTrainerSprite in the MBD.rb script. replacing GameData::TrainerType.front_sprite_filename(name) by
"Graphics/Trainers/{name}" might work though
 
Back
Top