Add Mundial hook on xlayer#1103
Merged
Ponx merged 1 commit intoJul 16, 2026
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
There was a problem hiding this comment.
Review: hooks/xlayer/0x51f3d18a574c1deec5c04d395573cda9248dd0c4.json
Address Flags (lowest 14 bits of 0x...d0c4)
0xd0c4 = 1101 0000 1100 0100 — decoded against the flag table:
| Flag | Bit | Expected | File |
|---|---|---|---|
| beforeInitialize | 13 | false | false ✓ |
| afterInitialize | 12 | true | true ✓ |
| beforeAddLiquidity | 11 | false | false ✓ |
| afterAddLiquidity | 10 | false | false ✓ |
| beforeRemoveLiquidity | 9 | false | false ✓ |
| afterRemoveLiquidity | 8 | false | false ✓ |
| beforeSwap | 7 | true | true ✓ |
| afterSwap | 6 | true | true ✓ |
| beforeDonate | 5 | false | false ✓ |
| afterDonate | 4 | false | false ✓ |
| beforeSwapReturnsDelta | 3 | false | false ✓ |
| afterSwapReturnsDelta | 2 | true | true ✓ |
| afterAddLiquidityReturnsDelta | 1 | false | false ✓ |
| afterRemoveLiquidityReturnsDelta | 0 | false | false ✓ |
All flags match the address bitmask.
Properties Verification
- dynamicFee: true ✓ —
afterInitializeenforceskey.fee.isDynamicFee().beforeSwapreturnsfee | LPFeeLibrary.OVERRIDE_FEE_FLAGviafeeFor(), which varies by tournament state (FEE_NEUTRAL, FEE_FAN_ALIVE, FEE_MATCH_LIVE, FEE_GOLDEN_GOAL). - upgradeable: false ✓ —
source_meta.jsonconfirmsproxy: false. Nodelegatecall, mutable implementation slot, orSELFDESTRUCTfound. - requiresCustomSwapData: false ✓ —
beforeSwap'sbytes calldataparameter is unnamed and unused. Swaps execute correctly with emptyhookData. - vanillaSwap: false ✓ — Correctly false: dynamic fee override is active,
afterSwapReturnsDeltais true, andafterSwapskims tokens from the pool into a Champions Pot. - swapAccess: "none" ✓ —
beforeSwapapplies no access control; all addresses can swap. Fan vs. neutral status only affects fee tier, not swap permission.
Metadata
- chain/chainId:
xlayer/196matcheschains.json✓ - name: "Mundial" — contract is
MundialHook; "Mundial" is a recognized abbreviation, no promotional language ✓ - verifiedSource: true — confirmed by
source_meta.json✓ - description: Accurately describes the World Cup tournament mechanics, dynamic fee tiers, Champions Pot skim via delta returns, and penalty tiebreakers — all substantiated by the Solidity source ✓
Everything checks out.
Ponx
approved these changes
Jul 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
A Uniswap v4 hook that runs an 8-team knockout World Cup tournament inside a single pool. Pledged fans receive dynamic LP fee discounts based on tournament state (neutral, fan-alive, match-live, golden-goal). afterSwap skims a Champions Pot via delta returns; match outcomes are determined by swap volume with extra-time and penalty tiebreakers.
Flags
Properties
Warnings
Closes #1068