diff --git a/android/assets/1280x720/PolyjetTitle.png b/android/assets/1280x720/PolyjetTitle.png old mode 100755 new mode 100644 index 7320f6a..ea10cf1 Binary files a/android/assets/1280x720/PolyjetTitle.png and b/android/assets/1280x720/PolyjetTitle.png differ diff --git a/android/assets/1280x720/Tech-Circle1.png b/android/assets/1280x720/Tech-Circle1.png old mode 100755 new mode 100644 index 4229dfe..2b38094 Binary files a/android/assets/1280x720/Tech-Circle1.png and b/android/assets/1280x720/Tech-Circle1.png differ diff --git a/android/assets/1280x720/cybercircle1.png b/android/assets/1280x720/cybercircle1.png old mode 100755 new mode 100644 index c40498d..35c2e1f Binary files a/android/assets/1280x720/cybercircle1.png and b/android/assets/1280x720/cybercircle1.png differ diff --git a/android/assets/1280x720/cybercircle3B.png b/android/assets/1280x720/cybercircle3B.png old mode 100755 new mode 100644 index a8a2dd6..1e0e957 Binary files a/android/assets/1280x720/cybercircle3B.png and b/android/assets/1280x720/cybercircle3B.png differ diff --git a/android/assets/1280x720/laser.png b/android/assets/1280x720/laser.png old mode 100755 new mode 100644 index 7394d7d..742c241 Binary files a/android/assets/1280x720/laser.png and b/android/assets/1280x720/laser.png differ diff --git a/android/assets/1280x720/pellet.png b/android/assets/1280x720/pellet.png new file mode 100644 index 0000000..9ba2e74 Binary files /dev/null and b/android/assets/1280x720/pellet.png differ diff --git a/android/assets/1280x720/polyjet-standard.png b/android/assets/1280x720/polyjet-standard.png old mode 100755 new mode 100644 index a7e2934..fcec042 Binary files a/android/assets/1280x720/polyjet-standard.png and b/android/assets/1280x720/polyjet-standard.png differ diff --git a/android/assets/1280x720/splashlogo.png b/android/assets/1280x720/splashlogo.png old mode 100755 new mode 100644 index 52e86e3..564992d Binary files a/android/assets/1280x720/splashlogo.png and b/android/assets/1280x720/splashlogo.png differ diff --git a/android/assets/1280x720/square.png b/android/assets/1280x720/square.png old mode 100755 new mode 100644 diff --git a/android/assets/1280x800/PolyjetTitle.png b/android/assets/1280x800/PolyjetTitle.png old mode 100755 new mode 100644 index 2f32320..c4d6607 Binary files a/android/assets/1280x800/PolyjetTitle.png and b/android/assets/1280x800/PolyjetTitle.png differ diff --git a/android/assets/1280x800/Tech-Circle1.png b/android/assets/1280x800/Tech-Circle1.png old mode 100755 new mode 100644 index bd661d3..1faac69 Binary files a/android/assets/1280x800/Tech-Circle1.png and b/android/assets/1280x800/Tech-Circle1.png differ diff --git a/android/assets/1280x800/cybercircle1.png b/android/assets/1280x800/cybercircle1.png old mode 100755 new mode 100644 index 2edc4d1..68e96a2 Binary files a/android/assets/1280x800/cybercircle1.png and b/android/assets/1280x800/cybercircle1.png differ diff --git a/android/assets/1280x800/cybercircle3B.png b/android/assets/1280x800/cybercircle3B.png old mode 100755 new mode 100644 index 6f5ab4e..64e8079 Binary files a/android/assets/1280x800/cybercircle3B.png and b/android/assets/1280x800/cybercircle3B.png differ diff --git a/android/assets/1280x800/laser.png b/android/assets/1280x800/laser.png old mode 100755 new mode 100644 index 5e3956b..628c29d Binary files a/android/assets/1280x800/laser.png and b/android/assets/1280x800/laser.png differ diff --git a/android/assets/1280x800/pellet.png b/android/assets/1280x800/pellet.png new file mode 100644 index 0000000..537a166 Binary files /dev/null and b/android/assets/1280x800/pellet.png differ diff --git a/android/assets/1280x800/polyjet-standard.png b/android/assets/1280x800/polyjet-standard.png old mode 100755 new mode 100644 index f942f94..7a319d8 Binary files a/android/assets/1280x800/polyjet-standard.png and b/android/assets/1280x800/polyjet-standard.png differ diff --git a/android/assets/1280x800/splashlogo.png b/android/assets/1280x800/splashlogo.png old mode 100755 new mode 100644 index 45390b5..ea009a7 Binary files a/android/assets/1280x800/splashlogo.png and b/android/assets/1280x800/splashlogo.png differ diff --git a/android/assets/1280x800/square.png b/android/assets/1280x800/square.png old mode 100755 new mode 100644 diff --git a/android/assets/1366x768/PolyjetTitle.png b/android/assets/1366x768/PolyjetTitle.png old mode 100755 new mode 100644 index d86c04c..d86a727 Binary files a/android/assets/1366x768/PolyjetTitle.png and b/android/assets/1366x768/PolyjetTitle.png differ diff --git a/android/assets/1366x768/Tech-Circle1.png b/android/assets/1366x768/Tech-Circle1.png old mode 100755 new mode 100644 index bb78f62..3a65576 Binary files a/android/assets/1366x768/Tech-Circle1.png and b/android/assets/1366x768/Tech-Circle1.png differ diff --git a/android/assets/1366x768/cybercircle1.png b/android/assets/1366x768/cybercircle1.png old mode 100755 new mode 100644 index 2d205ef..c50ca81 Binary files a/android/assets/1366x768/cybercircle1.png and b/android/assets/1366x768/cybercircle1.png differ diff --git a/android/assets/1366x768/cybercircle3B.png b/android/assets/1366x768/cybercircle3B.png old mode 100755 new mode 100644 index 8af9f1e..8c823c9 Binary files a/android/assets/1366x768/cybercircle3B.png and b/android/assets/1366x768/cybercircle3B.png differ diff --git a/android/assets/1366x768/laser.png b/android/assets/1366x768/laser.png old mode 100755 new mode 100644 index 113d796..b191ea8 Binary files a/android/assets/1366x768/laser.png and b/android/assets/1366x768/laser.png differ diff --git a/android/assets/1366x768/pellet.png b/android/assets/1366x768/pellet.png new file mode 100644 index 0000000..e8b1a8a Binary files /dev/null and b/android/assets/1366x768/pellet.png differ diff --git a/android/assets/1366x768/polyjet-standard.png b/android/assets/1366x768/polyjet-standard.png old mode 100755 new mode 100644 index 33486ed..1089369 Binary files a/android/assets/1366x768/polyjet-standard.png and b/android/assets/1366x768/polyjet-standard.png differ diff --git a/android/assets/1366x768/splashlogo.png b/android/assets/1366x768/splashlogo.png old mode 100755 new mode 100644 index 07c1aa4..28eea52 Binary files a/android/assets/1366x768/splashlogo.png and b/android/assets/1366x768/splashlogo.png differ diff --git a/android/assets/1366x768/square.png b/android/assets/1366x768/square.png old mode 100755 new mode 100644 diff --git a/android/assets/1920x1080/PolyjetTitle.png b/android/assets/1920x1080/PolyjetTitle.png old mode 100755 new mode 100644 index 2b66436..59adeef Binary files a/android/assets/1920x1080/PolyjetTitle.png and b/android/assets/1920x1080/PolyjetTitle.png differ diff --git a/android/assets/1920x1080/Tech-Circle1.png b/android/assets/1920x1080/Tech-Circle1.png old mode 100755 new mode 100644 index 73d6ecd..ad14c5f Binary files a/android/assets/1920x1080/Tech-Circle1.png and b/android/assets/1920x1080/Tech-Circle1.png differ diff --git a/android/assets/1920x1080/cybercircle1.png b/android/assets/1920x1080/cybercircle1.png old mode 100755 new mode 100644 index f3c7512..7ab48d2 Binary files a/android/assets/1920x1080/cybercircle1.png and b/android/assets/1920x1080/cybercircle1.png differ diff --git a/android/assets/1920x1080/cybercircle3B.png b/android/assets/1920x1080/cybercircle3B.png old mode 100755 new mode 100644 index 13f13ef..2fe3009 Binary files a/android/assets/1920x1080/cybercircle3B.png and b/android/assets/1920x1080/cybercircle3B.png differ diff --git a/android/assets/1920x1080/laser.png b/android/assets/1920x1080/laser.png old mode 100755 new mode 100644 index 8987e67..097b078 Binary files a/android/assets/1920x1080/laser.png and b/android/assets/1920x1080/laser.png differ diff --git a/android/assets/1920x1080/pellet.png b/android/assets/1920x1080/pellet.png new file mode 100644 index 0000000..87753a4 Binary files /dev/null and b/android/assets/1920x1080/pellet.png differ diff --git a/android/assets/1920x1080/polyjet-standard.png b/android/assets/1920x1080/polyjet-standard.png old mode 100755 new mode 100644 index 59afe13..f2a4585 Binary files a/android/assets/1920x1080/polyjet-standard.png and b/android/assets/1920x1080/polyjet-standard.png differ diff --git a/android/assets/1920x1080/splashlogo.png b/android/assets/1920x1080/splashlogo.png old mode 100755 new mode 100644 index 23efe16..2630d50 Binary files a/android/assets/1920x1080/splashlogo.png and b/android/assets/1920x1080/splashlogo.png differ diff --git a/android/assets/1920x1080/square.png b/android/assets/1920x1080/square.png old mode 100755 new mode 100644 diff --git a/android/assets/1920x1200/PolyjetTitle.png b/android/assets/1920x1200/PolyjetTitle.png old mode 100755 new mode 100644 index 719af2e..9dd8afe Binary files a/android/assets/1920x1200/PolyjetTitle.png and b/android/assets/1920x1200/PolyjetTitle.png differ diff --git a/android/assets/1920x1200/Tech-Circle1.png b/android/assets/1920x1200/Tech-Circle1.png old mode 100755 new mode 100644 index 973956b..00cd1d3 Binary files a/android/assets/1920x1200/Tech-Circle1.png and b/android/assets/1920x1200/Tech-Circle1.png differ diff --git a/android/assets/1920x1200/cybercircle1.png b/android/assets/1920x1200/cybercircle1.png old mode 100755 new mode 100644 index 6938404..c6350b4 Binary files a/android/assets/1920x1200/cybercircle1.png and b/android/assets/1920x1200/cybercircle1.png differ diff --git a/android/assets/1920x1200/cybercircle3B.png b/android/assets/1920x1200/cybercircle3B.png old mode 100755 new mode 100644 index de638f3..e3ea89d Binary files a/android/assets/1920x1200/cybercircle3B.png and b/android/assets/1920x1200/cybercircle3B.png differ diff --git a/android/assets/1920x1200/laser.png b/android/assets/1920x1200/laser.png old mode 100755 new mode 100644 index 72cef57..965130c Binary files a/android/assets/1920x1200/laser.png and b/android/assets/1920x1200/laser.png differ diff --git a/android/assets/1920x1200/pellet.png b/android/assets/1920x1200/pellet.png new file mode 100644 index 0000000..1635f8e Binary files /dev/null and b/android/assets/1920x1200/pellet.png differ diff --git a/android/assets/1920x1200/polyjet-standard.png b/android/assets/1920x1200/polyjet-standard.png old mode 100755 new mode 100644 index 4a9d4f3..c4fa809 Binary files a/android/assets/1920x1200/polyjet-standard.png and b/android/assets/1920x1200/polyjet-standard.png differ diff --git a/android/assets/1920x1200/splashlogo.png b/android/assets/1920x1200/splashlogo.png old mode 100755 new mode 100644 index f9f53dc..8c4efa6 Binary files a/android/assets/1920x1200/splashlogo.png and b/android/assets/1920x1200/splashlogo.png differ diff --git a/android/assets/1920x1200/square.png b/android/assets/1920x1200/square.png old mode 100755 new mode 100644 diff --git a/android/assets/2560x1440/PolyjetTitle.png b/android/assets/2560x1440/PolyjetTitle.png old mode 100755 new mode 100644 index f7ee3e9..06d2cba Binary files a/android/assets/2560x1440/PolyjetTitle.png and b/android/assets/2560x1440/PolyjetTitle.png differ diff --git a/android/assets/2560x1440/Tech-Circle1.png b/android/assets/2560x1440/Tech-Circle1.png old mode 100755 new mode 100644 index 076a8ca..1899dbb Binary files a/android/assets/2560x1440/Tech-Circle1.png and b/android/assets/2560x1440/Tech-Circle1.png differ diff --git a/android/assets/2560x1440/cybercircle1.png b/android/assets/2560x1440/cybercircle1.png old mode 100755 new mode 100644 index 2771c97..5cd365e Binary files a/android/assets/2560x1440/cybercircle1.png and b/android/assets/2560x1440/cybercircle1.png differ diff --git a/android/assets/2560x1440/cybercircle3B.png b/android/assets/2560x1440/cybercircle3B.png old mode 100755 new mode 100644 index f66907f..1585079 Binary files a/android/assets/2560x1440/cybercircle3B.png and b/android/assets/2560x1440/cybercircle3B.png differ diff --git a/android/assets/2560x1440/laser.png b/android/assets/2560x1440/laser.png old mode 100755 new mode 100644 index f2c4e5b..0751bfb Binary files a/android/assets/2560x1440/laser.png and b/android/assets/2560x1440/laser.png differ diff --git a/android/assets/2560x1440/pellet.png b/android/assets/2560x1440/pellet.png new file mode 100644 index 0000000..cb50eb2 Binary files /dev/null and b/android/assets/2560x1440/pellet.png differ diff --git a/android/assets/2560x1440/polyjet-standard.png b/android/assets/2560x1440/polyjet-standard.png old mode 100755 new mode 100644 index 5c125f5..05b4a5b Binary files a/android/assets/2560x1440/polyjet-standard.png and b/android/assets/2560x1440/polyjet-standard.png differ diff --git a/android/assets/2560x1440/splashlogo.png b/android/assets/2560x1440/splashlogo.png old mode 100755 new mode 100644 index f2fab6d..8a56653 Binary files a/android/assets/2560x1440/splashlogo.png and b/android/assets/2560x1440/splashlogo.png differ diff --git a/android/assets/2560x1440/square.png b/android/assets/2560x1440/square.png old mode 100755 new mode 100644 diff --git a/android/assets/3840x2160/pellet.png b/android/assets/3840x2160/pellet.png new file mode 100644 index 0000000..2a3b119 Binary files /dev/null and b/android/assets/3840x2160/pellet.png differ diff --git a/android/assets/800x480/PolyjetTitle.png b/android/assets/800x480/PolyjetTitle.png old mode 100755 new mode 100644 index 6cf71ba..de39b05 Binary files a/android/assets/800x480/PolyjetTitle.png and b/android/assets/800x480/PolyjetTitle.png differ diff --git a/android/assets/800x480/Tech-Circle1.png b/android/assets/800x480/Tech-Circle1.png old mode 100755 new mode 100644 index acf3162..dddfe05 Binary files a/android/assets/800x480/Tech-Circle1.png and b/android/assets/800x480/Tech-Circle1.png differ diff --git a/android/assets/800x480/cybercircle1.png b/android/assets/800x480/cybercircle1.png old mode 100755 new mode 100644 index 467fceb..adc051d Binary files a/android/assets/800x480/cybercircle1.png and b/android/assets/800x480/cybercircle1.png differ diff --git a/android/assets/800x480/cybercircle3B.png b/android/assets/800x480/cybercircle3B.png old mode 100755 new mode 100644 index cf3174f..06643cc Binary files a/android/assets/800x480/cybercircle3B.png and b/android/assets/800x480/cybercircle3B.png differ diff --git a/android/assets/800x480/laser.png b/android/assets/800x480/laser.png old mode 100755 new mode 100644 index f798f65..4a10e44 Binary files a/android/assets/800x480/laser.png and b/android/assets/800x480/laser.png differ diff --git a/android/assets/800x480/pellet.png b/android/assets/800x480/pellet.png new file mode 100644 index 0000000..33bcf67 Binary files /dev/null and b/android/assets/800x480/pellet.png differ diff --git a/android/assets/800x480/polyjet-standard.png b/android/assets/800x480/polyjet-standard.png old mode 100755 new mode 100644 index d0148cd..d97e271 Binary files a/android/assets/800x480/polyjet-standard.png and b/android/assets/800x480/polyjet-standard.png differ diff --git a/android/assets/800x480/splashlogo.png b/android/assets/800x480/splashlogo.png old mode 100755 new mode 100644 index 96fdfd0..b6326d4 Binary files a/android/assets/800x480/splashlogo.png and b/android/assets/800x480/splashlogo.png differ diff --git a/android/assets/800x480/square.png b/android/assets/800x480/square.png old mode 100755 new mode 100644 diff --git a/core/src/zero1hd/polyjet/Polyjet.java b/core/src/zero1hd/polyjet/Polyjet.java index 20c1ba0..ac65df4 100755 --- a/core/src/zero1hd/polyjet/Polyjet.java +++ b/core/src/zero1hd/polyjet/Polyjet.java @@ -124,6 +124,7 @@ public class Polyjet extends Game { assetManager.load("pop_open.ogg", Sound.class); assetManager.load("pop_close.ogg", Sound.class); assetManager.load("laser.png", Texture.class); + assetManager.load("pellet.png", Texture.class); } public void generateFonts() { initComplete = true; diff --git a/core/src/zero1hd/polyjet/entity/Entities.java b/core/src/zero1hd/polyjet/entity/Entities.java index c2251e1..464bfa8 100755 --- a/core/src/zero1hd/polyjet/entity/Entities.java +++ b/core/src/zero1hd/polyjet/entity/Entities.java @@ -1,7 +1,7 @@ package zero1hd.polyjet.entity; public enum Entities { - POLYJET, BAR_BEAT, VOID_CIRCLE, SHARDS, LASER; + POLYJET, BAR_BEAT, VOID_CIRCLE, SHARDS, LASER, PELLET; public float x; public float y; diff --git a/core/src/zero1hd/polyjet/entity/EntityController.java b/core/src/zero1hd/polyjet/entity/EntityController.java index 7c30eb3..455b271 100755 --- a/core/src/zero1hd/polyjet/entity/EntityController.java +++ b/core/src/zero1hd/polyjet/entity/EntityController.java @@ -7,6 +7,7 @@ import com.badlogic.gdx.utils.Array; import com.badlogic.gdx.utils.Pool; import zero1hd.polyjet.entity.ally.Laser; +import zero1hd.polyjet.entity.enemies.Pellet; import zero1hd.polyjet.entity.enemies.VoidCircle; public class EntityController { @@ -17,6 +18,7 @@ public class EntityController { public Array activeEnemies; //Enemy pool declaration; private Pool voidCirclePool; + private Pool pelletPool; //Ally pool declaration; private Pool laserPool; @@ -35,6 +37,12 @@ public class EntityController { return new VoidCircle(shapes); } }; + pelletPool = new Pool() { + @Override + protected Pellet newObject() { + return new Pellet(assets.get("pellet.png", Texture.class)); + } + }; //Ally pool initialization; laserPool = new Pool() { @@ -52,14 +60,14 @@ public class EntityController { VoidCircle voidCircle = voidCirclePool.obtain(); activeEnemies.add(voidCircle); return voidCircle; - case BAR_BEAT: - return null; - case SHARDS: - return null; case LASER: Laser laser = laserPool.obtain(); activeAllies.add(laser); return laser; + case PELLET: + Pellet pellet = pelletPool.obtain(); + activeEnemies.add(pellet); + return pellet; default: return null; } @@ -67,10 +75,6 @@ public class EntityController { public void free(Entity entity) { switch (entity.getEntityType()) { - case BAR_BEAT: - break; - case SHARDS: - break; case VOID_CIRCLE: VoidCircle voidCircle = (VoidCircle) entity; voidCircle.remove(); @@ -83,6 +87,11 @@ public class EntityController { activeAllies.removeValue(entity, true); laserPool.free(laser); break; + case PELLET: + Pellet pellet = (Pellet) entity; + pellet.remove(); + activeEnemies.removeValue(entity, true); + pelletPool.free(pellet); default: break; } diff --git a/core/src/zero1hd/polyjet/entity/enemies/Pellet.java b/core/src/zero1hd/polyjet/entity/enemies/Pellet.java new file mode 100644 index 0000000..a5dc000 --- /dev/null +++ b/core/src/zero1hd/polyjet/entity/enemies/Pellet.java @@ -0,0 +1,81 @@ +package zero1hd.polyjet.entity.enemies; + +import com.badlogic.gdx.graphics.Texture; +import com.badlogic.gdx.graphics.g2d.Batch; +import com.badlogic.gdx.math.Rectangle; +import com.badlogic.gdx.math.Vector2; +import com.badlogic.gdx.scenes.scene2d.Actor; +import com.badlogic.gdx.utils.Pool.Poolable; + +import zero1hd.polyjet.Polyjet; +import zero1hd.polyjet.entity.Entities; +import zero1hd.polyjet.entity.Entity; + +public class Pellet extends Actor implements Entity, Poolable { + private boolean dead; + private Texture texture; + private Rectangle hitBox; + private Vector2 direction; + private float rate; + + public Pellet(Texture texture) { + hitBox = new Rectangle(); + direction = new Vector2(); + this.texture = texture; + } + + public void init(float x, float y, float direction, float rate) { + setPosition(x, y); + this.direction.setAngle(direction); + rate = 0; + setSize(0.5f, 0.5f); + } + + @Override + public void act(float delta) { + moveBy(direction.x*delta*rate, direction.y*delta*rate); + super.act(delta); + + if (getX() > Polyjet.GAME_AREA_WIDTH || getY() > Polyjet.GAME_AREA_HEIGHT || getX()-getWidth() < 0 || getY()-getHeight() < 0) { + dead = true; + } + } + + @Override + public void draw(Batch batch, float parentAlpha) { + batch.draw(texture, getX(), getY(), getWidth(), getHeight()); + super.draw(batch, parentAlpha); + } + + @Override + public void collided(Entity entity) { + if (entity.getEntityType() == Entities.VOID_CIRCLE) { + dead = true; + } + } + + @Override + public Rectangle getHitZone() { + return hitBox; + } + + @Override + public Entities getEntityType() { + return Entities.PELLET; + } + + @Override + public boolean isDead() { + return dead; + } + + @Override + public void reset() { + hitBox.set(0, 0, 0, 0); + setSize(0, 0); + setPosition(0, 0); + direction.set(0,0); + rate = 0; + } + +} diff --git a/core/src/zero1hd/polyjet/ui/windows/SpawnerWindow.java b/core/src/zero1hd/polyjet/ui/windows/SpawnerWindow.java index 754d7ad..4d09a0f 100755 --- a/core/src/zero1hd/polyjet/ui/windows/SpawnerWindow.java +++ b/core/src/zero1hd/polyjet/ui/windows/SpawnerWindow.java @@ -14,6 +14,7 @@ import zero1hd.polyjet.entity.Entities; import zero1hd.polyjet.entity.Entity; import zero1hd.polyjet.entity.EntityController; import zero1hd.polyjet.entity.ally.Laser; +import zero1hd.polyjet.entity.enemies.Pellet; import zero1hd.polyjet.entity.enemies.VoidCircle; public class SpawnerWindow extends Window { @@ -68,7 +69,10 @@ public class SpawnerWindow extends Window { laser.init(coords.x, coords.y, mod1.getValue()); stage.addActor(laser); break; - case SHARDS: + case PELLET: + Pellet pellet = (Pellet) entity; + pellet.init(coords.x, coords.y, mod2.getValue(), mod3.getValue()); + stage.addActor(pellet); break; case VOID_CIRCLE: VoidCircle voidCircle = (VoidCircle) entity;