ReplicatorDrawer now handles every Directions.
PlayerBase.draw() is now synchronized.
This commit is contained in:
parent
6bc50e7810
commit
f38c4e5bd6
@ -13,21 +13,20 @@ public class PlayerBaseDrawer extends AbstractDrawer implements Drawer {
|
|||||||
@Override
|
@Override
|
||||||
public void draw() throws IOException {
|
public void draw() throws IOException {
|
||||||
|
|
||||||
//TODO Pictures for different facing directions.
|
|
||||||
switch(playerbase.name){
|
switch(playerbase.name){
|
||||||
case "Replicator":
|
case "Replicator":
|
||||||
switch(playerbase.facingDirection){
|
switch(playerbase.facingDirection){
|
||||||
case NORTH:
|
case NORTH:
|
||||||
changeImage("Replicator.png");
|
changeImage("Replicator_Up.png");
|
||||||
break;
|
break;
|
||||||
case EAST:
|
case EAST:
|
||||||
changeImage("Replicator_east.png");
|
changeImage("Replicator_Right.png");
|
||||||
break;
|
break;
|
||||||
case SOUTH:
|
case SOUTH:
|
||||||
changeImage("Replicator.png");
|
changeImage("Replicator_Down.png");
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
changeImage("Replicator_west.png");
|
changeImage("Replicator_Left.png");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user