Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by JPB18 · Aug 12, 2012 at 11:03 AM · scenesspacertsdimensions

Unity Scene Dimensions

Hi there!

I'm going to begin a project which involves the production of one space RTS (similar in concept to Nexus: The Jupiter Incident) and at this moment I'm choosing the game engine in which I want to produce it.

I am considering sticking with Unity (which I'm already familiarized with), however there's one doubt I've. Is Unity capable of handling vast 3D space scenes, massive worlds, alongside with huge mile long ships, while trying to maintain a 1:1 scale?

Thanks in advance for your answers.

João Borrego

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
0
Best Answer

Answer by Bunny83 · Aug 12, 2012 at 01:06 PM

It depends on your implementation. Generally since coordinates are stored as float values the range is between -infinity and +infinity. However the further you go away from center the worst the precision get. Floating point means that you have a fix amount of digits, but you can specify where the "decimal point"(actually the binary point ;)) is.

Just to give an overview of the concept how a float works:

 Just say we have 10 digits and another 2 digit number to specify the exponent (10^e)
 N = 9000000001   e = 00   --> 0.N * 10^0  -->  0.9 *         1 --> 0.9000000001   // 10 digits behind decimal point
 N = 9000000001   e = 01   --> 0.N * 10^1  -->  0.9 *        10 --> 9.0000000010   // 9 digits behind decimal point
 N = 9000000001   e = 08   --> 0.N * 10^8  -->  0.9 * 100000000 --> 90000000.1     // 1 digit behind decimal point

So the greater the nubers get the worst is the precision (the smallest step possible). This problem have all engines when you work with a linear world space. That's why such games are usually segmented into smaller sections. for example 1000x1000x1000 (so in each axis between -500 and 500). When ever you reach the border, the coordinates get shiftedto the other side in the new section / region.

Comment
Add comment · Show 3 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image JPB18 · Aug 12, 2012 at 02:44 PM 0
Share

Thanks for the answer, however I must ask, in practice, how would that affect movements, physics simulations, collisions and static objects?

avatar image Bunny83 · Aug 12, 2012 at 06:40 PM 0
Share

Well, usually you would hold 4 sections in memory. The best way is to have all static stuff in one gameobject for each region / section. You just shift the origin. For example, each section has it's pivot locally in the center so it represents 0,0,0. You just load all neighbor sections depending on the quadrant you're in.

-/+ +/+ -/- +/-

Whenever you cross the border of a section, for example at +500 / +100 you just shift everything on the x - axis by -1000. So your new position in worldspace is -500 / 100. But your no longer in section 0/0 now you are in 1/0.

It's also possible to shif only by half section size. This would prevent ping pong switches when you move along a section boarder. Since you shift only by 500, the section border you just crossed (at 500) becomes the center. The switch back would happen at -500

Physics and everything else shouldn't cause any problems since directions stay the same and even relative distances stay the same.

It can be a bit tricky, but you need a dynamic loading concept anyway ;)

avatar image JPB18 · Aug 12, 2012 at 07:32 PM 0
Share

I was asking more about what would happen if for example, I had two ships, each with 300 meters in lenght, fighting at extreme long range (like 100 kms apart (unity distance)). Would the physics engine, the renderer or the collision detection suffer from those?

However that's one idea I might consider :P

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

8 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

A node in a childnode? 1 Answer

Spaceship flying! 1 Answer

Scenario connection Problem 0 Answers

How to make a Homeworld Style Camera. 3 Answers

Ship movement in space-based RTS 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges