v0.8.0: bugfixes and tweaks:

- Fixed webs not always clearing properly
- Fixed doors being hidden on floor 2 in some cases when they shouldn't
- Fixed Yog and its minions ignoring bees
- Added back the name of an item when it can't be grabbed.
This commit is contained in:
Evan Debenham 2020-04-03 20:01:35 -04:00
parent 0653d0d1f2
commit 4152d9dc7a
5 changed files with 35 additions and 7 deletions

View File

@ -78,7 +78,7 @@ public class Web extends Blob {
@Override @Override
public void clear(int cell) { public void clear(int cell) {
super.clear(cell); super.clear(cell);
if (volume == 0) return; if (cur == null) return;
Level l = Dungeon.level; Level l = Dungeon.level;
l.solid[cell] = cur[cell] > 0 || (Terrain.flags[l.map[cell]] & Terrain.SOLID) != 0; l.solid[cell] = cur[cell] > 0 || (Terrain.flags[l.map[cell]] & Terrain.SOLID) != 0;
} }

View File

@ -106,6 +106,7 @@ import com.shatteredpixel.shatteredpixeldungeon.levels.Level;
import com.shatteredpixel.shatteredpixeldungeon.levels.Terrain; import com.shatteredpixel.shatteredpixeldungeon.levels.Terrain;
import com.shatteredpixel.shatteredpixeldungeon.levels.features.Chasm; import com.shatteredpixel.shatteredpixeldungeon.levels.features.Chasm;
import com.shatteredpixel.shatteredpixeldungeon.levels.traps.Trap; import com.shatteredpixel.shatteredpixeldungeon.levels.traps.Trap;
import com.shatteredpixel.shatteredpixeldungeon.messages.Languages;
import com.shatteredpixel.shatteredpixeldungeon.messages.Messages; import com.shatteredpixel.shatteredpixeldungeon.messages.Messages;
import com.shatteredpixel.shatteredpixeldungeon.plants.Earthroot; import com.shatteredpixel.shatteredpixeldungeon.plants.Earthroot;
import com.shatteredpixel.shatteredpixeldungeon.plants.Swiftthistle; import com.shatteredpixel.shatteredpixeldungeon.plants.Swiftthistle;
@ -737,6 +738,20 @@ public class Hero extends Char {
curAction = null; curAction = null;
} else { } else {
if (item instanceof Dewdrop
|| item instanceof TimekeepersHourglass.sandBag
|| item instanceof DriedRose.Petal
|| item instanceof Key) {
//Do Nothing
} else {
//TODO temporary until 0.8.0a, when all languages will get this phrase
if (Messages.lang() == Languages.ENGLISH) {
GLog.newLine();
GLog.n(Messages.get(this, "you_cant_have", item.name()));
}
}
heap.sprite.drop(); heap.sprite.drop();
ready(); ready();
} }

View File

@ -142,7 +142,7 @@ public class YogDzewa extends Mob {
sprite.parent.add(new Beam.DeathRay(sprite.center(), DungeonTilemap.raisedTileCenterToWorld(b.collisionPos))); sprite.parent.add(new Beam.DeathRay(sprite.center(), DungeonTilemap.raisedTileCenterToWorld(b.collisionPos)));
for (int p : b.path) { for (int p : b.path) {
Char ch = Actor.findChar(p); Char ch = Actor.findChar(p);
if (ch != null && ch.alignment != alignment) { if (ch != null && (ch.alignment != alignment || ch instanceof Bee)) {
affected.add(ch); affected.add(ch);
} }
if (Dungeon.level.flamable[p]) { if (Dungeon.level.flamable[p]) {
@ -338,6 +338,16 @@ public class YogDzewa extends Mob {
public void beckon( int cell ) { public void beckon( int cell ) {
} }
@Override
public void aggro(Char ch) {
for (Mob mob : (Iterable<Mob>)Dungeon.level.mobs.clone()) {
if (Dungeon.level.distance(pos, mob.pos) <= 4 &&
(mob instanceof Larva || mob instanceof RipperDemon)) {
mob.aggro(ch);
}
}
}
@SuppressWarnings("unchecked") @SuppressWarnings("unchecked")
@Override @Override
public void die( Object cause ) { public void die( Object cause ) {

View File

@ -188,11 +188,13 @@ public abstract class RegularPainter extends Painter {
} else { } else {
d.type = Room.Door.Type.UNLOCKED; d.type = Room.Door.Type.UNLOCKED;
} }
}
//entrance doors on floor 2 are hidden if the player hasn't beaten the first boss //entrance doors on floor 2 are hidden if the player hasn't beaten the first boss
if (Dungeon.depth == 2 && !Badges.isUnlocked(Badges.Badge.BOSS_SLAIN_1) && r instanceof EntranceRoom){ if (Dungeon.depth == 2
d.type = Room.Door.Type.HIDDEN; && !Badges.isUnlocked(Badges.Badge.BOSS_SLAIN_1)
&& r instanceof EntranceRoom){
d.type = Room.Door.Type.HIDDEN;
}
} }
switch (d.type) { switch (d.type) {

View File

@ -302,7 +302,8 @@ actors.hero.hero.leave=You can't leave yet!
actors.hero.hero.level_up=Level up! actors.hero.hero.level_up=Level up!
actors.hero.hero.new_level=Level up!\nYou are more accurate, evasive, & healthy! actors.hero.hero.new_level=Level up!\nYou are more accurate, evasive, & healthy!
actors.hero.hero.level_cap=You cannot grow stronger, but your experiences do give you a surge of power! actors.hero.hero.level_cap=You cannot grow stronger, but your experiences do give you a surge of power!
actors.hero.hero.you_now_have=You now have: %s. actors.hero.hero.you_now_have=You picked up: %s.
actors.hero.hero.you_cant_have=You can't carry: %s.
actors.hero.hero.locked_chest=This chest is locked and you don't have a matching key. actors.hero.hero.locked_chest=This chest is locked and you don't have a matching key.
actors.hero.hero.locked_door=You don't have a matching key. actors.hero.hero.locked_door=You don't have a matching key.
actors.hero.hero.noticed_smth=You noticed something. actors.hero.hero.noticed_smth=You noticed something.