mirror of
https://github.com/Noratrieb/Java2DGame.git
synced 2026-01-14 22:15:01 +01:00
coordinates
This commit is contained in:
parent
4fb5bcc543
commit
b530a5d3a5
10 changed files with 36 additions and 30 deletions
|
|
@ -10,19 +10,18 @@ import java.awt.*;
|
|||
/**
|
||||
* A shell fired by a cannon
|
||||
*/
|
||||
//TODO why tf do shells not use map coords...
|
||||
public class Shell extends GameObject {
|
||||
|
||||
|
||||
public Shell(Vector2D position, Vector2D size, Vector2D velocity) {
|
||||
super(position, size/*, new RectHitBox(position, size)*/);
|
||||
this.velocity = velocity;
|
||||
this.mainColor = Color.ORANGE;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void draw(Graphics2D g2d) {
|
||||
g2d.setPaint(Color.orange);
|
||||
g2d.fillOval((int) position.x, (int) position.y, (int) size.x, (int) size.y);
|
||||
fillOval(g2d);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue