コード例 #1
0
        public IPowerConsumer GetConnectedDevice()
        {
            Vector2Int cell = Cell;

            LocalPowerController lpc = TileController.Find <LocalPowerController>(cell.x, cell.y);

            if (CheckRotation(lpc))
            {
                return(lpc);
            }

            return(null);
        }
コード例 #2
0
 private bool CheckRotation(LocalPowerController lpc)
 {
     return(lpc.WallPressDirection == _connectionDirection);
 }