Loading [MathJax]/jax/output/CommonHTML/config.js
首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >专栏 >蓝桥ROS机器人之绚丽贪吃蛇

蓝桥ROS机器人之绚丽贪吃蛇

作者头像
zhangrelay
发布于 2022-05-01 02:23:17
发布于 2022-05-01 02:23:17
53200
代码可运行
举报
运行总次数:0
代码可运行

前面一个贪吃蛇🐍,效果很普通:

有了GitHub,结合蓝桥云课,几乎无敌!

参考:github.com/rapiz1/DungeonRush

下载代码:

代码语言:javascript
代码运行次数:0
运行
AI代码解释
复制
git clone https://github.com/rapiz1/DungeonRush.git
代码语言:javascript
代码运行次数:0
运行
AI代码解释
复制
# apt install libsdl2-dev libsdl2-image-dev libsdl2-mixer-dev libsdl2-net-dev libsdl2-ttf-dev

编译可能报错:

cmake ..

make

修改CMakeList.txt

project(DungeonRush)


编译后文件内容如下:

代码语言:javascript
代码运行次数:0
运行
AI代码解释
复制
shiyanlou:DungeonRush/ (master*) $ tree                              [20:53:10]
.
\u251c\u2500\u2500 build
\u2502   \u251c\u2500\u2500 bin
\u2502   \u2502   \u251c\u2500\u2500 dungeon_rush
\u2502   \u2502   \u2514\u2500\u2500 res
\u2502   \u2502       \u251c\u2500\u2500 audio
\u2502   \u2502       \u2502   \u251c\u2500\u2500 arrow_hit.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 bg1.ogg
\u2502   \u2502       \u2502   \u251c\u2500\u2500 bg2.ogg
\u2502   \u2502       \u2502   \u251c\u2500\u2500 bg3.ogg
\u2502   \u2502       \u2502   \u251c\u2500\u2500 button1.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 claw_hit_heavy.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 claw_hit.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 coin.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 fireball_explosion.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 hit_0.5v.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 human_death.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 ice_shoot_0.5v.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 ice_shoot.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 interaction1_0.75v.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 light_shoot.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 lose_2v.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 main_title.ogg
\u2502   \u2502       \u2502   \u251c\u2500\u2500 med.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 powerloss.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 shoot.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 sounds
\u2502   \u2502       \u2502   \u251c\u2500\u2500 sword_hit.wav
\u2502   \u2502       \u2502   \u251c\u2500\u2500 thunder_2v.wav
\u2502   \u2502       \u2502   \u2514\u2500\u2500 win.wav
\u2502   \u2502       \u251c\u2500\u2500 drawable
\u2502   \u2502       \u2502   \u251c\u2500\u2500 0x72_DungeonTilesetII_v1_3
\u2502   \u2502       \u2502   \u251c\u2500\u2500 0x72_DungeonTilesetII_v1_3.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 arrow
\u2502   \u2502       \u2502   \u251c\u2500\u2500 arrow.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 attack_up
\u2502   \u2502       \u2502   \u251c\u2500\u2500 attack_up.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 Axe
\u2502   \u2502       \u2502   \u251c\u2500\u2500 Axe.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 blood
\u2502   \u2502       \u2502   \u251c\u2500\u2500 BloodBound
\u2502   \u2502       \u2502   \u251c\u2500\u2500 BloodBound.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 blood.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 ClawFx
\u2502   \u2502       \u2502   \u251c\u2500\u2500 ClawFx2
\u2502   \u2502       \u2502   \u251c\u2500\u2500 ClawFx2.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 ClawFx.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 cross_hit
\u2502   \u2502       \u2502   \u251c\u2500\u2500 cross_hit.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 explosion-2
\u2502   \u2502       \u2502   \u251c\u2500\u2500 explosion-2.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 fireball
\u2502   \u2502       \u2502   \u251c\u2500\u2500 fireball_explosion1
\u2502   \u2502       \u2502   \u251c\u2500\u2500 fireball_explosion1.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 fireball.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 floor_exit
\u2502   \u2502       \u2502   \u251c\u2500\u2500 floor_exit.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 floor_spike
\u2502   \u2502       \u2502   \u251c\u2500\u2500 floor_spike.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 golden_cross_hit
\u2502   \u2502       \u2502   \u251c\u2500\u2500 golden_cross_hit.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 halo_explosion1
\u2502   \u2502       \u2502   \u251c\u2500\u2500 halo_explosion1.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 halo_explosion2
\u2502   \u2502       \u2502   \u251c\u2500\u2500 halo_explosion2.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 HolyShield
\u2502   \u2502       \u2502   \u251c\u2500\u2500 HolyShield.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 HpMed
\u2502   \u2502       \u2502   \u251c\u2500\u2500 HpMed.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 Ice
\u2502   \u2502       \u2502   \u251c\u2500\u2500 IcePick
\u2502   \u2502       \u2502   \u251c\u2500\u2500 IcePick.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 Ice.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 IceShatter
\u2502   \u2502       \u2502   \u251c\u2500\u2500 IceShatter.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 powerful_bow
\u2502   \u2502       \u2502   \u251c\u2500\u2500 powerful_bow.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 purple_ball
\u2502   \u2502       \u2502   \u251c\u2500\u2500 purple_ball.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 purple_exp
\u2502   \u2502       \u2502   \u251c\u2500\u2500 purple_exp.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 Shine
\u2502   \u2502       \u2502   \u251c\u2500\u2500 Shine.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 SolidFx
\u2502   \u2502       \u2502   \u251c\u2500\u2500 SolidFx.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 SolidFx.png.bk
\u2502   \u2502       \u2502   \u251c\u2500\u2500 staff
\u2502   \u2502       \u2502   \u251c\u2500\u2500 staff.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 SwordFx
\u2502   \u2502       \u2502   \u251c\u2500\u2500 SwordFx.bk
\u2502   \u2502       \u2502   \u251c\u2500\u2500 SwordFx.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 SwordFx.png.bk
\u2502   \u2502       \u2502   \u251c\u2500\u2500 SwordPack
\u2502   \u2502       \u2502   \u251c\u2500\u2500 SwordPack.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 Thunder
\u2502   \u2502       \u2502   \u251c\u2500\u2500 Thunder.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 Thunder_Yellow
\u2502   \u2502       \u2502   \u251c\u2500\u2500 Thunder_Yellow.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 title
\u2502   \u2502       \u2502   \u251c\u2500\u2500 title.png
\u2502   \u2502       \u2502   \u251c\u2500\u2500 ui
\u2502   \u2502       \u2502   \u2514\u2500\u2500 ui.png
\u2502   \u2502       \u251c\u2500\u2500 font
\u2502   \u2502       \u2502   \u2514\u2500\u2500 m5x7.ttf
\u2502   \u2502       \u2514\u2500\u2500 text.txt
\u2502   \u251c\u2500\u2500 CMakeCache.txt
\u2502   \u251c\u2500\u2500 CMakeFiles
\u2502   \u2502   \u251c\u2500\u2500 3.5.1
\u2502   \u2502   \u2502   \u251c\u2500\u2500 CMakeCCompiler.cmake
\u2502   \u2502   \u2502   \u251c\u2500\u2500 CMakeCXXCompiler.cmake
\u2502   \u2502   \u2502   \u251c\u2500\u2500 CMakeDetermineCompilerABI_C.bin
\u2502   \u2502   \u2502   \u251c\u2500\u2500 CMakeDetermineCompilerABI_CXX.bin
\u2502   \u2502   \u2502   \u251c\u2500\u2500 CMakeSystem.cmake
\u2502   \u2502   \u2502   \u251c\u2500\u2500 CompilerIdC
\u2502   \u2502   \u2502   \u2502   \u251c\u2500\u2500 a.out
\u2502   \u2502   \u2502   \u2502   \u2514\u2500\u2500 CMakeCCompilerId.c
\u2502   \u2502   \u2502   \u2514\u2500\u2500 CompilerIdCXX
\u2502   \u2502   \u2502       \u251c\u2500\u2500 a.out
\u2502   \u2502   \u2502       \u2514\u2500\u2500 CMakeCXXCompilerId.cpp
\u2502   \u2502   \u251c\u2500\u2500 cmake.check_cache
\u2502   \u2502   \u251c\u2500\u2500 CMakeDirectoryInformation.cmake
\u2502   \u2502   \u251c\u2500\u2500 CMakeError.log
\u2502   \u2502   \u251c\u2500\u2500 CMakeOutput.log
\u2502   \u2502   \u251c\u2500\u2500 CMakeTmp
\u2502   \u2502   \u251c\u2500\u2500 dungeon_rush.dir
\u2502   \u2502   \u2502   \u251c\u2500\u2500 build.make
\u2502   \u2502   \u2502   \u251c\u2500\u2500 C.includecache
\u2502   \u2502   \u2502   \u251c\u2500\u2500 cmake_clean.cmake
\u2502   \u2502   \u2502   \u251c\u2500\u2500 DependInfo.cmake
\u2502   \u2502   \u2502   \u251c\u2500\u2500 depend.internal
\u2502   \u2502   \u2502   \u251c\u2500\u2500 depend.make
\u2502   \u2502   \u2502   \u251c\u2500\u2500 flags.make
\u2502   \u2502   \u2502   \u251c\u2500\u2500 link.txt
\u2502   \u2502   \u2502   \u251c\u2500\u2500 progress.make
\u2502   \u2502   \u2502   \u2514\u2500\u2500 src
\u2502   \u2502   \u2502       \u251c\u2500\u2500 ai.c.o
\u2502   \u2502   \u2502       \u251c\u2500\u2500 audio.c.o
\u2502   \u2502   \u2502       \u251c\u2500\u2500 bullet.c.o
\u2502   \u2502   \u2502       \u251c\u2500\u2500 game.c.o
\u2502   \u2502   \u2502       \u251c\u2500\u2500 helper.c.o
\u2502   \u2502   \u2502       \u251c\u2500\u2500 main.c.o
\u2502   \u2502   \u2502       \u251c\u2500\u2500 map.c.o
\u2502   \u2502   \u2502       \u251c\u2500\u2500 net.c.o
\u2502   \u2502   \u2502       \u251c\u2500\u2500 player.c.o
\u2502   \u2502   \u2502       \u251c\u2500\u2500 prng.c.o
\u2502   \u2502   \u2502       \u251c\u2500\u2500 render.c.o
\u2502   \u2502   \u2502       \u251c\u2500\u2500 res.c.o
\u2502   \u2502   \u2502       \u251c\u2500\u2500 sprite.c.o
\u2502   \u2502   \u2502       \u251c\u2500\u2500 storage.c.o
\u2502   \u2502   \u2502       \u251c\u2500\u2500 types.c.o
\u2502   \u2502   \u2502       \u251c\u2500\u2500 ui.c.o
\u2502   \u2502   \u2502       \u2514\u2500\u2500 weapon.c.o
\u2502   \u2502   \u251c\u2500\u2500 feature_tests.bin
\u2502   \u2502   \u251c\u2500\u2500 feature_tests.c
\u2502   \u2502   \u251c\u2500\u2500 feature_tests.cxx
\u2502   \u2502   \u251c\u2500\u2500 Makefile2
\u2502   \u2502   \u251c\u2500\u2500 Makefile.cmake
\u2502   \u2502   \u251c\u2500\u2500 progress.marks
\u2502   \u2502   \u2514\u2500\u2500 TargetDirectories.txt
\u2502   \u251c\u2500\u2500 cmake_install.cmake
\u2502   \u2514\u2500\u2500 Makefile
\u251c\u2500\u2500 cmake
\u2502   \u2514\u2500\u2500 sdl2
\u2502       \u251c\u2500\u2500 Copyright.txt
\u2502       \u251c\u2500\u2500 FindSDL2.cmake
\u2502       \u251c\u2500\u2500 FindSDL2_gfx.cmake
\u2502       \u251c\u2500\u2500 FindSDL2_image.cmake
\u2502       \u251c\u2500\u2500 FindSDL2_mixer.cmake
\u2502       \u251c\u2500\u2500 FindSDL2_net.cmake
\u2502       \u251c\u2500\u2500 FindSDL2_ttf.cmake
\u2502       \u2514\u2500\u2500 README.md
\u251c\u2500\u2500 CMakeLists.txt
\u251c\u2500\u2500 dungeonrush.desktop
\u251c\u2500\u2500 dungeonrush.png
\u251c\u2500\u2500 LICENSE
\u251c\u2500\u2500 README.md
\u251c\u2500\u2500 res
\u2502   \u251c\u2500\u2500 audio
\u2502   \u2502   \u251c\u2500\u2500 arrow_hit.wav
\u2502   \u2502   \u251c\u2500\u2500 bg1.ogg
\u2502   \u2502   \u251c\u2500\u2500 bg2.ogg
\u2502   \u2502   \u251c\u2500\u2500 bg3.ogg
\u2502   \u2502   \u251c\u2500\u2500 button1.wav
\u2502   \u2502   \u251c\u2500\u2500 claw_hit_heavy.wav
\u2502   \u2502   \u251c\u2500\u2500 claw_hit.wav
\u2502   \u2502   \u251c\u2500\u2500 coin.wav
\u2502   \u2502   \u251c\u2500\u2500 fireball_explosion.wav
\u2502   \u2502   \u251c\u2500\u2500 hit_0.5v.wav
\u2502   \u2502   \u251c\u2500\u2500 human_death.wav
\u2502   \u2502   \u251c\u2500\u2500 ice_shoot_0.5v.wav
\u2502   \u2502   \u251c\u2500\u2500 ice_shoot.wav
\u2502   \u2502   \u251c\u2500\u2500 interaction1_0.75v.wav
\u2502   \u2502   \u251c\u2500\u2500 light_shoot.wav
\u2502   \u2502   \u251c\u2500\u2500 lose_2v.wav
\u2502   \u2502   \u251c\u2500\u2500 main_title.ogg
\u2502   \u2502   \u251c\u2500\u2500 med.wav
\u2502   \u2502   \u251c\u2500\u2500 powerloss.wav
\u2502   \u2502   \u251c\u2500\u2500 shoot.wav
\u2502   \u2502   \u251c\u2500\u2500 sounds
\u2502   \u2502   \u251c\u2500\u2500 sword_hit.wav
\u2502   \u2502   \u251c\u2500\u2500 thunder_2v.wav
\u2502   \u2502   \u2514\u2500\u2500 win.wav
\u2502   \u251c\u2500\u2500 drawable
\u2502   \u2502   \u251c\u2500\u2500 0x72_DungeonTilesetII_v1_3
\u2502   \u2502   \u251c\u2500\u2500 0x72_DungeonTilesetII_v1_3.png
\u2502   \u2502   \u251c\u2500\u2500 arrow
\u2502   \u2502   \u251c\u2500\u2500 arrow.png
\u2502   \u2502   \u251c\u2500\u2500 attack_up
\u2502   \u2502   \u251c\u2500\u2500 attack_up.png
\u2502   \u2502   \u251c\u2500\u2500 Axe
\u2502   \u2502   \u251c\u2500\u2500 Axe.png
\u2502   \u2502   \u251c\u2500\u2500 blood
\u2502   \u2502   \u251c\u2500\u2500 BloodBound
\u2502   \u2502   \u251c\u2500\u2500 BloodBound.png
\u2502   \u2502   \u251c\u2500\u2500 blood.png
\u2502   \u2502   \u251c\u2500\u2500 ClawFx
\u2502   \u2502   \u251c\u2500\u2500 ClawFx2
\u2502   \u2502   \u251c\u2500\u2500 ClawFx2.png
\u2502   \u2502   \u251c\u2500\u2500 ClawFx.png
\u2502   \u2502   \u251c\u2500\u2500 cross_hit
\u2502   \u2502   \u251c\u2500\u2500 cross_hit.png
\u2502   \u2502   \u251c\u2500\u2500 explosion-2
\u2502   \u2502   \u251c\u2500\u2500 explosion-2.png
\u2502   \u2502   \u251c\u2500\u2500 fireball
\u2502   \u2502   \u251c\u2500\u2500 fireball_explosion1
\u2502   \u2502   \u251c\u2500\u2500 fireball_explosion1.png
\u2502   \u2502   \u251c\u2500\u2500 fireball.png
\u2502   \u2502   \u251c\u2500\u2500 floor_exit
\u2502   \u2502   \u251c\u2500\u2500 floor_exit.png
\u2502   \u2502   \u251c\u2500\u2500 floor_spike
\u2502   \u2502   \u251c\u2500\u2500 floor_spike.png
\u2502   \u2502   \u251c\u2500\u2500 golden_cross_hit
\u2502   \u2502   \u251c\u2500\u2500 golden_cross_hit.png
\u2502   \u2502   \u251c\u2500\u2500 halo_explosion1
\u2502   \u2502   \u251c\u2500\u2500 halo_explosion1.png
\u2502   \u2502   \u251c\u2500\u2500 halo_explosion2
\u2502   \u2502   \u251c\u2500\u2500 halo_explosion2.png
\u2502   \u2502   \u251c\u2500\u2500 HolyShield
\u2502   \u2502   \u251c\u2500\u2500 HolyShield.png
\u2502   \u2502   \u251c\u2500\u2500 HpMed
\u2502   \u2502   \u251c\u2500\u2500 HpMed.png
\u2502   \u2502   \u251c\u2500\u2500 Ice
\u2502   \u2502   \u251c\u2500\u2500 IcePick
\u2502   \u2502   \u251c\u2500\u2500 IcePick.png
\u2502   \u2502   \u251c\u2500\u2500 Ice.png
\u2502   \u2502   \u251c\u2500\u2500 IceShatter
\u2502   \u2502   \u251c\u2500\u2500 IceShatter.png
\u2502   \u2502   \u251c\u2500\u2500 powerful_bow
\u2502   \u2502   \u251c\u2500\u2500 powerful_bow.png
\u2502   \u2502   \u251c\u2500\u2500 purple_ball
\u2502   \u2502   \u251c\u2500\u2500 purple_ball.png
\u2502   \u2502   \u251c\u2500\u2500 purple_exp
\u2502   \u2502   \u251c\u2500\u2500 purple_exp.png
\u2502   \u2502   \u251c\u2500\u2500 Shine
\u2502   \u2502   \u251c\u2500\u2500 Shine.png
\u2502   \u2502   \u251c\u2500\u2500 SolidFx
\u2502   \u2502   \u251c\u2500\u2500 SolidFx.png
\u2502   \u2502   \u251c\u2500\u2500 SolidFx.png.bk
\u2502   \u2502   \u251c\u2500\u2500 staff
\u2502   \u2502   \u251c\u2500\u2500 staff.png
\u2502   \u2502   \u251c\u2500\u2500 SwordFx
\u2502   \u2502   \u251c\u2500\u2500 SwordFx.bk
\u2502   \u2502   \u251c\u2500\u2500 SwordFx.png
\u2502   \u2502   \u251c\u2500\u2500 SwordFx.png.bk
\u2502   \u2502   \u251c\u2500\u2500 SwordPack
\u2502   \u2502   \u251c\u2500\u2500 SwordPack.png
\u2502   \u2502   \u251c\u2500\u2500 Thunder
\u2502   \u2502   \u251c\u2500\u2500 Thunder.png
\u2502   \u2502   \u251c\u2500\u2500 Thunder_Yellow
\u2502   \u2502   \u251c\u2500\u2500 Thunder_Yellow.png
\u2502   \u2502   \u251c\u2500\u2500 title
\u2502   \u2502   \u251c\u2500\u2500 title.png
\u2502   \u2502   \u251c\u2500\u2500 ui
\u2502   \u2502   \u2514\u2500\u2500 ui.png
\u2502   \u251c\u2500\u2500 font
\u2502   \u2502   \u2514\u2500\u2500 m5x7.ttf
\u2502   \u2514\u2500\u2500 text.txt
\u251c\u2500\u2500 screenshot.gif
\u2514\u2500\u2500 src
    \u251c\u2500\u2500 adt.h
    \u251c\u2500\u2500 ai.c
    \u251c\u2500\u2500 ai.h
    \u251c\u2500\u2500 audio.c
    \u251c\u2500\u2500 audio.h
    \u251c\u2500\u2500 bullet.c
    \u251c\u2500\u2500 bullet.h
    \u251c\u2500\u2500 game.c
    \u251c\u2500\u2500 game.h
    \u251c\u2500\u2500 helper.c
    \u251c\u2500\u2500 helper.h
    \u251c\u2500\u2500 main.c
    \u251c\u2500\u2500 map.c
    \u251c\u2500\u2500 map.h
    \u251c\u2500\u2500 net.c
    \u251c\u2500\u2500 net.h
    \u251c\u2500\u2500 player.c
    \u251c\u2500\u2500 player.h
    \u251c\u2500\u2500 prng.c
    \u251c\u2500\u2500 prng.h
    \u251c\u2500\u2500 render.c
    \u251c\u2500\u2500 render.h
    \u251c\u2500\u2500 res.c
    \u251c\u2500\u2500 res.h
    \u251c\u2500\u2500 sprite.c
    \u251c\u2500\u2500 sprite.h
    \u251c\u2500\u2500 storage.c
    \u251c\u2500\u2500 storage.h
    \u251c\u2500\u2500 text.h
    \u251c\u2500\u2500 types.c
    \u251c\u2500\u2500 types.h
    \u251c\u2500\u2500 ui.c
    \u251c\u2500\u2500 ui.h
    \u251c\u2500\u2500 weapon.c
    \u2514\u2500\u2500 weapon.h

