Форум программистов, компьютерный форум, киберфорум
Visual Basic .NET
Войти
Регистрация
Восстановить пароль
Блоги Сообщество Поиск Заказать работу  
 
 
Рейтинг 4.55/11: Рейтинг темы: голосов - 11, средняя оценка - 4.55
2 / 2 / 1
Регистрация: 15.02.2011
Сообщений: 70

Кликнуть по двум кнопкам и поменять их картинки друг с другом

20.05.2012, 20:25. Показов 2394. Ответов 21
Метки нет (Все метки)

Студворк — интернет-сервис помощи студентам
У меня есть 3 кнопки Button1,Button2,Button3. На каждой из них разные картинки. Как сделать чтобы они менялись картинками. только те которые нажмешь. Ну тоесть если я нажму сначала на 1 потом на 3, поменяются они соотвественно, 2 останется не тронутой. Ну и т.д.. Надо осуществить в отдельной подпрограмме. Тоесть если нажать на Button1 там создаться автоматически подпрограмма,так же для остальных 2, вот их использовать нельзя.

Как бы изложить то проблему. Ну вот есть класс Button. И вот разве нет в этом классе такой функции или переменной, отвечающей за нажата она или нет, ну что-то типо того...
0
IT_Exp
Эксперт
34794 / 4073 / 2104
Регистрация: 17.06.2006
Сообщений: 32,602
Блог
20.05.2012, 20:25
Ответы с готовыми решениями:

Разместить картинки друг под другом, справа у каждой картинки текстовая информация
Добрый день, уважаемые специалисты. Очень нужен Ваш совет (поиском пользовалась - не нашла в чем ошибка- вроде все правильно)... ...

Поместить 4 картинки друг за другом
Здравствуйте, Подскажите пожалуйста как поместить 4 картинки друг за другом. И под каждой картинкой поместить текст Вот мой код...

Не могу расположить картинки рядом с друг другом
Не могу расположить картинки с текстом рядом с друг другом <!DOCTYPE html> <!DOCTYPE html> <html lang="ru"> ...

21
1712 / 579 / 76
Регистрация: 10.04.2009
Сообщений: 9,323
20.05.2012, 20:28
Цитата Сообщение от Wolfed Посмотреть сообщение
У меня есть 3 кнопки Button1,Button2,Button3. На каждой из них разные картинки. Как сделать чтобы они менялись картинками
если было менялись надписи на кнопке - всё просто, Caption менять, с картинками не помню, вроде тоже самое, как они к Вам на поверхность кнопки попали, попадают?
1
 Аватар для morgann55
1365 / 207 / 37
Регистрация: 09.02.2012
Сообщений: 745
20.05.2012, 20:45
Посмотри, только что была тема... https://www.cyberforum.ru/post3057816.html
1
1712 / 579 / 76
Регистрация: 10.04.2009
Сообщений: 9,323
20.05.2012, 20:49
он и есть автор
0
2 / 2 / 1
Регистрация: 15.02.2011
Сообщений: 70
20.05.2012, 20:54  [ТС]
перетаскиванием из ToolBoxа на Форму) Да у меня как бы проблема. Пишу шашки. Прошлая тема нужна была для дамок. Что при доходе до граней, нужно менять изображение. Уже написал шаги написал рубку, множественную рубку. Теперь возникла проблема с выбором рубки. то есть если шашка может рубить вверх и вправо по диагонали и может рубить вверх и влево по диагонали например. Вот и думаю как осуществить такую рубку. Как бы игрок должен выбирать. Вот так выглядит рубка:

Visual Basic
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
 Sub Rubka4()
        TextBox2.Text = corr
        If (corr = 13) Then
            If (shashki(i - 2, j - 2).ImageIndex = 0 And shashki(i - 2, j + 2).ImageIndex <> 0) Then
                corr = 1
            End If
            If (shashki(i - 2, j - 2).ImageIndex <> 0 And shashki(i - 2, j + 2).ImageIndex = 0) Then
                corr = 2
            End If
            If (shashki(i - 2, j - 2).ImageIndex = 0 And shashki(i + 2, j - 2).ImageIndex = 0) Then
 
                If (TextBox3.Text = "влево") Then
                    corr = 1
                End If
                If (TextBox3.Text = "Вправо") Then
                    corr = 2
                End If
            End If
            If (shashki(i - 2, j - 2).ImageIndex <> 0 And shashki(i - 2, j + 2).ImageIndex <> 0) Then
                corr = 0
                kk = 1
            End If
        End If
        If (corr = 1) Then
            TextBox1.Text = shashki(i, j).ImageIndex
            'TextBox2.Text = shashki(i - 2, j - 2).ImageIndex
            If (shashki(i - 2, j - 2).ImageIndex = 0) Then
                shashki(i - 2, j - 2).BackgroundImage = shashki(i, j).BackgroundImage
                shashki(i - 2, j - 2).ImageIndex = shashki(i, j).ImageIndex
                shashki(i, j).ImageIndex = 0
                shashki(i, j).BackgroundImage = Button1.BackgroundImage
                shashki(i - 1, j - 1).BackgroundImage = Button1.BackgroundImage
                shashki(i - 1, j - 1).ImageIndex = 0
                Button1.TabIndex = 0
                Button1.ImageIndex = 100
                corr = 0
                i = i - 2
                j = j - 2
            Else
                corr = 0
                kk = 1
            End If
        End If
        If (corr = 3) Then
            TextBox1.Text = shashki(i, j).ImageIndex
            'TextBox2.Text = shashki(i - 2, j + 2).ImageIndex
            If (shashki(i - 2, j + 2).ImageIndex = 0) Then
                shashki(i - 2, j + 2).BackgroundImage = shashki(i, j).BackgroundImage
                shashki(i - 2, j + 2).ImageIndex = shashki(i, j).ImageIndex
                shashki(i, j).ImageIndex = 0
                shashki(i, j).BackgroundImage = Button1.BackgroundImage
                shashki(i - 1, j + 1).BackgroundImage = Button1.BackgroundImage
                shashki(i - 1, j + 1).ImageIndex = 0
                Button1.TabIndex = 0
                Button1.ImageIndex = 100
                i = i - 2
                j = j + 2
                corr = 0
            Else
                corr = 0
                kk = 1
            End If
        End If
        If (corr = 2) Then
            TextBox1.Text = shashki(i, j).ImageIndex
            TextBox2.Text = shashki(i + 2, j - 2).ImageIndex
            If (shashki(i + 2, j - 2).ImageIndex = 0) Then
                shashki(i + 2, j - 2).BackgroundImage = shashki(i, j).BackgroundImage
                shashki(i + 2, j - 2).ImageIndex = shashki(i, j).ImageIndex
                shashki(i, j).ImageIndex = 0
                shashki(i, j).BackgroundImage = Button1.BackgroundImage
                shashki(i + 1, j - 1).BackgroundImage = Button1.BackgroundImage
                shashki(i + 1, j - 1).ImageIndex = 0
                Button1.TabIndex = 0
                Button1.ImageIndex = 100
                i = i + 2
                j = j - 2
                corr = 0
            Else
                kk = 1
                corr = 0
            End If
        End If
        If (corr = 4) Then
            TextBox1.Text = shashki(i, j).ImageIndex
            TextBox2.Text = shashki(i + 2, j + 2).ImageIndex
            If (shashki(i + 2, j + 2).ImageIndex = 0) Then
                shashki(i + 2, j + 2).BackgroundImage = shashki(i, j).BackgroundImage
                shashki(i + 2, j + 2).ImageIndex = shashki(i, j).ImageIndex
                shashki(i, j).ImageIndex = 0
                shashki(i, j).BackgroundImage = Button1.BackgroundImage
                shashki(i + 1, j + 1).BackgroundImage = Button1.BackgroundImage
                shashki(i + 1, j + 1).ImageIndex = 0
                Button1.TabIndex = 0
                Button1.ImageIndex = 100
                i = i + 2
                j = j + 2
                corr = 0
            Else
                kk = 1
                corr = 0
            End If
        End If
    End Sub
