I was importing the source code of a Java game to my local IntelliJ (community edition 2.3.2019) and try to make it run.
(我正在将Java游戏的源代码导入本地IntelliJ(社区版本2.3.2019),并尝试使其运行。)
I'm new to Java btw. (我是Java的新手。)
I got the code from here: https://github.com/janbodnar/Java-Space-Invaders (我从这里获得了代码: https : //github.com/janbodnar/Java-Space-Invaders)
What I did is download the code from the repo, export the zip file in a folder and import it as a project in IntelliJ.
(我所做的就是从存储库中下载代码,将zip文件导出到一个文件夹中,然后将其导入为IntelliJ中的项目。)
After importing a lot of my project files appear red as you can see here: IntelliJ red icons (导入后,很多项目文件都显示为红色,如下所示: IntelliJ红色图标)
My first question is: Why are these icons red?
(我的第一个问题是:为什么这些图标是红色的?)
And how can I find out why IntelliJ is marking them red? (我如何找出IntelliJ为什么将它们标记为红色?)
I tried by hovering over these icons, but nothing happens / indicates what's wrong. (我将鼠标悬停在这些图标上,但没有任何反应/表明出了什么问题。)
Also: Afaik in order to make this project run I need to take care of the run configuration.
(另外:Afaik为了使这个项目运行,我需要注意运行配置。)
I tried this, but the main class is not choosable if I choose the path com.zetcode.SpaceInvaders.java (where the main class is part of the code). (我试过了,但是如果我选择路径com.zetcode.SpaceInvaders.java(其中主类是代码的一部分),则主类是不可选的。)
What am I doing wrong?
(我究竟做错了什么?)
How can I run this project/code in IntelliJ? (如何在IntelliJ中运行此项目/代码?)
Many thanks in advance.
(提前谢谢了。)
ask by doct0re translate from so 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…