windows扫雷源代码,windows扫雷源代码,windows扫雷源代码
2020-01-03 11:34:52 79KB 扫雷
1
cocos 扫雷代码工程,编译中可能会遇到log函数找不到的情况,删除即可
2020-01-03 11:33:39 934KB cocos
1
基于Qt的扫雷游戏开发及其源码
2019-12-21 21:41:09 2.52MB Qt 扫雷 代码
1
自己学习扫雷程序时,对代码做了一定的注释,对扫雷程序进行了代码注释,适合初学者。
2019-12-21 21:19:45 122KB 扫雷 详解
1
参考文章:https://blog.csdn.net/su20145104009/article/details/52152514
1
简易版扫雷程序代码 public class MineSweeperGame2 extends Application { Cell[][] cell; int totalMines=0; int markBomb=0; //总的地雷数量,简单会有10个,一般会有40个,困难99个 int showMines=10; String s=String.valueOf(showMines); Label tips=new Label("Game is running!"); Label showMineNum=new Label("mines: "+s); public void start(Stage primaryStage){ Stage startStage=new Stage(); //选择按钮的界面 Button startButton=new Button("RESTART"); Button chooseeasy=new Button(" EASY (10mines)"); Button choosenormal=new Button("NORMAL(40mines)"); Button choosehard=new Button(" HARD(99mines)"); BorderPane primaryPane=new BorderPane(); HBox startPane=new HBox(15); StackPane topButtonPane=new StackPane(startButton); StackPane topButtonPane2=new StackPane(showMineNum); StackPane buttomPane=new StackPane(tips); HBox topPane=new HBox(50); topPane.getChildren().addAll(topButtonPane,topButtonPane2); primaryPane.setTop(topPane); tips.setStyle("-fx-border-color:red;-fx-background-color:white;"); showMineNum.setStyle("-fx-border-color:black"); primaryPane.setBottom(buttomPane); buttomPane.setPadding(new Insets(15,15,15,15)); topPane.setPadding(new Insets(15,15,15,15)); startPane.setPadding(new Insets(15,15,15,15)); startPane.getChildren().add(chooseeasy); startPane.getChildren().add(choosenormal);
2019-12-21 20:08:49 12KB java
1