entity.clj

Bowmap · bowmap.git · Tickets

Branches > main > b6d3d26 > files / src / net / bowmap / server / protocol / entity.clj

(ns net.bowmap.server.protocol.entity)

(defonce highest-entity-id (atom 0))

(defn next-entity-id
  "Returns the next highest available entity ID.
   Entity IDs are unique used in the protocol to refer to entities."
  []
  (swap! highest-entity-id inc))