Comment on page


Add the "Blackboard" prefab from the Repositories folder to your project. The Blackboard.cs component is already attached here.
The Blackboard component is the central hub for all of the Blackboard actions. Add this to the top of any script which utilizes it:
using static InfinityPBR.Modules.MainBlackboard;
// Refer to Blackboard Note, Blackboard Event, and Blackboard Values for additional code references.
// Obtaining a specific value from a Blackboard Note
GameStat gameStat = Blackboard.ValueGameStat(topic, subject);
// Doing something with a specific value from a Blackboard Note
public float FloatValue => Blackboard.ValueFloat(topic, subject);
The best way to interact with the Blackboard is to have your class inherit from BlackboardFollower, which will automatically subscribe and unsubscribe it to event and note notifications. All you have to do is override the methods so you can choose how to handle the notifications as they come in.
The Gametime module has a Timeboard object which has it's own Blackboard. It is used to send information out, and also keep track of time without requiring objects to access the Gametime data directly. Check it out to see how it talks with its blackboard object.