Skip to content

Commit 374727f

Browse files
committed
Buffed Zot a little
1 parent d7fa25d commit 374727f

File tree

38 files changed

+78
-100
lines changed

38 files changed

+78
-100
lines changed
Binary file not shown.
Loading

app/debug/app-debug.apk

67.4 KB
Binary file not shown.

app/src/main/assets/banners.png

12.8 KB
Loading

app/src/main/java/com/github/dachhack/sprout/actors/hero/HeroClass.java

+45-38
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@
8686
import com.github.dachhack.sprout.items.wands.WandOfLightning;
8787
import com.github.dachhack.sprout.items.wands.WandOfMagicMissile;
8888
import com.github.dachhack.sprout.items.wands.WandOfTelekinesis;
89+
import com.github.dachhack.sprout.items.weapon.enchantments.Slashing;
8990
import com.github.dachhack.sprout.items.weapon.melee.Chainsaw;
9091
import com.github.dachhack.sprout.items.weapon.melee.Dagger;
9192
import com.github.dachhack.sprout.items.weapon.melee.Glaive;
@@ -304,54 +305,60 @@ public static void playtest(Hero hero) {
304305
if (!Dungeon.playtest) {
305306
//Playtest
306307
//TomeOfMastery tome = new TomeOfMastery(); tome.collect();
307-
new WandOfDisintegration().identify().reinforce().upgrade(15).collect();
308-
new WandOfFirebolt().identify().reinforce().upgrade(15).collect();
309-
new WandOfLightning().identify().reinforce().upgrade(15).collect();
310-
new WandOfAvalanche().identify().reinforce().upgrade(15).collect();
311-
new WandOfTelekinesis().identify().reinforce().upgrade(15).collect();
312-
new WandHolster().collect();
308+
//new WandOfDisintegration().identify().reinforce().upgrade(15).collect();
309+
//new WandOfFirebolt().identify().reinforce().upgrade(15).collect();
310+
//new WandOfLightning().identify().reinforce().upgrade(15).collect();
311+
//new WandOfAvalanche().identify().reinforce().upgrade(15).collect();
312+
//new WandOfTelekinesis().identify().reinforce().upgrade(15).collect();
313+
//new WandHolster().collect();
313314

314-
new Tamahawk().quantity(40).collect();
315+
//new Tamahawk().quantity(40).collect();
315316

316-
new AnkhChain().collect();
317-
new KeyRing().collect();
317+
//new AnkhChain().collect();
318+
//new KeyRing().collect();
318319

319-
new SeedPouch().collect();
320+
//new SeedPouch().collect();
320321

321-
new PotionBandolier().collect();
322+
//new PotionBandolier().collect();
322323

323-
new DewVial().fill().collect();
324+
//new DewVial().fill().collect();
324325

325-
new BookOfDead().collect();
326-
new BookOfLife().collect();
327-
new BookOfTranscendence().collect();
328-
new Amulet().collect();
326+
//new BookOfDead().collect();
327+
//new BookOfLife().collect();
328+
//new BookOfTranscendence().collect();
329+
//new Amulet().collect();
329330

330-
(hero.belongings.misc2 = new RingOfWealth()).identify().upgrade(28);
331-
hero.belongings.misc2.activate(hero);
332-
new PotionOfHealing().quantity(50).identify().collect();
331+
//(hero.belongings.misc2 = new RingOfWealth()).identify().upgrade(28);
332+
//hero.belongings.misc2.activate(hero);
333+
//new PotionOfHealing().quantity(50).identify().collect();
333334

334335
//hero.HT=hero.HP=999;
335-
hero.STR = hero.STR + 10;
336-
PlateArmor armor1 = new PlateArmor();
337-
armor1.reinforce().upgrade(15).identify().collect();
336+
//hero.STR = hero.STR + 10;
337+
//PlateArmor armor1 = new PlateArmor();
338+
//armor1.reinforce().upgrade(15).identify().collect();
338339
// PlateArmor armor2 = new PlateArmor();
339340
// armor2.upgrade(14).identify().collect();
340341

341-
WarHammer hammer = new WarHammer();
342-
hammer.reinforce().upgrade(15).identify().collect();
342+
//WarHammer hammer = new WarHammer();
343+
//hammer.reinforce().upgrade(15).identify().collect();
343344

344-
Glaive glaive = new Glaive();
345-
glaive.reinforce().upgrade(15).identify().collect();
345+
//Glaive glaive = new Glaive();
346+
//glaive.reinforce().upgrade(15).identify().collect();
346347

347348
Spork spork = new Spork();
348-
spork.reinforce().upgrade(15).identify().collect();
349+
spork.enchantNom().upgrade(4).identify().collect();
350+
new Spork().enchant(new Slashing()).upgrade(4).identify().collect();
351+
if (hero.heroClass == HeroClass.HUNTRESS) {
352+
new Boomerang().enchant(new Slashing()).identify().collect();
353+
}
349354

350-
Towel towel = new Towel();
351-
towel.identify().collect();
355+
//spork.reinforce().upgrade(15).identify().collect();
352356

353-
Spectacles specs = new Spectacles();
354-
specs.collect();
357+
//Towel towel = new Towel();
358+
//towel.identify().collect();
359+
360+
//Spectacles specs = new Spectacles();
361+
//specs.collect();
355362
//Dewcatcher.Seed seed3 = new Dewcatcher.Seed(); seed3.collect();
356363
//Flytrap.Seed seed1 = new Flytrap.Seed(); seed1.collect();
357364
//Phaseshift.Seed seed2 = new Phaseshift.Seed(); seed2.collect();
@@ -361,16 +368,16 @@ public static void playtest(Hero hero) {
361368
//new JupitersWrath().enchantJupiter().setTesting().identify().collect();
362369
//new CromCruachAxe().enchantLuck().setTesting().identify().collect();
363370
//new AresSword().enchantAres().setTesting().identify().collect();
364-
ScrollHolder bag2 = new ScrollHolder();
365-
bag2.collect();
371+
//ScrollHolder bag2 = new ScrollHolder();
372+
//bag2.collect();
366373
// armor = new PlateArmor(); armor.upgrade(130); armor.identify().collect();
367374
//OrbOfZot zot = new OrbOfZot(); zot.collect();
368375
//WarHammer hammer = new WarHammer();
369376
//hammer.identify().collect();
370377
// Wand wand = new WandOfDisintegration(); wand.upgrade(50); wand.collect();
371-
Wand wand3 = new WandOfFlock();
372-
wand3.upgrade(15).reinforce();
373-
wand3.collect();
378+
//Wand wand3 = new WandOfFlock();
379+
//wand3.upgrade(15).reinforce();
380+
//wand3.collect();
374381
// Wand wand2 = new WandOfTelekinesis(); wand2.upgrade(15); wand2.collect();
375382
//Wand wand3 = new WandOfTeleportation(); wand3.upgrade(15); wand3.collect();
376383
// Wand wand4 = new WandOfBlink(); wand4.upgrade(15); wand4.collect();
@@ -453,7 +460,7 @@ public static void playtest(Hero hero) {
453460
GLog.i("Playtest Activated");
454461

455462

456-
for (int i = 0; i < 50; i++) {
463+
/*for (int i = 0; i < 50; i++) {
457464
//Scroll scroll = new ScrollOfMagicalInfusion();
458465
//scroll.identify().collect();
459466
Scroll scroll2 = new ScrollOfMagicMapping();
@@ -481,7 +488,7 @@ public static void playtest(Hero hero) {
481488
new Stormvine.Seed().collect();
482489
new Sungrass.Seed().collect();
483490
484-
}
491+
}*/
485492

486493
/*
487494
for(int i=1; i<61; i++){

app/src/main/java/com/github/dachhack/sprout/actors/mobs/Eye.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ public boolean attack(Char enemy) {
131131
}
132132

133133
if (hit(this, ch, true)) {
134-
ch.damage(Random.NormalIntRange(14, 20+ adjustForDepth(0)), this);
134+
ch.damage(Random.NormalIntRange(14, 45), this);
135135

136136
if (Dungeon.visible[pos]) {
137137
ch.sprite.flash();

app/src/main/java/com/github/dachhack/sprout/items/DewVial.java

+3-6
Original file line numberDiff line numberDiff line change
@@ -103,8 +103,8 @@ public void setVol (int vol) {
103103
volume=vol;
104104
}
105105

106-
public int upgradeLimit() {
107-
int levelLimit = 2+(int)(Statistics.deepestFloor/2f);
106+
public static int upgradeLimit() {
107+
int levelLimit = 2+Math.round(Statistics.deepestFloor/2f);
108108
if (Dungeon.hero.heroClass == HeroClass.MAGE){levelLimit++;}
109109
levelLimit = Math.min(15,levelLimit);
110110
return levelLimit;
@@ -324,10 +324,7 @@ public void execute(final Hero hero, String action) {
324324
public static boolean uncurse(Hero hero, Item... items) {
325325

326326

327-
int levelLimit = 0;
328-
if (Dungeon.dewVial != null) {
329-
levelLimit = Dungeon.dewVial.upgradeLimit();
330-
}
327+
int levelLimit = DewVial.upgradeLimit();
331328

332329
float lvlchance = 0.50f;
333330
if (hero.heroClass == HeroClass.MAGE){lvlchance = 0.55f;}

app/src/main/java/com/github/dachhack/sprout/items/weapon/Weapon.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -339,13 +339,13 @@ public static abstract class Enchantment implements Bundlable {
339339
Luck.class, Nomnom.class, BuzzSaw.class, NeptuneShock.class,
340340
CromLuck.class, AresLeech.class, Elastic.class};
341341
private static final float[] chances = new float[] { 10, 10, 1, 2, 1,
342-
2, 6, 3, 2, 2, 0, 0, 0, 0, 0, 4 };
342+
2, 6, 3, 2, 2, 0, 0, 0, 0, 0, 10 };
343343

344344
private static final float[] chancesLow = new float[] { 10, 10, 0, 0, 1,
345345
2, 6, 0, 0, 2, 0, 0, 0, 0, 0, 0 };
346346

347347
private static final float[] chancesAdv = new float[] { 2, 2, 2, 2, 2,
348-
2, 2, 2, 2, 2, 0, 0,0, 0, 0, 0 };
348+
2, 2, 2, 2, 2, 0, 0,0, 0, 0, 2 };
349349

350350
private static final float[] chancesNom = new float[] { 0, 0, 0, 0, 0,
351351
0, 0, 0, 0, 0, 1, 0,0, 0, 0, 0 };

app/src/main/java/com/github/dachhack/sprout/items/weapon/enchantments/Nomnom.java

+7-7
Original file line numberDiff line numberDiff line change
@@ -38,19 +38,19 @@ public class Nomnom extends Weapon.Enchantment {
3838
public boolean proc(RelicMeleeWeapon weapon, Char attacker, Char defender, int damage) {
3939
return false;
4040
}
41-
41+
4242
@Override
4343
public boolean proc(Weapon weapon, Char attacker, Char defender, int damage) {
4444
// lvl 0 - 8%
4545
// lvl 1 ~ 9%
4646
// lvl 2 ~ 10%
4747
int level = Math.max(0, weapon.level*3);
48-
48+
4949
if (Random.Int(level + 100) >= 75) {
5050

5151
defender.damage(defender.HP, this);
52-
53-
52+
53+
5454
int maxValue = damage * (level + 2) / (level + 3);
5555
int effValue = Math.min(Random.IntRange(0, maxValue), attacker.HT-attacker.HP);
5656

@@ -60,11 +60,11 @@ public boolean proc(Weapon weapon, Char attacker, Char defender, int damage) {
6060
attacker.sprite.emitter().start(Speck.factory(Speck.HEALING), 0.4f, 1);
6161
attacker.sprite.showStatus(CharSprite.POSITIVE, Integer.toString(effValue));
6262
}
63-
63+
6464
attacker.buff(Hunger.class).satisfy(maxValue);
6565
SpellSprite.show(attacker, SpellSprite.FOOD);
66-
67-
66+
67+
6868
return true;
6969

7070
} else {

app/src/main/java/com/github/dachhack/sprout/items/weapon/missiles/MissileWeapon.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ public void proc(Char attacker, Char defender, int damage) {
142142
detach(null);
143143
}
144144
}
145-
if (defender.buff(PinCushion.class) == null || Random.Int(Dungeon.hero.heroClass == HeroClass.HUNTRESS ? 2 : 5) == 0) {
145+
if ((defender.buff(PinCushion.class) == null || Random.Int(Dungeon.hero.heroClass == HeroClass.HUNTRESS ? 2 : 5) == 0) && !(this instanceof Boomerang | this instanceof JupitersWrath)) {
146146
Buff.affect(defender, PinCushion.class).stick(this);
147147
}
148148
}

app/src/main/java/com/github/dachhack/sprout/sprites/OtilukeNPCSprite.java

-9
Original file line numberDiff line numberDiff line change
@@ -17,17 +17,8 @@
1717
*/
1818
package com.github.dachhack.sprout.sprites;
1919

20-
import javax.microedition.khronos.opengles.GL10;
21-
22-
import android.opengl.GLES20;
23-
2420
import com.github.dachhack.sprout.Assets;
25-
import com.github.dachhack.sprout.actors.Char;
26-
import com.github.dachhack.sprout.effects.Halo;
27-
import com.github.dachhack.sprout.effects.particles.ElmoParticle;
28-
import com.watabou.noosa.Game;
2921
import com.watabou.noosa.TextureFilm;
30-
import com.watabou.utils.PointF;
3122

3223
public class OtilukeNPCSprite extends MobSprite {
3324

app/src/main/java/com/github/dachhack/sprout/windows/WndBag.java

+19-36
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
import com.github.dachhack.sprout.items.AdamantRing;
2929
import com.github.dachhack.sprout.items.AdamantWand;
3030
import com.github.dachhack.sprout.items.AdamantWeapon;
31+
import com.github.dachhack.sprout.items.DewVial;
3132
import com.github.dachhack.sprout.items.EquipableItem;
3233
import com.github.dachhack.sprout.items.Gold;
3334
import com.github.dachhack.sprout.items.Item;
@@ -47,6 +48,7 @@
4748
import com.github.dachhack.sprout.items.weapon.melee.MeleeWeapon;
4849
import com.github.dachhack.sprout.items.weapon.missiles.Boomerang;
4950
import com.github.dachhack.sprout.items.weapon.missiles.JupitersWrath;
51+
import com.github.dachhack.sprout.plants.Dewcatcher;
5052
import com.github.dachhack.sprout.plants.Plant.Seed;
5153
import com.github.dachhack.sprout.scenes.GameScene;
5254
import com.github.dachhack.sprout.scenes.PixelScene;
@@ -372,47 +374,28 @@ public void item(Item item) {
372374
enable(false);
373375
} else {
374376

375-
int levelLimit = 0;
376-
if (Dungeon.dewVial != null) {
377-
levelLimit = Dungeon.dewVial.upgradeLimit();
378-
}
379-
380-
enable(mode == Mode.FOR_SALE
381-
&& (item.price() > 0)
382-
&& (!item.isEquipped(Dungeon.hero) || !item.cursed)
383-
384-
|| mode == Mode.UPGRADEABLE
385-
&& ((item.isUpgradable() && item.level<15 && !item.isReinforced())
386-
|| item.isUpgradable() && item.isReinforced())
387-
|| mode == Mode.UPGRADEDEW
388-
&& (item.isUpgradable() && item.level <= levelLimit)
389-
|| mode == Mode.UPGRADEABLESIMPLE
390-
&& item.isUpgradable()
391-
|| mode == Mode.ADAMANT
392-
&& (item instanceof AdamantArmor || item instanceof AdamantRing || item instanceof AdamantWand || item instanceof AdamantWeapon)
393-
|| mode == Mode.REINFORCED
394-
&& item.isReinforced()
395-
|| mode == Mode.NOTREINFORCED
396-
&& (!item.isReinforced() && item.isUpgradable())
397-
|| mode == Mode.UNIDENTIFED
398-
&& !item.isIdentified()
399-
|| mode == Mode.QUICKSLOT
400-
&& (item.defaultAction != null)
401-
|| mode == Mode.WEAPON
402-
&& (item instanceof MeleeWeapon || item instanceof Boomerang || item instanceof JupitersWrath)
403-
|| mode == Mode.ARMOR
404-
&& (item instanceof Armor)
405-
|| mode == Mode.ENCHANTABLE
406-
&& (item instanceof MeleeWeapon || item instanceof Boomerang || item instanceof Armor)
407-
|| mode == Mode.JOURNALPAGES
408-
&& (item instanceof JournalPage)
377+
int levelLimit = DewVial.upgradeLimit();
378+
379+
enable(mode == Mode.FOR_SALE && (item.price() > 0) && (!item.isEquipped(Dungeon.hero) || !item.cursed)
380+
|| mode == Mode.UPGRADEABLE && ((item.isUpgradable() && item.level<15 && !item.isReinforced())
381+
|| item.isUpgradable() && item.isReinforced())
382+
|| mode == Mode.UPGRADEDEW && (item.isUpgradable() && item.level <= levelLimit)
383+
|| mode == Mode.UPGRADEABLESIMPLE && item.isUpgradable()
384+
|| mode == Mode.ADAMANT && (item instanceof AdamantArmor || item instanceof AdamantRing || item instanceof AdamantWand || item instanceof AdamantWeapon)
385+
|| mode == Mode.REINFORCED && item.isReinforced()
386+
|| mode == Mode.NOTREINFORCED && (!item.isReinforced() && item.isUpgradable())
387+
|| mode == Mode.UNIDENTIFED && !item.isIdentified()
388+
|| mode == Mode.QUICKSLOT && (item.defaultAction != null)
389+
|| mode == Mode.WEAPON && (item instanceof MeleeWeapon || item instanceof Boomerang || item instanceof JupitersWrath)
390+
|| mode == Mode.ARMOR && (item instanceof Armor)
391+
|| mode == Mode.ENCHANTABLE && (item instanceof MeleeWeapon || item instanceof Boomerang || item instanceof Armor)
392+
|| mode == Mode.JOURNALPAGES && (item instanceof JournalPage)
409393
|| mode == Mode.WAND && (item instanceof Wand)
410394
|| mode == Mode.SEED && (item instanceof Seed)
411395
|| mode == Mode.FOOD && (item instanceof Food)
412396
|| mode == Mode.POTION && (item instanceof Potion)
413397
|| mode == Mode.SCROLL && (item instanceof Scroll)
414-
|| mode == Mode.EQUIPMENT
415-
&& (item instanceof EquipableItem)
398+
|| mode == Mode.EQUIPMENT && (item instanceof EquipableItem)
416399
|| mode == Mode.ALL);
417400
}
418401
} else {
8.08 KB
Loading
9.68 KB
Loading
7.15 KB
Loading
2.71 KB
Loading
-975 Bytes
Loading

0 commit comments

Comments
 (0)