I want to display event CGs. What is the common method for implementing this? I’m planning to show a few base CGs and their variations. Ideally, I’d like to achieve what Picture display, move, and erase functions do in RPG Maker MZ.
There are several methods available, each with its own strengths and weaknesses, so we recommend choosing the one that best suits your needs.
-
“Show Image” Action
If you simply need to display an image, this method is sufficient. However, if you want to add animations, we recommend the following approach instead. -
Display an image using an object and animations
This involves controlling transitions with Visual Script while playing animations created with AnimationPlayer.
(This is slightly more complex, but the dialogue scenes in the conversation sample and the bullet hell sample DLC use this format.)
With AnimationPlayer, you can replace image sources, toggle visibility, and move elements, allowing for highly flexible animations.
Thank you for your response.
I took a look at the DLC bullet hell samples, and I thought it might be better to manage the differences this way, so I’d like to try various things while referring to this.
I am following the settings based on the DLC bullet curtain sample, but there is a part that is not working as expected.
What I want to achieve is to display CG_test01 during Event A in the story, and CG_test02 during Event B.
I have set it up as follows, but when I try to display CG_test01, CG_test02 also appears simultaneously (and vice versa).
I cannot understand why CG_test02 is also displayed even though I have specified CG_test01 as the target object in the “Execute specified action” action. Could you please advise me?
• Menu Scene RootNode ┗CanvasLayer ┣EventCG_Control (Game Object) ┗Control ┣CG_test01 (Game Object. Visible is Off) ┗CG_test02 (Game Object. Visible is Off)• CG_test01, 02 (Game Objects)
Register the CG you want to display in AnimationPlayer, and specify the name of the animation category to execute in the VS state.
• EventCG_Control (Game Object)
Specify the corresponding action of CG_test01 or 02 in the VS execution action “Execute specified action”
Just use AnimationPlayer to create two animations within the same animation node, then control which animation plays using an object. You don’t need to create two new child nodes.
Thank you for your response.
Indeed, I think that is one approach.
However, since the number of CGs to handle will be quite large, considering management, I would like to separate the objects for each event.
I understand your request. Are you setting each animation in the related AnimationPlayer to autoplay, and this autoplay feature is overriding the previous visibility settings?
Check if this is the reason why several objects start playing animations simultaneously after loading.
When checking the runtime state remotely, it appears that the animations set for CG_test01 and CG_test02 are playing at the moment the menu scene is displayed.
By adding animations that display nothing to CG_test01 and CG_test02 respectively and setting them as the initial states, we were able to show only the desired CGs.
Actually, there’s another method, but it requires using code.
Place all animations into an AnimatedSprite2D node.
Use a global variable to control which animation to play. To play a specific animation, use the code play(“animation_name”), and then use frame to set the specific frame.
I see, there’s another way to do it.
Thank you! I’ll use it as a reference.
