c#拼图游戏源码

上传者: oysd0628 | 上传时间: 2022-06-25 14:07:40 | 文件大小: 2.05MB | 文件类型: RAR
拼图游戏源码,部分代码: private void InitializeLocations() { List allLocations = new List(); allLocations.Clear(); int getRandNumber = rand.Next(1, 17); allLocations.Add(getRandNumber); spaceLocation = getRandNumber;//设置空白位置 for (int i = 1; i < 16; i++) { while (true) { getRandNumber = rand.Next(1, 17); if ((getRandNumber != spaceLocation) && !(allLocations.Contains(getRandNumber))) { break; } } ControlLocation cl = new ControlLocation(); cl.LableNum = i; cl.LocationNum = getRandNumber;//5~1|a|s|p|x clList.Add(cl); allLocations.Add(getRandNumber); } //循环设置每一个lable位置 foreach (ControlLocation cl in clList) { int lableNumber = cl.LableNum; int locationNumber = cl.LocationNum; string getLocation = locations[locationNumber]; string[] locationArray = getLocation.Split(','); Label lable = (Label)this.Controls["label" + lableNumber.ToString()]; lable.Location = new System.Drawing.Point(int.Parse(locationArray[0]), int.Parse(locationArray[1])); } Invalidate(); } private int SelectLocationNumber(int lableNumber) { int result = 0; foreach (ControlLocation cl in clList) { if (cl.LableNum == lableNumber) { result=cl.LocationNum; } } return result; }

文件下载

资源详情

[{"title":"( 76 个子文件 2.05MB ) c#拼图游戏源码","children":[{"title":"bin","children":[{"title":"Debug","children":[{"title":"GamePicture.pdb <span style='color:#111;'> 63.50KB </span>","children":null,"spread":false},{"title":"GamePicture.vshost.exe.manifest <span style='color:#111;'> 490B </span>","children":null,"spread":false},{"title":"GamePicture.exe <span style='color:#111;'> 569.00KB </span>","children":null,"spread":false},{"title":"GamePicture.vshost.exe <span style='color:#111;'> 13.99KB </span>","children":null,"spread":false}],"spread":true}],"spread":true},{"title":"Form1.Designer.cs <span style='color:#111;'> 23.55KB </span>","children":null,"spread":false},{"title":"GamePicture.suo <span style='color:#111;'> 14.00KB </span>","children":null,"spread":false},{"title":"Images","children":[{"title":"Dog1","children":[{"title":"123_10.gif <span style='color:#111;'> 9.12KB </span>","children":null,"spread":false},{"title":"123_04.gif <span style='color:#111;'> 8.93KB </span>","children":null,"spread":false},{"title":"123_07.gif <span style='color:#111;'> 10.97KB </span>","children":null,"spread":false},{"title":"123_11.gif <span style='color:#111;'> 10.16KB </span>","children":null,"spread":false},{"title":"123_06.gif <span style='color:#111;'> 11.63KB </span>","children":null,"spread":false},{"title":"123_16.gif <span style='color:#111;'> 10.84KB </span>","children":null,"spread":false},{"title":"123_12.gif <span style='color:#111;'> 10.90KB </span>","children":null,"spread":false},{"title":"123_03.gif <span style='color:#111;'> 9.92KB </span>","children":null,"spread":false},{"title":"123_09.gif <span style='color:#111;'> 7.11KB </span>","children":null,"spread":false},{"title":"123_08.gif <span style='color:#111;'> 11.29KB </span>","children":null,"spread":false},{"title":"123_13.gif <span style='color:#111;'> 7.58KB </span>","children":null,"spread":false},{"title":"Full.jpg <span style='color:#111;'> 46.91KB </span>","children":null,"spread":false},{"title":"123_15.gif <span style='color:#111;'> 9.64KB </span>","children":null,"spread":false},{"title":"123_05.gif <span style='color:#111;'> 8.57KB </span>","children":null,"spread":false},{"title":"123_01.gif <span style='color:#111;'> 7.60KB </span>","children":null,"spread":false},{"title":"123_14.gif <span style='color:#111;'> 8.92KB </span>","children":null,"spread":false},{"title":"123_02.gif <span style='color:#111;'> 9.80KB </span>","children":null,"spread":false}],"spread":false},{"title":"windows98","children":[{"title":"789_14.gif <span style='color:#111;'> 9.09KB </span>","children":null,"spread":false},{"title":"789_10.gif <span style='color:#111;'> 8.96KB </span>","children":null,"spread":false},{"title":"789_16.gif <span style='color:#111;'> 9.33KB </span>","children":null,"spread":false},{"title":"789_06.gif <span style='color:#111;'> 8.93KB </span>","children":null,"spread":false},{"title":"789_03.gif <span style='color:#111;'> 7.52KB </span>","children":null,"spread":false},{"title":"789_12.gif <span style='color:#111;'> 7.71KB </span>","children":null,"spread":false},{"title":"789_15.gif <span style='color:#111;'> 9.14KB </span>","children":null,"spread":false},{"title":"789_02.gif <span style='color:#111;'> 7.99KB </span>","children":null,"spread":false},{"title":"789_01.gif <span style='color:#111;'> 8.26KB </span>","children":null,"spread":false},{"title":"full3.jpg <span style='color:#111;'> 26.13KB </span>","children":null,"spread":false},{"title":"789_07.gif <span style='color:#111;'> 8.23KB </span>","children":null,"spread":false},{"title":"789_08.gif <span style='color:#111;'> 8.09KB </span>","children":null,"spread":false},{"title":"789_05.gif <span style='color:#111;'> 7.67KB </span>","children":null,"spread":false},{"title":"789_13.gif <span style='color:#111;'> 8.34KB </span>","children":null,"spread":false},{"title":"789_11.gif <span style='color:#111;'> 8.01KB </span>","children":null,"spread":false},{"title":"789_09.gif <span style='color:#111;'> 8.34KB </span>","children":null,"spread":false},{"title":"789_04.gif <span style='color:#111;'> 8.40KB </span>","children":null,"spread":false}],"spread":false},{"title":"Girl1","children":[{"title":"456_05.gif <span style='color:#111;'> 3.64KB </span>","children":null,"spread":false},{"title":"456_14.gif <span style='color:#111;'> 5.41KB </span>","children":null,"spread":false},{"title":"456_13.gif <span style='color:#111;'> 3.84KB </span>","children":null,"spread":false},{"title":"456_07.gif <span style='color:#111;'> 5.51KB </span>","children":null,"spread":false},{"title":"456_01.gif <span style='color:#111;'> 2.31KB </span>","children":null,"spread":false},{"title":"456_08.gif <span style='color:#111;'> 4.46KB </span>","children":null,"spread":false},{"title":"456_09.gif <span style='color:#111;'> 2.67KB </span>","children":null,"spread":false},{"title":"456_03.gif <span style='color:#111;'> 4.21KB </span>","children":null,"spread":false},{"title":"456_06.gif <span style='color:#111;'> 5.78KB </span>","children":null,"spread":false},{"title":"456_11.gif <span style='color:#111;'> 5.44KB </span>","children":null,"spread":false},{"title":"456_15.gif <span style='color:#111;'> 6.67KB </span>","children":null,"spread":false},{"title":"456_10.gif <span style='color:#111;'> 4.61KB </span>","children":null,"spread":false},{"title":"456_16.gif <span style='color:#111;'> 5.18KB </span>","children":null,"spread":false},{"title":"456_12.gif <span style='color:#111;'> 2.65KB </span>","children":null,"spread":false},{"title":"456_04.gif <span style='color:#111;'> 3.17KB </span>","children":null,"spread":false},{"title":"Full2.jpg <span style='color:#111;'> 102.39KB </span>","children":null,"spread":false},{"title":"456_02.gif <span style='color:#111;'> 3.79KB </span>","children":null,"spread":false}],"spread":false}],"spread":true},{"title":"GamePicture.csproj <span style='color:#111;'> 6.38KB </span>","children":null,"spread":false},{"title":"Program.cs <span style='color:#111;'> 503B </span>","children":null,"spread":false},{"title":"obj","children":[{"title":"Debug","children":[{"title":"GamePicture.csproj.FileListAbsolute.txt <span style='color:#111;'> 1.20KB </span>","children":null,"spread":false},{"title":"GamePicture.pdb <span style='color:#111;'> 63.50KB </span>","children":null,"spread":false},{"title":"TempPE","children":[{"title":"Properties.Resources.Designer.cs.dll <span style='color:#111;'> 10.00KB </span>","children":null,"spread":false}],"spread":true},{"title":"GamePicture.Form1.resources <span style='color:#111;'> 180B </span>","children":null,"spread":false},{"title":"Refactor","children":null,"spread":false},{"title":"GamePicture.csproj.GenerateResource.Cache <span style='color:#111;'> 3.01KB </span>","children":null,"spread":false},{"title":"GamePicture.exe <span style='color:#111;'> 569.00KB </span>","children":null,"spread":false},{"title":"GamePicture.Properties.Resources.resources <span style='color:#111;'> 542.36KB </span>","children":null,"spread":false}],"spread":true}],"spread":true},{"title":"from.gif <span style='color:#111;'> 4.83KB </span>","children":null,"spread":false},{"title":"Form1.cs <span style='color:#111;'> 15.55KB </span>","children":null,"spread":false},{"title":"Form1.resx <span style='color:#111;'> 5.87KB </span>","children":null,"spread":false},{"title":"ControlLocation.cs <span style='color:#111;'> 530B </span>","children":null,"spread":false},{"title":"Properties","children":[{"title":"Resources.resx <span style='color:#111;'> 18.09KB </span>","children":null,"spread":false},{"title":"Settings.settings <span style='color:#111;'> 249B </span>","children":null,"spread":false},{"title":"AssemblyInfo.cs <span style='color:#111;'> 1.40KB </span>","children":null,"spread":false},{"title":"Settings.Designer.cs <span style='color:#111;'> 1.07KB </span>","children":null,"spread":false},{"title":"Resources.Designer.cs <span style='color:#111;'> 15.35KB </span>","children":null,"spread":false}],"spread":true},{"title":"GamePicture.sln <span style='color:#111;'> 911B </span>","children":null,"spread":false}],"spread":true}]

评论信息

免责申明

【只为小站】的资源来自网友分享,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,【只为小站】 无法对用户传输的作品、信息、内容的权属或合法性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论 【只为小站】 经营者是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。
本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二条之规定,若资源存在侵权或相关问题请联系本站客服人员,zhiweidada#qq.com,请把#换成@,本站将给予最大的支持与配合,做到及时反馈和处理。关于更多版权及免责申明参见 版权及免责申明