fix: changed package name
This commit is contained in:
parent
64b487f80d
commit
a2b1108ad5
|
@ -1,4 +1,4 @@
|
||||||
package bzh.fainsin.sagittarius;
|
package sagittarius;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
|
||||||
|
@ -106,9 +106,9 @@ class Arrow extends Entity {
|
||||||
path.add(dummyArrow.position.y);
|
path.add(dummyArrow.position.y);
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO : optimize, lots of useless stuff
|
// TODO : optimize, lots of useless stuff + change name
|
||||||
|
|
||||||
final float[] arr = new float[path.size()]; // TODO : min with 2, Exception in thread "main" java.lang.IllegalArgumentException: Polylines must contain at least 2 points.
|
final float[] arr = new float[path.size()];
|
||||||
int index = 0;
|
int index = 0;
|
||||||
for (final Float value: path) {
|
for (final Float value: path) {
|
||||||
arr[index++] = value;
|
arr[index++] = value;
|
|
@ -1,4 +1,4 @@
|
||||||
package bzh.fainsin.sagittarius;
|
package sagittarius;
|
||||||
|
|
||||||
import com.badlogic.gdx.Gdx;
|
import com.badlogic.gdx.Gdx;
|
||||||
import com.badlogic.gdx.Input.Buttons;
|
import com.badlogic.gdx.Input.Buttons;
|
||||||
|
@ -56,7 +56,7 @@ class Bow {
|
||||||
public void render(ShapeRenderer shapeRenderer) {
|
public void render(ShapeRenderer shapeRenderer) {
|
||||||
if (pressed) {
|
if (pressed) {
|
||||||
shapeRenderer.line(this.anchor, SagittariusGame.worldCursor);
|
shapeRenderer.line(this.anchor, SagittariusGame.worldCursor);
|
||||||
float[] traj = Arrow.traj(angle, power, shooter, 250, 0.05f);
|
float[] traj = Arrow.traj(angle, power, shooter, 400, 0.05f);
|
||||||
if (traj.length > 2) {
|
if (traj.length > 2) {
|
||||||
shapeRenderer.polyline(traj);
|
shapeRenderer.polyline(traj);
|
||||||
}
|
}
|
|
@ -1,4 +1,4 @@
|
||||||
package bzh.fainsin.sagittarius;
|
package sagittarius;
|
||||||
|
|
||||||
import com.badlogic.gdx.graphics.Color;
|
import com.badlogic.gdx.graphics.Color;
|
||||||
import com.badlogic.gdx.math.Vector2;
|
import com.badlogic.gdx.math.Vector2;
|
|
@ -1,4 +1,4 @@
|
||||||
package bzh.fainsin.sagittarius;
|
package sagittarius;
|
||||||
|
|
||||||
import com.badlogic.gdx.Gdx;
|
import com.badlogic.gdx.Gdx;
|
||||||
import com.badlogic.gdx.ScreenAdapter;
|
import com.badlogic.gdx.ScreenAdapter;
|
|
@ -1,4 +1,4 @@
|
||||||
package bzh.fainsin.sagittarius;
|
package sagittarius;
|
||||||
|
|
||||||
import com.badlogic.gdx.Gdx;
|
import com.badlogic.gdx.Gdx;
|
||||||
import com.badlogic.gdx.graphics.g2d.Batch;
|
import com.badlogic.gdx.graphics.g2d.Batch;
|
||||||
|
@ -27,7 +27,7 @@ class HUD implements Disposable {
|
||||||
// framerate
|
// framerate
|
||||||
font.draw(batch, frameRate + " fps", 3, Gdx.graphics.getHeight() - 3);
|
font.draw(batch, frameRate + " fps", 3, Gdx.graphics.getHeight() - 3);
|
||||||
|
|
||||||
// cursor positions
|
// cursor positions, oui c'est dégueu
|
||||||
font.draw(batch, "x_r = " + (int) SagittariusGame.screenCursor.x + ", y_r = " + (int) SagittariusGame.screenCursor.y, SagittariusGame.screenCursor.x + 5, Gdx.graphics.getHeight() - SagittariusGame.screenCursor.y + 5);
|
font.draw(batch, "x_r = " + (int) SagittariusGame.screenCursor.x + ", y_r = " + (int) SagittariusGame.screenCursor.y, SagittariusGame.screenCursor.x + 5, Gdx.graphics.getHeight() - SagittariusGame.screenCursor.y + 5);
|
||||||
font.draw(batch, "x_g = " + (int) SagittariusGame.worldCursor.x + ", y_g = " + (int) SagittariusGame.worldCursor.y, SagittariusGame.screenCursor.x + 5, Gdx.graphics.getHeight() - SagittariusGame.screenCursor.y + 20);
|
font.draw(batch, "x_g = " + (int) SagittariusGame.worldCursor.x + ", y_g = " + (int) SagittariusGame.worldCursor.y, SagittariusGame.screenCursor.x + 5, Gdx.graphics.getHeight() - SagittariusGame.screenCursor.y + 20);
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
package bzh.fainsin.sagittarius;
|
package sagittarius;
|
||||||
|
|
||||||
import com.badlogic.gdx.graphics.Color;
|
import com.badlogic.gdx.graphics.Color;
|
||||||
import com.badlogic.gdx.graphics.g2d.Batch;
|
import com.badlogic.gdx.graphics.g2d.Batch;
|
|
@ -1,4 +1,4 @@
|
||||||
package bzh.fainsin.sagittarius;
|
package sagittarius;
|
||||||
|
|
||||||
import com.badlogic.gdx.Gdx;
|
import com.badlogic.gdx.Gdx;
|
||||||
import com.badlogic.gdx.Input.Keys;
|
import com.badlogic.gdx.Input.Keys;
|
|
@ -1,4 +1,4 @@
|
||||||
package bzh.fainsin.sagittarius;
|
package sagittarius;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
|
@ -2,7 +2,7 @@ sourceCompatibility = 1.15
|
||||||
sourceSets.main.java.srcDirs = [ "src/" ]
|
sourceSets.main.java.srcDirs = [ "src/" ]
|
||||||
sourceSets.main.resources.srcDirs = ["../core/assets"]
|
sourceSets.main.resources.srcDirs = ["../core/assets"]
|
||||||
|
|
||||||
project.ext.mainClassName = "bzh.fainsin.sagittarius.desktop.DesktopLauncher"
|
project.ext.mainClassName = "sagittarius.desktop.DesktopLauncher"
|
||||||
project.ext.assetsDir = new File("../core/assets")
|
project.ext.assetsDir = new File("../core/assets")
|
||||||
|
|
||||||
task run(dependsOn: classes, type: JavaExec) {
|
task run(dependsOn: classes, type: JavaExec) {
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
package bzh.fainsin.sagittarius.desktop;
|
package sagittarius.desktop;
|
||||||
|
|
||||||
import com.badlogic.gdx.backends.lwjgl3.Lwjgl3Application;
|
import com.badlogic.gdx.backends.lwjgl3.Lwjgl3Application;
|
||||||
import com.badlogic.gdx.backends.lwjgl3.Lwjgl3ApplicationConfiguration;
|
import com.badlogic.gdx.backends.lwjgl3.Lwjgl3ApplicationConfiguration;
|
||||||
import bzh.fainsin.sagittarius.SagittariusGame;
|
import sagittarius.SagittariusGame;
|
||||||
|
|
||||||
public class DesktopLauncher {
|
public class DesktopLauncher {
|
||||||
public static void main(String[] arg) {
|
public static void main(String[] arg) {
|
Loading…
Reference in a new issue