Hi @rexrainbow
I have a question about FindFOV and visibilityPoints. I am using FindFOV passing in visibilityPoints. As you know, it goes FindFOV --> IsInLOS --> isPathVisible --> GetCost which will then call my costCallback.
In my game, each hex is assigned a terrain which all have a “sightCost”. Here is my costCallback
costCallback: (tileXY) => {
// getTileAttribute returns an integer value for how hard is it to see through the hex
const totalSightCost = this.ember.map.getTileAttribute(this.scene, tileXY, 'sightCost');
return totalSightCost;
},
Some terrains are “blockers” in that you can not see past them. Doors, walls, mountains, etc. What is happening is that when the “blocker” hex has a higher sightCost than what is left of the player’s visibilityPoints, everything behind that hex’s cone is hidden as expected. It ALSO hides the “blocker” hex from being seen.
What I would like is for the blocker hex to be visible (I want them to see the door), but everything behind it’s cone to be invisible like normal.
Hopefully that is clear enough for you to understand what I am trying to achieve. Any suggestions?
Dan