Generate a YGOPro Lua script for the following Yu-Gi-Oh card effect:
If a player would take damage from a battle involving this card, they gain that much LP, instead.
--衛生兵マッスラー
--Muscle Medic
local s,id=GetID()
function s.initial_effect(c)
	--damage conversion
	local e1=Effect.CreateEffect(c)
	e1:SetType(EFFECT_TYPE_FIELD)
	e1:SetCode(EFFECT_REVERSE_DAMAGE)
	e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
	e1:SetRange(LOCATION_MZONE)
	e1:SetTargetRange(1,1)
	e1:SetValue(s.rev)
	c:RegisterEffect(e1)
end
function s.rev(e,re,r,rp,rc)
	return r&REASON_BATTLE~=0 and (Duel.GetAttacker()==e:GetHandler() or (Duel.GetAttackTarget() and Duel.GetAttackTarget()==e:GetHandler()))
end