20 directories, 293 files
shiyanlou:DungeonRush/ (master*) $                                   [20:53:13]
代码语言:javascript
代码运行次数:0
运行
AI代码解释
复制
shiyanlou:build/ (master) $ cmake ..                                 [20:39:08]
CMake Error: Could not find cmake module file: CMakeDetermineDESCRIPTIONCompiler.cmake
CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_DESCRIPTION_COMPILER_ENV_VAR
CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_DESCRIPTION_COMPILER
CMake Error: Could not find cmake module file: /home/shiyanlou/Code/DungeonRush/build/CMakeFiles/3.5.1/CMakeDESCRIPTIONCompiler.cmake
CMake Error: Could not find cmake module file: CMakeDetermineA game inspired by snakeCompiler.cmake
CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_A game inspired by snake_COMPILER_ENV_VAR
CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_A game inspired by snake_COMPILER
CMake Error: Could not find cmake module file: /home/shiyanlou/Code/DungeonRush/build/CMakeFiles/3.5.1/CMakeA game inspired by snakeCompiler.cmake
CMake Error at CMakeLists.txt:2 (project):
  No CMAKE_DESCRIPTION_COMPILER could be found.

  Tell CMake where to find the compiler by setting the CMake cache entry
  CMAKE_DESCRIPTION_COMPILER to the full path to the compiler, or to the
  compiler name if it is in the PATH.


