Skip to content

Commit 08269be

Browse files
committed
推箱子v0.0.4
修复了在撤回功能仅能在游玩开始的那一个关卡使用的bug 新增了一个 🎉 Features
1 parent ef99088 commit 08269be

4 files changed

Lines changed: 6 additions & 3 deletions

File tree

PushBox.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -251,8 +251,10 @@ void game() {
251251
p = Move(head, p);//人物移动函数
252252
if (!Remain_Box) {
253253
Level++;//关卡数加一
254+
p = NULL;//指针指向空指针
254255
free(head);//释放指针空间
255256
head = malloc(sizeof(Position));//头结点分配内存
257+
p = head;//指针重新指向头结点,用于遍历链表
256258
win();//关卡通过✅函数
257259
Level_start = time(NULL); //获取当前时间,单位为s
258260
}

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ gcc PushBox.c -o PushBox -lncurses
5555

5656
- [x] 无限回滚操作
5757
- [ ] 自动寻路算法
58+
- [ ] 支持直接链接编译
5859
- [ ] 自动生成地图文件
5960
- [ ] 优化代码及其性能
6061
- [ ] 支持3D图形化显示
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
Start testing: May 08 23:46 CST
1+
Start testing: May 15 01:40 CST
22
----------------------------------------------------------
3-
End testing: May 08 23:46 CST
3+
End testing: May 15 01:40 CST

data.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
Top_Level:14
2-
Latest_Level:14
2+
Latest_Level:5

0 commit comments

Comments
 (0)