joparino 3 lat temu
rodzic
commit
5280038b09
1 zmienionych plików z 7 dodań i 7 usunięć
  1. 7 7
      clicker/MainWindow.xaml.cs

+ 7 - 7
clicker/MainWindow.xaml.cs

@@ -30,7 +30,7 @@ namespace clicker
             InitializeComponent();
         }
 
-        public void Update(ref long point, ref int click)
+        public void Update()
         {
             poi.Content = "Points: " + point;
             cli.Content = "PpS: " + click;
@@ -48,11 +48,11 @@ namespace clicker
         public long MouseDownd_Update(ref long point, ref int click)
         {
             point += click;
-            Update(ref point, ref click);
+            Update();
             return point;
         }
 
-        public void b1_Click(object sender, RoutedEventArgs e)
+        private void b1_Click(object sender, RoutedEventArgs e)
         {
             B1_Click_Update(ref point, ref click);
         }
@@ -63,7 +63,7 @@ namespace clicker
             {
                 point -= Convert.ToInt64(Math.Round(sol_b1));
                 click += 3;
-                Update(ref point, ref click);
+                Update();
                 return point + click;
             }
             return 0;
@@ -80,7 +80,7 @@ namespace clicker
             {
                 point -= Convert.ToInt64(Math.Round(sol_b2));
                 click += 5;
-                Update(ref point, ref click);
+                Update();
                 return point + click;
             }
             return 0;
@@ -97,7 +97,7 @@ namespace clicker
             {
                 point -= Convert.ToInt64(Math.Round(sol_b3));
                 click += 7;
-                Update(ref point, ref click);
+                Update();
                 return point + click;
             }
             return 0;
@@ -114,7 +114,7 @@ namespace clicker
             {
                 point -= Convert.ToInt64(Math.Round(sol_b4));
                 click += 12;
-                Update(ref point, ref click);
+                Update();
                 return point+ click;
             }
             return 0;