CMake Error: Could not find cmake module file: CMakeDESCRIPTIONInformation.cmake
CMake Error at CMakeLists.txt:2 (project):
  No CMAKE_A game inspired by snake_COMPILER could be found.

  Tell CMake where to find the compiler by setting the CMake cache entry
  CMAKE_A game inspired by snake_COMPILER to the full path to the compiler,
  or to the compiler name if it is in the PATH.


CMake Error: Could not find cmake module file: CMakeA game inspired by snakeInformation.cmake
CMake Error: CMAKE_DESCRIPTION_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_A game inspired by snake_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!
See also "/home/shiyanlou/Code/DungeonRush/build/CMakeFiles/CMakeOutput.log".
shiyanlou:build/ (master) $ cmake ..                                 [20:39:16]
-- The CXX compiler identification is GNU 5.4.0
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found SDL2: /usr/lib/x86_64-linux-gnu/libSDL2.so (found version "2.0.4") 
-- Found SDL2main: /usr/lib/x86_64-linux-gnu/libSDL2main.a (found version "2.0.4") 
-- Found SDL2_image: /usr/lib/x86_64-linux-gnu/libSDL2_image.so (found version "2.0.1") 
-- Found SDL2_net: /usr/lib/x86_64-linux-gnu/libSDL2_net.so (found version "2.0.1") 
-- Found SDL2_mixer: /usr/lib/x86_64-linux-gnu/libSDL2_mixer.so (found version "2.0.1") 
-- Found SDL2_ttf: /usr/lib/x86_64-linux-gnu/libSDL2_ttf.so (found version "2.0.14") 
-- Configuring done
-- Generating done
-- Build files have been written to: /home/shiyanlou/Code/DungeonRush/build
shiyanlou:build/ (master*) $ make                                    [20:40:02]
Scanning dependencies of target dungeon_rush
[  5%] Building C object CMakeFiles/dungeon_rush.dir/src/prng.c.o
[ 11%] Building C object CMakeFiles/dungeon_rush.dir/src/sprite.c.o
[ 16%] Building C object CMakeFiles/dungeon_rush.dir/src/net.c.o
[ 22%] Building C object CMakeFiles/dungeon_rush.dir/src/bullet.c.o
[ 27%] Building C object CMakeFiles/dungeon_rush.dir/src/player.c.o
[ 33%] Building C object CMakeFiles/dungeon_rush.dir/src/ai.c.o
[ 38%] Building C object CMakeFiles/dungeon_rush.dir/src/audio.c.o
[ 44%] Building C object CMakeFiles/dungeon_rush.dir/src/res.c.o
[ 50%] Building C object CMakeFiles/dungeon_rush.dir/src/map.c.o
[ 55%] Building C object CMakeFiles/dungeon_rush.dir/src/game.c.o
[ 61%] Building C object CMakeFiles/dungeon_rush.dir/src/types.c.o
[ 66%] Building C object CMakeFiles/dungeon_rush.dir/src/render.c.o
[ 72%] Building C object CMakeFiles/dungeon_rush.dir/src/weapon.c.o
[ 77%] Building C object CMakeFiles/dungeon_rush.dir/src/main.c.o
[ 83%] Building C object CMakeFiles/dungeon_rush.dir/src/helper.c.o
[ 88%] Building C object CMakeFiles/dungeon_rush.dir/src/storage.c.o
[ 94%] Building C object CMakeFiles/dungeon_rush.dir/src/ui.c.o
[100%] Linking C executable bin/dungeon_rush
[100%] Built target dungeon_rush
shiyanlou:build/ (master*) $ ls                                      [20:40:13]
bin  CMakeCache.txt  CMakeFiles  cmake_install.cmake  Makefile
shiyanlou:build/ (master*) $ cd bin                                  [20:40:22]
shiyanlou:bin/ (master*) $ ls                                        [20:40:26]
dungeon_rush  res
shiyanlou:bin/ (master*) $ ./dungeon_rush                            [20:40:27]
libpng warning: Duplicate iCCP chunk
shiyanlou:bin/ (master*) $ ./dungeon_rush                            [20:43:34]
libpng warning: Duplicate iCCP chunk
shiyanlou:bin/ (master*) $ ./dungeon_rush                            [20:43:48]
libpng warning: Duplicate iCCP chunk
shiyanlou:bin/ (master*) $ ./dungeon_rush                            [20:44:50]
libpng warning: Duplicate iCCP chunk
本文参与 腾讯云自媒体同步曝光计划,分享自作者个人站点/博客。
原始发表:2022-03-25,如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 作者个人站点/博客 前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体同步曝光计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
暂无评论
推荐阅读
编辑精选文章
换一批
快来看看 ECMAScript 2024 (ES15) 发布了什么新特性
2024 年 6 月 26 日,第 127 届 Ecma 大会批准了 ECMAScript 2024 语言规范,这意味着它现在正式成为标准。
前端蛋卷
2024/07/02
4990
快来看看 ECMAScript 2024 (ES15)  发布了什么新特性
【完整汇总】近 5 年 JavaScript 新特性完整总览
本文深度解析近 5 年来 JavaScript 的所有重要更新,帮助你快速了解 JavaScript 新特性。
Immerse
2025/03/04
1900
【完整汇总】近 5 年 JavaScript 新特性完整总览
JavaScript中的ES7/ES8/ES9/ES10
自从前端开发流行起来,前端的各类技术如雨后春笋般出现,让人应接不暇,几年前还是jq一把梭,现在除了三大主流框架var,何种混合开发也接踵而至,还有可能取代JS的TS出现,我们要跟上时代的步伐,了解最新的技术,走在技术的前沿。
刘亦枫
2020/03/19
4.3K0
ECMAScript 2017(ES8) 的新特性总结
Object.values()省去了遍历key,并根据这些key获取value的步骤。
江一铭
2022/06/16
6050
ECMAScript 2017(ES8) 的新特性总结
2022 年 JavaScript 从 ES6 到 ES12 新特性汇总
Javascript 是前端三剑客技术最重要的技能之一。每个学习前端的人,这个JavaScript技术是必须要学的。随着技术不断更新迭代,所以现在有一些新的知识来支持我们去学习 ES6 ~ ES12。
五月君
2022/12/12
1.6K0
2022 年 JavaScript 从 ES6 到 ES12 新特性汇总
JavaScript 又出新特性了?来看看这篇就明白了
https://juejin.im/post/5ca2e1935188254416288eb2
崔庆才
2019/05/06
1.7K0
汇总JS语法 ES6、ES7、ES8、ES9、ES10、ES11、ES12新特性
本文集合了 ES6 至 ES11 常用到的特性,包括还在规划的 ES12,只列举大概使用,详细介绍的话内容量将十分巨大~.~。PS:使用新特性需要使用最新版的 bable 就行转义
coder_koala
2021/03/12
2.7K0
汇总JS语法 ES6、ES7、ES8、ES9、ES10、ES11、ES12新特性
两个新的 JavaScript 提案
今天带大家了解两个刚刚进入 stage3 阶段的新的 JavaScript 语法提案。
ConardLi
2023/08/23
3140
两个新的 JavaScript 提案
ES2024新特性:object.groupBy()让分组更简单
2024年初,JavaScript(也称为Ecma Script)推出了一项全新的内置函数——object.groupBy()。这一创新功能将彻底改变我们对数据进行分组和组织的方式!
前端达人
2024/07/10
4670
ES2024新特性:object.groupBy()让分组更简单
ES6,ES7,ES8,ES9,ES10,ES11,ES12...JS语法汇总集合
ES6,ES7,ES8,ES9,ES10,ES11,ES12...JS语法汇总集合新特性
痴心阿文
2022/11/18
3.7K0
ES6,ES7,ES8,ES9,ES10,ES11,ES12...JS语法汇总集合
查漏补缺喽~JavaScript ES8-10的新特性
引入了async和await关键字,简化异步操作的编写方式,使代码更易读和理解。async函数会返回一个Promise对象,而在async函数内部可以使用await关键字来暂停执行,并等待Promise对象的解析。
肥晨
2023/08/18
3810
查漏补缺喽~JavaScript ES8-10的新特性
ECMAScript 各个主要版本的关键特性概述
ECMAScript 是 JavaScript 的标准规范,各个版本的 ECMAScript 引入了许多新特性和改进。以下是 ECMAScript 各个主要版本的关键特性概述:
jack.yang
2025/04/05
2390
ES6、ES7、ES8、ES9、ES10、ES11、ES12、ES13新特性大全
本文是对 ES6 至 ES13 常用到的特性的总结,关于每个特性的详细内容,都有单独的文章进行详细讲述,可以跳转到具体文章进行学习查看。学习永无止境大家一起努力 。
江一铭
2022/06/16
2.5K0
ES6、ES7、ES8、ES9、ES10、ES11、ES12、ES13新特性大全
从 JavaScript 发展历史中聊 ECMAScript(ES6-ES11) 新功能
JavaScript 是当今使用最广泛的、发展最好的前后端(后端主要是 Nodejs)语言,如果我们想要灵活使用 JavaScript,我们首先需要了解的就是 JavaScript 和 ECMAScript(ES) 的基础知识及发展历程。
coder_koala
2020/03/20
7K0
2022年,马上都ES2022了,还只知道ES6的新特性?
实际上,ES6都是2015年出的规范了,现在都是2022年,还考试这个,未免有些落伍。
伯约同学
2022/02/12
9550
ECMAScript 2017(ES8)新特性简介
ES8是ECMA协会在2017年6月发行的一个版本,因为是ECMAScript的第八个版本,所以也称为ES8.
程序那些事
2021/03/17
6290
[译] ​ES2017 最佳特性 -- 数组中的异步函数以及共享缓冲区
Array.prototype.forEach 并不适用 async 和 await 语法。
江米小枣
2020/11/04
8700
[译] ​ES2017 最佳特性 -- 数组中的异步函数以及共享缓冲区
从ES6到ES10的新特性万字大总结(不得不收藏)
ECMAScript是一种由Ecma国际(前身为欧洲计算机制造商协会)在标准ECMA-262中定义的脚本语言规范。这种语言在万维网上应用广泛,它往往被称为JavaScript或JScript,但实际上后两者是ECMA-262标准的实现和扩展。
陈大鱼头
2020/04/16
2.4K0
告别数据竞争:JavaScript 互斥锁高效解决方案
在单线程的JavaScript世界中,异步编程让并发操作成为可能。随着Node.js的普及和前端复杂度的提升,并发操作无处不在:从用户界面的多个异步请求到服务器端的数据库操作,再到微服务间的通信。然而,这种并发性带来了一个棘手问题——资源竞争(Race Condition)。
叶一一
2025/07/14
2410
告别数据竞争:JavaScript 互斥锁高效解决方案
JavaScript ES9新特性
finally()方法在Promise被解决或拒绝后,无论如何都会执行。它允许你指定在Promise结束时必须执行的清理逻辑。
肥晨
2023/06/27
2790
推荐阅读
相关推荐
快来看看 ECMAScript 2024 (ES15) 发布了什么新特性
更多 >
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档
本文部分代码块支持一键运行,欢迎体验
本文部分代码块支持一键运行,欢迎体验