Fire System Unreal
Inspired by missions in games that involve torching huge fields or buildings, such as the ones found in the far cry series. I set out to make my own fire system in unreal engine. Going into this project I defined my three main objectives, simplicity, believability, and emergent.
Grass System - This is a volume that is placed by the user that instantiates randomized grass on a surface. It can control the density of the grass patch and the direction of the wind in the volume.
Grass - The grass that is instantiated from the volume is an optimized actor that can receive fire damage.
Flammable Object - This is the parent of all objects that are not grass actors.
Flammable Component - This component controls all fire behavior and if it is attached to any actor it will be included in the fire system. The component reads different fire damage input types, and based on the damage type different fire behaviors are available.
Circular method - This type of spread will happen in the absence of wind or with objects that are set to spread without taking the wind into account.
Wind Method - This spread will limit the spread only in the direction of the current wind vector. Some fires can be put out by changing this direction towards a location that has no burnable objects.
Heat Method - This is a specialized method that takes account of whether the object is in a room or not, this requires a continuous fire source to be burning. after a certain heat index is reached the room will become hot enough to ignite objects that are in the room that are out of the range of the traditional spread radius.