fix: torneo intl se juega directo sin boton (liga pausada); suspension de un anio salta 2 splits real
This commit is contained in:
+14
-8
@@ -1007,7 +1007,7 @@ const EVENTS = [
|
||||
{ t: 'Decir que no, obvio', d: { marca: 1.6, sinergia: 0.6 }, risk: 0.1,
|
||||
pos: 'Le cerraste la puerta al tipo y se corrió la voz: te respetan como el que no se vende.',
|
||||
neg: 'El pro se ofendió y te tildó de "amargo" en una entrevista. La gente le creyó a él.' },
|
||||
{ t: 'Aceptar jugar "solo un game"', d: { mecanica: 1.6 }, risk: 0.75,
|
||||
{ t: 'Aceptar jugar "solo un game"', d: { mecanica: 1.6 }, risk: 0.75, x: { suspend: 2 },
|
||||
pos: 'Un game, una clasificatoria asegurada, plata en el bolsillo. Nadie miró, dicen.',
|
||||
neg: 'La liga comparó IPs y horarios: sancionado el equipo menor, el pro y vos. Suspensión de un año.' },
|
||||
{ t: 'Exigir plata por adelantado', d: { marca: 1.2 }, risk: 0.6,
|
||||
@@ -1956,13 +1956,9 @@ function renderIntl(ev){
|
||||
box.innerHTML = `
|
||||
<div class="dc-cat">${comp.ic} ${ev.name} · Split ${G.split}</div>
|
||||
<h2>${isWorlds ? 'El torneo más grande del año' : ev.name}</h2>
|
||||
<p class="dc-ctx">${esc(comp.flavor)} La liga se pausa: este split se juega ${ev.name} y tu equipo tiene cupo.</p>
|
||||
<div class="opt-grid">
|
||||
<button class="opt-card wide" data-i="go"><span class="oc-title">Jugar el torneo</span><span class="oc-desc">La liga está parada: este split es ${ev.name}. Todo o nada.</span></button>
|
||||
</div>`;
|
||||
box.querySelectorAll('.opt-card').forEach(b => b.addEventListener('click', () => {
|
||||
runIntl(ev);
|
||||
}));
|
||||
<p class="dc-ctx">${esc(comp.flavor)} La liga se pausa: tu equipo ya tiene cupo y este split se juega ${ev.name}. Sin vuelta atrás.</p>
|
||||
<p class="dc-hint">Determinando el resultado del torneo…</p>`;
|
||||
setTimeout(() => runIntl(ev), 900);
|
||||
}
|
||||
|
||||
function runIntl(ev){
|
||||
@@ -2037,6 +2033,7 @@ function resolveDecision(ev, optIdx){
|
||||
}
|
||||
if (opt.x && opt.x.rolChange) res.rolChange = true;
|
||||
if (opt.x && opt.x.transfer === 'other') res.transferSearch = true;
|
||||
if (opt.x && opt.x.suspend && !ok) res.suspend = opt.x.suspend;
|
||||
return res;
|
||||
}
|
||||
function round1(x){ return Math.round(x * 10) / 10; }
|
||||
@@ -2110,6 +2107,15 @@ function statLabel(k){ const m = statNames().find(s => s[0] === k); return m ? m
|
||||
|
||||
function doSplitEnd(res){
|
||||
if (G.retiring){ finishCareer(); return; }
|
||||
/* suspensión: el jugador se pierde los splits sancionado (no juega, no suma nada) */
|
||||
if (res && res.suspend){
|
||||
const lost = Math.min(res.suspend, G.totalSplits - G.split);
|
||||
G.history.push({ split: G.split, org: G.teamId, orgName: teamById(G.teamId).name, elo: rating(), games: 0, kills: 0, ast: 0, suspended: true });
|
||||
G.split += lost;
|
||||
if (G.split >= G.totalSplits){ finishCareer(); return; }
|
||||
nextSplit();
|
||||
return;
|
||||
}
|
||||
if (res && res.kind === 'decision' && res.opt && res.opt.x && res.opt.x.rolChange){
|
||||
const roles = Object.keys(ROLES);
|
||||
G.role = roles[(roles.indexOf(G.role) + rnd(1, roles.length - 1)) % roles.length];
|
||||
|
||||
Reference in New Issue
Block a user