Flood Season escalates again, and empty POPs no longer hold floods for free

Every flood was 700G or more from day 1, so the scenario no longer built up. Sizes
are 1.36's again (a third terabit monsters, the rest ordinary floods sized to the
city), growing by the year as #153 had it. Floods go for POPs that serve someone,
and a city with nobody to serve only holds a flood its tools soak up. Seeded runs
over a year: no defence or one 1T center cannot win; one 1T center with full
Flowspec and clean pipe wins around day 100 (main needed two centers, day 164).
This commit is contained in:
Frederic Jung 2026-10-29 07:17:08 +01:00
parent 4bb5e07c28
commit 31e44440e8
No known key found for this signature in database
5 changed files with 44 additions and 21 deletions

View file

@ -30,7 +30,8 @@ const ddosFind=id=>ddosAll().find(a=>id===undefined||a.id===id);
function ddosDrop(a){const left=ddosAll(S,false).filter(x=>x!==a);S.ev.ddos=left[0]||null;S.ev.ddosMore=left.slice(1);}
function ddosExpire(){for(const a of ddosAll(S,false))if(a.until<=S.day||!S.pops[a.city]){ddosDone(a);ddosDrop(a);}}
// An attack is held or lost at its victim: the junk lands there, and other POPs' bad days are not the attacker's doing.
const ddosSf=a=>sfOf(R,a.city);
// A city with nobody to serve holds only if its tools soak up the flood (or there is nothing to judge but that).
const ddosSf=a=>((R.cityDem||{})[a.city]||0)>1e-6||!a.gbps?sfOf(R,a.city):clamp(1-ddosReport(a).leak/a.gbps,0,1);
function ddosReport(a){return (R.ddos||[]).find(m=>m.attack===a)||ddosMitigation(a);}
// Where the junk comes in: one of the city's live uplinks, or just "the edge" if it has none yet.
function ddosEntry(c){const o=[];