46a654f

Branches > refactor/use-spec-1 > 46a654f > files

clientbound message names

Grahp, 2026-06-04

Commit: 46a654fbb7462cbf228ddf4ba5cbfa7f4fa3de27
Parent: a6d28b5

1 changed file:

src/net/bowmap/network/message/client.clj modified (view file)

@@ -2,7 +2,7 @@   (:require    [clojure.alpha.spec :as s]    [dev.grahp.build :refer [build]]-   [dev.grahp.error :refer [adorn defn! get!]]+   [dev.grahp.error :refer [defn! get!]]    [net.bowmap.network.message :as msg]    [net.bowmap.network.packet :as pk]    [net.bowmap.network.packet.types :as t]@@ -286,10 +286,10 @@    ids are not unique across connection states. Several packets are logically    the same across states, and can be sent without needing to switch on state."   [msg state]-  (let [encode-body (get! packets (::msg/id msg))]+  (let [payload-writer (get! packets (::msg/id msg))]     (length-prefixed (-> (Unpooled/buffer)                          (varint-> (get! message->packet-ids {::msg/id (::msg/id msg) ::state/connection-state state}))-                         (encode-body msg)))))+                         (payload-writer msg)))))  (s/fdef message->packet         :args (s/cat :msg ::msg/message :state ::state/connection-state)