Skip to content

Commit

Permalink
0.6.0.ru russian.
Browse files Browse the repository at this point in the history
  • Loading branch information
egoal committed May 17, 2021
1 parent 6c25a33 commit 10f69c2
Show file tree
Hide file tree
Showing 21 changed files with 189 additions and 152 deletions.
4 changes: 2 additions & 2 deletions core/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.egoal.darkestpixeldungeon"
android:installLocation="auto"
android:versionCode="41"
android:versionName="0.6.0">
android:versionCode="42"
android:versionName="0.6.0.ru">

<uses-permission android:name="android.permission.VIBRATE" />

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -276,8 +276,11 @@ class Hero : Char() {
}.shuffled()

for (i in 0 until min(avals.size, followers.size)) {
followers[i].pos = avals[i]
level.mobs.add(followers[i] as Mob)
val m = followers[i] as Mob
m.pos = avals[i]
m.resetTarget()

level.mobs.add(m)
}
followers.clear()
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import com.egoal.darkestpixeldungeon.*
import com.egoal.darkestpixeldungeon.actors.Damage
import com.egoal.darkestpixeldungeon.actors.buffs.Pressure
import com.egoal.darkestpixeldungeon.actors.hero.perks.*
import com.egoal.darkestpixeldungeon.effects.PerkGain
import com.egoal.darkestpixeldungeon.items.armor.*
import com.egoal.darkestpixeldungeon.items.artifacts.*
import com.egoal.darkestpixeldungeon.items.bags.SeedPouch
Expand All @@ -20,6 +21,7 @@ import com.egoal.darkestpixeldungeon.items.weapon.missiles.*
import com.egoal.darkestpixeldungeon.messages.M
import com.egoal.darkestpixeldungeon.messages.Messages
import com.egoal.darkestpixeldungeon.plants.CorrodeCyan
import com.egoal.darkestpixeldungeon.utils.GLog
import com.watabou.utils.Bundle
import com.watabou.utils.Random
import kotlin.math.min
Expand Down Expand Up @@ -99,6 +101,19 @@ enum class HeroClass(private val title: String) {
hero.addResistances(Damage.Element.LIGHT, -0.1f)
hero.addResistances(Damage.Element.SHADOW, 0.1f)
}

override fun upgradeHero(hero: Hero) {
super.upgradeHero(hero)
if (hero.lvl == 12) {
val p = WandPerception()
if(p.isAcquireAllowed(hero)){
hero.heroPerk.add(p)
PerkGain.Show(hero, p)

GLog.p(M.L(p, "gain_level_2"))
}
}
}
},

