# AnythingCreator

## AnythingCreator Class Reference

### Public Member Functions

> `List<`` `<mark style="color:blue;">`AWObj`</mark>` ``>`` `<mark style="color:blue;">`MakeManyObjects`</mark>` ``(string objName, int quantity, bool hasBehaviour=true)`
>
> <mark style="color:blue;">`AWObj MakeObject`</mark>` ``(string objName, bool hasBehaviour=true, bool hasCollider=true)`
>
> <mark style="color:blue;">`AWObj MakeObject`</mark>` ``(string objName, Transform parentTransform, bool hasBehaviour=true, bool hasCollider=true, bool positionGlobally=false)`
>
> <mark style="color:blue;">`AWObj MakeObject`</mark>` ``(string objName, Transform transform, Transform parentTransform, bool hasBehaviour=true, bool hasCollider=true, bool positionGlobally=false)`
>
> <mark style="color:blue;">`AWObj MakeObject`</mark>` ``(string objName, Vector3 objectPos, bool hasBehaviour=true, bool hasCollider=true)`
>
> <mark style="color:blue;">`AWObj MakeObject`</mark>` ``(string objName, Vector3 objectPos, Quaternion objectRot, bool hasBehaviour=true, bool hasCollider=true)`
>
> <mark style="color:blue;">`AWObj MakeObject`</mark>` ``(string objName, Vector3 objectPos, Quaternion objectRot, Vector3 objectScale, bool hasBehaviour=true, bool hasCollider=true)`
>
> <mark style="color:blue;">`AWObj MakeObject`</mark>` ``(string objName, Vector3 objectPos, Quaternion objectRot, Vector3 objectScale, Transform parentTransform, bool hasBehaviour=true, bool hasCollider=true, bool positionGlobally=false)`

### Member Functions

#### <mark style="color:purple;">MakeManyObjects()</mark>

List< <mark style="color:blue;">AWObj</mark> > AnythingWorld.AnythingCreator.MakeManyObjects (string <mark style="color:blue;">objName</mark>, int <mark style="color:blue;">quantity</mark>, bool <mark style="color:blue;">hasBehaviour</mark> = true)

#### <mark style="color:purple;">MakeObject()</mark>

<mark style="color:blue;">AWObj</mark> AnythingWorld.AnythingCreator.MakeObject(string <mark style="color:blue;">objName</mark>, bool <mark style="color:blue;">hasBehaviour</mark> = true, bool <mark style="color:blue;">hasCollider</mark> = true)

#### <mark style="color:purple;">MakeObject()</mark>

<mark style="color:blue;">AWObj</mark> AnythingWorld.AnythingCreator.MakeObject (string <mark style="color:blue;">objName</mark>, Transform <mark style="color:blue;">parentTransform</mark>, bool <mark style="color:blue;">hasBehaviour =</mark> true, bool <mark style="color:blue;">hasCollider =</mark> true, bool <mark style="color:blue;">positionGlobally =</mark> false)

#### <mark style="color:purple;">MakeObject()</mark>

<mark style="color:blue;">AWObj</mark> AnythingWorld.AnythingCreator.MakeObject (string <mark style="color:blue;">objName</mark>, Transform <mark style="color:blue;">transform</mark>, Transform <mark style="color:blue;">parentTransform</mark>, bool <mark style="color:blue;">hasBehaviour =</mark> true, bool <mark style="color:blue;">hasCollider = true</mark>, bool <mark style="color:blue;">positionGlobally =</mark> false )

#### <mark style="color:purple;">MakeObject()</mark>

<mark style="color:blue;">AWObj</mark> AnythingWorld.AnythingCreator.MakeObject (string <mark style="color:blue;">objName</mark>, Vector3 <mark style="color:blue;">objectPos</mark>, bool <mark style="color:blue;">hasBehaviour =</mark> true, bool <mark style="color:blue;">hasCollider =</mark> true)

#### <mark style="color:purple;">MakeObject()</mark>

<mark style="color:blue;">AWObj</mark> AnythingWorld.AnythingCreator.MakeObject (string <mark style="color:blue;">objName</mark>, Vector3 <mark style="color:blue;">objectPos</mark>, Quaternion <mark style="color:blue;">objectRot</mark>, bool <mark style="color:blue;">hasBehaviour =</mark> true, bool <mark style="color:blue;">hasCollider =</mark> true)

