Skip to content

Instantly share code, notes, and snippets.

@MRtecno98
Created August 14, 2017 19:59
Show Gist options
  • Save MRtecno98/b6c6168b234fe041beea18b54fdfc0b9 to your computer and use it in GitHub Desktop.
Save MRtecno98/b6c6168b234fe041beea18b54fdfc0b9 to your computer and use it in GitHub Desktop.
Simply Console Pokemon Game
<?xml version="1.0" encoding="UTF-8"?>
<module type="JAVA_MODULE" version="4">
<component name="NewModuleRootManager" inherit-compiler-output="true">
<exclude-output />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/src" isTestSource="false" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>
package com.tecno.battles.moves;
public class Move {
int damage;
public Move(int damage) {
this.damage = damage;
}
}
package com.tecno.battles.pokemons;
public class Bidoof extends NormalPokemon {
public Bidoof(int life) {
super("Bidoof" , life);
}
}
package com.tecno.battles.pokemons;
public class Charizard extends FirePokemon {
public Charizard(int life) {
super("Charizard" , life);
}
}
package com.tecno.battles.pokemons;
public class FirePokemon extends Pokemon {
public FirePokemon(String name , int life) {
super(name,life);
}
}
package com.tecno.battles.pokemons;
public abstract class NormalPokemon extends Pokemon {
public NormalPokemon(String name , int life) {
super(name,life);
}
}
package com.tecno.battles.pokemons;
public class Pokemon {
int life;
String name;
public Pokemon(String name , int life) {
this.name = name;
this.life = life;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment