第十一阶段 stage 2:场外换币台(暗灯招换币客户)

- 新人脉升级“场外换币台”(OtcUnlockPrice 500),附赠一盏暗灯
- 包装原版暗灯工厂:切换顺序末尾加目标 pd_otc(只接管进出这一步,其余交给原切换函数);顾客工厂写进公开的 StoreClientListDict.storeClientDict,顾客面板与概率走原版逻辑
- 换色:底图换成原版熄灭的暗灯,叠加层画黄绿色光晕(otc_lamp_on),不进存档
- 换币客户(OtcClient)一半卖币、一半买币:卖币并入原收黑币(Domain/Otc.cs 取代 HotCoins.cs,HotCoinSeller 删除),污点比例随机、越脏越便宜、地址来历写进账本;买币三档报价,PLEDGER 转账确认后现金到账,当晚未付作废
- 只在生成顾客的回调窗口里生成报价、写账本(原版取名字也会调用工厂)
- 存档数据版本 4:旧存档出块奖励、NPC 算力按 MiningScale 放大
- 8 种语言文字、手册“换币客户”一节;单元测试

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
ZHU MINCHAOandClaude Opus 5.5 committed 2026-11-08 14:29:49 +08:00
1 parent bc23ae056b
commit ec578a39d9
25 files changed
+833 -321

No files matched your search

