Generate a YGOPro Lua script for the following Yu-Gi-Oh card effect:
Gains 500 ATK for each "Lava Battleguard" you control.
--バーバリアン2号
--Swamp Battleguard
local s,id=GetID()
function s.initial_effect(c)
	local e1=Effect.CreateEffect(c)
	e1:SetType(EFFECT_TYPE_SINGLE)
	e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
	e1:SetRange(LOCATION_MZONE)
	e1:SetCode(EFFECT_UPDATE_ATTACK)
	e1:SetValue(s.value)
	c:RegisterEffect(e1)
end
s.listed_names={20394040}
function s.filter(c)
	return c:IsFaceup() and c:IsCode(20394040)
end
function s.value(e,c)
	return Duel.GetMatchingGroupCount(s.filter,c:GetControler(),LOCATION_MZONE,0,nil)*500
end