A C++ version of the tiny game!
- DevBobcorn
- 2019年4月21日
- 読了時間: 1分
更新日:2019年4月21日

As a fan of Rusty Lake, I usually spend time playing their games. And that's when I began to be curious about what their algorithms were like. Since I'm learning programming these days, I find myself able to make part of the game on my own. So I gave it a try, and I did it. Though it's not so perfect, I'm quite satisfied with my work, which cost me about an hour to finish. Here's the code:
To start the Game, you need to input the game map first, for example:
17 (This represents the total number of nodes)
1 2
1 4
2 3
3 4
4 7
3 7
2 5
3 6
6 7
6 8
5 6
5 8
8 9
6 9
6 10
7 10
9 10 (These Above represents the connections between the nodes)
2 (This represents the number of fireflies)
5
10 (And these 2 numbers marked the positions of fireflies)
You can try changing the ShowDetail variable to false if you wonder what the spider is thinking about :P.
And if you find it hard to work it out,or simply want to try more levels, just take a look at these pictures
.
Enjoy yourself! ☺
Comments