Unity - Scripting API: RequireComponent.RequireComponent
RequireComponent Constructor
Success!
Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.
Submission failed
For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.
Declaration
public RequireComponent(Type requiredComponent);
Description
Require a single component.
Declaration
public RequireComponent(Type requiredComponent, Type requiredComponent2);
Description
Require two components.
Declaration
public RequireComponent(Type requiredComponent, Type requiredComponent2, Type requiredComponent3);
Description
Require three components.