0
1712 / 579 / 76
Регистрация: 10.04.2009
Сообщений: 9,323
20.05.2012, 21:00
не понял поля доски, это кнопки? или что?
1
2 / 2 / 1
Регистрация: 15.02.2011
Сообщений: 70
20.05.2012, 21:01  [ТС]
Цитата Сообщение от Ципихович Эндрю Посмотреть сообщение
не понял поля доски, это кнопки? или что?
дада Это кнопки) Я незнал как сделать иначе))

Можно было конечно через OvalShape, но это не легче) там бы нужно было их привязывать к координатам и т.д.))
0
1712 / 579 / 76
Регистрация: 10.04.2009
Сообщений: 9,323
20.05.2012, 21:04
Цитата Сообщение от Wolfed Посмотреть сообщение
Я незнал как сделать иначе))
думаю с этого надо начать (тема же избитая гуглить пробовали - шашки в VB6)
0
2 / 2 / 1
Регистрация: 15.02.2011
Сообщений: 70
20.05.2012, 21:18  [ТС]
Цитата Сообщение от Ципихович Эндрю Посмотреть сообщение
думаю с этого надо начать (тема же избитая гуглить пробовали - шашки в VB6)
Ну не нравится мне чужие коды) вот вообще) не знаю почему)) поэтому пробую своими силами, ну и как всегда это бывает из-за отсутствия какой-либо базы, придумываю ахинею)

