Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help  Addition of Obi Collider
#2
(29-03-2019, 09:12 AM)Richard Wrote: Hello.

This is very basic question, but I cannot add Obi collider by AddComponent.
My code is.

using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class ManSetting : MonoBehaviour
{
    public GameObject man;
    // Start is called before the first frame update
    void Start()
    {
        man.AddComponent<MeshCollider>();
        man.AddComponent<ObiCollider>();
    }
}

However, error massage is displayed like the image.

You forgot to include the Obi library. Add "using Obi;" to other usings in the top of the script.
Reply


Messages In This Thread
Addition of Obi Collider - by Richard - 29-03-2019, 09:12 AM
RE: Addition of Obi Collider - by Evgenius - 29-03-2019, 09:18 AM
RE: Addition of Obi Collider - by Richard - 29-03-2019, 09:50 AM
RE: Addition of Obi Collider - by Evgenius - 29-03-2019, 09:53 AM
RE: Addition of Obi Collider - by Richard - 29-03-2019, 10:03 AM
RE: Addition of Obi Collider - by Evgenius - 29-03-2019, 10:07 AM
RE: Addition of Obi Collider - by Richard - 29-03-2019, 10:14 AM
RE: Addition of Obi Collider - by Evgenius - 29-03-2019, 10:22 AM