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 Anu8is · Mar 20, 2015 at 11:28 AM · unity 2dgraphicslaglayersz axis

Graphical issue in 2D mode.

I have next problem in my project:

When some object moving in the Y coordinates it also moving in the Z coordinates. This used for changing object layer (object can be in front of another object or behind). So the problem is that when object moving scene is lagging (object moves jerkily but fps is fine). If I disable the Z axis problem is gone but I need the Z axis. How to fix this?

P.S.: sorry for my English -___-

Comment
Add comment · Show 3
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 saud_ahmed020 · Mar 20, 2015 at 12:46 PM 0
Share

Are you using 3D model/objects?? If your objects are in 2D then I think you have no need to Z axis.

avatar image Anu8is · Mar 20, 2015 at 03:06 PM 0
Share

I think you have no need to Z axis

So then how I should move object in front of another object or behind them? I think it barrely possible without using Z axis. And yes this is 2D object. With Sprite renderer.
avatar image Utamaru · Mar 20, 2015 at 04:43 PM 0
Share

Use sortingOrder. This will help you to manually set render order of your spriteRenderers.

1 Reply

· Add your reply
  • Sort: 
avatar image
1

Answer by Zealord · Mar 20, 2015 at 11:15 PM

You shouldn't use the Z-layer to move characters or renderables in front of eachother in a 2D game with the purpose you described. You should use the sorting layers on the sprite renderers to fix that issue. Moreover, if you think it is "barely possible" to move it then read up some more on the documentation regarding these topics!

Comment
Add comment · Show 2 · 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 Anu8is · Mar 21, 2015 at 07:21 AM 0
Share

Sorting order I forgot about it! Thank you! By the way if "barely possible" looks like "impossible" then sorry I didn't mean that T_Т

avatar image Zealord · Mar 22, 2015 at 09:01 PM 0
Share

Glad to see it was fixed then! I'm far from being good myself and I also think this at times.

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

5 People are following this question.

avatar image avatar image avatar image avatar image avatar image

Related Questions

Graphic layering like problem in game option 0 Answers

My 2d Game Is Running At A Constant 2-3FPS? 2 Answers

My game is lagging and i don't know how to fix 0 Answers

How do I define draw layers for particles? 1 Answer

How do i make an object visible in particular layer? 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