Добавлено через 12 минут
Ну вот я и скачал чужой код) как теперь его просмотреть? .vbproj отсутствует. Все отсутствует Есть чтото этого:
Visual Basic
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
VERSION 5.00
Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.OCX"
Object = "{F9043C88-F6F2-101A-A3C9-08002B2F49FB}#1.2#0"; "COMDLG32.OCX"
Begin VB.Form frmMain 
   AutoRedraw      =   -1  'True
   BorderStyle     =   1  'Fixed Single
   Caption         =   "Checkers V2.3"
   ClientHeight    =   8325
   ClientLeft      =   45
   ClientTop       =   330
   ClientWidth     =   12105
   ClipControls    =   0   'False
   Icon            =   "frmMain.frx":0000
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   MinButton       =   0   'False
   ScaleHeight     =   555
   ScaleMode       =   3  'Pixel
   ScaleWidth      =   807
   StartUpPosition =   2  'CenterScreen
   Begin MSComDlg.CommonDialog CD1 
      Left            =   3840
      Top             =   1680
      _ExtentX        =   847
      _ExtentY        =   847
      _Version        =   393216
   End
   Begin VB.CommandButton cmdSave 
      Caption         =   "&Save Board"
      Height          =   375
      Left            =   120
      TabIndex        =   111
      Top             =   5640
      Width           =   1575
   End
   Begin VB.CommandButton cmdOpen 
      Caption         =   "&Load Board"
      Height          =   375
      Left            =   120
      TabIndex        =   110
      Top             =   6120
      Width           =   1575
   End
   Begin MSComctlLib.StatusBar StatusBar1 
      Align           =   2  'Align Bottom
      Height          =   300
      Left            =   0
      TabIndex        =   109
      Top             =   8025
      Width           =   12105
      _ExtentX        =   21352
      _ExtentY        =   529
      Style           =   1
      ShowTips        =   0   'False
      _Version        =   393216
      BeginProperty Panels {8E3867A5-8586-11D1-B16A-00C0F0283628} 
      EndProperty
   End
   Begin VB.PictureBox Pictures 
      AutoSize        =   -1  'True
      Height          =   1035
      Index           =   5
      Left            =   7920
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   108
      Top             =   2520
      Visible         =   0   'False
      Width           =   1035
   End
   Begin VB.PictureBox Pictures 
      AutoSize        =   -1  'True
      Height          =   1035
      Index           =   3
      Left            =   5760
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   107
      Top             =   2520
      Visible         =   0   'False
      Width           =   1035
   End
   Begin VB.PictureBox Pictures 
      AutoSize        =   -1  'True
      Height          =   1035
      Index           =   4
      Left            =   6840
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   106
      Top             =   2520
      Visible         =   0   'False
      Width           =   1035
   End
   Begin VB.PictureBox Pictures 
      AutoSize        =   -1  'True
      Height          =   1035
      Index           =   2
      Left            =   4680
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   105
      Top             =   2520
      Visible         =   0   'False
      Width           =   1035
   End
   Begin VB.PictureBox Pictures 
      AutoSize        =   -1  'True
      Height          =   1035
      Index           =   1
      Left            =   3600
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   104
      Top             =   2520
      Visible         =   0   'False
      Width           =   1035
   End
   Begin VB.CommandButton cmdBack 
      Caption         =   "&Back"
      Height          =   375
      Left            =   10320
      TabIndex        =   103
      Top             =   7440
      Width           =   1695
   End
   Begin VB.Frame Frame6 
      Caption         =   "Statistics"
      Height          =   1455
      Left            =   10320
      TabIndex        =   94
      Top             =   5400
      Width           =   1695
      Begin VB.Label Labels 
         Alignment       =   2  'Center
         Caption         =   "Current Moves"
         Height          =   255
         Index           =   6
         Left            =   120
         TabIndex        =   98
         Top             =   840
         Width           =   1455
      End
      Begin VB.Label Labels 
         Alignment       =   2  'Center
         Caption         =   "Current Depth"
         Height          =   255
         Index           =   5
         Left            =   120
         TabIndex        =   97
         Top             =   240
         Width           =   1455
      End
      Begin VB.Label lblMMatrixSize 
         Alignment       =   2  'Center
         Caption         =   "0"
         Height          =   255
         Left            =   120
         TabIndex        =   96
         Top             =   1080
         Width           =   1455
      End
      Begin VB.Label lblPlyDepth 
         Alignment       =   2  'Center
         Caption         =   "0"
         Height          =   255
         Left            =   120
         TabIndex        =   95
         Top             =   480
         Width           =   1455
      End
   End
   Begin VB.Frame Frame5 
      Caption         =   "Game Info"
      Height          =   2775
      Left            =   10320
      TabIndex        =   87
      Top             =   240
      Width           =   1695
      Begin VB.Label Labels 
         Alignment       =   2  'Center
         Caption         =   "Total Turns"
         Height          =   255
         Index           =   10
         Left            =   120
         TabIndex        =   102
         Top             =   2040
         Width           =   1455
      End
      Begin VB.Label Labels 
         Alignment       =   2  'Center
         Caption         =   "Total Time"
         Height          =   255
         Index           =   9
         Left            =   120
         TabIndex        =   101
         Top             =   1440
         Width           =   1455
      End
      Begin VB.Label Labels 
         Alignment       =   2  'Center
         Caption         =   "P2 Time"
         Height          =   255
         Index           =   8
         Left            =   120
         TabIndex        =   100
         Top             =   840
         Width           =   1455
      End
      Begin VB.Label Labels 
         Alignment       =   2  'Center
         Caption         =   "P1 Time"
         Height          =   255
         Index           =   7
         Left            =   120
         TabIndex        =   99
         Top             =   240
         Width           =   1455
      End
      Begin VB.Label lblTurns 
         Alignment       =   2  'Center
         Caption         =   "0"
         Height          =   255
         Left            =   120
         TabIndex        =   93
         Top             =   2280
         Width           =   1455
      End
      Begin VB.Label lblTotalTime 
         Alignment       =   2  'Center
         Caption         =   "0 Min 0 Sec"
         Height          =   255
         Left            =   120
         TabIndex        =   90
         Top             =   1680
         Width           =   1455
      End
      Begin VB.Label lblP2Time 
         Alignment       =   2  'Center
         Caption         =   "0 Min 0 Sec"
         Height          =   255
         Left            =   120
         TabIndex        =   89
         Top             =   1080
         Width           =   1455
      End
      Begin VB.Label lblP1Time 
         Alignment       =   2  'Center
         Caption         =   "0 Min 0 Sec"
         Height          =   255
         Left            =   120
         TabIndex        =   88
         Top             =   480
         Width           =   1455
      End
   End
   Begin VB.CommandButton cmdAdvanced 
      Caption         =   "&Advanced -->"
      Height          =   375
      Left            =   120
      TabIndex        =   86
      Top             =   5160
      Width           =   1575
   End
   Begin VB.Frame Frame4 
      Caption         =   "Options"
      Height          =   1455
      Left            =   120
      TabIndex        =   82
      Top             =   3600
      Width           =   1575
      Begin VB.CheckBox CheckCheat 
         Caption         =   "Cheat"
         Height          =   255
         Left            =   120
         TabIndex        =   85
         Top             =   600
         Width           =   1335
      End
      Begin VB.CheckBox CheckAutoSwitch 
         Caption         =   "Auto Switch"
         Height          =   255
         Left            =   120
         TabIndex        =   84
         Top             =   240
         Width           =   1335
      End
      Begin VB.CheckBox CheckDisErrors 
         Caption         =   "Display Errors"
         Height          =   255
         Left            =   120
         TabIndex        =   83
         Top             =   960
         Width           =   1335
      End
   End
   Begin VB.CommandButton cmdReset 
      Caption         =   "&Start"
      Height          =   375
      Left            =   120
      TabIndex        =   79
      Top             =   240
      Width           =   1575
   End
   Begin VB.Frame Frame2 
      Caption         =   "Points"
      Height          =   975
      Left            =   120
      TabIndex        =   76
      Top             =   1440
      Width           =   1575
      Begin VB.Label lblP2Points 
         Alignment       =   2  'Center
         Height          =   255
         Left            =   120
         TabIndex        =   78
         Top             =   600
         Width           =   1335
      End
      Begin VB.Label lblP1Points 
         Alignment       =   2  'Center
         Height          =   255
         Left            =   120
         TabIndex        =   77
         Top             =   240
         Width           =   1335
      End
   End
   Begin VB.Frame Frame1 
      Caption         =   "Gameplay Type"
      Height          =   975
      Left            =   120
      TabIndex        =   73
      Top             =   2520
      Width           =   1575
      Begin VB.OptionButton Option1 
         Caption         =   "1 Player"
         Height          =   255
         Left            =   120
         TabIndex        =   75
         Top             =   240
         Value           =   -1  'True
         Width           =   975
      End
      Begin VB.OptionButton Option2 
         Caption         =   "2 Player"
         Height          =   255
         Left            =   120
         TabIndex        =   74
         Top             =   600
         Width           =   975
      End
   End
   Begin VB.CommandButton cmdSwitch 
      Caption         =   "Skip &Go"
      Height          =   375
      Left            =   120
      TabIndex        =   72
      Top             =   6600
      Width           =   1575
   End
   Begin VB.CommandButton cmdReverse 
      Caption         =   "&Reverse Board"
      Enabled         =   0   'False
      Height          =   375
      Left            =   120
      TabIndex        =   71
      Top             =   7080
      Width           =   1575
   End
   Begin VB.CommandButton cmdName 
      Caption         =   "&Name Players"
      Height          =   375
      Left            =   10320
      TabIndex        =   70
      Top             =   6960
      Width           =   1695
   End
   Begin VB.CommandButton cmdExit 
      Cancel          =   -1  'True
      Caption         =   "E&xit"
      Height          =   375
      Left            =   120
      TabIndex        =   69
      Top             =   7560
      Width           =   1575
   End
   Begin VB.Frame Frame3 
      Caption         =   "Advanced Options"
      Height          =   2175
      Left            =   10320
      TabIndex        =   64
      Top             =   3120
      Width           =   1695
      Begin VB.TextBox txtMaxTime 
         Alignment       =   2  'Center
         BackColor       =   &H8000000F&
         BorderStyle     =   0  'None
         Height          =   285
         Left            =   240
         TabIndex        =   92
         ToolTipText     =   "Click to change"
         Top             =   1680
         Width           =   1215
      End
      Begin VB.TextBox txtError 
         Alignment       =   2  'Center
         BackColor       =   &H8000000F&
         BorderStyle     =   0  'None
         Height          =   285
         Left            =   120
         TabIndex        =   68
         ToolTipText     =   "Click to change"
         Top             =   1080
         Width           =   1455
      End
      Begin VB.TextBox txtDepth 
         Alignment       =   2  'Center
         BackColor       =   &H8000000F&
         BorderStyle     =   0  'None
         Height          =   285
         Left            =   240
         TabIndex        =   65
         ToolTipText     =   "Click to change"
         Top             =   480
         Width           =   1215
      End
      Begin VB.Label Labels 
         Alignment       =   2  'Center
         Caption         =   "Max Think Time"
         Height          =   255
         Index           =   3
         Left            =   120
         TabIndex        =   91
         Top             =   1440
         Width           =   1455
      End
      Begin VB.Label Labels 
         Alignment       =   2  'Center
         Caption         =   "Array Error Size (%)"
         Height          =   255
         Index           =   2
         Left            =   120
         TabIndex        =   67
         Top             =   840
         Width           =   1455
      End
      Begin VB.Label Labels 
         Alignment       =   2  'Center
         Caption         =   "Max Ply Depth"
         Height          =   255
         Index           =   1
         Left            =   240
         TabIndex        =   66
         Top             =   240
         Width           =   1215
      End
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   63
      Left            =   8880
      ScaleHeight     =   65
      ScaleMode       =   3  'Pixel
      ScaleWidth      =   65
      TabIndex        =   63
      Top             =   6960
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   62
      Left            =   7920
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   62
      Top             =   6960
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   61
      Left            =   6960
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   61
      Top             =   6960
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   60
      Left            =   6000
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   60
      Top             =   6960
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   59
      Left            =   5040
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   59
      Top             =   6960
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   58
      Left            =   4080
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   58
      Top             =   6960
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   57
      Left            =   3120
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   57
      Top             =   6960
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   56
      Left            =   2160
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   56
      Top             =   6960
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   55
      Left            =   8880
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   55
      Top             =   6000
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   54
      Left            =   7920
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   54
      Top             =   6000
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   53
      Left            =   6960
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   53
      Top             =   6000
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   52
      Left            =   6000
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   52
      Top             =   6000
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   51
      Left            =   5040
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   51
      Top             =   6000
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   50
      Left            =   4080
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   50
      Top             =   6000
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   49
      Left            =   3120
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   49
      Top             =   6000
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   48
      Left            =   2160
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   48
      Top             =   6000
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   47
      Left            =   8880
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   47
      Top             =   5040
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   46
      Left            =   7920
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   46
      Top             =   5040
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   45
      Left            =   6960
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   45
      Top             =   5040
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   44
      Left            =   6000
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   44
      Top             =   5040
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   43
      Left            =   5040
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   43
      Top             =   5040
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   42
      Left            =   4080
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   42
      Top             =   5040
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   41
      Left            =   3120
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   41
      Top             =   5040
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   40
      Left            =   2160
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   40
      Top             =   5040
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   39
      Left            =   8880
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   39
      Top             =   4080
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   38
      Left            =   7920
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   38
      Top             =   4080
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   37
      Left            =   6960
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   37
      Top             =   4080
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   36
      Left            =   6000
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   36
      Top             =   4080
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   35
      Left            =   5040
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   35
      Top             =   4080
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   34
      Left            =   4080
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   34
      Top             =   4080
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   33
      Left            =   3120
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   33
      Top             =   4080
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   32
      Left            =   2160
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   32
      Top             =   4080
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   31
      Left            =   8880
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   31
      Top             =   3120
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   30
      Left            =   7920
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   30
      Top             =   3120
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   29
      Left            =   6960
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   29
      Top             =   3120
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   28
      Left            =   6000
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   28
      Top             =   3120
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   27
      Left            =   5040
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   27
      Top             =   3120
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   26
      Left            =   4080
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   26
      Top             =   3120
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   25
      Left            =   3120
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   25
      Top             =   3120
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   24
      Left            =   2160
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   24
      Top             =   3120
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   23
      Left            =   8880
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   23
      Top             =   2160
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   22
      Left            =   7920
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   22
      Top             =   2160
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   21
      Left            =   6960
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   21
      Top             =   2160
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   20
      Left            =   6000
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   20
      Top             =   2160
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   19
      Left            =   5040
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   19
      Top             =   2160
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   18
      Left            =   4080
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   18
      Top             =   2160
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   17
      Left            =   3120
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   17
      Top             =   2160
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   16
      Left            =   2160
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   16
      Top             =   2160
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   15
      Left            =   8880
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   15
      Top             =   1200
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   14
      Left            =   7920
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   14
      Top             =   1200
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   13
      Left            =   6960
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   13
      Top             =   1200
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   12
      Left            =   6000
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   12
      Top             =   1200
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   11
      Left            =   5040
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   11
      Top             =   1200
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   10
      Left            =   4080
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   10
      Top             =   1200
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   9
      Left            =   3120
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   9
      Top             =   1200
      Width           =   975
      Begin VB.Timer Timer1 
         Interval        =   100
         Left            =   120
         Top             =   480
      End
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   8
      Left            =   2160
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   8
      Top             =   1200
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   7
      Left            =   8880
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   7
      Top             =   240
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   6
      Left            =   7920
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   6
      Top             =   240
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   5
      Left            =   6960
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   5
      Top             =   240
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   4
      Left            =   6000
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   4
      Top             =   240
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   3
      Left            =   5040
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   3
      Top             =   240
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   2
      Left            =   4080
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   2
      Top             =   240
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000009&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   1
      Left            =   3120
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   1
      Top             =   240
      Width           =   975
   End
   Begin VB.PictureBox Shape1 
      BackColor       =   &H80000007&
      BorderStyle     =   0  'None
      Height          =   975
      Index           =   0
      Left            =   2160
      ScaleHeight     =   975
      ScaleWidth      =   975
      TabIndex        =   0
      Top             =   240
      Width           =   975
   End
   Begin VB.Line Line1 
      BorderWidth     =   2
      Index           =   1
      X1              =   672
      X2              =   672
      Y1              =   16
      Y2              =   528
   End
   Begin VB.Label Labels 
      Alignment       =   2  'Center
      Caption         =   "Player Turn:"
      Height          =   255
      Index           =   0
      Left            =   120
      TabIndex        =   81
      Top             =   840
      Width           =   1575
   End
   Begin VB.Label lblTurn 
      Alignment       =   2  'Center
      Height          =   255
      Left            =   120
      TabIndex        =   80
      Top             =   1080
      Width           =   1575
   End
   Begin VB.Line Line1 
      BorderWidth     =   2
      Index           =   0
      X1              =   128
      X2              =   128
      Y1              =   16
      Y2              =   528
   End
