Investors on a revenue share take their cut of IPv4 lease income (#150)
Merged onto Island Wi-Fi: the revenue share base keeps the islands (V.wisp) and adds IPv4 leases (V.ip4); the CHANGELOG bullet goes above the Island Wi-Fi and Starblink ones.
This commit is contained in:
parent
6f0c080875
commit
efe4405ea4
5 changed files with 46 additions and 6 deletions
|
|
@ -6,6 +6,7 @@ All notable changes to this project are documented here. The project follows
|
|||
|
||||
## [Unreleased]
|
||||
|
||||
- Investors on a revenue share now take their cut of your IPv4 lease income too, as they already did of fiber pairs you lease out (#150). Selling a block is still a one-off that is all yours, like the up-front price of a fiber pair, and the NOC dashboard's Investor revenue share row now includes the leases.
|
||||
- Island Wi-Fi: bring the internet to 18 groups of outer islands, over satellite capacity first and your own spur cable later (#83). Each group looks to an island city, like Vanua Levu to Suva or the Out Islands to Nassau: open a POP there and its Customers tab lists them. Rent capacity at the city's teleport and about a third of the islanders sign up over GEO, three quarters over MEO and nine in ten over Starblink from a gateway there; from level 3 a spur cable from the city lets everyone sign up and needs no rent. Islanders pay island prices, their homes are IPv6-only from day one, and their traffic rides the city's routers and links. A spur can be cut and the repair ship takes weeks: a satellite circuit kept beside it carries the islands meanwhile. Investors on a revenue share take their cut of what the islands pay.
|
||||
- Rent low-orbit satellite capacity from Starblink from level 5: islands near your fiber get circuits at about 30 ms round trip (#83). Host a Starblink gateway at a teleport on your fiber, then rent 5 to 50 Gbps to small islands and remote towns within 1,200 km of it. Users hardly notice the lag, and selective networks peer over it as over a cable; next to a cable it waits on standby, and a GEO or MEO circuit to the same island waits on standby beside it. Every island behind a gateway leans on that POP's routers and fiber, which its teleport section now shows, and a rare solar storm puts the circuits in safe mode for a day or two. Once your own constellation carries traffic, Starblink sells you nothing new.
|
||||
- A POP you mark as a micro POP, medium POP or regional hub now keeps that kind's routers when you also have a build standard (#315). Its router model and count come from its kind: "Bring everything up now" and your intern no longer swap its routers or add more to meet the build standard, while the standard's other targets still apply there. The POP's router section says so.
|
||||
|
|
|
|||
|
|
@ -99,8 +99,8 @@ Asked on 2026-11-09, not answered yet:
|
|||
6. **#83 WISP zones and a rented LEO tier.** Add island demand pools served remotely on top of the existing island
|
||||
cities, and a tier between MEO and Pie in the Sky that rents LEO capacity from a partner network? Or are teleports
|
||||
with GEO and MEO circuits enough?
|
||||
7. **Investors' cut of IPv4 lease income.** Should investors on a revenue-share loan take their cut of the income from
|
||||
leasing out IPv4 blocks too? Today they do not (dark fiber sold to customers is in their share).
|
||||
7. ~~**Investors' cut of IPv4 lease income.**~~ *Answered 2026-11-11 (yes) and built: investors on a revenue share
|
||||
take their cut of IPv4 lease income, as of fiber pairs leased out; a sale stays all the player's.*
|
||||
8. **Founding an exchange on a basic router.** Founding your own exchange gives a 400G port even where the POP's router
|
||||
only takes 100G, though the shop would not sell that port. Document it as a limitation, block founding until the
|
||||
router takes 400G, or found at the router's largest port size? (`tests/server-sim-prereqs.test.js` asserts today's
|
||||
|
|
@ -142,8 +142,8 @@ Asked on 2026-11-09, not answered yet:
|
|||
- **Dark mode (#80):** the share card PNG and the web manifest stay light; the WebGL map was checked by tests only, not
|
||||
by eye in a real GPU browser.
|
||||
- **IPv4 (#150):** the intern does not manage addresses (optional in the issue); transfers are instant (real ones take
|
||||
weeks); lease-out income is not in the investor revenue share (open question 7); blocks granted to old saves can be
|
||||
sold after two years (a one-off windfall); CGNAT annoyance costs refunds but does not slow broadband growth.
|
||||
weeks); blocks granted to old saves can be sold after two years (a one-off windfall); CGNAT annoyance costs refunds
|
||||
but does not slow broadband growth.
|
||||
- **IPv6-only broadband:** no one-off grumble while a city's home routers are swapped; a new home in an IPv6-only city
|
||||
pays its router even when cash is short (a running cost, so a finished city never looks like a stopped swap). The
|
||||
NAT64 ratio is not in the build standard (the swap is), and the standard starts a swap only with the whole of it to
|
||||
|
|
|
|||
|
|
@ -22,7 +22,8 @@ const IP4_BB=10,IP4_V4=0.55,IP4_V4_YR=0.02,IP4_V4_MIN=0.2,IP4_CGN=2;
|
|||
// under CGNAT's at the same ratio, and shrinking as the world goes IPv6.
|
||||
const IP4_N64=[64,128,256],IP4_N640=128,IP4_ANNOY64={64:0.006,128:0.01,256:0.016};
|
||||
// The market: dollars per address, flat for half a year, then +3% a year on a slow four-year swing. Leases are by the
|
||||
// month (a broker keeps a cut of what yours earn), sales pay 92% of the price after the broker's fee.
|
||||
// month (a broker keeps a cut of what yours earn, and investors on a revenue share take theirs: computeMoney), sales pay
|
||||
// 92% of the price after the broker's fee.
|
||||
const IP4_PX=38,IP4_FREE=180,IP4_YR=0.03,IP4_IN=0.5,IP4_OUT=0.4,IP4_SELL=0.92;
|
||||
// Of the bill of a home behind CGNAT, the share that comes back as refunds (gamers, mostly): more homes per address, more
|
||||
// grumbling. Homes squeezed past the ratio (port exhaustion) are worse.
|
||||
|
|
|
|||
|
|
@ -274,7 +274,9 @@ function computeMoney(R2,PX=null){
|
|||
if(PX)pieMoney(PX,R2,V);
|
||||
// The UK grant for Pitcairn, its satellite tier once orbit is known; the Rural Digital Pie Fund (99-pie-subsidies.js).
|
||||
{const on=grantOn(R2),sky=!on&&!!PX&&grantSky(R2);V.grant=on?GRANT_MO:sky?GRANT_SKY_MO:0;if(PX)V.gov=pieGovMo();if(PX)R2.pie.gov={rdf:V.gov||0,sky:sky?GRANT_SKY_MO:0};}
|
||||
C.revshare=(S.loans||[]).reduce((a,l)=>a+(BANKS[l.bank].equity||l.bal>0?l.share||0:0),0)*(V.eyeballs+V.business+V.ix+(V.orbit||0)+(V.wisp||0));
|
||||
// Investors take their share of what customers and tenants pay (an IPv4 block leased out too, as a leased fiber pair),
|
||||
// not of grants or one-off sales.
|
||||
C.revshare=(S.loans||[]).reduce((a,l)=>a+(BANKS[l.bank].equity||l.bal>0?l.share||0:0),0)*(V.eyeballs+V.business+V.ix+(V.orbit||0)+(V.ip4||0)+(V.wisp||0));
|
||||
R2.costMo=Object.values(C).reduce((a,b)=>a+b,0);
|
||||
R2.revMo=V.eyeballs+V.business+V.ix+V.grant+(V.gov||0)+(V.orbit||0)+(V.ip4||0)+(V.wisp||0);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -171,6 +171,42 @@ test('buying, leasing in, leasing out and selling move the right money', (t) =>
|
|||
assert.deepEqual(errors, []);
|
||||
});
|
||||
|
||||
test('investors on a revenue share take their cut of IPv4 lease income, not of a sale', (t) => {
|
||||
const { ev, dom, errors } = game(t);
|
||||
homes(ev, 20);
|
||||
ev("S.loanOffers.push({id:'v1',bank:'vult',amount:500000,exp:S.day+20,covs:['blitz'],share:0.1});ACT.takeLoan({id:'v1'})");
|
||||
const base = () => ev('R.rev.eyeballs+R.rev.business+R.rev.ix+(R.rev.orbit||0)');
|
||||
const rs0 = ev('R.cost.revshare');
|
||||
assert.ok(rs0 > 0 && Math.abs(rs0 - 0.1 * base()) < 1e-6, 'the vultures take 10% of what homes pay');
|
||||
ev('ACT.ip4Buy({len:20})');
|
||||
const id = ev("S.ip4.b.find(b=>b.k==='buy').id");
|
||||
ev(`ACT.ip4Out({id:${lit(id)}})`);
|
||||
const lout = ev('R.rev.ip4');
|
||||
assert.equal(lout, ev('ip4OutMo(20)'));
|
||||
assert.ok(Math.abs(ev('R.cost.revshare') - 0.1 * (base() + lout)) < 1e-6, 'and 10% of the lease too');
|
||||
assert.ok(Math.abs(ev('R.cost.revshare') - 0.1 * (ev('R.revMo') - ev('R.rev.grant||0') - ev('R.rev.gov||0'))) < 1, 'of everything but government money');
|
||||
// A bank's big loan with a revenue share takes its share of the lease while it runs, and stops once repaid.
|
||||
ev("S.loans.push({id:'b1',bank:'db',start:S.day,amount:2e6,got:2e6,bal:2e6,apr:0.1,apr0:0.1,pay:1,left:12,term:12,share:0.05,covs:[],base:{sub:0}});compute()");
|
||||
assert.ok(Math.abs(ev('R.cost.revshare') - 0.15 * (base() + lout)) < 1e-6);
|
||||
ev("S.loans.find(l=>l.id==='b1').bal=0;compute()");
|
||||
assert.ok(Math.abs(ev('R.cost.revshare') - 0.1 * (base() + lout)) < 1e-6);
|
||||
// Taking the block back ends the cut; selling it is a one-off that is all yours, like a fiber pair's up-front price.
|
||||
ev(`ACT.ip4Back({id:${lit(id)}})`);
|
||||
assert.equal(ev('R.rev.ip4'), undefined);
|
||||
assert.ok(Math.abs(ev('R.cost.revshare') - rs0) < 1e-6);
|
||||
ev('S.day+=730;compute()');
|
||||
const rs1 = ev('R.cost.revshare'), cash = ev('S.cash');
|
||||
ev(`ACT.ip4Sell({id:${lit(id)}});ACT.ip4Sell({id:${lit(id)}})`);
|
||||
assert.equal(ev(`S.ip4.b.some(b=>b.id===${lit(id)})`), false);
|
||||
assert.equal(ev('S.cash'), cash + ev('ip4Value(20)'));
|
||||
assert.ok(Math.abs(ev('R.cost.revshare') - rs1) < 1e-6);
|
||||
// The dashboard's Investor revenue share row shows the new amount.
|
||||
ev("ACT.ip4Buy({len:20});ACT.ip4Out({id:S.ip4.b.filter(b=>b.k==='buy').pop().id});UI.dtab='overview';renderDash()");
|
||||
assert.ok(ev('R.cost.revshare') > rs1, 'a new lease is shared again');
|
||||
assert.ok(dom.window.document.getElementById('dash').textContent.includes(ev('fmt$(R.cost.revshare)')));
|
||||
assert.deepEqual(errors, []);
|
||||
});
|
||||
|
||||
test('a list of blocks stops where a save keeps them: buying and leasing past it is refused, and a full save loads whole', (t) => {
|
||||
const { ev, dom, errors } = load({ agent: true });
|
||||
t.after(() => dom.window.close());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue