SOLVED Circle collision

I've got a character that I want to have a electric ring surround it. I'm using an asset that I create an instance of it and the electric ring surrounding
it damages any of the bad guys that come in contact with it. So forget the electric ring part. I need to be able to detect when a character hits this
radius. So I need something like point_in_circle.

RIght now all I have is the code to create the electric ring:

for (i=0;i<room_speed;i++)
{
lit_inst = instance_create_depth(x+200,y+200,-1900,o_lightning_circle);
}
 
Something like this??
GML:
if collision_circle(x,y,10, BrainSuperParent, false, true)
{
    //hp_minus = strength*dexterity*intelligence*irandom_range(20, 50)/500;
    BrainSuperParent.hp -= 100;
    floater = instance_create_depth(x+10, y-10, -1700, DamageIndicatorObject);
    floater.text = string(hp_minus);
       
    for (i=0;i<room_speed;i++)
    {
        lit_inst = instance_create_depth(x+200,y+200,-1900,o_lightning_circle);
    }
   
}
So there are like 12 types of enemies that are "special" enemies. Then there are
four types of enemies that are "normal" enemies. Then there is a Frankenstein type
enemy. Each of type of enemy has a parent object. Then there is a BrainSuperParent
that is parent to the three.
 

sp202

Member
That's going to reduce every enemy's HP by 100. I would do this
GML:
with(BrainSuperParent)
{
    if collision_circle(other.x,other.y,10,self,false,true)
    {
        hp-=100
    }
}
 
Top