v0.7.4a: fixed heavy boomerangs being lost when inventory is full
This commit is contained in:
parent
af7bb632ea
commit
e36ea99a61
|
@ -100,9 +100,12 @@ public class HeavyBoomerang extends MissileWeapon {
|
||||||
@Override
|
@Override
|
||||||
public void call() {
|
public void call() {
|
||||||
if (returnTarget == Dungeon.hero){
|
if (returnTarget == Dungeon.hero){
|
||||||
boomerang.doPickUp(Dungeon.hero);
|
if (boomerang.doPickUp(Dungeon.hero)) {
|
||||||
//grabbing the boomerang takes no time
|
//grabbing the boomerang takes no time
|
||||||
Dungeon.hero.spend(-TIME_TO_PICK_UP);
|
Dungeon.hero.spend(-TIME_TO_PICK_UP);
|
||||||
|
} else {
|
||||||
|
Dungeon.level.drop(boomerang, returnPos).sprite.drop();
|
||||||
|
}
|
||||||
|
|
||||||
} else if (returnTarget != null){
|
} else if (returnTarget != null){
|
||||||
if (curUser.shoot( returnTarget, boomerang )) {
|
if (curUser.shoot( returnTarget, boomerang )) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user