+27 -15
View File
@@ -247,7 +247,7 @@ black.kind.Contraband.3,Contraband (high)
black.kind.Tech,High-tech (markup)
nightlog.bm.ready,Black market: {0} arrived; a courier will come by once you open.
guide.web3.title,Web3 Handbook
guide.web3.text,"Bank and trading: the Bank page is read-only and shows cash, rent and the CRC in your Poinbase account. Poinbase's Funds page handles deposits and withdrawals; pick the coin first: CRC can go through the bank account or a wallet, every other coin only through a wallet. Depositing from the bank turns credits into CRC in your Poinbase account; withdrawing to the bank turns CRC back into credits and goes through compliance screening, which looks at the Poinbase account's taint. Withdrawing to a wallet needs a payee address and a few confirmations before it arrives; the gas fee is fixed at the normal tier and taken from the coin sent. A wrong address format or checksum is rejected; a correctly formatted address nobody uses means the coins are gone.¶Trading: PSC stands for Probably Stolen Coin, the coin mined by GPUs and miners. Poinbase spot has two pairs, PSC/CRC and SPARK/CRC, following the coin picked on the chart. Buys and sells are both entered as an amount of the traded coin; the preview shows the quote coin paid or received, the average price includes the fee and the slippage does not.¶The Web3 trade page can swap any two coins, always through CRC: with CRC on one side it uses one pool, otherwise two pools, with two fees and stacked slippage; the preview shows the amount received, the pools crossed and the loss. Stablecoin swaps (CRT or CRA against CRC) use stable pools: a {StableFee:%} fee and almost no slippage near the peg; during a depeg liquidity thins, and in a collapse it is pulled and slippage jumps.§Hardware wallets: on-chain coins sit in PLEDGER hardware wallets, each with its own balances and taint. A wallet is an item: drag it onto the trading terminal to load it. Open it on the terminal's Wallets page; connect and disconnect at the top right of the terminal. Trading on the Web3 page and the shop and mixer on the Gray Net page use the connected wallet; with no wallet or no connection they are view-only and every balance reads 0. Coin-paying customers pay into the connected wallet.¶Payments (shop, mixer, Ponero desk, listing fees) start as an invoice on the terminal; type the payee address on the wallet and hold ✓ to sign. The last two characters of an address are a checksum, so a one-character typo is usually caught; once in a while it happens to be valid and the coins go to an address nobody uses. DEX swaps also need a signature on the wallet.¶Poinbase is a custodial account; deposits are sent from a wallet to Poinbase's deposit address (only PSC, CRC and SPARK; the compliant exchange takes neither the black market's CRT nor the Revolution's CRA, and the wallet blocks sending them to the deposit address) and withdrawals are started on Poinbase's Funds page. The Explorer on the Wallets page looks up transfers by address and shows only transfers that really happened: every movement in and out of your wallets (transfers, DEX swaps and other contract calls, miner payouts, withdrawals, coins others send you); Ponero is a privacy coin and never shows. More hardware wallets are sold by Dr. Jackson; drag one onto the trading terminal to add it, up to {WalletMax}. The shop has cheaper ones. A wallet you no longer want can be destroyed on the Wallets page; its coins are lost for good, and anything sent to its address afterwards is lost too.¶Transfers pay a gas fee: slow, normal or fast, and gas prices rise and fall over roughly a week; when the network is congested gas fees rise and slow transactions may be dropped from the mempool. Check the full address before sending.§Staking: CRA staked in the Revolution pool earns a daily rate that compounds into the stake; withdrawing means requesting first and waiting four days, with no interest while waiting and no way to take it early. CRA is partly collateralized: each CRA is backed by the CRC reserve the Revolution holds and by the balance token SPARK; reserve coverage and the collateral ratio are shown on the staking page. Interest is paid in new uncollateralized CRA, which dilutes reserve coverage, faster the more is staked; when coverage is too low the Revolution cuts the rate. The Revolution sometimes diverts the reserve, preceded by rumors: that is the warning. If coverage then falls below {CraCrashRatio:%} it collapses: CRA is worthless within three days and four days of unlocking is too slow; above that there is only a discount, and money from raiding the upper class slowly refills the reserve.¶Official minting: deposit CRC and SPARK (ratio per the current collateral ratio; the preview shows what is needed) to mint CRA, queued {CraMintDaysMin}-{CraMintDaysMax} days; the minted CRA goes straight into staking. Burning turns CRA back into CRC and SPARK, waiting as long as the unlock period; when the reserve is short the CRC share is cut by coverage. Queued mints and burns may be dishonored in full by the Revolution: the nightly chance is how far the CRA price is below 1 times {CraRugPerDepeg}; if the price is not below 1 it cLine truncated
guide.web3.text,"Bank and trading: the Bank page is read-only and shows cash, rent and the CRC in your Poinbase account. Poinbase's Funds page handles deposits and withdrawals; pick the coin first: CRC can go through the bank account or a wallet, every other coin only through a wallet. Depositing from the bank turns credits into CRC in your Poinbase account; withdrawing to the bank turns CRC back into credits and goes through compliance screening, which looks at the Poinbase account's taint. Withdrawing to a wallet needs a payee address and a few confirmations before it arrives; the gas fee is fixed at the normal tier and taken from the coin sent. A wrong address format or checksum is rejected; a correctly formatted address nobody uses means the coins are gone.¶Trading: PSC stands for Probably Stolen Coin, the coin mined by GPUs and miners. Poinbase spot has two pairs, PSC/CRC and SPARK/CRC, following the coin picked on the chart. Buys and sells are both entered as an amount of the traded coin; the preview shows the quote coin paid or received, the average price includes the fee and the slippage does not.¶The Web3 trade page can swap any two coins, always through CRC: with CRC on one side it uses one pool, otherwise two pools, with two fees and stacked slippage; the preview shows the amount received, the pools crossed and the loss. Stablecoin swaps (CRT or CRA against CRC) use stable pools: a {StableFee:%} fee and almost no slippage near the peg; during a depeg liquidity thins, and in a collapse it is pulled and slippage jumps.§Hardware wallets: on-chain coins sit in PLEDGER hardware wallets, each with its own balances and taint. A wallet is an item: drag it onto the trading terminal to load it. Open it on the terminal's Wallets page; connect and disconnect at the top right of the terminal. Trading on the Web3 page and the shop and mixer on the Gray Net page use the connected wallet; with no wallet or no connection they are view-only and every balance reads 0. Coin-paying customers pay into the connected wallet.¶Payments (shop, mixer, Ponero desk, listing fees) start as an invoice on the terminal; type the payee address on the wallet and hold ✓ to sign. The last two characters of an address are a checksum, so a one-character typo is usually caught; once in a while it happens to be valid and the coins go to an address nobody uses. DEX swaps also need a signature on the wallet.¶Poinbase is a custodial account; deposits are sent from a wallet to Poinbase's deposit address (only PSC, CRC and SPARK; the compliant exchange takes neither the black market's CRT nor the Revolution's CRA, and the wallet blocks sending them to the deposit address) and withdrawals are started on Poinbase's Funds page. The Explorer on the Wallets page looks up transfers by address and shows only transfers that really happened: every movement in and out of your wallets (transfers, DEX swaps and other contract calls, miner payouts, withdrawals, coins others send you); Ponero is a privacy coin and never shows. More hardware wallets are sold by Dr. Jackson; drag one onto the trading terminal to add it, up to {WalletMax}. The shop has cheaper ones. A wallet you no longer want can be destroyed on the Wallets page; its coins are lost for good, and anything sent to its address afterwards is lost too.¶Transfers pay a gas fee: slow, normal or fast, and gas prices rise and fall over roughly a week; when the network is congested gas fees rise and slow transactions may be dropped from the mempool. Check the full address before sending.§Staking: CRA staked in the Revolution pool earns a daily rate that compounds into the stake; withdrawing means requesting first and waiting four days, with no interest while waiting and no way to take it early. CRA is partly collateralized: each CRA is backed by the CRC reserve the Revolution holds and by the balance token SPARK; reserve coverage and the collateral ratio are shown on the staking page. Interest is paid in new uncollateralized CRA, which dilutes reserve coverage, faster the more is staked; when coverage is too low the Revolution cuts the rate. The Revolution sometimes diverts the reserve, preceded by rumors: that is the warning. If coverage then falls below {CraCrashRatio:%} it collapses: CRA is worthless within three days and four days of unlocking is too slow; above that there is only a discount, and money from raiding the upper class slowly refills the reserve.¶Official minting: deposit CRC and SPARK (ratio per the current collateral ratio; the preview shows what is needed) to mint CRA, queued {CraMintDaysMin}-{CraMintDaysMax} days; the minted CRA goes straight into staking. Burning turns CRA back into CRC and SPARK, waiting as long as the unlock period; when the reserve is short the CRC share is cut by coverage. Queued mints and burns may be dishonored in full by the Revolution: the nightly chance is how far the CRA price is below 1 times {CraRugPerDepeg}; if the price is not below 1 it cLine truncated
courier.odd1,...Package is here.
courier.odd2,(His hand stays in his pocket.) Sign here.
courier.sign,Sign
@@ -964,18 +964,30 @@ news.wipe.down.title,"{0} falls {1}% in a day, {2} traders liquidated"
news.wipe.down.desc,"Over the past day {1} long positions on {0} perps were liquidated, {2} credits in total. The Poinbase insurance fund stands at {3} credits."
news.wipe.up.title,"{0} jumps {1}% in a day, {2} traders liquidated"
news.wipe.up.desc,"Over the past day {1} short positions on {0} perps were liquidated, {2} credits in total. The Poinbase insurance fund stands at {3} credits."
hot.name,Seller
hot.intro.CRT,"Things are tense lately and this CRT is too hot to hold. I need cash, fast."
hot.intro.PSC,"A mining farm's wallet changed hands last night. The PSC is with me now, and I only take cash."
hot.intro.PONERO,"Ransom money, in Ponero. Nobody can trace it. Cash only."
hot.offer,"{0} {1}, worth {2} at today's price. Give me {3} in cash and the coins are yours right now."
hot.choice.yes,Take it
hot.choice.no,Pass
hot.say.yes,Deal.
hot.say.no,I'm not touching that.
hot.done,Coins sent. We never met.
hot.refused,Plenty of others will take it.
hot.nocash,You can't even put up the cash? Forget it.
hot.nowallet,"No wallet connected, so where would the coins go? Forget it."
hot.sting,Don't move. Security. Buying stolen funds: the cash is confiscated and this goes on your record.
otc.name,OTC client
otc.intro.CRT,"Things are tense lately and this CRT is too hot to hold. I need cash, fast."
otc.intro.PSC,"A mining farm's wallet changed hands last night. The PSC is with me now, and I only take cash."
otc.intro.PONERO,"Ransom money, in Ponero. Nobody can trace it. Cash only."
otc.offer,"{0} {1}, worth {2} at today's price, sent from {4}. Give me {3} in cash and the coins are yours right now."
otc.intro.sell,Got some {0} I want to turn into cash. Check where it came from if you like.
otc.buy.ask,"I want {0} {1}, worth {2} at today's price. Cash. Name your price."
otc.tier,Market +{0}%: {1}
otc.buy.say,"{0}, not a credit less."
otc.buy.accept,"Fine, {0}. Send the coins to {1}; cash when they land."
otc.buy.reject,Too steep. Forget it.
otc.buy.no,Not selling that.
pay.otc,OTC client {0} {1} (cash {2})
nightlog.otc.paid,The OTC client received {0} {1} and paid {2} in cash.
nightlog.otc.unpaid,The OTC client never got the {0} {1}; the bill is void.
otc.upgrade.title,OTC Desk
otc.upgrade.desc,"Adds a Black Lamp target: OTC clients. Some come to sell coins of unknown origin, some come to buy coins; all deals are settled in cash. Includes one Black Lamp."
otc.choice.yes,Take it
otc.choice.no,Pass
otc.say.yes,Deal.
otc.say.no,I'm not touching that.
otc.done,Coins sent. We never met.
otc.refused,Plenty of others will take it.
otc.nocash,You can't even put up the cash? Forget it.
otc.nowallet,"No wallet connected, so where would the coins go? Forget it."
otc.sting,Don't move. Security. Buying stolen funds: the cash is confiscated and this goes on your record.
hw.err.poinbase,Poinbase does not accept {0}.