[r2096] killing blow with Blood Grasp do not heal player

Where bugs go to lie down and rest

Moderator: Moderator

Post Reply
Message
Author
hops
Halfling
Posts: 111
Joined: Tue Sep 21, 2010 9:05 am

[r2096] killing blow with Blood Grasp do not heal player

#1 Post by hops »

But the damage of the spell will be 1000+ with blood fury and crit for my corruptor, killing most mobs outright, making this spell much less useful.

yufra
Perspiring Physicist
Posts: 1332
Joined: Tue Jul 13, 2010 2:53 pm

Re: [r2096] killing blow with Blood Grasp do not heal player

#2 Post by yufra »

You could try this fix in tome/data/damage_types.lua:

Code: Select all

-- Drain Life
newDamageType{
	name = "drain life", type = "DRAINLIFE",
	projector = function(src, x, y, type, dam)
		if _G.type(dam) == "number" then dam = {dam=dam, healfactor=0.4} end
		local target = game.level.map(x, y, Map.ACTOR)
		local realdam = DamageType:get(DamageType.BLIGHT).projector(src, x, y, DamageType.BLIGHT, dam.dam)
		if realdam > 0 then
			src:heal(realdam * dam.healfactor)
			game.logSeen(target, "%s drains life from %s!", src.name:capitalize(), target.name)
		end
	end,
}
This checks if there is anything there to start with, then if any damage is actually done (which is zero if there is no target) and finally heals and adds the log message.
<DarkGod> lets say it's intended

hops
Halfling
Posts: 111
Joined: Tue Sep 21, 2010 9:05 am

Re: [r2096] killing blow with Blood Grasp do not heal player

#3 Post by hops »

thanks

darkgod
Master of Eyal
Posts: 10751
Joined: Wed Jul 24, 2002 9:26 pm
Location: Angolwen
Contact:

Re: [r2096] killing blow with Blood Grasp do not heal player

#4 Post by darkgod »

fixed
[tome] joylove: You can't just release an expansion like one would release a Kraken XD
--
[tome] phantomfrettchen: your ability not to tease anyone is simply stunning ;)

Post Reply