End
Attribute VB_Name = "frmMain"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
 
Private Sub CheckAutoSwitch_Click()
  AutoSwitch = CheckAutoSwitch
  If AutoSwitch = 1 Then cmdReverse.Enabled = False Else cmdReverse.Enabled = True
  Select Case Turn
    Case 1
      If Reversed = True Then Reversed = False: RefreshBoard Currentpieces
    Case 2
      If Reversed = False Then Reversed = True: RefreshBoard Currentpieces
  End Select
  
  General.SaveSettings
End Sub
 
Private Sub CheckAutoSwitch_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Automatically switches board orientation to current players side (only in 2 player mode)"
End Sub
 
Private Sub CheckCheat_Click()
  CheatSwitch = CheckCheat
  General.SaveSettings
End Sub
 
Private Sub CheckCheat_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Used as debug, allow you to move any piece anywhere, moving a piece onto another deletes the original piece"
End Sub
 
Private Sub CheckDisErrors_Click()
  Select Case CheckDisErrors
    Case 0
      DisplayErrors = 0
    Case 1
      DisplayErrors = 1
  End Select
End Sub
 
Private Sub CheckDisErrors_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Select to show all errors which occur in the game, deselect to ignore them"
End Sub
 
Private Sub cmdAdvanced_Click()
 
  If IsAdvanced = 0 Then
    frmMain.Width = 12240
    cmdAdvanced.Caption = "&Advanced <--"
    IsAdvanced = 1
  Else
    frmMain.Width = 10125
    cmdAdvanced.Caption = "&Advanced -->"
    IsAdvanced = 0
  End If
  
  General.SaveSettings
End Sub
 
Private Sub cmdAdvanced_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Click to toggle advanced controls panel"
End Sub
 
Private Sub cmdBack_Click()
Dim Lng1 As Long
For Lng1 = 1 To 16
  Currentpieces(Lng1) = Lastpieces(Lng1)
Next
  RefreshBoard Currentpieces
End Sub
 
Private Sub cmdBack_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Click to revert back to board state before last move"
End Sub
 
Private Sub cmdExit_Click()
  Unload Me
  End
End Sub
 
Private Sub cmdExit_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Click to exit game"
End Sub
 
Private Sub cmdName_Click()
Dim Response As String
 
Response = InputBox("Enter Player 1 Name", "Player 1", Names(1))
If Response <> "" Then Names(1) = Response Else Exit Sub
 
Response = InputBox("Enter Player 2 Name", "Player 2", Names(2))
If Response <> "" Then Names(2) = Response Else Exit Sub
 
General.SaveSettings
General.RefreshDisplay
 
End Sub
 
Private Sub cmdName_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Click to name players"
End Sub
 
Private Sub cmdOpen_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Click to load a saved game"
End Sub
 
Private Sub cmdReset_Click()
  Call General.ResetGame
End Sub
 
Private Sub cmdReset_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Starts a new game"
End Sub
 
Private Sub cmdReverse_Click()
  Reversed = Not Reversed
  Call RefreshBoard(Currentpieces)
End Sub
 
Private Sub cmdReverse_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Reverses board orientation"
End Sub
 
