v0.2.3: implementation on timekeepers hourglass (almost done!)

This commit is contained in:
Evan Debenham
2014-12-08 17:10:39 -05:00
parent 59df503355
commit 5bf2d72a90
5 changed files with 77 additions and 14 deletions
@@ -847,7 +847,8 @@ public abstract class Level implements Bundlable {
int cx = c.pos % WIDTH;
int cy = c.pos / WIDTH;
boolean sighted = c.buff( Blindness.class ) == null && c.buff( Shadows.class ) == null && c.isAlive();
boolean sighted = c.buff( Blindness.class ) == null && c.buff( Shadows.class ) == null
&& c.buff( TimekeepersHourglass.timeStasis.class ) == null && c.isAlive();
if (sighted) {
ShadowCaster.castShadow( cx, cy, fieldOfView, c.viewDistance );
} else {
@@ -17,6 +17,7 @@
*/
package com.shatteredpixel.shatteredpixeldungeon.levels.features;
import com.shatteredpixel.shatteredpixeldungeon.items.artifacts.TimekeepersHourglass;
import com.watabou.noosa.Camera;
import com.watabou.noosa.Game;
import com.watabou.noosa.audio.Sample;
@@ -67,6 +68,10 @@ public class Chasm {
jumpConfirmed = false;
Sample.INSTANCE.play( Assets.SND_FALLING );
Buff buff = Dungeon.hero.buff(TimekeepersHourglass.timeFreeze.class);
if (buff != null)
buff.detach();
if (Dungeon.hero.isAlive()) {
Dungeon.hero.interrupt();