Respawn Manager

Respawn Manager - an object that restores the specified object(s) to their original position when a certain height is reached. This can be useful for the user in cases when an object has fallen under the ground and because of this the scenario passage is blocked. Or if you simply do not want to reach for the floor to pick them up. Let's look at the object properties
Inspector
Only one parameter is defined for the inspector

Respawn manager
- Respawn plane height - the value of the plane height, when reached, the object specified in the logic will return to its initial position at the start of the scene
Blockly
Variables
Returns the specified object
Actions

Adding recovery mechanics to a specified list of objects

Adding recovery mechanics to specified objects
Events

Calls an event when the specified object is restored
Example
Let's consider a simple logic of the object's operation
- First of all, let's put the ‘Recovery Manager’ object and the object we're going to return on the stage. As a return object, we will use a basketball
- Let's select the Recovery Manager in the hierarchy and in the Height of respawn plane field set the value to 1. So, after reaching this height (0 - half of the location) the ball will appear in its original point
- Let's go to the logic editor and add the block of adding the mechanics of object return for the specified object
- Let's insert a ball variable into the object specification cell and wrap it all in the Run chain event when the scene starts
- Save the logic, start the project
You can use any other event, such as a button press, instead of the ‘execute chain at scene launch’ event of the scene. And you can specify a whole list of objects as an object
If you need to set different return heights for different objects, place multiple recovery managers with different heights on the stage