private void setTileValueWithButton(GridTile tile, ButtonTile button) { if (!dataCount.ContainsKey(button.dataValue)) { dataCount.Add(button.dataValue, 0); } if (dataCount.ContainsKey(tile.getValue())) { dataCount [tile.getValue()]--; } dataCount [button.dataValue]++; tile.setDataValue(button.dataValue); tile.setSpriteToShow(button.spriteToshow); }
private void setCurrentButtonSelected(ButtonTile current) { currentButtonSelected = current; selectedToShow.sprite = current.spriteToshow; }
public void OnButtonClick(ButtonTile target) { setCurrentButtonSelected(target); }