123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172 |
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- using System.Windows;
- using System.Windows.Controls;
- using System.Windows.Data;
- using System.Windows.Documents;
- using System.Windows.Input;
- using System.Windows.Media;
- using System.Windows.Media.Imaging;
- using System.Windows.Navigation;
- using System.Windows.Shapes;
- namespace Cliker
- {
- /// <summary>
- /// Логика взаимодействия для MainWindow.xaml
- /// </summary>
- public partial class MainWindow : Window
- {
- long point = 1;
- static int click = 1;
- double sol_b1 = 25;
- double sol_b2 = 50;
- public MainWindow()
- {
- InitializeComponent();
- }
- public void Update()
- {
- OYIP.Content = point;
- YPC.Content = click;
- Price_IIPF.Content = (sol_b1).ToString();
- Price_IIPS.Content = (sol_b2).ToString();
- }
- private void Image_MouseDown(object sender, MouseButtonEventArgs e)
- {
- point += click;
- Update();
- }
- private void Upgrade4(object sender, RoutedEventArgs e)
- {
- if (point >= (sol_b1))
- {
- point -= Convert.ToInt64(Math.Round(sol_b1));
- click += 4;
- Update();
- }
- }
- private void Upgrade6(object sender, RoutedEventArgs e)
- {
- if (point >= (sol_b2))
- {
- point -= Convert.ToInt64(Math.Round(sol_b1));
- click += 6;
- Update();
- }
- }
- private void Button_Click(object sender, RoutedEventArgs e)
- {
- Application.Current.Shutdown();
- }
- }
- }
|