Dithmenos 0.14.0 source dive, AKA more than you ever needed to know about the Shadow God(I don't guarantee anything in this will be accurate come 0.15!)
Umbra: ....../*.....ish-As a Dith worshipper, your umbra radius = piety / sqrt(393) which covers LoS at ****** (160) piety.
Night vision: ......-Night vision is the property of being immune to umbra maluses.
-Players have night vision if undead, Dith ...... or better or Yred **.... or better.
-Monsters have night vision if undead, Dith worshipper or Yred worshipper.
-Bolts suffer an accuracy penalty if the target is in an umbra and the shooter lacks night vision:
- Code:
if (!nightvision && you.umbra(true, true))
real_tohit -= 2 + random2(4);
-Similarly, meleeing an actor standing in an umbra, if the attacker lacks night vision, suffers an accuracy penalty:
- Code:
else if (!attacker->nightvision()
&& defender->umbra(true, true))
mhit -= 2 + random2(4);
-This is a weird one - monsters that EMIT their own umbra (or are wearing the ring of shadows!) (or are shadows) get a boost to monster stealth, which is only used to determine how hard it is to see an invisible monster's disturbance.
- Code:
if (mons_class_flag(type, M_SHADOW) || umbra_radius2() != -1)
actual_stealth += 3;
- Code:
if (_hashed_rand(mons, 0, 7) >= mons->stealth() + 4
&& (mons->stealth() <= -2 || !_hashed_rand(mons, 1, 4)))
{
_mark_invisible_at(gp);
}
-Player stealth is boosted in an umbra too - and the higher your Dith/Yred piety, the more it boosts it - from +0% at ...... to +100% at MAX_PIETY:
- Code:
if (you.umbra())
{
if (you_worship(GOD_DITHMENOS) || you_worship(GOD_YREDELEMNUL))
stealth = stealth * (you.piety + MAX_PIETY) / MAX_PIETY;
else if (player_equip_unrand(UNRAND_SHADOWS))
stealth = stealth * 3 / 2;
}
-I can't tell if having an umbra that doesn't stretch to other tiles yet is good enough for these bonuses, or if you need to wait for roughly *..... before they come online.
---
Shadow step: **....-Base failure rate (not a probability):
-To target something with shadow step it must be within your umbra and it must be 'not moving':
--Asleep
--Cannot move (paralysed, stupefied (Zin recite paralysis), fully petrified or Shedu preparing to resurrect another)
--Is stationary (a kind of monster that is naturally stationary or an animal withdrawn into its shell)
-So as far as I can tell you can't net something and then shadow step to it.
Black smoke/fog: **..../***...ish-Imagine two lines on your HP meter. The top line is always at half your max HP.
-After exceeding ** piety, as your piety approaches 200, the bottom line approaches 0 of your max HP.
When you are hit, if the amount of damage you took falls into this range, then the % past the bottom line it got is how likely dark smoke is to appear. (If you're hit for more than half your max HP, the % chance is more than 100 - so you always emit. Conversely, if you're at max piety, even a tiny nick has a single digit % chance of emitting smog.)
-Dark smoke always comes out with the same thickness regardless of damage taken.
---
Shadow mimic: ***.../****..ish-Your shadow mimic acts with 0% chance at ***... piety, 10% chance at ****.. piety, 50% chance at 200 piety (in a linearly scaling fashion).
-Your shadow has a HD of weapon skill*1/2 + fighting skill*1/2 (min 1 max 27). Most importantly of all, it is a monster - so it does monster melee, monster ranged attacks and monster spellcasting (instead of the player version thereof). Nothing about the shadow monster is varied based on what species you are or anything like that.
1)
Shadow melee: Your shadow holds a shadow clone of your weapon (the same base and sub type, so unenchanted, unbranded and no artifact properties). This can distract enemies (for the purposes of stabbing).
2)
Shadow throw: Your shadow throws/fires a shadow clone of the thing you threw/fired (again, no enchantment/brands/artifact properties). This is monster ranged, so I bet it's really powerful. Maybe it can distract as well, I haven't tried it yet.
3)
Shadow magic: If it targets yourself or has no target, it is not mimiced. If it's an enchantment that has no monster version, it is not mimiced. Instead of using the default shadow HD, the HD is set to the smaller of 3 * spell level and xl/2 (minimum 1). If it was an enchantment, the shadow casts the monster version. If it was a beam, the shadow casts shadow bolt. If it was not a beam, the shadow casts shadow shard.
-Both spells work the same except one beams and the other doesn't:
- Code:
beam.damage = 3d(8+(power/11))
beam.colour = MAGENTA
beam.flavour = BEAM_MMISSILE (same as force lance, stone arrow, iron shot...)
beam.hit = 17 + power / 25
---
Shadow Form: *****.Important stuff:-Base failure rate (not a probability):
-Shadow form duration: pow = invo*2, duration = 18+2d(invo*2) (maximum of 100)
-When you melee, your damage is divided by 2 (with random floor/ceil for .5). This is after fighting skill, slaying, str/dex effect but before ac and stab. So it makes it a lot harder to get past AC, it's not just half expected DPS.
-If you take 1 or more damage in shadow form, Dith dark smoke emission is guaranteed.
-Just before your HP would be reduced by taking damage, shadow form steps in and halves it, turning the rest into drain:
- Code:
if (you.form == TRAN_SHADOW)
{
drain_amount = (dam - (dam / 2));
dam /= 2;
}
-Undead resistance suite: rTorment rPois+++ rN+++ rRot+++
-It gives you stealth race_mod of 30. (For comparison, tree is 27, spider/jelly/wisp is 21, octopode is 18, bat is 17, vampire is 18-21)
-It gives you MR IMMUNE.
-You are invisible while you are in shadow form (unless you are backlit).
-You have 2 extra negative enhancers when casting any spell.
-You are not technically undead, as far as I can gather from the source.
Not as important (or obvious) stuff:-It makes you 'a swirling mass of dark shadows'.
-Your tile becomes that of the monster 'shadow'.
-You can wield and wear and keep your mutations.
-Shadow form makes you extra balanced in water. (Assuming I'm reading player::extra_balanced() in player-act.cc right.)
-It halves your weight. (This makes beams/bolts that knockback harder to resist. It would also shrink your carry capacity, but the calculation use your untransformed weight, not your current weight.)
-You still breathe.
-It makes your genus the same as MONS_SHADOW.
-You don't bleed.
-No shatter immunity.
---
Appendix A: Converting a base failure rate into a true failure rateif
random2avg(100, 3) < base failure rate then using the ability worked.
Basically, it calls random2(100) (random 0-99 inclusive) three times and takes the average of those three rolls.
The result is that 'unlucky' and 'lucky' rolls are less likely - if your failure rate is awful then it becomes awfuler, and if your success rate is great than it becomes greater.
But - what you see on the ability menu is the true failure rate, post figuring out how likely you are to pass
random2avg(100, 3) < base failure rate, so you don't have to care about any of this.
(See spl-cast.cc _get_true_fail_rate