Hello.

Could you tell me how to start the battle when you switch scenes?
I want to switch scenes as shown below.

Scene A → Battle scene → Scene B

In this case, will it be a form of creating a battle end event that calls the battle in scene A and calls scene B after the end?
Please let me know if there is a good way.
  • There are different ways to do it - but it mainly depends on the details of your use case, e.g. if transfering to the battle scene is done via a regular scene changer, a teleport battle or if it's an event that starts the battle.

    If you just load the battle scene via a scene changer, you can use a Battle component with Autostart start type (maybe using a short start delay) and a battle end event that loads a different scene.

    You can also control which scene to load with a general battle end event instead of creating one for each different scene by storing the name of the scene you want to load into a global string game variable (e.g. before the battle) and use that in the Load Scene node.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Thank you for your response.
    I created a scene to call a battle in the following form, but the battle does not start.
    Do I need other objects such as players to start the battle?
    I would appreciate any advice.
    Attach the image of the created scene.

    image

    ①. Create a scene with only objects that have a Battle Component that is set to call the battle scene with Auto Start.
    ②. Call the scene of ① from another scene.
  • Try enabling In Blocked Control, e.g. if the player control is blocked from an event or the scene change it would otherwise prevent the battle from starting.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • When I tried the method you taught me, I was able to call the battle scene in debug execution.
    However, the following problems have occurred and I am worried about how to solve them.
    I'm sorry to hear that, but I would appreciate any advice.

    1. The battle scene was not called in the built application.

    2. When changing scenes, after fading out the scene before moving, the screen of the scene before moving is reflected again.
    image
  • Is your battle scene added to the scenes in your build? The scene has to be added to Unity's Build Settings.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • As I confirmed, a scene that calls a battle and a scene that battles after being called have been added to Unity's Build Settings.
    Currently, the scene is transitioning in the form of ①, but will the problem be solved by changing to the form of ②?
    In case of (2), will the event to be used be a form that is partially modified from the tutorial (http://orkframework.com/tutorial/game-tutorial/23-battle-start-events/)?

    ① The scene that calls the battle and the scene that performs the battle are different

    Scene A → Scene to call battle → Scene to perform battle → Scene B

    ② The scene to call the battle and the scene to perform the battle are the same

    Scene A → Scene that calls the battle → Scene B

    Sincerely
  • #2 will definitely be better.

    How have you set up the transition from Scene A to the battle scene? Is it using a Scene Changer component, a game event or are you using a teleport battle?
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Scene A → Scene to call battle uses scene changes that are not ork's.
    In Scene to call battle → Scene to perform battle, the event of a teleport battle is changed and used.
    It is changed and used as shown in the image below.
    image
  • And how's the Battle component in the scene set up?

    The Battle Start Event is used by a battle when it starts, i.e. the scene to call battle needs a correct battle setup that can start, e.g. using Autostart start type, maybe with In Blocked Controls enabled and a short delay (Start After) of 0.1seconds.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
Sign In or Register to comment.