Hey everyone. I'm helping in the programming of an A.R game for the iOS and I'm using a bit of raycast to get random positions off of the camera limits to spawn the mobs with camera.ViewportPointToRay.
I'm generating raycasts for bottom-left and right and upper-left and right corners to get the collision point of the ray and then going through the process of randomly choose a position to instantiate the enemy. This process is done each 4-7 seconds.
Did you guys think that this can cause some performance issues when running in an iPhone?
There's other way I can get an off limits of view position without using raycast if this way is too expensive?
The point in use a constant limit is that the player will be constantly moving the phone and that would cause some strange instantiation.
Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.
The best place to ask and answer questions about development with Unity.
If you are a new user, check out our FAQ for more information.
If you are a moderator, see our Moderator Guidelines page.
We are making improvements to UA, see the list of changes.
For troubleshooting common problems with Unity 5.x Editor (including Win 10).
To help users post good questions and use the site effectively we have posted a user guide. Please check it out.
Answers and Comments
3 People are following this question.
How to check performance of the game in the device made in Unity 3d
Empty public script variables.
iOS Performance with multiple meshes
Best Practice For Shader Complexity + IOS
What are causes of "Overhead" in Profiler?