Beispiel #1
0
    void IExecuteSystem.Execute()
    {
        coroutines.Update();

        var entities = smoothMoveGroup.GetEntities();

        foreach (var e in entities)
        {
            if (e.isSmoothMoveInProgress)
            {
                // already being handled, ignore
                continue;
            }

            var position     = e.position;
            var viewPosition = e.view.gameObject.transform.position;
            if (position.x != viewPosition.x || position.y != viewPosition.y)
            {
                coroutines.Add(SmoothMovement(e));
            }
        }
    }