Search Apps Documentation Source Content File Folder Download Copy Actions Download

params.gno

1.39 Kb · 29 lines
 1// Package memba_market_core holds the frozen, cross-engine money math and event
 2// schema for the Memba NFT marketplace engines. It is a PURE package (no chain/
 3// realm imports): split math returns values, event helpers return ordered arg
 4// slices, and the importing engine performs chain.Emit / banker / MarketTransfer.
 5//
 6// Constants are copied verbatim from memba_nft_market_v3 (the deployed reference).
 7// SplitProceeds must stay behaviorally identical to v3's splitProceeds so every
 8// engine pays out identically (fee/royalty conformance).
 9package memba_market_core
10
11import "strconv"
12
13const (
14	FeeBPS        = int64(200)                   // 2.0% platform fee (matches v3)
15	MaxRoyaltyBPS = int64(1000)                  // 10% royalty clamp (defense-in-depth)
16	MinPrice      = int64(1000)                  // 0.001 GNOT — prevents fee truncation to zero
17	MaxPrice      = int64(1_000_000_000_000_000) // 1 billion GNOT
18
19	// SettlementDenom is carried on every settlement event for forward-compat with
20	// the GRC20 settlement desk (PHASE 3+). Engines settle in ugnot today.
21	SettlementDenom = "ugnot"
22
23	// SchemaVersion stamps every event so the indexer can branch parsing
24	// deterministically and the schema can evolve without ambiguity. Bump ONLY
25	// when an event's key set changes; never reuse a version for a different shape.
26	SchemaVersion = "1"
27)
28
29func itoa(n int64) string { return strconv.FormatInt(n, 10) }