I try to make behaviour system for enemy units. Everything worked fine untill I added the following event;
Enemy -- has LOS to Player ---> Enemy set Alarm to true
System-- Else ---> Set Alarm to false
Enemy has the boolean instance variables "Alarm".
If the Player comes in LOS sector the "Alarm" is true and the Enemy fires.
The quantity of units is 60.
I do not understand why these two simple lines of a code drop the FPS to 30 percent?
I can't belive that it is because of the number of units.
What should be changed not to drop FPS?