QING — Venues
Evidence scope: The behavior below is from the pinned Solidity source. A source-file hash does not establish deployed bytecode equivalence. Check the selected deployment and caller before sending a transaction.
What this is
Section titled “What this is”A QING wraps an Asset token and has a Waat, cover charge, staff list and private guest-list expiries. QING.Chat(lau, message) emits the venue’s LogEvent. It does not run CHOA’s reward calculation.
What you actually do with it
Section titled “What you actually do with it”- Inspect
CoverChargeand the underlying Asset. For a paid, expired entry, the source requiresallowance(msg.sender, QING) > CoverCharge; approving exactly the cover is insufficient. The transfer itself charges exactlyCoverCharge. - Call
Join(lau)to pay when required and establish an expired guest-list entry. A join while the entry is still valid does not extend it. - Use direct
QING.Chatfor its venue event, or CHOA.Chat for the additional YUE reaction and conditional CHOA-token payment. - Bouncers can set cover, divisor, staff and guest-list entries.
setGuestlist(lau)explicitly writesnow + 1 days;removeGuest(lau)clears the entry. - Direct owners can call
Rename,AllowCROWS, market controls and ownership controls.Withdrawalso requiresGWAT == falseand transfers tomsg.sender.
Use these calls here. Simulations preview the current state; each confirmed call is a separate transaction.
VenueAsset.allowance(address owner, address spender)Read
Open this function to load its call form.
VenueAsset.approve(address spender, uint256 value)Simulate / call
Open this function to load its call form.
QING.Admitted(address UserToken)Read
Open this function to load its call form.
QING.Join(address UserToken)Simulate / call
Open this function to load its call form.
QING.setCoverCharge(uint256 _c)Simulate / call
Open this function to load its call form.
QING.setBouncerDivisor(uint16 _d)Simulate / call
Open this function to load its call form.
QING.setStaff(address _a, bool active)Simulate / call
Open this function to load its call form.
QING.setGuestlist(address _a)Simulate / call
Open this function to load its call form.
QING.removeGuest(address _a)Simulate / call
Open this function to load its call form.
QING.AllowCROWS(bool _b)Simulate / call
Open this function to load its call form.
QING.Withdraw(address what, uint256 amount)Simulate / call
Open this function to load its call form.
CHOA.Chat(address Qing, string MSG)Simulate / call
Open this function to load its call form.
Admission boundaries
Section titled “Admission boundaries”| Entry expiry compared with now | Join at nonzero cover | Admitted | Chat |
|---|---|---|---|
| In the future | No payment; expiry unchanged | true | Passes the expiry checks |
| Exactly now | No payment; expiry unchanged | true | Reverts PayCover |
| In the past | Pays cover and writes now + 1 days |
false before Join | Reverts NotAdmitted before Join |
At zero cover, admission and chat do not require a current guest-list expiry. Staff and CROWS-based bouncer status do not bypass the paid chat checks. Bouncers can grant an entry explicitly.
Ownership and caller checks
Section titled “Ownership and caller checks”The constructor marks tx.origin as staff. MAP adds CHO as an owner, may add the address returned by the Asset’s owner(), and removes its own ownership. Staff status does not grant owner-only Rename.
Chat checks the supplied LAU’s session validity and admission, but does not itself verify that the caller owns it. Wallet and MCP ownership checks provide an additional boundary; the raw event is not a signature by the named character.
Bouncer rules
Section titled “Bouncer rules”Staff qualify immediately. With CROWS enabled, a balance of at least 25 * 10^decimals() qualifies. Otherwise the Asset balance must reach Asset.totalSupply() / BouncerDivisor, or its owner(address) probe must recognize the candidate. _checkBouncer tries the origin, sender, then the origin’s active LAU. A zero divisor can cause a division-by-zero revert for paths that reach that division.
Where it connects
Section titled “Where it connects”QING source, MAP, CHO, and CHOA define distinct checks. MAP’s forbidden check can block Chat regardless of admission.