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 serenefox · Feb 20, 2014 at 01:22 AM · cameragravityfallingendless runner

Endless "Falling in place" Simulation Question

Hello,

I searched the forums and the internet in general but can't seem to find an answer to this so I thought I would ask:

I am trying to make a small "endless runner" type game and I want the player(currently a sphere) to fall continuously. I am pretty sure I can't just loosely attach a camera to the player and just add a rigidbody because it will just keep going further and further away from the origin, and as far as I've heard that would cause problems.

Ideally I would create an object pool and scrolling background with another camera and just have the player only be able to control their movement on the X axis. But if the player were to hit something on the way down (part of the design, they have to dodge) they get moved to the top of the screen and stay there with the controls I have now( I don't have a rigid body because of the above reason) for a penalty. They should come back to the center of the screen(after a certain amount of time) to continue falling assuming they didn't go off the top and out of view(game over).

The problem is if the player were to hit something that is supposed to make them go sideways, I would want them to bounce to the left or right and have it seem like an actual bounce and not a slight "nudge". That way I could also just use a Physical material. Unfortunately without gravity I don't know how I would achieve this effect.

So I am basically asking how one would go about simulating gravity so the player would stay inside the camera view and it looks like they are falling and bouncing without the camera actually moving with the player and the player doesn't go far either?

Im sorry if this isn't the best place to ask this and if so please tell me. And I'm not expecting a detailed answer just if you can point me in the right direction.

Comment
Add comment · Show 2
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 mattyman174 · Feb 20, 2014 at 02:11 AM 0
Share

You can still use a Rigid Body, there is an Option to constrain its $$anonymous$$ovement on different axis. If you constrain it from being able to move Down as Gravity would have it, you still would get the desired effects of being pushed side to side with Phys $$anonymous$$aterials and the like.

avatar image serenefox · Feb 20, 2014 at 02:40 AM 0
Share

Thanks for the suggestion but even with that it still doesn't achieve the effect I need, so I might just go a separate way with this little game.

0 Replies

· Add your reply
  • Sort: 

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

19 People are following this question.

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

Related Questions

Let character walk on walls 1 Answer

Problem of gravity 1 Answer

Mouse Orbit - Camera Up Vector 0 Answers

Can't move when fall from high 1 Answer

character gravity problem 1 Answer


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