You’re in luck, because that is how cover works by default. You can use the FindTargetCoverRelativeToSource function in the cover component to find the cover value (float) of a tile (the Target) when being targeted by an ability from a different tile (the Source)
Here is a quick debugging setup you can use to check the cover values of the tiles you hover over from the tile of the current active unit:
https://i.imgur.com/JoYIasy.png