因为是自学Android自然是想找一些源代码,自己跑着试试,然后自己再去解读这些代码~~
本着这样的想法,于是就在Github上找了一个Android的小游戏
https://github.com/HurTeng/StormPlane 连接奉上~~ -。-
高高兴兴的下完源代码,就想导入AS中跑跑看。。。
万万没想到。。。出现各种破事
一开始用Genymotion,创建三星 Galaxy S8 -8.0-API 26的虚拟机
点击开始按钮后报错
Unable to start the virtual device
Virtualbox cannot start the virtual device .Your CPU is incompatible with virtualization technologies.For more information, check the log files. Please refer to: www.genvmotion com/OK
emmmm。。。。说是CPU不兼容什么乱七八糟的
找了半天终于找到解决办法 http://blog.csdn.net/tlh0212/article/details/47173377
到此Genymotion就没出啥问题了
然后在AndroidStudio开始导入项目文件,发现运行按钮是灰的0.0 边上也没有app那个东西,还报了个什么错给忘记了= =
android studio导入其他项目工程报错解决方法
http://blog.csdn.net/fan7983377/article/details/51679199
嗯嗯~~~继续粘上传送门~~
不过我没有按照他说的吧那些东西给删了0.0
继续运行依然报错
Failed to resolve: com.android.support:support-v4:18.0.0
话多不说,连接奉上
https://www.cnblogs.com/apptao/p/5231184.html
发现是SDK Manager 里少下了个东西 就是那个Android Support Repository
然后下载不了- -......
总会有解决方法的
在SDK Manager里的Tools中选择Options
mirrors.zzu.edu.cn
80
在把下面勾给勾上~~~
下完之后,发现可以在虚拟机上跑出来了
但是!!!!!
Invalid VCS root mapping
The directory D:\AndroidStudioProjects\StormPlane-master is registered as a Git root, but no Git repositories were found there.
。。。。。。。。。。。。。
http://blog.csdn.net/weixin_37771550/article/details/78212461
跟着走,发现并没有git.exe这个东西
于是
http://blog.csdn.net/Carol_1992/article/details/75174518
嗯。。。在最后面,六那里~~~
至此。。。虽然还有点问题。。。但程序是扣以跑起来的0.0虽然有点卡(是很卡= =)
O那啥K。。。下一次就发代码分析了-。-