private void Awake()
    {
        turretBehavior = GetComponent <ITileTurretBehavior>();
        rangeIndicator = GetComponent <ITileRangeIndicator>();

        Root = GetComponent <Tile.Tile>();

        // note if you use, `IGridPositionedItem`, you will find
        // that this class will satisfy it, even though it shouldn't
        // and doing that will cause a self-reference, which will
        // lead to a stack overflow on the call to GetLocation.
        gridPosition    = GetComponent <IGridPositionedItem>();
        focusInteractor = GetComponent <ITileExclusiveFocusInteractor>();
    }
示例#2
0
 private void Awake()
 {
     selectionInteraction = GetComponent <ITileSelectionInteractor>();
     focusInteractor      = GetComponent <ITileExclusiveFocusInteractor>();
 }