Remove unused imports and correct warnings

Co-authored-by: r3cp3ct <45179536+r3cp3ct@users.noreply.github.com>
Co-authored-by: sigonasr2 <sigonasr2@gmail.com>
main
Nic0Nic0Nii 3 years ago
parent 55276867cc
commit 627c788d05
  1. 1
      src/sig/RabiClone.java
  2. 2
      src/sig/map/Tile.java
  3. 5
      src/sig/objects/EditorRenderer.java
  4. 5
      src/sig/objects/Player.java

@ -5,7 +5,6 @@ import javax.swing.JFrame;
import net.java.games.input.Component; import net.java.games.input.Component;
import net.java.games.input.Controller; import net.java.games.input.Controller;
import net.java.games.input.ControllerEnvironment; import net.java.games.input.ControllerEnvironment;
import net.java.games.input.Component.Identifier;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;

@ -1,7 +1,5 @@
package sig.map; package sig.map;
import sig.RabiClone;
public enum Tile { public enum Tile {
VOID(0,0,true,CollisionType.NONE), //File is populated by 0s by default. This represents the void. VOID(0,0,true,CollisionType.NONE), //File is populated by 0s by default. This represents the void.
WALL(0,0,CollisionType.BLOCK), WALL(0,0,CollisionType.BLOCK),

@ -10,7 +10,6 @@ import sig.engine.Font;
import sig.engine.MouseScrollValue; import sig.engine.MouseScrollValue;
import sig.engine.PaletteColor; import sig.engine.PaletteColor;
import sig.engine.Panel; import sig.engine.Panel;
import sig.engine.Sprite;
import sig.map.Background; import sig.map.Background;
import sig.map.Map; import sig.map.Map;
import sig.map.Tile; import sig.map.Tile;
@ -61,8 +60,8 @@ public class EditorRenderer extends LevelRenderer{
setY(Math.max(0,getY()+(down-up)*CAMERA_SPD*updateMult)); setY(Math.max(0,getY()+(down-up)*CAMERA_SPD*updateMult));
} }
boolean left_mb = MouseHeld(MouseEvent.BUTTON1); boolean left_mb = MouseHeld(MouseEvent.BUTTON1);
boolean middle_mb = MouseHeld(MouseEvent.BUTTON2); // boolean middle_mb = MouseHeld(MouseEvent.BUTTON2);
boolean right_mb = MouseHeld(MouseEvent.BUTTON3); // boolean right_mb = MouseHeld(MouseEvent.BUTTON3);
if(left_mb){ if(left_mb){
int tileX = (int)(RabiClone.MOUSE_POS.getX()+getX())/Tile.TILE_WIDTH; int tileX = (int)(RabiClone.MOUSE_POS.getX()+getX())/Tile.TILE_WIDTH;

@ -2,7 +2,6 @@ package sig.objects;
import sig.RabiClone; import sig.RabiClone;
import sig.engine.AnimatedObject; import sig.engine.AnimatedObject;
import sig.engine.Object;
import sig.engine.Panel; import sig.engine.Panel;
import sig.engine.Sprite; import sig.engine.Sprite;
import sig.map.CollisionType; import sig.map.CollisionType;
@ -308,6 +307,10 @@ public class Player extends AnimatedObject{
} }
} }
break; break;
case FIXED:
break;
default:
break;
} }
RabiClone.level_renderer.setX(newX<0?0:newX); RabiClone.level_renderer.setX(newX<0?0:newX);
RabiClone.level_renderer.setY(newY<0?0:newY); RabiClone.level_renderer.setY(newY<0?0:newY);

Loading…
Cancel
Save