#### <mark style="color:purple;">MakeObject()</mark>

<mark style="color:blue;">AWObj</mark> AnythingWorld.AnythingCreator.MakeObject (string <mark style="color:blue;">objName</mark>, Vector3 <mark style="color:blue;">objectPos</mark>, Quaternion <mark style="color:blue;">objectRot</mark>, Vector3 <mark style="color:blue;">objectScale</mark>, bool <mark style="color:blue;">hasBehaviour =</mark> true, bool <mark style="color:blue;">hasCollider =</mark> true)

#### <mark style="color:purple;">MakeObject()</mark>

<mark style="color:blue;">AWObj</mark> AnythingWorld.AnythingCreator.MakeObject (string <mark style="color:blue;">objName</mark>, Vector3 <mark style="color:blue;">objectPos</mark>, Quaternion <mark style="color:blue;">objectRot</mark>, Vector3 <mark style="color:blue;">objectScale</mark>, Transform <mark style="color:blue;">parentTransform</mark>, bool <mark style="color:blue;">hasBehaviour =</mark> true, bool <mark style="color:blue;">hasCollider =</mark> true, bool <mark style="color:blue;">positionGlobally =</mark> false)

### Property

#### <mark style="color:purple;">Instance</mark>

<mark style="color:blue;">AnythingCreator</mark> AnythingWorld.AnythingCreator.Instance

#### <mark style="color:purple;">MadeThings</mark>

Dictionary\<string, List > AnythingWorld.AnythingCreator.MadeThings

### Parameters

| **Parameters**                                      | **Type**   | **Definition**                                                     |
| --------------------------------------------------- | ---------- | ------------------------------------------------------------------ |
| <mark style="color:blue;">`objName`</mark>          | string     | Name of object to be requested from server.                        |
| <mark style="color:blue;">`objectPos`</mark>        | Vector3    | Position in scene to be applied requested object.                  |
| <mark style="color:blue;">`objectRot`</mark>        | Quaternion | Local rotation to be applied to requested object.                  |
| <mark style="color:blue;">`objectScale`</mark>      | Vector3    | Local scale to be applied to request object.                       |
| <mark style="color:blue;">`parentTransform`</mark>  | Transform  | Transform that new object will be parented to.                     |
| <mark style="color:blue;">`transfrom`</mark>        | Transfrom  | transform to be applied to object after creation                   |
| <mark style="color:blue;">`hasBehaviour`</mark>     | bool       | Will object receive default behaviour & animations.                |
| <mark style="color:blue;">`hasCollider`</mark>      | bool       | Will object receive automatically generated collider around model. |
| <mark style="color:blue;">`positionGlobally`</mark> | bool       | Will object be applied globally? (Default: false, locally)         |

### Returns

Reference to [AWObj](broken://pages/-MaU1fy4Sf5XpBWBUNo3) of the object being made. Objects are generated asynchronously, make the status of your object attached to AWObj can be queried using the ObjectMade bool property.

### Example

```csharp
using AnythingWorld;
public class MakeSingleObject : MonoBehaviour
{
    public string objectToName = "cat";
    
    void Start()
    {
        AnythingCreator.Instance.MakeObject("cat");
    }
}
```

```csharp
public class MakeObjectQuaternion : MonoBehaviour
    {
        public string objectToMake = "dog";
        public Vector3 vectorPosition = new Vector3(2, 1, 2);
        public Quaternion quaternionRotation = Quaternion.identity;
        private void Start()
        {
            AnythingCreator.Instance.MakeObject(objectToMake, vectorPosition, quaternionRotation);
        }
    }
```

```csharp
using AnythingWorld;

public class MakeObjectFullCustom : MonoBehaviour
{
    public string objectToMake;
    public Vector3 objectPos;
    public Quaternion objectRotation;
    public Vector3 objectScale;
    public Transform parentTransform;
   
    void Start()
    {
        AnythingCreator.Instance.MakeObject(objectToMake, objectPos, objectRotation, objectScale, parentTransform);
    }
}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://anything-world.gitbook.io/anything-world/~/changes/qJerPYmdDjrB4JWorym2/unity/api-references/anythingcreator.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
