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 JakeLeB · Feb 09, 2015 at 05:09 AM · ropeswing

Creating a rope from C# that attaches to a tag and lets you swing from it?

I've decided to try my hand at learning a few newer things, I've created a player script with movement, sprinting and learned how to use Mecanim but now I'd like to go one better, I've looked around but I can't find any tutorials on this, is there any help I could get without spoon feeding me the answers directly?

I'd basically like Q&E to shoot ropes at a specific angle and attach to any items with the tag (Wall) and stay hooked until you let go, at the same time allowing you to swing from them and automatically reel in?

Comment
Add comment · Show 5
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 Owen-Reynolds · Feb 09, 2015 at 06:02 AM 2
Share

This is a bunch of things and a bunch of ways to do it. Pick one and start. Rope could be a model or lineRenderer (is it 2D or 3D.) Raycasting and then checking a tag is common for lots of stuff. Swing can use physics and a hinge, or just math. The shoot/reelIn animation could probably be done lots of ways.

avatar image jpthek9 · Feb 09, 2015 at 08:02 AM 0
Share

Owen hit it spot on. It'd be better to ask for specifics when you hit a wall because there's so many methods in achieving this.

avatar image VOTRUBEC · Feb 09, 2015 at 08:36 AM 0
Share

I'll second what Owen said. There's so much more you'll need to define before a specific answer can be supplied.

I'd suggest that if you're new to program$$anonymous$$g and/or Unity, that you start with the basics, and master those. And by that, I mean master. There's also plenty of tutorials online covering just about every problem. That's one of the really great things about Unity. For example, this page talks you through the use on HingeJoint2D, which sounds pretty much like what you might be looking for to get the "rope" dynamic working, for starters.

avatar image JakeLeB · Feb 09, 2015 at 09:22 AM 0
Share

Thanks everyone, I guess I'd prefer using Raycast + Line Rendering, but would it be possible to use this and make it feel as if a rope is being shot without spawning the line renderer straight away on keypress?

avatar image HarshadK · Feb 09, 2015 at 09:33 AM 0
Share

$$anonymous$$ove the second point of the LineRenderer rope that is shot from close to the player to tagged object over time. You can use a Coroutine for this.

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

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

Related Questions

2D Platforme Rope 1 Answer

2D rope swing - Image explains all 1 Answer

How to get First person controller to swing on rope? 1 Answer

2D hinge joint with sprite 0 Answers

Attach to cloth Unity5 - How to pull cloth objects instead of push? 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