public void DrawBegin() { if (Game.IsPointerOverUIObject()) { return; } Vector3Int?coordinate = map.MouseToCoordinateInt(); if (coordinate != null && brush != null) { brush.DrawBegin(map, coordinate.GetValueOrDefault(), brushPrefab); isDrawing = true; } }