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 z7x9r0 · May 20, 2015 at 03:59 PM · 2djavascriptplatformer

2D Platformer - Sidekick Follow Player

Trying to figure out the logic to recreate this effect (Donkey Kong Country - SNES): https://www.youtube.com/watch?v=W_kI5xOQ0Lc

  • Sidekick follows player.

  • Sidekick can switch places with player.

In the YouTube video notice at 0:28 - 0:30 how it seems that the sidekick character follows the players position, seems to want to be in the same location as the player, but when they collide the side kick is pushed back. 0:43 - 0:45 is interesting as well since the sidekick doesn't fall. Can't figure out how this is done but want to replicate the effect. Need help on how to think or understand the logic on how this effect is done. I do think there is a delay on repeated inputs but the collision detection confuses me.

  • 0:28 - https://youtu.be/W_kI5xOQ0Lc?t=28s

  • 0:43 - https://youtu.be/W_kI5xOQ0Lc?t=43s

I am not using Unity's physics since I needed a platformer similar to SNES platformers, close to pixel perfect collision (I had glitching through corner issues using Unity's physics).


If any code is shared or found Javascript is all I know and can read at the moment.


  • Bonus - Going to be recreating the mine cart levels and wondering how to handle sprites and physics. Will post more about it another time. I don't want to slant/tilt the sprites. Instead I was wanting to change sprites to keep the SNES pixel look. Collision and movement is what I know I'll have to figure out.

THANK YOU

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 hexagonius · May 20, 2015 at 04:57 PM 0
Share

Just a guess: Diddy places breadcrums to where he was and Donkey $$anonymous$$ong is following those at a distance, like the body pars in snake. Along with the position could go information about animation changes. With that, Donkey does not need collision, because Diddy already did.

Just a tip. If you don't want to use Unity's collision, use a different Engine. I really don't think you want to program that.

avatar image z7x9r0 · May 20, 2015 at 06:38 PM 0
Share

I chose Unity3D for mobile developing to be honest. It made it seem easy to develop for Iphone, Android, and Windows phones. Just wanted to make a game with a different concept for controlling platform games on mobile without virtual touch controls and ins$$anonymous$$d using touch gestures.

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

20 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 avatar image

Related Questions

Change gravity on button 1 Answer

I am having issues with my Jumping Script. 2 Answers

Has anyone made a successful Pixel Perfect Camera script for platformer games? 2 Answers

2D Platformer - How Do I Replicate Inputs And Delay Them? 1 Answer

Why does my enemies' movement change whenever my player moves toward and away from the enemies' current position? 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