如何在Intellij IDEA中设置JMonkeyEngine。在文档(http://hub.jmonkeyengine.org/wiki/doku.php/)中未指定。
最佳答案
现在,如果您使用Maven或Gradle,这很容易。
Maven的简单pom.xml:
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.mycompany</groupId>
<artifactId>jme3-example</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>jar</packaging>
<name>JME3 maven project</name>
<properties>
<jme3.version>3.0.10</jme3.version>
</properties>
<dependencies>
<dependency>
<groupId>com.jme3</groupId>
<artifactId>jme3-core</artifactId>
<version>${jme3.version}</version>
</dependency>
<dependency>
<groupId>com.jme3</groupId>
<artifactId>jme3-desktop</artifactId>
<version>${jme3.version}</version>
</dependency>
<dependency>
<groupId>com.jme3</groupId>
<artifactId>jme3-lwjgl</artifactId>
<version>${jme3.version}</version>
</dependency>
</dependencies>
<repositories>
<repository>
<id>jme3-repo</id>
<name>JME3 maven repo</name>
<url>http://updates.jmonkeyengine.org/maven/</url>
</repository>
</repositories>
</project>
注0: JME 3.1已部署在JCenter上
注1:将JMonkeyEngine官方Wiki移至https://jmonkeyengine.github.io/wiki/
这里记录了Gradle配置和其他Maven依赖项:https://jmonkeyengine.github.io/wiki/jme3/maven.html
如果您以前没有使用过Maven或Gradle,请学习它:)