Private Sub cmdOpen_Click()
Dim File As String, Response As Long, Buffer As String
  If GameStarted Then
    Response = MsgBox("Erase current game?", vbExclamation + vbYesNo)
    If Response = vbNo Then Exit Sub
  End If
  
  CD1.DialogTitle = "Load Board"
  CD1.Filter = "Board File (*.brd)|*.brd"
  CD1.Flags = cdlOFNHideReadOnly
  CD1.InitDir = CurDir
  CD1.FileName = ""
  CD1.ShowOpen
  File = CD1.FileName
  If File = "" Then Exit Sub
  
  If Dir(File, vbHidden Or vbSystem Or vbNormal Or vbReadOnly) = "" Then
    MsgBox CD1.FileTitle & " does not exist", vbExclamation
    Exit Sub
  End If
  
  Open File For Binary Access Read As #1
    Get #1, , Currentpieces
    Get #1, , Turn
    Get #1, , Option1
  Close #1
  
  General.RefreshDisplay
  General.RefreshBoard Currentpieces
  
End Sub
 
Private Sub cmdSave_Click()
Dim File As String, Response As Long, Buffer As String
 
  CD1.DialogTitle = "Save Board"
  CD1.Filter = "Board File (*.brd)|*.brd"
  CD1.Flags = cdlOFNHideReadOnly
  CD1.InitDir = CurDir
  CD1.FileName = ""
  CD1.ShowSave
  File = CD1.FileName
  If File = "" Then Exit Sub
  If Dir(File, vbHidden Or vbSystem Or vbNormal Or vbReadOnly) <> "" Then
    Response = MsgBox(CD1.FileTitle & " already exists, overwrite?", vbExclamation + vbYesNo)
    If Response = vbNo Then Exit Sub
  End If
  
  Open File For Binary As #1
    Put #1, , Currentpieces
    Put #1, , Turn
    Put #1, , CBool(Option1)
  Close #1
  
End Sub
 
Private Sub cmdSave_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Click to save the current game"
End Sub
 
Private Sub cmdSwitch_Click()
  Select Case Turn
    Case 1
      Turn = 2
      If Option1 = True Then Call AIMove(2)
    Case 2
      Turn = 1
  End Select
  RefreshDisplay
End Sub
 
Private Sub cmdSwitch_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Click to skip the current players go"
End Sub
 
Private Sub Form_Load()
  
  Pictures(1).Picture = LoadPicture(App.Path & "\Art\Red.bmp")
  Pictures(2).Picture = LoadPicture(App.Path & "\Art\DRed.bmp")
  Pictures(3).Picture = LoadPicture(App.Path & "\Art\Blue.bmp")
  Pictures(4).Picture = LoadPicture(App.Path & "\Art\DBlue.bmp")
  Pictures(5).Picture = LoadPicture(App.Path & "\Art\Yellow.bmp")
  
  IndexMoves(1) = -7
  IndexMoves(2) = 9
  IndexMoves(3) = 7
  IndexMoves(4) = -9
  IndexMoves(5) = -14
  IndexMoves(6) = 18
  IndexMoves(7) = 14
  IndexMoves(8) = -18
  
  XYMoves(1).X = 1
  XYMoves(2).X = 1
  XYMoves(3).X = -1
  XYMoves(4).X = -1
  XYMoves(5).X = 2
  XYMoves(6).X = 2
  XYMoves(7).X = -2
  XYMoves(8).X = -2
  
  XYMoves(1).Y = -1
  XYMoves(2).Y = 1
  XYMoves(3).Y = 1
  XYMoves(4).Y = -1
  XYMoves(5).Y = -2
  XYMoves(6).Y = 2
  XYMoves(7).Y = 2
  XYMoves(8).Y = -2
  
  ReDim SMatrix(0 To 0)
  ReDim MoveMatrix(0 To 0)
 
  General.GetSettings
  
  If Names(1) = "" Then
    Names(1) = "Player 1"
    Names(2) = "Player 2"
    MaxDepth = 5
    txtDepth = "5"
    ErrorMargin = 25
    txtError = "25%"
    General.SaveSettings
  End If
  
  If IsAdvanced = 1 Then frmMain.Width = 12240: cmdAdvanced.Caption = "&Advanced <--" Else frmMain.Width = 10150: cmdAdvanced.Caption = "&Advanced -->"
  CheckAutoSwitch = AutoSwitch
  CheckCheat = CheatSwitch
  CheckDisErrors = DisplayErrors
  txtDepth = MaxDepth
  txtError = ErrorMargin
  txtMaxTime = MaxThoughtTime & " Sec"
  
  General.ResetGame
  General.RefreshDisplay
  
End Sub
 
Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = ""
End Sub
 
Private Sub lblMMatrixSize_Click()
  StatusBar1.SimpleText = "Displays the amount of moves the AI engine has generated so far"
End Sub
 
Private Sub lblP1Time_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Displays time taken for " & Names(1) & " this game"
End Sub
 
Private Sub lblP2Time_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Displays time taken for " & Names(2) & " this game"
End Sub
 
Private Sub lblPlyDepth_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Displays current depth that the AI engine is thinking at"
End Sub
 
Private Sub lblTotalTime_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Displays total time taken for this game"
End Sub
 
Private Sub lblTurns_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Displays number of turns this game"
End Sub
 
Private Sub Option1_Click()
  If Turn = 2 Then Call AIMove(2)
  cmdReverse.Enabled = False
End Sub
 
Private Sub Option2_Click()
  cmdReverse.Enabled = True
End Sub
 
Private Sub Shape1_Click(Index As Integer)
Static Selected As Boolean, SelectedPiece As SelectedSquare, RealIndex As Long
 
RealIndex = General.IndexTranslation(Val(Index))
 
If Selected = True Then
  If SelectedPiece.Index = RealIndex Then GoTo Deselect
  GameStarted = True
  If MovePiece(Val(SelectedPiece.Index), RealIndex, 0, False) Then Selected = False
  If P1MultiMode Then SelectedPiece = CheckSquare(Currentpieces, , , Currentpieces(SelectedPiece.Piece).Index)
Else
  SelectedPiece = CheckSquare(Currentpieces, , , Val(RealIndex))
  If SelectedPiece.IsPiece And (Turn = SelectedPiece.Player Or CheatSwitch = 1) Then
    Shape1(Index).Picture = Pictures(5).Picture
    Selected = True
  End If
End If
 
Exit Sub
 
Deselect:
 
If SelectedPiece.Player = 1 Then
  If SelectedPiece.Double Then
    Shape1(Index).Picture = Pictures(2).Picture
  Else
    Shape1(Index).Picture = Pictures(1).Picture
  End If
Else
  If SelectedPiece.Double Then
    Shape1(Index).Picture = Pictures(4).Picture
  Else
    Shape1(Index).Picture = Pictures(3).Picture
  End If
End If
 
Selected = False
 
If P1MultiMode Then
  P1MultiMode = False
  If Turn = 1 Then
    Turn = 2
    If CheckWin(Currentpieces) = True Then
      RefreshDisplay
    Else
      RefreshDisplay
    End If
    DoEvents
    If frmMain.Option1 And CheatSwitch = 0 Then Call AIMove(CByte(Turn))
    If frmMain.Option2 And frmMain.CheckAutoSwitch Then Sleep 600: Reversed = True: RefreshBoard Currentpieces  ' Switch board
  Else
    Turn = 1
    If CheckWin(Currentpieces) = True Then
      RefreshDisplay
    Else
      RefreshDisplay
    End If
    DoEvents
    If frmMain.Option2 And frmMain.CheckAutoSwitch Then Sleep 500: Reversed = False: RefreshBoard Currentpieces  ' Switch board
  End If
