Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public abstract class UnitClass{
- public UnitClass(int _health, int _defense){
- //instantiate stuff
- }
- public abstract void attack(int damage, int enemyHealth, int enemyDefense){
- //will be different for each class
- }
- public void die(){
- //everyone shares this one
- }
- }
- public abstract class Fighter extends UnitClass{
- public Fighter(int _health, int _defense){
- this.super(_health, _defense);
- }
- public abstract void fighterStuff(){
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement