Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 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 Jonas9983 · Sep 09, 2016 at 10:39 AM · objectjumping objectridgidbodyfalls

I can't make my object grounded and to move it

Hello everyone I'm a beginner in unity, but I'm trying to make my first game. I have my Player, which is a simple pixle art frog which I designed in photoshop and a water lily made in pixel art too. The objective of the game is really simple: just to make the frog jump between water lily. I've watched a lot of tutorials but I can't find any that helps me. My problem is to make the frog grounded in the water lily because once I apply a ridgidbody2d in it it just falls. So my question is What do I have to do so it stays grounded and I can make it move? thank you!

Comment
Add comment · Show 4
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 tqkiettk10 · Sep 09, 2016 at 10:57 AM 0
Share

you need attach Boxcollider2D component to your water lily and the frog and in the Boxcollider2D component make sure isTigger box is disable. only add ridgidbody2d to the frog.

avatar image elmidiachi · Sep 09, 2016 at 01:32 PM 0
Share

Yeah, make sure the Lily also has a collider On it. Else your game wont know if the frog and the lily 'touch' eachother and the frog Will always fall though the Lily. So like tqkiettk says, You need an collider2D :)

avatar image Jonas9983 elmidiachi · Sep 10, 2016 at 04:16 PM 0
Share

The thing is that I did all of that, seen a lot of videos and stuff but still it keeps happenning. $$anonymous$$y frog keeps falling down. As I said to Dream_in_code I've had the idea of denying the gravity scale so my frog didnt happen to fall again. That is what I'm dealing now. Here are two pics of what I have. With the gravity scale in 1 it falls and doesnt stay grounded in the lily. Thanks again!

[1]: /storage/temp/77975-sem-titulo1.png

sem-titulo.png (200.3 kB)
sem-titulo1.png (198.6 kB)
avatar image tqkiettk10 Jonas9983 · Sep 10, 2016 at 05:01 PM 0
Share

Okay maybe I Understand your problem. You need a frog stand in water lily so you need rigidbody work on z axis. But ridgidbody2D cannot work on z axis. So to fix your problem you can rotate all Sprite (The frog and the water lily) in X axis to 90.

Set the camera postion to (0, 10, 0), Rotation to (90,0,0).

Another way I think easier is change Physic from 2D to 3D (remove rigidbody2d and add rigidbody component, BoxCollider2D to BoxCollider). Then go to "Edit > Project Settings > Physics" Change Gravity set to (0,0, -9.81).

Hope this help!

EDIT: Add note. Think you missing something when view your screenshot image. 1. you dont add Boxcollider to the Hero (Boxcollider2D or Boxcollider if you using my second way) 2. If you want to see effect when the frog jump. you can set Projection of the Camera from Orthographic to Perspective (optional).

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by Dream_in_code · Sep 09, 2016 at 11:23 AM

If you are a beginner telling everything in a comment will be difficult. You can watch this video >> https://www.youtube.com/watch?v=86Bgt--Ww7w&list=PLiyfvmtjWC_Up8XNvM3OSqgbJoMQgHkVz∈dex=2

it has everything you need as a beginner on how to move and jump a player

Comment
Add comment · Show 1 · 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 Jonas9983 · Sep 10, 2016 at 04:11 PM 0
Share

Thank you very much for that video, I've watched it a lot of times but I have the same problem. In the video, his object was grounded and it didnt fall because of that but in $$anonymous$$e I can't figure out how to keep it grounded and I did everything he did. Here's a pic so you can see it better! I've had the idea to put the gravity scale to zero but when I put that if I jump the frog just keeps going up and he doesnt stop. So I don't really know what to do. Thanks again!

[1]: /storage/temp/77973-sem-titulo1.png

sem-titulo.png (200.3 kB)
sem-titulo1.png (198.6 kB)

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

Rigid Character always falls (Physics) (No Root Motion) 1 Answer

How can I make an object in my scene jump continuously? 1 Answer

TK script: selecting all objects 0 Answers

Object Falls from Moving Platform 1 Answer

Export Scene Objects to Package 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