Factoring and Managing Project

Hey, not really sure how to succinctly sum this up so sorry for the weird title. Basically, I’m trying to make a clone of the original Legend of Zelda in unity. In the game, all enemies (and link) can hit and be hit. On hit a bunch of things happen, notably damage and knockback. I figured for efficiency I could factor these into general “HitBox”/“HurtBox” for giving/receiving hits, and then some sort of combat manager to manage knockback, resistance, damage etc as opposed to hard coding the interactions into every single type of monster and player AI.

However a problem I keep running into in Unity is suppose I want the “combat manager” component to be able to let another script know if a hit has been taken (this script could be any number of monster AI’s or even the player’s controller). There doesn’t seem to be a way to send a message to a nonspecified type of component.

Is there a way to accomplish specifically this (send some sort of general message to another component without necessarily knowing its type?) or is there a completely different way I should approach this. Any suggestions would be helpful.

One nice way it to use interfaces to define that your component can be hit and has the required functions to process the hit. Then you can make GetComponent(); to get the component that has the interface implemented.
If you need it more general you can use SendMessage(). on a object.to call the function in every component that hast it.