anchor.diff:  			chainshock(summonerchain)
   		else
   			summonerchain = Beam(summoner,"lightning[rand(1,12)]",'icons/effects/effects.dmi',INFINITY, INFINITY,/obj/effect/ebeam/chain)
  -	if(enemy && enemychain && !qdeleted(enemychain))
  -		chainshock(enemychain)
  -	else
  -		enemy = null
  -		enemychain = null
  +	if(enemychains.len)
  +		for(var/chain in enemychains)
  +			if(!qdeleted(chain))
  +				chainshock(chain)
  +			else
  +				enemychains -= chain
   
   /mob/living/simple_animal/hostile/guardian/beam/Destroy()
   	removechains()
  
positive.code: 	if(summonerchain)
  		qdel(summonerchain)
  		summonerchain = null
  	if(enemychain)
  		qdel(enemychain)
  		enemychain = null
  		enemy = null
  
  /mob/living/simple_animal/hostile/guardian/beam/proc/chainshock(datum/beam/B)
  	var/list/turfs = list()
  
negative.code: 
  /mob/living/simple_animal/hostile/guardian/beam
  	next_move_modifier = 0.5
  	melee_damage_lower = 5
  	melee_damage_upper = 5
  	attacktext = "shocks"
  	melee_damage_type = BURN
  	attack_sound = 'sound/machines/defib_zap.ogg'
  	damage_coeff = list(BRUTE = 0.7, BURN = 0.7, TOX = 0.7, CLONE = 0.7, STAMINA = 0, OXY = 0.7)
  	range = 7
  	playstyle_string = "As a lightning type, you will apply lightning chains to targets on attack and have a lightning chain to your summoner. Lightning chains will shock anyone near them."
  	magic_fluff_string = "..And draw the Tesla, a shocking, lethal source of power."
  	tech_fluff_string = "Boot sequence complete. Lightning modules active. Holoparasite swarm online."
  	var/datum/beam/summonerchain
  	var/list/enemychains = list()
  
  /mob/living/simple_animal/hostile/guardian/beam/AttackingTarget()
  	if(..())
  		if(isliving(target) && target != src && target != summoner)
  			for(var/chain in enemychains)
  				var/datum/beam/B = chain
  				if(B.target == target)
  					return //oh this guy already HAS a chain, let's not chain again
  			if(enemychains.len > 2)
  				var/datum/beam/C = pick(enemychains)
  				qdel(C)
  				enemychains -= C
  			enemychains += Beam(target,"lightning[rand(1,12)]",'icons/effects/effects.dmi',70, 7,/obj/effect/ebeam/chain)
  
  /mob/living/simple_animal/hostile/guardian/beam/Life()
  	..()
  