ROGUE("rogue") {
Expand Down Expand Up @@ -285,7 +300,7 @@ enum class HeroClass(private val title: String) {
}

// called when hero level up
fun upgradeHero(hero: Hero) {
open fun upgradeHero(hero: Hero) {
val ht = hero.HT
val hp = hero.HP

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ abstract class Perk(val maxLevel: Int = 1, var level: Int = 1) : Bundlable {
GoodAppetite() to 1f,
StrongConstitution() to 1f,
Keen() to 1f,
WandPerception() to 1f,
WandPerception() to 0f,
NightVision() to 0.75f,
Telepath() to 1f,
Fearless() to 1f,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ class WandCharger : Perk(3) {
fun factor(): Float = 2f - 0.8f.pow(level)
}

class WandPerception : Perk(1) {
class WandPerception : Perk(2) {
override fun image(): Int = PerkImageSheet.WAND_PERCEPTION

fun onWandUsed(wand: Wand) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,11 +75,11 @@ object Bestiary {
classes = arrayOf(Rat::class.java, Slug::class.java, Gnoll::class.java)
}
3 -> {
chances = floatArrayOf(1f, 1f, 4f, 0.5f, 1f)
chances = floatArrayOf(1f, 0.5f, 4f, 0.5f, 1f)
classes = arrayOf(Rat::class.java, Slug::class.java, Gnoll::class.java, Crab::class.java, Swarm::class.java)
}
4 -> {
chances = floatArrayOf(0.5f, 0.5f, 2f, 3f, 1f, 0.02f)
chances = floatArrayOf(0.5f, 0.25f, 2f, 3f, 1f, 0.02f)
classes = arrayOf(Rat::class.java, Slug::class.java, Gnoll::class.java, Crab::class.java, Swarm::class.java, MadMan::class.java)
}
5 -> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -270,6 +270,10 @@ abstract class Mob : Char() {
}
}

fun resetTarget() {
target = -1
}

protected open fun canAttack(enemy: Char): Boolean = Dungeon.level.adjacent(pos, enemy.pos)

protected open fun getCloser(target: Int): Boolean {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,10 @@ abstract class DamageWand(isMissile: Boolean) : Wand(isMissile) {
PI.toFloat() / 3f, particleColor(), Random.NormalIntRange(12, 20))
}

if (!enemy.isAlive) onKilled(damage)
if (!enemy.isAlive){
hero.onKillChar(enemy)
onKilled(damage)
}

return true
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -980,6 +980,8 @@ abstract class Level : Bundlable {
val prop = 0.3f - Dungeon.depth / 5 * 0.025f
var cnt = 0
while (Random.Float() < prop && cnt++ < 5) items.add(Torch())
if (cnt == 0 && Dungeon.torch < 1f) // u should give us at least one.
items.add(Torch())
}

// dagger
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,11 @@ enum class Languages(val nativeName: String,
arrayOf<String>("Egoal", "endlesssolitude", " 路人NPC"),
arrayOf<String>(" 1834515403a", "Fevre", "Fishbone", "MrKukurykpl", "Omicronrg9", "Piedro0", "SeaMonser", "riwansia", "shenlingfeiniao")),

CHINESE_TR("繁体中文", Locale.TRADITIONAL_CHINESE, Status.INCOMPLETE, arrayOf<String>("Egoal"), arrayOf<String>("那些回忆")),
CHINESE_TR("繁体中文", Locale.TRADITIONAL_CHINESE, Status.UNREVIEWED, arrayOf<String>("Egoal"), arrayOf<String>("那些回忆")),

CHINESE("中文", Locale.CHINESE, Status.REVIEWED, arrayOf<String>("Jinkeloid(zdx00793)"),
arrayOf<String>("931451545", "HoofBumpBlurryface", "Lery", "Lyn-0401", "ShatteredFlameBlast", "Hmdzl001", "Tempest102")),
RUSSIAN("русский", Locale("ru"), Status.INCOMPLETE, arrayOf<String>("John Deeper"), arrayOf<String>()),
RUSSIAN("русский", Locale("ru"), Status.REVIEWED, arrayOf<String>("John Deeper"), arrayOf<String>("Red Rum")),
;

enum class Status {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ class ChangesScene : PixelScene() {
// add versions' button
val HSPLIT = "---"
val oldVersions = arrayOf(
"0.6.0", HSPLIT,
"0.5.0", HSPLIT,
"0.4.3", "0.4.2a", "0.4.2", "0.4.1", "0.4.0", HSPLIT,
"0.3.2a", "0.3.2", "0.3.1a", "0.3.1", "0.3.0", HSPLIT,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -637,7 +637,7 @@ actors.mobs.npcs.ghosthero.voice_cured_1=Are you OK?...
actors.mobs.npcs.ghosthero.voice_cured_2=I'm curing wound for you, please hold on...

actors.mobs.npcs.imp.name=ambitious imp
actors.mobs.npcs.imp.quest_1=Are you an adventurer? I love adventurers! You can always rely on them if something needs to be killed. Am I right? For a bounty of course ;)\nIn my case this is _golems_ who need to be killed. You see, I'm going to start a little business here, but these stupid monks and golems are bad for business! So please, kill, and collect dwarf tokens... let's say _8 tokens_ and a reward is yours.
actors.mobs.npcs.imp.quest_1=Are you an adventurer? I love adventurers! You can always rely on them if something needs to be killed. Am I right? For a bounty of course ;)\nIn my case this is _golems_ or _monks_ who need to be killed. You see, I'm going to start a little business here, but these stupid monks and golems are bad for business! So please, kill, and collect dwarf tokens... let's say _8 tokens_ and a reward is yours.
actors.mobs.npcs.imp.quest_2=Hey, %s! What about your hunting? I know your skills are reliable :) Be careful of these monks and golems.
actors.mobs.npcs.imp.cya=See you, %s!
actors.mobs.npcs.imp.hey=Psst, %s!
Expand Down
Loading

0 comments on commit 10f69c2

Please sign in to comment.