• 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

Fixes in upcoming releases of Unity Answers

Using a good tone of voice when replying to posts

Requests for new tags/topics

How to use the META space

How to use the Moderator space

Questions in topic: addcomponent

  • Unanswered Questions
  • Recommended Questions
Once you sign in you will be able to subscribe for any updates here
avatar image

Lava444 asked

I can't pass arguments into constructor with AddComponent.

1 hour ago gameobject·addcomponent·constructor

0 Replies

0 Votes

avatar image

angelonit commented

How to get a component from an object and add it to another? (Copy components at runtime)

May 19, '22 c#·gameobject·getcomponent·component·addcomponent

12 Replies

13 Votes

avatar image

liamrasoull edited

Destroying a LineRenderer component and then adding it again at runtime

Apr 28, '22 destroy·runtime·linerenderer·addcomponent·clear

4 Replies

0 Votes

avatar image

Keslen published

How do I make a transform on a Child (added by script) apply to that Child instead of its Parent?

Feb 17, '22 transform·parent·child·addcomponent·scripteditor

0 Replies

0 Votes

avatar image

sisus_co answered

Passing arguments into a constructor via AddComponent

Dec 28, '21 instance·addcomponent·arguments·constructors

5 Replies

2 Votes

avatar image

aswanevelder answered

How can I add external-assets(C#)

Dec 18, '21 addcomponent·external assets

1 Reply

1 Votes

avatar image

BlackMashroom commented

Turning a Light on With Collision Detection

Nov 21, '21 c#·light·oncollisionenter·find·addcomponent

1 Reply

0 Votes

avatar image

K0m1x answered

AddComponent passing variable before Start/Awake

Nov 15, '21 gameobject·variable·start·addcomponent·awake

5 Replies

5 Votes

avatar image

podjigateligrey commented

how do I add link script to gameobject that already exist with attached script

Jul 25, '21 in Help Room

1 Reply

0 Votes

avatar image

doobywoo published

Rigid body component added without me telling it to be added,Rigid body component being added when it is never told to

May 14, '21 rigidbody·prefab·component·addcomponent·automatically

0 Replies

0 Votes

avatar image

unity_RJs1M1mPBz0Pxg published

Why does AddComponent not exist in the current context?

Apr 29, '21 start·dictionary·addcomponent·state-machine·context

2 Replies

0 Votes

avatar image

marek_PLH commented

Assign a variable of type "type" on the inspector or best work around

Feb 11, '21 scriptableobject·type·addcomponent·skills

2 Replies

1 Votes

avatar image

khanism edited

How does AddComponent work from the inside?

Jan 28, '21 in Help Room

1 Reply

0 Votes

avatar image

Feathered asked

Why "AddComponent" behaves differently in "Play" and "Edit" modes?

Dec 18, '20 editor·addcomponent

0 Replies

0 Votes

avatar image

streeetwalker answered

,I can't find my .cs file in "Add Component"

Sep 16, '20 in Help Room

1 Reply

0 Votes

avatar image

GeniusGamerYT commented

How can I put a new script on the main camera?

Aug 17, '20 in Help Room

2 Replies

0 Votes

avatar image

Pyunityer8002 commented

How can I AddComponent() now?

Aug 1, '20 in Help Room

3 Replies

3 Votes

avatar image

andrew-lukasik edited

How do I get a CS script in assets to be a stored monobehaviour variable

Jul 21, '20 instantiate·monobehaviour·addcomponent

1 Reply

1 Votes

avatar image

Long2904 commented

How to add audio source to gameobject with PlayOnAwake turn on through script?

Apr 30, '20 audio·audiosource·audioclip·addcomponent·awake

1 Reply

0 Votes

avatar image

streeetwalker edited

Instantiate object through a coroutine problem

Apr 16, '20 in Help Room

1 Reply

0 Votes

avatar image

mattssheep4 answered

Load a list of scripts from folder Wiki

Mar 28, '20 instantiate·resources·addcomponent·resources.loadall

1 Reply

0 Votes

avatar image

ericlclancy published

Dynamically adding Javascript to an Instantiated object using AddComponent,Using AddComponent to add a JS Monoscript Causes "NullReferenceException

Mar 14, '20 in Help Room

0 Replies

0 Votes

avatar image

cin31877 answered

Addcompont and Change It's Value After Delete another Same Parent type inheritanced Component ,Addcomponent after DeleteAnother Same MotherType Component And Change It's Value

Feb 1, '20 in Help Room

1 Reply

0 Votes

avatar image

Larry-Dietz commented

AddComponent isn't working

Jan 11, '20 in Help Room

1 Reply

0 Votes

avatar image

atomodelfinal commented

Can't add sprite to instantiated GameObject

Jan 9, '20 instantiate·getcomponent·spriterenderer·addcomponent

2 Replies

0 Votes

avatar image

GameDBharat asked

When i try to add Collider2D or Rigidbody2D through code to prefab gameObject after stopping game the added component remain added to the prefab obejct.

Nov 28, '19 gameobject·rigidbody2d·collider2d·addcomponent

0 Replies

0 Votes

avatar image

HarvesteR answered

Adding a component to an object over UNET?

Aug 14, '19 networking·components·addcomponent·command

2 Replies

1 Votes

avatar image

puchingeralexander asked

Access Top and Right Variables from RectTransform

Jun 17, '19 in Help Room

0 Replies

0 Votes

avatar image

Hellium answered

How do I change when my RigidBody 2D initializes? C# Question/Noob,How do I change when rigidbody initializes?

May 25, '19 in Help Room

1 Reply

0 Votes

avatar image

WarmedxMints answered

Inconsistent Accessibility: Parameter type is less accessible than method

Mar 4, '19 enum·access·addcomponent·constructor·inconsistent

1 Reply

1 Votes

  • 1
  • 2
  • 3
  • 4
  • 5
  • ›
  • »

Welcome to Unity Answers

If you’re new to Unity Answers, please check our User Guide to help you navigate through our website and refer to our FAQ for more information.

Before posting, make sure to check out our Knowledge Base for commonly asked Unity questions.

Check our Moderator Guidelines if you’re a new moderator and want to work together in an effort to improve Unity Answers and support our users.

Follow This Topic

Follow This Topic

Follow by RSS

No one has followed this topic yet.

Popular Topics

c# animation android unity 5 camera 2d rotation javascript scripting problem collision ui gui error shader movement gameobject physics rigidbody editor ios texture networking raycast instantiate collider transform terrain mesh prefab input
View all

Recent Badges

  • Supporter   RonJonesTheArtist
  • Teacher   Frostbite23
  • Popular Question   denil98
  • Popular Question   anurooppv
  • Necromancer   Tarrag
  • Good Answer   Tarrag
  • Supporter   jaydnwlsn
  • Notable Question   Ikrambandagi
  • Notable Question   Duncan1971
  • Popular Question   Trevdevs


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