[1.0.4] Error in range of Healing Nexus

Where bugs go to lie down and rest

Moderator: Moderator

Post Reply
Message
Author
jenx
Sher'Tul Godslayer
Posts: 2263
Joined: Mon Feb 14, 2011 11:16 pm

[1.0.4] Error in range of Healing Nexus

#1 Post by jenx »

Healing Nexus has range of 10, and then a range of 0 (and hence, a range of 0). And I think requires_target = true should be removed, but I'm not completely sure of this.

Code: Select all

newTalent{
	name = "Healing Nexus",
	type = {"wild-gift/harmony", 4},
	require = gifts_req4,
	points = 5,
	equilibrium = 24,
	cooldown = 20,
	range = 10,
	tactical = { DISABLE = 3, HEAL = 0.5 },
	direct_hit = true,
	requires_target = true,
	range = 0,
	radius = function(self, t) return 1 + self:getTalentLevelRaw(t) end,
	target = function(self, t) return {type="ball", range=self:getTalentRange(t), radius=self:getTalentRadius(t), selffire=true, talent=t} end,
	action = function(self, t)
		local tg = self:getTalentTarget(t)
		local grids = self:project(tg, self.x, self.y, function(px, py)
			local target = game.level.map(px, py, Map.ACTOR)
			if not target then return end
			target:setEffect(target.EFF_HEALING_NEXUS, 3 + self:getTalentLevelRaw(t), {src=self, pct=0.4 + self:getTalentLevel(t) / 10, eq=5 + self:getTalentLevel(t)})
		end)
		game.level.map:particleEmitter(self.x, self.y, tg.radius, "ball_acid", {radius=tg.radius})
		game:playSoundNear(self, "talents/spell_generic2")
		return true
	end,
	info = function(self, t)
		return ([[A wave of natural energies flow around you in a radius of %d; all creatures hit will suffer from the Healing Nexus status for %d turns.
		While under the effect, all healing done to the creature will instead heal you for %d%% of the heal value (and no healing at all goes to the target).
		Each heal leeched will also restore %d equilibrium.]]):
		format(self:getTalentRadius(t), 3 + self:getTalentLevelRaw(t), (0.4 + self:getTalentLevel(t) / 10) * 100, 5 + self:getTalentLevel(t))
	end,
MADNESS rocks

Post Reply