Showing an image based on a variable?

Hey there! I'm currently implementing a quest where a player can give 50 items to a character in exchange for a weapon, and want to have unique graphics to show the amount the player has given this character. I want to have a picture show up based on the variable for this exchange, and while I know I could do it like this,
picturevariable.PNG

I really don't want to if there's an easier way I don't know about.
In command Show Picture, you have the option of replacing the last characters of the picture name you chose with the value of a variable:
1746084071623.png

So your event could look like this to avoid too many conditional branches:
1746084334898.png
In command Show Picture, you have the option of replacing the last characters of the picture name you chose with the value of a variable:
View attachment 339095
So your event could look like this to avoid too many conditional branches:
View attachment 339096
Thank you so much, I can't believe I missed this somehow lol
A tip, using ELSE is irrelevant in this type of verification, and will make your event too big unnecessarily, because you don't need to check for exception 1 if 2 is already clearly different from 1, so just do the sequence, there is no possibility of both conditions happening together, since they are the same variable:
Code:
@> Conditional Branch: Variable [0017:SoulOrbsGivenToGears] == 1
  @>
 : Branch End
@> Conditional Branch: Variable [0017:SoulOrbsGivenToGears] == 2
  @>
 : Branch End
@> Conditional Branch: Variable [0017:SoulOrbsGivenToGears] == 3
  @>
 : Branch End

The only development scenario in which you can use the same variable is in the case of a range of values, for example, you want an event to happen up to a certain value, and the opposite is true when that value passes a limit, but within those values there are other events:
Code:
@> Conditional Branch: Variable [0017:SoulOrbsGivenToGears] < 10
  @> Conditional Branch: Variable [0017:SoulOrbsGivenToGears] == 0
    @>
   : Branch End
  @> Conditional Branch: Variable [0017:SoulOrbsGivenToGears] == 1
    @>
   : Branch End
  @> Conditional Branch: Variable [0017:SoulOrbsGivenToGears] == 3
    @>
   : Branch End
  @>
 : Else
  @> Conditional Branch: Variable [0017:SoulOrbsGivenToGears] == 16
    @>
   : Branch End
  @> Conditional Branch: Variable [0017:SoulOrbsGivenToGears] == 17
    @>
   : Branch End
  @> Conditional Branch: Variable [0017:SoulOrbsGivenToGears] == 18
    @>
   : Branch End
  @>
 : Branch End

This type of logic can greatly reduce the number of events, which sometimes take a long time to load due to several unnecessary Condinal Branches.

Original thread: https://forums.rpgmakerweb.com/threads/showing-an-image-based-on-a-variable.177338/