[SOLVED] CS代写 package dungeonmania.entities.enemies;

30 $

package dungeonmania.entities.enemies;

import dungeonmania.Game;
import dungeonmania.battles.BattleStatistics;

Copyright By PowCoder代写加微信 powcoder

import dungeonmania.battles.Battleable;
import dungeonmania.entities.Entity;
import dungeonmania.entities.Player;
import dungeonmania.map.GameMap;
import dungeonmania.util.Position;

public abstract class Enemy extends Entity implements Battleable {
private BattleStatistics battleStatistics;

public Enemy(Position position, double health, double attack) {
super(position.asLayer(Entity.CHARACTER_LAYER));
battleStatistics = new BattleStatistics(
BattleStatistics.DEFAULT_DAMAGE_MAGNIFIER,
BattleStatistics.DEFAULT_ENEMY_DAMAGE_REDUCER);

public boolean canMoveOnto(GameMap map, Entity entity) {
return entity instanceof Player;

public BattleStatistics getBattleStatistics() {
return battleStatistics;

public void onOverlap(GameMap map, Entity entity) {
if (entity instanceof Player) {
Player player = (Player) entity;
map.getGame().battle(player, this);

public void onDestroy(GameMap map) {
Game g = map.getGame();
g.unsubscribe(getId());

public void onMovedAway(GameMap map, Entity entity) {

public abstract void move(Game game);

程序代写 CS代考加微信: powcoder QQ: 1823890830 Email: [email protected]

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.

Shopping Cart
[SOLVED] CS代写 package dungeonmania.entities.enemies;
30 $