v3.0.0: implemented the Radiance spell
This commit is contained in:
Binary file not shown.
|
Before Width: | Height: | Size: 2.6 KiB After Width: | Height: | Size: 2.7 KiB |
@@ -591,6 +591,10 @@ actors.hero.spells.holyweapon.desc=The Cleric enchants their worn weapon with ho
|
||||
actors.hero.spells.holyweapon$holywepbuff.name=holy weapon
|
||||
actors.hero.spells.holyweapon$holywepbuff.desc=The Cleric has imbued their worn weapon with holy energy, temporarily overriding any existing enchantment and causing the weapon to deal an extra 2 magical damage on each attack.\n\nTurns renaming: %s.
|
||||
|
||||
actors.hero.spells.radiance.name=radiance
|
||||
actors.hero.spells.radiance.short_desc=Illuminates and briefly stuns visible enemies.
|
||||
actors.hero.spells.radiance.desc=The Priest erupts in holy light, stunning all visible enemies for 2 turns and illuminating them as if they were hit by Guiding Light. Radiance will also cause the Priest to glow for 100 turns if the current floor is dark.
|
||||
|
||||
actors.hero.spells.recallglyph.name=recall glyph
|
||||
actors.hero.spells.recallglyph.short_desc=Repeats a recently used stone or scroll.
|
||||
actors.hero.spells.recallglyph.desc=The Cleric uses holy magic to replicate and re-cast the effect of a magical glyph found on a runestone or scroll they used in the last %s turns.\n\nRecall Glyph cannot be used to replicate scrolls of upgrade. This spell's charge cost varies based on which item was used recently: 1 for a runestone, 2 for a scroll, 3 for an exotic scroll. This charge cost is also doubled when replicating a scroll of transmutation, or alchemy items that must be crafted using transmutation or upgrade.
|
||||
|
||||
+2
-1
@@ -105,7 +105,7 @@ public abstract class ClericSpell {
|
||||
} else if (tier == 3){
|
||||
|
||||
if (cleric.subClass == HeroSubClass.PRIEST) {
|
||||
//TODO innate radiance spell
|
||||
spells.add(Radiance.INSTANCE);
|
||||
|
||||
if (cleric.hasTalent(Talent.HOLY_LANCE)){
|
||||
spells.add(HolyLance.INSTANCE);
|
||||
@@ -131,6 +131,7 @@ public abstract class ClericSpell {
|
||||
spells.add(Sunray.INSTANCE);
|
||||
spells.add(RecallGlyph.INSTANCE);
|
||||
spells.add(DivineSense.INSTANCE);
|
||||
spells.add(Radiance.INSTANCE);
|
||||
spells.add(HolyLance.INSTANCE);
|
||||
return spells;
|
||||
}
|
||||
|
||||
+76
@@ -0,0 +1,76 @@
|
||||
/*
|
||||
* Pixel Dungeon
|
||||
* Copyright (C) 2012-2015 Oleg Dolya
|
||||
*
|
||||
* Shattered Pixel Dungeon
|
||||
* Copyright (C) 2014-2024 Evan Debenham
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>
|
||||
*/
|
||||
|
||||
package com.shatteredpixel.shatteredpixeldungeon.actors.hero.spells;
|
||||
|
||||
import com.shatteredpixel.shatteredpixeldungeon.Assets;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.Challenges;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.Dungeon;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.actors.Char;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.Buff;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.Light;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.Paralysis;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Hero;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.actors.mobs.Mob;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.items.artifacts.HolyTome;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.scenes.GameScene;
|
||||
import com.shatteredpixel.shatteredpixeldungeon.ui.HeroIcon;
|
||||
import com.watabou.noosa.audio.Sample;
|
||||
|
||||
public class Radiance extends ClericSpell {
|
||||
|
||||
public static final Radiance INSTANCE = new Radiance();
|
||||
|
||||
@Override
|
||||
public int icon() {
|
||||
return HeroIcon.RADIANCE;
|
||||
}
|
||||
|
||||
@Override
|
||||
public float chargeUse(Hero hero) {
|
||||
return 2;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCast(HolyTome tome, Hero hero) {
|
||||
|
||||
GameScene.flash( 0x80FFFFFF );
|
||||
Sample.INSTANCE.play(Assets.Sounds.BLAST);
|
||||
|
||||
if (Dungeon.level.viewDistance < 6 ){
|
||||
Buff.affect(hero, Light.class, Dungeon.isChallenged(Challenges.DARKNESS) ? 20 : 100);
|
||||
}
|
||||
|
||||
for (Mob mob : Dungeon.level.mobs.toArray( new Mob[0] )) {
|
||||
if (mob.alignment != Char.Alignment.ALLY && Dungeon.level.heroFOV[mob.pos]) {
|
||||
Buff.affect(mob, GuidingLight.Illuminated.class);
|
||||
Buff.affect(mob, Paralysis.class, 1f);
|
||||
}
|
||||
}
|
||||
|
||||
hero.spend( 1f );
|
||||
hero.busy();
|
||||
hero.sprite.operate(hero.pos);
|
||||
|
||||
onSpellCast(tome, hero);
|
||||
|
||||
}
|
||||
}
|
||||
@@ -82,6 +82,7 @@ public class HeroIcon extends Image {
|
||||
public static final int DIVINE_SENSE = 46;
|
||||
public static final int RECALL_GLYPH = 47;
|
||||
public static final int HOLY_LANCE = 48;
|
||||
public static final int RADIANCE = 49;
|
||||
|
||||
//all cleric spells have a separate icon with no background for the action indicator
|
||||
public static final int SPELL_ACTION_OFFSET = 32;
|
||||
|
||||
Reference in New Issue
Block a user