예제 #1
0
    /// This function is called when the object becomes enabled and active.
    void OnEnable()
    {
        if (physicsObjects == null)
        {
            physicsObjects = new Dictionary <int, PhysicsObject>();
        }

        physicsObjects.Add(ID, this);

        physicsEngine.AddObject(this);
    }