End If
 
End Sub
 
Private Sub Shape1_DblClick(Index As Integer)
Dim TempSquare As SelectedSquare, Msg As String
 
TempSquare = CheckSquare(Currentpieces, , , IndexTranslation(Val(Index)))
 
Msg = "X = " & TempSquare.X & vbCrLf & _
"Y = " & TempSquare.Y & vbCrLf & _
"Index = " & TempSquare.Index & vbCrLf & _
"Double = " & TempSquare.Double & vbCrLf & _
"IsPiece = " & TempSquare.IsPiece & vbCrLf & _
"IsSquare = " & TempSquare.IsSquare & vbCrLf & _
"Piece Number = " & TempSquare.Piece & vbCrLf & _
"Player = " & TempSquare.Player & vbCrLf
 
MsgBox Msg, vbExclamation, "Shape(" & Index & ") info"
End Sub
 
Private Sub Shape1_MouseMove(Index As Integer, Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = ""
End Sub
 
Private Sub Timer1_Timer()
 
  If GameStarted = False Then Exit Sub
  Select Case Turn
    Case 1
      VP1Time.Seconds = VP1Time.Seconds + 0.1
      If VP1Time.Seconds >= 60 Then VP1Time.Minutes = VP1Time.Minutes + Int(VP1Time.Seconds / 60): VP1Time.Seconds = VP2Time.Seconds - (Int(VP2Time.Seconds / 60) * 60)
      If InStr(1, CStr(Round(VP1Time.Seconds, 1)), ".", vbBinaryCompare) = 0 Then
        lblP1Time = VP1Time.Minutes & " Min " & Round(VP1Time.Seconds, 1) & ".0 Sec"
      Else
        lblP1Time = VP1Time.Minutes & " Min " & Round(VP1Time.Seconds, 1) & " Sec"
      End If
    Case 2
      If Option1 = True Then Exit Sub
      VP2Time.Seconds = VP2Time.Seconds + 0.1
      If VP2Time.Seconds >= 60 Then VP2Time.Minutes = VP2Time.Minutes + Int(VP2Time.Seconds / 60): VP2Time.Seconds = VP2Time.Seconds - (Int(VP2Time.Seconds / 60) * 60)
      If InStr(1, CStr(Round(VP2Time.Seconds, 1)), ".", vbBinaryCompare) = 0 Then
        lblP2Time = VP2Time.Minutes & " Min " & Round(VP2Time.Seconds, 1) & ".0 Sec"
      Else
        lblP2Time = VP2Time.Minutes & " Min " & Round(VP2Time.Seconds, 1) & " Sec"
      End If
  End Select
  
  TotalTime.Seconds = VP2Time.Seconds + VP1Time.Seconds
  TotalTime.Minutes = VP2Time.Minutes + VP2Time.Minutes
  If TotalTime.Seconds >= 60 Then TotalTime.Minutes = TotalTime.Minutes + Int(TotalTime.Seconds / 60): TotalTime.Seconds = TotalTime.Seconds - (Int(TotalTime.Seconds / 60) * 60)
  If InStr(1, CStr(Round(TotalTime.Seconds, 1)), ".", vbBinaryCompare) = 0 Then
    lblTotalTime = TotalTime.Minutes & " Min " & Round(TotalTime.Seconds, 1) & ".0 Sec"
  Else
    lblTotalTime = TotalTime.Minutes & " Min " & Round(TotalTime.Seconds, 1) & " Sec"
  End If
  
End Sub
 
Private Sub txtDepth_Click()
  txtDepth.Alignment = 0
  txtDepth.BackColor = &H8000000E
  txtDepth.BorderStyle = 1
  txtDepth.SelStart = 0
  txtDepth.SelLength = Len(txtDepth)
End Sub
 
Private Sub txtDepth_KeyPress(KeyAscii As Integer)
  If KeyAscii = 13 Then Call txtDepth_LostFocus: cmdReset.SetFocus
End Sub
 
Private Sub txtDepth_LostFocus()
  txtDepth.Alignment = 2
  txtDepth.BackColor = &H8000000F
  txtDepth.BorderStyle = 0
  If IsNumeric(txtDepth) Then
    MaxDepth = txtDepth
    General.SaveSettings
  Else
    MsgBox "The Maximum Ply Depth must be numeric!", vbExclamation
    txtDepth = MaxDepth
    txtDepth.SelStart = 0
    txtDepth.SelLength = Len(txtDepth)
  End If
End Sub
 
Private Sub txtDepth_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Click to change maximum ply depth"
End Sub
 
Private Sub txtError_Click()
  txtError.Alignment = 0
  txtError.BackColor = &H8000000E
  txtError.BorderStyle = 1
  txtError.SelStart = 0
  txtError.SelLength = Len(txtError)
End Sub
 
Private Sub txtError_KeyPress(KeyAscii As Integer)
  If KeyAscii = 13 Then Call txtError_LostFocus: cmdReset.SetFocus
End Sub
 
Private Sub txtError_LostFocus()
  txtError.Alignment = 2
  txtError.BackColor = &H8000000F
  txtError.BorderStyle = 0
  If IsNumeric(txtError) Then
    ErrorMargin = txtError
    General.SaveSettings
  Else
    MsgBox "The Array Upper Bound Error Margin must be numeric", vbExclamation
    txtError = ErrorMargin
    txtError.SelStart = 0
    txtError.SelLength = Len(txtError)
  End If
End Sub
 
Private Sub txtError_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Click to change array error margin"
End Sub
 
Private Sub txtMaxTime_Click()
  txtMaxTime = Left(txtMaxTime, Len(txtMaxTime) - 4)
  txtMaxTime.Alignment = 0
  txtMaxTime.BackColor = &H8000000E
  txtMaxTime.BorderStyle = 1
  txtMaxTime.SelStart = 0
  txtMaxTime.SelLength = Len(txtMaxTime)
End Sub
 
Private Sub txtMaxTime_KeyPress(KeyAscii As Integer)
  If KeyAscii = 13 Then cmdReset.SetFocus
End Sub
 
Private Sub txtMaxTime_LostFocus()
  txtMaxTime.Alignment = 2
  txtMaxTime.BackColor = &H8000000F
  txtMaxTime.BorderStyle = 0
  If IsNumeric(txtMaxTime) Then
    MaxThoughtTime = txtMaxTime
    General.SaveSettings
  Else
    MsgBox "The Array Upper Bound Error Margin must be numeric", vbExclamation
    txtMaxTime = ErrorMargin
    txtMaxTime.SelStart = 0
    txtMaxTime.SelLength = Len(txtMaxTime)
  End If
  txtMaxTime = txtMaxTime & " Sec"
End Sub
 
Private Sub txtMaxTime_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
  StatusBar1.SimpleText = "Click to set maximum tinking time for the computer player"
End Sub
Куда это вставлять? Как это использовать?
0
1712 / 579 / 76
Регистрация: 10.04.2009
Сообщений: 9,323
20.05.2012, 21:43
Цитата Сообщение от Wolfed Посмотреть сообщение
Куда это вставлять? Как это использовать?
ого и
Цитата Сообщение от Wolfed Посмотреть сообщение
Begin
- дельфями попахиват
что значит не люблю чужие коды
начало игры - 64 чёрно белых поля (в Вашем случае кнопки) и шашки на ней, сделано? как?
0
2 / 2 / 1
Регистрация: 15.02.2011
Сообщений: 70
20.05.2012, 22:06  [ТС]
Цитата Сообщение от Ципихович Эндрю Посмотреть сообщение
ого и - дельфями попахиват
что значит не люблю чужие коды
начало игры - 64 чёрно белых поля (в Вашем случае кнопки) и шашки на ней, сделано? как?
Люблю когда сам пишешь и прямо твоим почерком попахивает, ты разбираешься в проге на все стопять процентов
Создал 1 кнопку, копирнул, вставил, создал две, копирнул вставил, довел до 8 кнопок, копирнул,вставил 8 раз, разместил под друг другом, начиная с 1 кнопки через одну делал Enabled=false, красил их в серый цвет,начиная со 2,через одну, красил в черный и добавлял картинки для первых 12 черной шашки и последних 12 картинку белой шашки, ImageIndex для черных шашек =1 ImageIndex для белых шашек =2.Для пустых ImageIndex=0.Так получилось поле)) Вот перемещение:
Visual Basic
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
  Sub Letgo4(ByRef Button28 As Button, ByRef Button1 As Button, ByRef Button18 As Button, ByRef _
             Button20 As Button, ByRef Button34 As Button, ByRef Button36 As Button, ByRef corr As Integer)
 
        If (Button28.ImageIndex = 0) Then
            If (Button1.TabIndex = Button18.TabIndex And (Button1.ImageIndex = 1 Or Button1.ImageIndex = 3 Or Button1.ImageIndex = 4) And (corr = 0 Or corr = 1)) Then
                Letgo(Button18, Button28, Button1)
            End If
            '////////////////////////////////////////////////////////////////////////'
            If (Button1.TabIndex = Button20.TabIndex And (Button1.ImageIndex = 1 Or Button1.ImageIndex = 3 Or Button1.ImageIndex = 4) And (corr = 0 Or corr = 2)) Then
                Letgo(Button20, Button28, Button1)
            End If
            '////////////////////////////////////////////////////////////////////////'
            If (Button1.TabIndex = Button34.TabIndex And (Button1.ImageIndex = 2 Or Button1.ImageIndex = 3 Or Button1.ImageIndex = 4) And (corr = 0 Or corr = 3)) Then
                If (corr = 0) Then
                    Letgo(Button34, Button28, Button1)
                End If
            End If
            '////////////////////////////////////////////////////////////////////////'
            If (Button1.TabIndex = Button36.TabIndex And (Button1.ImageIndex = 2 Or Button1.ImageIndex = 3 Or Button1.ImageIndex = 4) And (corr = 0 Or corr = 4)) Then
                Letgo(Button36, Button28, Button1)
            End If
            '////////////////////////////////////////////////////////////////////////'
        Else
            Button1.TabIndex = Button28.TabIndex
            Button1.ImageIndex = Button28.ImageIndex
        End If
 
    End Sub
 
