Include framework for Controller/Joystick/Device support. Add in
dependencies for Windows Libraries. Need to implement cross-platform libraries and provide a java system path (instead of root path)
This commit is contained in:
parent
222de35e80
commit
a96e8ad323
@ -5,5 +5,7 @@
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8"/>
|
||||
<classpathentry kind="lib" path="lib/commons-io-2.5.jar"/>
|
||||
<classpathentry kind="lib" path="lib/twitch-api-wrapper-0.3-jar-with-dependencies.jar"/>
|
||||
<classpathentry kind="lib" path="C:/Users/Joshua Sigona/git/sigIRCv2/lib/jinput-2.0.5.jar"/>
|
||||
<classpathentry kind="lib" path="C:/Users/Joshua Sigona/git/sigIRCv2/lib/jutils-1.0.0.jar"/>
|
||||
<classpathentry kind="output" path="bin"/>
|
||||
</classpath>
|
||||
|
5
.gitignore
vendored
5
.gitignore
vendored
@ -9,3 +9,8 @@
|
||||
/update.png
|
||||
/WSplits
|
||||
/drag_bar.png
|
||||
/jinput-dx8.dll
|
||||
/jinput-dx8_64.dll
|
||||
/jinput-raw.dll
|
||||
/jinput-raw_64.dll
|
||||
/jinput-wintab.dll
|
||||
|
BIN
lib/jinput-2.0.5.jar
Normal file
BIN
lib/jinput-2.0.5.jar
Normal file
Binary file not shown.
BIN
lib/jutils-1.0.0.jar
Normal file
BIN
lib/jutils-1.0.0.jar
Normal file
Binary file not shown.
@ -15,6 +15,8 @@
|
||||
<fileset dir="${dir.jarfile}/bin"/>
|
||||
<zipfileset excludes="META-INF/*.SF" src="lib/commons-io-2.5.jar"/>
|
||||
<zipfileset excludes="META-INF/*.SF" src="lib/twitch-api-wrapper-0.3-jar-with-dependencies.jar"/>
|
||||
<zipfileset excludes="META-INF/*.SF" src="lib/jinput-2.0.5.jar"/>
|
||||
<zipfileset excludes="META-INF/*.SF" src="lib/jutils-1.0.0.jar"/>
|
||||
</jar>
|
||||
</target>
|
||||
</project>
|
||||
|
@ -1 +1 @@
|
||||
java -jar ./sigIRCv2.jar
|
||||
java -jar ./sigIRCv2.jar -Djava.library.path=lib/
|
BIN
sigIRCv2.jar
BIN
sigIRCv2.jar
Binary file not shown.
@ -161,7 +161,6 @@ public class MyPanel extends JPanel implements MouseListener, ActionListener, Mo
|
||||
|
||||
@Override
|
||||
public void keyTyped(KeyEvent e) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
|
27
src/sig/modules/ControllerModule.java
Normal file
27
src/sig/modules/ControllerModule.java
Normal file
@ -0,0 +1,27 @@
|
||||
package sig.modules;
|
||||
|
||||
import java.awt.Graphics;
|
||||
import java.awt.geom.Rectangle2D;
|
||||
|
||||
import net.java.games.input.Controller;
|
||||
import net.java.games.input.ControllerEnvironment;
|
||||
import sig.Module;
|
||||
|
||||
public class ControllerModule extends Module{
|
||||
|
||||
public ControllerModule(Rectangle2D bounds, String moduleName) {
|
||||
super(bounds, moduleName);
|
||||
Controller[] ca = ControllerEnvironment.getDefaultEnvironment().getControllers();
|
||||
for (Controller c : ca) {
|
||||
System.out.println(c.getName());
|
||||
}
|
||||
}
|
||||
|
||||
public void run() {
|
||||
super.run();
|
||||
}
|
||||
|
||||
public void draw(Graphics g) {
|
||||
super.draw(g);
|
||||
}
|
||||
}
|
@ -14,6 +14,7 @@ import com.mb3364.twitch.api.models.Channel;
|
||||
import com.mb3364.twitch.api.models.Stream;
|
||||
|
||||
import sig.modules.ChatLogModule;
|
||||
import sig.modules.ControllerModule;
|
||||
import sig.modules.TouhouMotherModule;
|
||||
import sig.modules.TwitchModule;
|
||||
import sig.modules.ChatLog.ChatLogMessage;
|
||||
@ -116,6 +117,11 @@ public class sigIRC{
|
||||
public static int chatlogmodule_X=0;
|
||||
public static int chatlogmodule_Y=312;
|
||||
public static int chatlogMessageHistory=50;
|
||||
public static boolean controllermodule_enabled=true;
|
||||
public static int controllermodule_width=320;
|
||||
public static int controllermodule_height=312;
|
||||
public static int controllermodule_X=0;
|
||||
public static int controllermodule_Y=312;
|
||||
public static String twitchmodule_newfollowerImgBackgroundColor="90,90,90";
|
||||
public static String twitchmodule_newfollowerShadowTextColor="26,90,150";
|
||||
public static String twitchmodule_newfollowerTextColor="255,255,255";
|
||||
@ -183,6 +189,10 @@ public class sigIRC{
|
||||
chatlogmodule_Y = config.getInteger("CHATLOG_module_Y",312);
|
||||
chatlogmodule_width = config.getInteger("CHATLOG_module_width",320);
|
||||
chatlogmodule_height = config.getInteger("CHATLOG_module_height",312);
|
||||
controllermodule_X = config.getInteger("CONTROLLER_module_X",0);
|
||||
controllermodule_Y = config.getInteger("CONTROLLER_module_Y",312);
|
||||
controllermodule_width = config.getInteger("CONTROLLER_module_width",320);
|
||||
controllermodule_height = config.getInteger("CONTROLLER_module_height",312);
|
||||
chatlogmodule_backgroundColor = config.getProperty("CHATLOG_module_BackgroundColor", "195,195,195,255");
|
||||
chatlogMessageHistory = config.getInteger("CHATLOG_module_MessageHistory",50);
|
||||
hardwareAcceleration = config.getBoolean("hardware_acceleration",true);
|
||||
@ -256,7 +266,11 @@ public class sigIRC{
|
||||
manager = new FileManager("update.png"); manager.verifyAndFetchFileFromServer();
|
||||
manager = new FileManager("backcolor.png"); manager.verifyAndFetchFileFromServer();
|
||||
manager = new FileManager("drag_bar.png"); manager.verifyAndFetchFileFromServer();
|
||||
manager = new FileManager("WSplits"); manager.verifyAndFetchFileFromServer();
|
||||
manager = new FileManager("jinput-dx8.dll"); manager.verifyAndFetchFileFromServer();
|
||||
manager = new FileManager("jinput-dx8_64.dll"); manager.verifyAndFetchFileFromServer();
|
||||
manager = new FileManager("jinput-raw.dll"); manager.verifyAndFetchFileFromServer();
|
||||
manager = new FileManager("jinput-raw_64.dll"); manager.verifyAndFetchFileFromServer();
|
||||
manager = new FileManager("jinput-wintab.dll"); manager.verifyAndFetchFileFromServer();
|
||||
DownloadProgramUpdate();
|
||||
System.out.println("Downloaded Dependencies. ");
|
||||
}
|
||||
@ -310,6 +324,12 @@ public class sigIRC{
|
||||
"Chat Log"
|
||||
));
|
||||
}
|
||||
if (controllermodule_enabled) {
|
||||
modules.add(new ControllerModule(
|
||||
new Rectangle(controllermodule_X,controllermodule_Y,controllermodule_width,controllermodule_height),
|
||||
"Controller"
|
||||
));
|
||||
}
|
||||
}
|
||||
|
||||
private static void InitializeCustomSounds() {
|
||||
|
Loading…
x
Reference in New Issue
Block a user