Bladeren bron

Resources

frans 8 jaren geleden
bovenliggende
commit
4dc03693bd
5 gewijzigde bestanden met toevoegingen van 39 en 12 verwijderingen
  1. 1 1
      .classpath
  2. 0 2
      .gitignore
  3. 37 4
      pom.xml
  4. BIN
      res/white.png
  5. 1 5
      src/eu/tankernn/pong/Pong.java

+ 1 - 1
.classpath

@@ -6,7 +6,7 @@
 			<attribute name="maven.pomderived" value="true"/>
 		</attributes>
 	</classpathentry>
-	<classpathentry kind="lib" path="target/tankernn-pong-0.0.1.jar"/>
+	<classpathentry kind="src" path="res"/>
 	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8">
 		<attributes>
 			<attribute name="maven.pomderived" value="true"/>

+ 0 - 2
.gitignore

@@ -1,7 +1,5 @@
 /bin/
 /target/
-/res/
-res
 .project
 .settings
 .DS_Store

+ 37 - 4
pom.xml

@@ -24,14 +24,34 @@
 	</dependencies>
 
 	<build>
+		<finalName>${project.artifactId}-${project.version}.${build.number}</finalName>
 		<sourceDirectory>src</sourceDirectory>
 		<plugins>
 			<plugin>
-				<artifactId>maven-compiler-plugin</artifactId>
-				<version>3.5.1</version>
+				<artifactId>maven-assembly-plugin</artifactId>
+				<executions>
+					<execution>
+						<phase>package</phase>
+						<goals>
+							<goal>single</goal>
+						</goals>
+						<configuration>
+							<archive>
+								<manifest>
+									<addClasspath>true</addClasspath>
+									<mainClass>eu.tankernn.pong.Pong</mainClass>
+								</manifest>
+							</archive>
+							<!-- The filename of the assembled distribution file default ${project.build.finalName} -->
+							<finalName>${project.build.finalName}</finalName>
+							<appendAssemblyId>false</appendAssemblyId>
+						</configuration>
+					</execution>
+				</executions>
 				<configuration>
-					<source>1.8</source>
-					<target>1.8</target>
+					<descriptorRefs>
+						<descriptorRef>jar-with-dependencies</descriptorRef>
+					</descriptorRefs>
 				</configuration>
 			</plugin>
 			<plugin>
@@ -49,5 +69,18 @@
 				</executions>
 			</plugin>
 		</plugins>
+		<resources>
+			<resource>
+				<directory>res</directory>
+				<excludes>
+				</excludes>
+			</resource>
+		</resources>
 	</build>
+
+	<properties>
+		<maven.compiler.source>1.8</maven.compiler.source>
+		<maven.compiler.target>1.8</maven.compiler.target>
+		<build.number>SNAPSHOT</build.number>
+	</properties>
 </project>

BIN
res/white.png


+ 1 - 5
src/eu/tankernn/pong/Pong.java

@@ -87,15 +87,11 @@ public class Pong extends TankernnGame {
 	public void render() {
 		glClearColor(0, 0, 0, 1);
 		glClear(GL11.GL_COLOR_BUFFER_BIT | GL11.GL_DEPTH_BUFFER_BIT);
-
-		guiMaster.render();
-		textMaster.render();
+		
 		super.render();
 	}
 
 	public void cleanUp() {
-		guiMaster.cleanUp();
-		textMaster.cleanUp();
 		super.cleanUp();
 	}