'///////////////////////////////////////////////////////////////////////////////////////////////////////////'
Sub Letgo(ByRef Button18 As Button, ByRef Button26 As Button, ByRef Button1 As Button)
        Button26.BackgroundImage = Button18.BackgroundImage
        Button26.ImageIndex = Button18.ImageIndex
        Button18.ImageIndex = 0
        Button18.BackgroundImage = Button1.BackgroundImage
        Button1.TabIndex = 0
        Button1.ImageIndex = 100
    End Sub
Добавлено через 11 минут
Сейчас сделал перемещение что-то типо этого
Visual Basic
1
2
3
4
5
6
7
8
9
10
11
12
13
   If (shashki(i - 2, j - 2).ImageIndex = 0 And shashki(i + 2, j - 2).ImageIndex = 0) Then
                While ((xod <> "Вправо") And (xod <> "Влево"))
                    xod = InputBox("Куда пойти влево или вправо? Чтобы пойти влево - напишите 'Влево', если вправо - то 'Вправо'", "Выбор хода")
                End While
                If (xod = "Влево") Then
                    corr = 1
                    xod = ""
                End If
                If (xod = "Вправо") Then
                    xod = ""
                    corr = 2
                End If
            End If
Кстати почему в VB And и or какие-то неправильные
0
1712 / 579 / 76
Регистрация: 10.04.2009
Сообщений: 9,323
20.05.2012, 22:16
Цитата Сообщение от Wolfed Посмотреть сообщение
Кстати почему в VB And и or какие-то неправильные
обоснуйте коротким примером не из этой проги а+в... и т.д. для себя сделал вывод что or - к нему нужно осторожно относится

Добавлено через 6 минут
Цитата Сообщение от Wolfed Посмотреть сообщение
Куда пойти влево или вправо? Чтобы пойти влево - напишите 'Влево', если вправо - то 'Вправо'"
я бы с таким играть не стал шашку выделил, если несколько вариантов хода у неё, то эти варианты подсвечивались бы предлагая себя, куда ткнул туда и сходило
0
2 / 2 / 1
Регистрация: 15.02.2011
Сообщений: 70
20.05.2012, 22:20  [ТС]
Цитата Сообщение от Ципихович Эндрю Посмотреть сообщение
обоснуйте коротким примером не из этой проги а+в... и т.д. для себя сделал вывод что or - к нему нужно осторожно относится
OR - обычная дизъюнкция. Моя ошибка была в том, что я отрицаю некоторое выражение, забывая менять or, поэтому оператор показался не логичным.

Так вернемся к изначальному вопросу, можно ли выполнить без InputBoxa? Как определить что кнопка была нажата?

Добавлено через 1 минуту
я бы с таким играть не стал шашку выделил, если несколько вариантов хода у неё, то эти варианты подсвечивались бы предлагая себя, куда ткнул туда и сходило
Я могу их подсветить - не проблема. Другое дело - как определить это ткнуние? IF(shashki(i-2,j-2).ТКНУЛ?!) Then шаг на i-2 j-2. Что вот нужно в ТКНУЛ?
0
1712 / 579 / 76
Регистрация: 10.04.2009
Сообщений: 9,323
20.05.2012, 22:22
обработчик события на нажатие кнопки
1
2 / 2 / 1
Регистрация: 15.02.2011
Сообщений: 70
20.05.2012, 22:23  [ТС]
Цитата Сообщение от Ципихович Эндрю Посмотреть сообщение
обработчик события на нажатие кнопки
Умная и очевидная мысль Как описать этот обработчик? В стандарте Button1_Click()
0
1712 / 579 / 76
Регистрация: 10.04.2009
Сообщений: 9,323
20.05.2012, 22:28
блин на форму ложите кнопку, наведите курсор и там в меню будет показать код, ОК?

Добавлено через 3 минуты
если ничего изобретать не будете с именем добавленной кнопки тогда
Visual Basic
1
2
3
Sub Command1_Click()
шо хотим.........
End Sub
0
es geht mir gut
 Аватар для SoftIce
11274 / 4760 / 1183
Регистрация: 27.07.2011
Сообщений: 11,439
21.05.2012, 00:18
Цитата Сообщение от Ципихович Эндрю Посмотреть сообщение
ого и

Begin
- дельфями попахиват
Какой Delphi ? Это файл .frx от Бейсика.
Только программа не запускается - не хватает модуля.
Вот как это выглядит:
Миниатюры
Кликнуть по двум кнопкам и поменять их картинки друг с другом  
1
es geht mir gut
 Аватар для SoftIce
