Week 3 - Giving Shelter & Characters Led Astray
A Home For All Last week, there was a start on natural character spawning inside city buildings. This spawning was on a time-based cycle, where after a defined period of time a character was spawned inside each building with a PotentialHomeComponent . However, this seemed very unorganized, since characters would have no attachment to the buildings that they came from. This week, that approach was switched out in favour of a 'shelter' based approach. Each building's home component is defined with the number of characters that can spawn inside of it, ranging from 1-5. When characters are spawned inside of buildings, this component also contains references to the characters that it contains. On each spawn check, characters will not spawn if the building already contains the maximum number of characters. This results in each building having a defined set of residents: Gooey roommates With every character now having a hard reference to their spawn building/home, thi...