Form1.cs

(开头部分) 10KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using 下落棋.Properties;

namespace 下落棋
{
    public partial class Form1 : Form
    {
        int index = 0;
        List<Tuple<int, int, PictureBox>> pictuplelist = new List<Tuple<int, int, PictureBox>>();
        List<Point> redpointlist = new List<Point>();
        List<Point> bluepointlist = new List<Point>();
        List<Point> winpointlist = new List<Point>();

        public Form1()
        {
            InitializeComponent();
        }

        private void Form1_Load(object sender, EventArgs e)
        {
            InitUI();
        }

        private void InitUI()
        {
            this.Controls.Clear();
            pictuplelist.Clear();
            redpointlist.Clear();
            bluepointlist.Clear();
            index = 0;
            for (int i = 0; i < 7; i++)
            {
                var pic = new PictureBox();
                pic.BackColor = Color.Transparent;
                pic.Size = new Size(94, 94);
                pic.Image = Resources.Arrow;
                pic.Location = new Point(i * 94 + 33, 614);
                pictuplelist.Add(Tuple.Create<int, int, PictureBox>(pic.Location.X, pic.Location.X + pic.Width, pic));
            }
            foreach (var pictuple in pictuplelist)
            {
                this.Controls.Add(pictuple.Item3);
            }

            this.Text = "下落棋(红方回合)";
        }

        private void Form1_MouseClick(object sender, MouseEventArgs e)
        {
            if (e.X < 20 || e.X > 700) return;
            if (e.Y < 80 || e.Y > 770) return;
            var pictuple = pictuplelist.FirstOrDefault(predicate => predicate.Item1 < e.X && predicate.Item2 > e.X);
后面还有 207 行代码,解锁后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明

AI 解读

登录后可用,每次 10 积分,解读结果公开显示在下面。

还没有人解读过这个文件。