11274 / 4760 / 1183
Регистрация: 27.07.2011
Сообщений: 11,439
21.05.2012, 00:26
Цитата Сообщение от Wolfed Посмотреть сообщение
Сейчас сделал перемещение что-то типо этого
А почему ты не хочешь мышкой таскать?
Типа так.
Вложения
Тип файла: rar ШАХМАТНАЯ ДОСКА.rar (2.1 Кб, 12 просмотров)
2
1712 / 579 / 76
Регистрация: 10.04.2009
Сообщений: 9,323
21.05.2012, 06:01
Цитата Сообщение от SoftIce Посмотреть сообщение
А почему ты не хочешь мышкой таскать?
не пойму у Вас кликнул на форму, есть показать код, а показать объект нет, где он?
0
es geht mir gut
 Аватар для SoftIce
11274 / 4760 / 1183
Регистрация: 27.07.2011
Сообщений: 11,439
21.05.2012, 06:15
Цитата Сообщение от Ципихович Эндрю Посмотреть сообщение
показать объект нет, где он
Какой объект? На форме 2 Label-a.
Весь код набросал по-быстрому. Там только одна шашка в качестве примера, остальные также можно создать при помощи массива. Я хотел показать, что не обязательно использовать кнопки и перетаскивать шашки удобнее мышкой:
Visual Basic
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
Dim X As Long, Y As Long, zv1 As Long, zv2 As Long
Dim a As Integer, b As Integer, c As Integer, d As Integer
Dim kolV As Integer, kolG As Integer, kNOP() As Integer, kxKNOP As Integer, kyKNOP As Integer
Dim zapX, zapY
Private Sub RISOVANIE()
Cls
ReDim kNOP(kolG, kolGV)
 For c = 1 To kolG Step 1
   CurrentY = b - 300: CurrentX = a * c + a / 6: Print c
   For d = 1 To kolV Step 1
       X = a * c
       Y = b * d
       CurrentY = b * d: CurrentX = a - 400: Print d
       If (c + d) Mod 2 = 0 Then Line (X, Y)-(X + a, Y + b), zv1, BF Else Line (X, Y)-(X + a, Y + b), zv2, BF
       CurrentY = b * d: CurrentX = a * kolG + a: Print d
    Next d
    CurrentX = a * c + a / 6: CurrentY = b * d: Print c
 Next c
End Sub
Private Sub Form_Load()
  AutoRedraw = True
  Me.Font = Bold: Me.Font.Size = 12: ScaleMode = 1: Me.Height = 6500: Me.Width = 6500
  a = 600: b = 600: kolV = 8: kolG = 8 ' Размер и количество клеток
  zv1 = vbWhite: zv2 = vbBlack 'Цвет клеток
  RISOVANIE
End Sub
Private Sub Form_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
    kxKNOP = (X + a / 2) / a - 1: kyKNOP = (Y + b / 2) / b - 1
    If kyKNOP <= kolV And kxKNOP <= kolG And kyKNOP <> 0 And kxKNOP <> 0 Then
       Label2.Caption = "Клетка" & Str(kyKNOP) & "-" & Str(kxKNOP)
    End If
End Sub
Private Sub label1_DragOver(Source As Control, X As Single, Y As Single, State As Integer)
    Label1.Left = Label1.Left + X - Label1.Width / 2
    Label1.Top = Label1.Top + Y - Label1.Height / 2
    kxKNOP = (Label1.Left - Label1.Width / 2 + a / 2) / a: kyKNOP = (Label1.Top - Label1.Height / 2 + b / 2) / b
    Label2.Caption = "Клетка" & Str(kyKNOP) & "-" & Str(kxKNOP)
End Sub
Private Sub label1_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
    Label1.Drag vbBeginDrag
    zapX = Label1.Left: zapY = Label1.Top
End Sub
Private Sub Label1_DragDrop(Source As Control, X As Single, Y As Single)
    If (kxKNOP + kyKNOP) Mod 2 <> 1 Then Label2.Caption = "": Label1.Left = zapX: Label1.Top = zapY
End Sub
1
Надоела реклама? Зарегистрируйтесь и она исчезнет полностью.
BasicMan
Эксперт
29316 / 5623 / 2384
Регистрация: 17.02.2009
Сообщений: 30,364
Блог
21.05.2012, 06:15
Помогаю со студенческими работами здесь

Создание простой анимации что бы менялись картинки друг за другом
Создание простой анимации что бы менялись картинки друг за другом как реализовать

Расположить картинки в виде ромбов рядом друг с другом (hover,onclick etc)
Есть 4 картинки (ромбы), надо расположить их, чтобы в итоге получился 1 ромб, соответственно блоки данных картинок будут заезжать друг на...

как изменить скрипт что бы картинки перемещались с лева на право друг за другом по всей страничке
как изменить скрипт что бы картинки перемещались с лева на право друг за другом по всей страничке ...

Массив: Найти наименьший и наибольший элементы матрицы, и поменять их местами друг с другом
Дана действительная квадратная матрица порядка n, найти наименьший и наибольший элементы матрицы, и поменять их местами друг с другом.

Как поменять несколько слоев div, находящихся друг над другом, местами
Как поменять несколько слоев div, находящихся друг над другом, местами? Например: Слой1 Слой1а Слой2 Слой2а Слой3 Слой3а ...


Искать еще темы с ответами

Или воспользуйтесь поиском по форуму:
20
Ответ Создать тему
Новые блоги и статьи
Символьное дифференцирование
igorrr37 13.02.2026
/ * Программа принимает математическое выражение в виде строки и выдаёт его производную в виде строки и вычисляет значение производной при заданном х Логарифм записывается как: (x-2)log(x^2+2) -. . .
Камера Toupcam IUA500KMA
Eddy_Em 12.02.2026
Т. к. у всяких "хикроботов" слишком уж мелкий пиксель, для подсмотра в ESPriF они вообще плохо годятся: уже 14 величину можно рассмотреть еле-еле лишь на экспозициях под 3 секунды (а то и больше),. . .
И ясному Солнцу
zbw 12.02.2026
И ясному Солнцу, и светлой Луне. В мире покоя нет и люди не могут жить в тишине. А жить им немного лет.
«Знание-Сила»
zbw 12.02.2026
«Знание-Сила» «Время-Деньги» «Деньги -Пуля»
SDL3 для Web (WebAssembly): Подключение Box2D v3, физика и отрисовка коллайдеров
8Observer8 12.02.2026
Содержание блога Box2D - это библиотека для 2D физики для анимаций и игр. С её помощью можно определять были ли коллизии между конкретными объектами и вызывать обработчики событий столкновения. . . .
SDL3 для Web (WebAssembly): Загрузка PNG с прозрачным фоном с помощью SDL_LoadPNG (без SDL3_image)
8Observer8 11.02.2026
Содержание блога Библиотека SDL3 содержит встроенные инструменты для базовой работы с изображениями - без использования библиотеки SDL3_image. Пошагово создадим проект для загрузки изображения. . .
SDL3 для Web (WebAssembly): Загрузка PNG с прозрачным фоном с помощью SDL3_image
8Observer8 10.02.2026
Содержание блога Библиотека SDL3_image содержит инструменты для расширенной работы с изображениями. Пошагово создадим проект для загрузки изображения формата PNG с альфа-каналом (с прозрачным. . .
Установка Qt-версии Lazarus IDE в Debian Trixie Xfce
volvo 10.02.2026
В общем, достали меня глюки IDE Лазаруса, собранной с использованием набора виджетов Gtk2 (конкретно: если набирать текст в редакторе и вызвать подсказку через Ctrl+Space, то после закрытия окошка. . .
КиберФорум - форум программистов, компьютерный форум, программирование
Powered by vBulletin
Copyright ©2000 - 2026, CyberForum.ru