Skip to content

Commit

Permalink
Add detail to Agent IDs (#181)
Browse files Browse the repository at this point in the history
The representation of ID not set was not discussed.
  • Loading branch information
Robadob authored Nov 29, 2024
1 parent 8fe6b07 commit 2557778
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/guide/defining-agents/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ Agent ID
All agents have a built in ID variable. This is a number which uniquely identifies this agent. Each agent will automatically be assigned an ID when the simulation
starts or the agent is birthed. The ID is value for every agent is unique among agents of all types. There is currently no way to change the ID of an agent. The agent ID variable is of type :type:`flamegpu::id_t` (Python: ``ID``) which is an ``unsigned int`` by default, but can be redefined if more IDs are required, e.g. a model with extremely high rates of agent birth/death.

The symbol :var:`flamegpu::ID_NOT_SET` , equal to ``0``, is reserved and will never be assigned as an agent's ID. Therefore it can be used if invalid or no ID must be represented.

User Defined Variables
----------------------

Expand Down

0 comments on commit 2557778

Please sign in to comment.