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 Kensharma · Mar 08, 2014 at 06:50 AM · 2dswitchcharacters

Switching Between 3 Character Models At Same Location

Hey there Unity devs;

How would you all go about switching between 3 different character models (same model, different color) without moving position and enabling/disabling active and inactive characters as you switch?

The player would press a button, switch to another character model and the original one would need to become disabled. He would need to be able to continually switch as leisure.

The character is animated however it's not a big deal if the model goes to idle then continues with animations when he is swapped.

This of course means I need to make the 2 sub-characters follow the original one perfectly for starters.

Thanks for any help.

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 robertbu · Mar 08, 2014 at 06:57 AM 0
Share

Why do you say: "without moving position and enabling/disabling active and inactive characters as you switch?" How are you moving the characters? Can't you just make all three children of an empty game object, put the move code on the empty game object, then show/hide/enable/disable whatever you need? Or if color is the only change between the three models, why have three models? Why not just change the color or material of a single model?

avatar image Kensharma · Mar 08, 2014 at 07:18 AM 0
Share

I got a system in place now however I have run into an issue. The 3 models switch and are at the same location for their transform values, but ingame they do not overlap due to their collision boxes. How can I work around this?

avatar image robertbu · Mar 08, 2014 at 07:36 AM 0
Share

You can use Physics.IgnoreCollision(). You would call it between each pair of colliders. Or, if only one is active at a time, you could enable or disable colliders, or you could place each character on a different layer, and setup the collision matrix.

avatar image Destran · Mar 08, 2014 at 08:02 AM 0
Share

there was a question just like this like 12 hours ago I think. http://answers.unity3d.com/questions/657456/2d-character-switch-systsem-same-location.html#answer-657556

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 Animation does not start 1 Answer

Sprite in game switch system 1 Answer

Single Camera Lerping between three characters? (code provided) 0 Answers

Assets/Scripts/PlayerController.cs(32,49): error CS0126: An object of a type convertible to `float' is required for the return statement 1 Answer

Inactive player continues moving if switching player while moving 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