Changeset 8edd04e in lost-haven for main/Structure.java
- Timestamp:
- Jun 7, 2020, 3:04:32 PM (5 years ago)
- Branches:
- master
- Children:
- a49176d
- Parents:
- 155577b
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/Structure.java
r155577b r8edd04e 1 1 package main; 2 2 3 import java.awt.image. *;3 import java.awt.image.BufferedImage; 4 4 5 5 public class Structure extends MapElement { 6 private StructureType type; 7 8 public Structure(StructureType type, BufferedImage img, boolean passable) { 9 super(img, passable); 10 11 this.type = type; 12 } 13 14 public Structure(StructureType type, String imgFile, boolean passable) { 15 super(imgFile, passable); 16 17 this.type = type; 18 } 19 20 public StructureType getType() { 21 return type; 22 } 6 7 private StructureType type; 8 private Point loc; 9 10 public Structure(StructureType type, BufferedImage img, boolean passable) { 11 super(img, passable); 12 this.type = type; 13 this.loc = null; 14 } 15 16 public Structure(StructureType type, String imgFile, boolean passable) { 17 super(imgFile, passable); 18 this.type = type; 19 this.loc = null; 20 } 21 22 public Structure(Structure copy, Point loc) { 23 super(copy); 24 this.type = copy.type; 25 this.loc = loc; 26 } 27 28 public StructureType getType() { 29 return this.type; 30 } 31 32 public Point getLoc() { 33 return this.loc; 34 } 23 35 }
Note:
See TracChangeset
for help on using the changeset viewer.