I understand it.
I'm just trying to explain that the map does not know real size of your GameObject.
Let us suppose you have GameObject with the structure:
Prefab (Scale - 1, 1, 1) / Cube (Scale - 1, 1, 1).
The real size of GameObject (1, 1, 1).
But you can have GameObject:
Prefab (Scale - 1, 1, 1) / Cube (Scale - 10, 10, 10).
GameObject have Scale (1, 1, 1), but the real size (10, 10, 10).
Map does not know it. Actually, the map does not need to know it.
To work around this problem, you use this example.
Step-by-step instruction:
1. Run the scene and find the location where building should be.
2. Create a new empty GameObject.
3. Create a an instance of the building as a child of the empty GameObject.
4. Adjust the building GameObject on the map.
5. Create a prefab from the outer GameObject.
6. Reset position of building in prefab.
7. Set position.y building so that the bottom of the building was to 0.
Otherwise, you can have part of the building below the map.
8. Use a prefab as 3d marker in the example.
In this case, you will always have the correct size of the building.
Script «Aircraft.cs» attached.
Post's attachments
Aircraft.cs 3.29 kb, 346 downloads since 2016-08-03
Kind Regards,
Infinity Code Team.
Boost your productivity a lot and immediately using
Ultimate Editor Enhancer.
Trial and non-commerce versions available.