-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Java3D. Modify .obj file to be compatible with Java3D.
Give up on not checking in dependencies. WIP on #12
- Loading branch information
Andrew Brindamour
committed
Jan 11, 2016
1 parent
bfcf548
commit e99109a
Showing
234 changed files
with
16,912 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,5 +5,4 @@ | |
.project | ||
bin/* | ||
out/* | ||
lib/* | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
build/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
language: java | ||
sudo: false | ||
jdk: | ||
- oraclejdk8 | ||
- oraclejdk7 | ||
- openjdk7 | ||
- openjdk6 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
<project name="artclientlib" basedir="." default="jar"> | ||
<property name="srcPath" value="src"/> | ||
<property name="testPath" value="test"/> | ||
<property name="buildPath" value="build"/> | ||
<property name="buildPath.src" value="${buildPath}/src/classes"/> | ||
<property name="buildPath.test" value="${buildPath}/test/classes"/> | ||
<property name="buildPath.junit" value="junitlib"/> | ||
<property name="jvm.source" value="1.6"/> | ||
<property name="jvm.target" value="1.6"/> | ||
<property name="version" value="2.6.0"/> | ||
|
||
<path id="testBuildClasspath"> | ||
<pathelement path="${buildPath.src}"/> | ||
<fileset dir="${buildPath.junit}"> | ||
<include name="*.jar"/> | ||
</fileset> | ||
</path> | ||
|
||
<path id="testClasspath"> | ||
<pathelement path="${buildPath.src}"/> | ||
<pathelement path="${buildPath.test}"/> | ||
<fileset dir="${buildPath.junit}"> | ||
<include name="*.jar"/> | ||
</fileset> | ||
</path> | ||
|
||
<target name="clean"> | ||
<delete dir="${buildPath}"/> | ||
</target> | ||
|
||
<target name="compile" depends="clean"> | ||
<mkdir dir="${buildPath.src}"/> | ||
<javac srcdir="${srcPath}" destdir="${buildPath.src}" source="${jvm.source}" target="${jvm.target}" includeantruntime="no" debug="yes" debuglevel="lines,vars,source"/> | ||
<copy todir="${buildPath.src}"> | ||
<fileset dir="${srcPath}"> | ||
<exclude name="**/*.java"/> | ||
</fileset> | ||
</copy> | ||
</target> | ||
|
||
<target name="compileTest" depends="compile"> | ||
<mkdir dir="${buildPath.test}"/> | ||
<javac srcdir="${testPath}" destdir="${buildPath.test}" source="${jvm.source}" target="${jvm.target}" includeantruntime="yes" debug="yes" debuglevel="lines,vars,source"> | ||
<classpath refid="testBuildClasspath"/> | ||
</javac> | ||
<copy todir="${buildPath.test}"> | ||
<fileset dir="${testPath}"> | ||
<exclude name="**/*.java"/> | ||
</fileset> | ||
</copy> | ||
</target> | ||
|
||
<target name="test" depends="compileTest"> | ||
<junit> | ||
<formatter type="plain" usefile="false"/> | ||
<classpath refid="testClasspath"/> | ||
<batchtest> | ||
<fileset dir="${testPath}"> | ||
<include name="**/*Test.java"/> | ||
</fileset> | ||
</batchtest> | ||
</junit> | ||
</target> | ||
|
||
<target name="jar" depends="test"> | ||
<jar destfile="${buildPath}/${ant.project.name}-${version}.jar" basedir="${buildPath.src}"/> | ||
</target> | ||
</project> |
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
ArtClientLib | ||
============ | ||
[![Build Status](https://secure.travis-ci.org/rjwut/ArtClientLib.svg)](http://travis-ci.org/rjwut/ArtClientLib) | ||
|
||
**ArtClientLib** is an _unofficial_ Java library for communicating with [Artemis Spaceship Bridge Simulator](http://www.artemis.eochu.com/) servers and clients. | ||
|
||
Documentation for the project is found on the [wiki](https://github.com/rjwut/ArtClientLib/wiki). Please also read the [disclaimer](https://github.com/rjwut/ArtClientLib/wiki/Disclaimer) before using ArtClientLib. | ||
|
||
ArtClientLib does not maintain backwards compatibility when updating for new versions of Artemis. The current release supports version 2.1.1. The list below provides links to the latest release of ArtClientLib to support various previous versions. Keep in mind that current documentation will differ significantly from these past versions. | ||
|
||
* Artemis v2.1: [ArtClientLib v2.4.0](https://github.com/rjwut/ArtClientLib/releases/tag/v2.4.0) | ||
* Artemis v2.0: [ArtClientLib v2.3.0](https://github.com/rjwut/ArtClientLib/releases/tag/v2.3.0) | ||
* Artemis v1.x: [ArtClientLib v1.x](https://github.com/dhleong/ArtClientLib) (by Daniel Leong) | ||
|
||
ArtClientLib was originally developed by Daniel Leong and released on GitHub with permission of the developer of Artemis, Thom Robertson. |
6 changes: 6 additions & 0 deletions
6
lib/ArtClientLib-2.6.0/src/net/dhleong/acl/enums/AlertStatus.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
package net.dhleong.acl.enums; | ||
|
||
public enum AlertStatus { | ||
NORMAL, | ||
RED | ||
} |
6 changes: 6 additions & 0 deletions
6
lib/ArtClientLib-2.6.0/src/net/dhleong/acl/enums/AudioCommand.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
package net.dhleong.acl.enums; | ||
|
||
public enum AudioCommand { | ||
PLAY, | ||
DISMISS | ||
} |
6 changes: 6 additions & 0 deletions
6
lib/ArtClientLib-2.6.0/src/net/dhleong/acl/enums/AudioMode.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
package net.dhleong.acl.enums; | ||
|
||
public enum AudioMode { | ||
PLAYING, | ||
INCOMING | ||
} |
40 changes: 40 additions & 0 deletions
40
lib/ArtClientLib-2.6.0/src/net/dhleong/acl/enums/BaseMessage.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
package net.dhleong.acl.enums; | ||
|
||
/** | ||
* Messages that can be sent to bases. | ||
* @author rjwut | ||
*/ | ||
public enum BaseMessage implements CommsMessage { | ||
STAND_BY_FOR_DOCKING("Stand by for docking."), | ||
PLEASE_REPORT_STATUS("Please report status."), | ||
BUILD_HOMING_MISSILES("Please build type 1 homing ordnance for us."), | ||
BUILD_NUKES("Please build type 4 nuke ordnance for us."), | ||
BUILD_MINES("Please build type 6 mine ordnance for us."), | ||
BUILD_EMPS("Please build type 9 EMP ordnance for us."); | ||
|
||
private String label; | ||
|
||
BaseMessage(String label) { | ||
this.label = label; | ||
} | ||
|
||
@Override | ||
public String toString() { | ||
return label; | ||
} | ||
|
||
@Override | ||
public boolean hasArgument() { | ||
return false; | ||
} | ||
|
||
@Override | ||
public int getId() { | ||
return ordinal(); | ||
} | ||
|
||
@Override | ||
public CommsRecipientType getRecipientType() { | ||
return CommsRecipientType.BASE; | ||
} | ||
} |
9 changes: 9 additions & 0 deletions
9
lib/ArtClientLib-2.6.0/src/net/dhleong/acl/enums/BeamFrequency.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
package net.dhleong.acl.enums; | ||
|
||
/** | ||
* The available frequencies to which beams can be tuned. | ||
* @author rjwut | ||
*/ | ||
public enum BeamFrequency { | ||
A, B, C, D, E | ||
} |
23 changes: 23 additions & 0 deletions
23
lib/ArtClientLib-2.6.0/src/net/dhleong/acl/enums/CommsMessage.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package net.dhleong.acl.enums; | ||
|
||
/** | ||
* All messages that can be sent over COMMs implement this interface. | ||
* @author rjwut | ||
*/ | ||
public interface CommsMessage { | ||
/** | ||
* Returns the ID of this CommsMessage. IDs are unique per | ||
* CommsRecipientType. | ||
*/ | ||
public int getId(); | ||
|
||
/** | ||
* Returns the CommsTargetType that can recieve this CommsMessage. | ||
*/ | ||
public CommsRecipientType getRecipientType(); | ||
|
||
/** | ||
* Returns whether or not this message has an argument. | ||
*/ | ||
public boolean hasArgument(); | ||
} |
84 changes: 84 additions & 0 deletions
84
lib/ArtClientLib-2.6.0/src/net/dhleong/acl/enums/CommsRecipientType.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
package net.dhleong.acl.enums; | ||
|
||
import net.dhleong.acl.util.BoolState; | ||
import net.dhleong.acl.vesseldata.Vessel; | ||
import net.dhleong.acl.world.ArtemisNpc; | ||
import net.dhleong.acl.world.ArtemisObject; | ||
|
||
/** | ||
* The types of ArtemisObjects to which players can send COMMs messages. | ||
* @author rjwut | ||
*/ | ||
public enum CommsRecipientType { | ||
/** | ||
* Other player ships | ||
*/ | ||
PLAYER { | ||
@Override | ||
public CommsMessage messageFromId(int id) { | ||
return PlayerMessage.values()[id]; | ||
} | ||
}, | ||
/** | ||
* NCP enemy ships | ||
*/ | ||
ENEMY { | ||
@Override | ||
public CommsMessage messageFromId(int id) { | ||
return EnemyMessage.values()[id]; | ||
} | ||
}, | ||
/** | ||
* Bases | ||
*/ | ||
BASE { | ||
@Override | ||
public CommsMessage messageFromId(int id) { | ||
return BaseMessage.values()[id]; | ||
} | ||
}, | ||
/** | ||
* Other (civilian NPCs) | ||
*/ | ||
OTHER { | ||
@Override | ||
public CommsMessage messageFromId(int id) { | ||
return OtherMessage.fromId(id); | ||
} | ||
}; | ||
|
||
/** | ||
* Returns the CommsRecipientType that corresponds to the given | ||
* ArtemisObject; or null if the object in question cannot receive COMMs | ||
* messages. | ||
*/ | ||
public static CommsRecipientType fromObject(ArtemisObject obj) { | ||
ObjectType type = obj.getType(); | ||
|
||
switch (type) { | ||
case PLAYER_SHIP: | ||
return PLAYER; | ||
case BASE: | ||
return BASE; | ||
case NPC_SHIP: | ||
ArtemisNpc npc = (ArtemisNpc) obj; | ||
Vessel vessel = npc.getVessel(); | ||
boolean enemy; | ||
|
||
if (vessel != null) { | ||
enemy = vessel.getFaction().is(FactionAttribute.ENEMY); | ||
} else { | ||
enemy = BoolState.safeValue(npc.isEnemy()); | ||
} | ||
|
||
return enemy ? ENEMY : OTHER; | ||
default: | ||
return null; | ||
} | ||
} | ||
|
||
/** | ||
* Returns the CommsMessage value that corresponds to the given message ID. | ||
*/ | ||
public abstract CommsMessage messageFromId(int id); | ||
} |
37 changes: 37 additions & 0 deletions
37
lib/ArtClientLib-2.6.0/src/net/dhleong/acl/enums/ConnectionType.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
package net.dhleong.acl.enums; | ||
|
||
/** | ||
* Represents the type of the machine found at the opposite end of a connection. | ||
* @author rjwut | ||
*/ | ||
public enum ConnectionType { | ||
SERVER, CLIENT; | ||
|
||
/** | ||
* Returns the ConnectionType that corresponds to the given int value. | ||
*/ | ||
public static final ConnectionType fromInt(int value) { | ||
return value == 1 ? SERVER : (value == 2 ? CLIENT : null); | ||
} | ||
|
||
private int val; | ||
|
||
ConnectionType() { | ||
val = ordinal() + 1; | ||
} | ||
|
||
/** | ||
* Returns the int value for this ConnectionType. | ||
*/ | ||
public int toInt() { | ||
return val; | ||
} | ||
|
||
/** | ||
* Returns the opposite ConnectionType to this one: SERVER.opposite() | ||
* returns CLIENT and vice-versa. | ||
*/ | ||
public ConnectionType opposite() { | ||
return this == SERVER ? CLIENT : SERVER; | ||
} | ||
} |
29 changes: 29 additions & 0 deletions
29
lib/ArtClientLib-2.6.0/src/net/dhleong/acl/enums/Console.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
package net.dhleong.acl.enums; | ||
|
||
/** | ||
* The bridge conoles. | ||
* @author rjwut | ||
*/ | ||
public enum Console { | ||
MAIN_SCREEN("Main screen"), | ||
HELM("Helm"), | ||
WEAPONS("Weapons"), | ||
ENGINEERING("Engineering"), | ||
SCIENCE("Science"), | ||
COMMUNICATIONS("Communications"), | ||
DATA("Data"), | ||
OBSERVER("Observer"), | ||
CAPTAINS_MAP("Captain's map"), | ||
GAME_MASTER("Game master"); | ||
|
||
private String label; | ||
|
||
Console(String label) { | ||
this.label = label; | ||
} | ||
|
||
@Override | ||
public String toString() { | ||
return label; | ||
} | ||
} |
Oops, something went wrong.