|
|
| Line 938: |
Line 938: |
| </div> | | </div> |
|
| |
|
| <!-- Edit CTA -->
| | |
| <div style="padding:22px;border-radius:14px;background:rgba(255,255,255,0.025);border:1px solid rgba(255,255,255,0.06);text-align:center;">
| |
| <div style="font-size:1rem;margin-bottom:6px;">📊</div>
| |
| <div style="font-size:0.92rem;font-weight:700;color:#e8eef8;margin-bottom:4px;">Sabe um método de farm melhor?</div>
| |
| <div style="font-size:0.84rem;color:rgba(122,144,176,0.60);margin-bottom:14px;">Compartilhe! Guias são mais ricos com a experiência de toda a comunidade.</div>
| |
| [[Farming_Guide/talk|<span style="display:inline-flex;align-items:center;gap:7px;padding:9px 18px;border-radius:10px;background:rgba(249,197,0,0.08);border:1px solid rgba(249,197,0,0.18);color:rgba(249,197,0,0.70);font-size:0.82rem;font-weight:700;letter-spacing:0.05em;text-transform:uppercase;">💬 Discussão do Guia</span>]]
| |
|
| |
| [https://timero.com.br/discord <span style="display:inline-flex;align-items:center;gap:7px;padding:9px 18px;border-radius:10px;background:rgba(114,137,218,0.10);border:1px solid rgba(114,137,218,0.20);color:#7289da;font-size:0.82rem;font-weight:700;letter-spacing:0.05em;text-transform:uppercase;">Discord TimeRO</span>]
| |
| </div>
| |
| | |
| </div>
| |
| </div>
| |
| <!-- /RELATED -->
| |
| | |
| | |
| </div>
| |
| <!-- /farming-guide-root -->
| |
| | |
| | |
| <script>
| |
| /* ════════════════════════════════════════════════════════
| |
| FARMING GUIDE JAVASCRIPT | |
| All new functions — none shared with leveling/mvp guides.
| |
| ════════════════════════════════════════════════════════ */
| |
| | |
| /* ── Method tab switcher ─────────────────────────── */
| |
| var activeMethod = 'grind';
| |
| var methodColors = {
| |
| grind: { bg: 'rgba(249,197,0,0.18)', color: '#f9c500' },
| |
| market: { bg: 'rgba(0,212,255,0.14)', color: '#00d4ff' },
| |
| passive: { bg: 'rgba(176,108,255,0.14)', color: '#b06cff' }
| |
| };
| |
| | |
| function switchMethod(m) {
| |
| activeMethod = m;
| |
| | |
| /* Hide all panels */
| |
| document.querySelectorAll('.method-panel').forEach(function(p) {
| |
| p.style.display = 'none';
| |
| });
| |
| | |
| /* Show selected panel */
| |
| var panel = document.getElementById('method-' + m);
| |
| if (panel) { panel.style.display = 'grid'; panel.style.animation = 'method-in 0.3s ease both'; }
| |
| | |
| /* Update tab buttons */
| |
| var tabs = { grind: 'grind', market: 'market', passive: 'passive' };
| |
| Object.keys(tabs).forEach(function(key) {
| |
| var btn = document.getElementById('mtab-' + key);
| |
| if (!btn) return;
| |
| if (key === m) {
| |
| var mc = methodColors[m];
| |
| btn.style.background = mc.bg;
| |
| btn.style.color = mc.color;
| |
| btn.style.fontWeight = '900';
| |
| } else {
| |
| btn.style.background = 'transparent';
| |
| btn.style.color = 'rgba(122,144,176,0.55)';
| |
| btn.style.fontWeight = '700';
| |
| }
| |
| });
| |
| }
| |
| | |
| /* ── Route pill viewer ───────────────────────────── */
| |
| var openRoute = null;
| |
| | |
| function expandRoute(id) {
| |
| var detail = document.getElementById(id);
| |
| if (!detail) return;
| |
| | |
| if (openRoute === id) {
| |
| /* Toggle close */
| |
| detail.style.display = 'none';
| |
| openRoute = null;
| |
| var pill = document.getElementById('pill-' + id);
| |
| if (pill) { pill.style.transform = ''; pill.style.fontWeight = '800'; }
| |
| return;
| |
| }
| |
| | |
| /* Close previously open */
| |
| if (openRoute) {
| |
| var prev = document.getElementById(openRoute);
| |
| if (prev) prev.style.display = 'none';
| |
| var prevPill = document.getElementById('pill-' + openRoute);
| |
| if (prevPill) { prevPill.style.transform = ''; prevPill.style.fontWeight = '800'; }
| |
| }
| |
| | |
| detail.style.display = 'block';
| |
| openRoute = id;
| |
| | |
| /* Highlight active pill */
| |
| var pill = document.getElementById('pill-' + id);
| |
| if (pill) { pill.style.transform = 'scale(1.04)'; pill.style.fontWeight = '900'; }
| |
| | |
| /* Scroll to route */
| |
| setTimeout(function() { detail.scrollIntoView({ behavior: 'smooth', block: 'nearest' }); }, 80);
| |
| }
| |
| | |
| /* ── Profitability Calculator ────────────────────── */
| |
| var calcState = {
| |
| hours: 2,
| |
| methodRate: 70, /* estimated M z per hour — change per method option */
| |
| booster: false
| |
| };
| |
| | |
| function adjustCalc(field, delta) {
| |
| if (field === 'hours') {
| |
| calcState.hours = Math.max(0.5, Math.min(12, calcState.hours + delta));
| |
| var el = document.getElementById('calc-hours');
| |
| if (el) el.textContent = calcState.hours;
| |
| }
| |
| updateCalc();
| |
| }
| |
| | |
| function setBooster(on) {
| |
| calcState.booster = on;
| |
| var yes = document.getElementById('boost-yes');
| |
| var no = document.getElementById('boost-no');
| |
| if (yes && no) {
| |
| if (on) {
| |
| yes.style.background = 'rgba(0,255,136,0.16)';
| |
| yes.style.borderColor = 'rgba(0,255,136,0.35)';
| |
| yes.style.color = '#00ff88';
| |
| no.style.background = 'rgba(255,255,255,0.04)';
| |
| no.style.borderColor = 'rgba(255,255,255,0.09)';
| |
| no.style.color = 'rgba(122,144,176,0.60)';
| |
| } else {
| |
| no.style.background = 'rgba(255,61,90,0.15)';
| |
| no.style.borderColor = 'rgba(255,61,90,0.30)';
| |
| no.style.color = '#ff3d5a';
| |
| yes.style.background = 'rgba(255,255,255,0.04)';
| |
| yes.style.borderColor = 'rgba(255,255,255,0.09)';
| |
| yes.style.color = 'rgba(122,144,176,0.60)';
| |
| }
| |
| }
| |
| updateCalc();
| |
| }
| |
| | |
| function updateCalc() {
| |
| var sel = document.getElementById('calc-method');
| |
| if (sel) calcState.methodRate = parseInt(sel.value) || 70;
| |
| | |
| var rate = calcState.methodRate * (calcState.booster ? 1.5 : 1.0);
| |
| var session = rate * calcState.hours;
| |
| var day = session;
| |
| var week = day * 7;
| |
| | |
| /* Format: if >= 1000, show as B (billions), >= 1 show as M, else k */
| |
| function fmt(v) {
| |
| if (v >= 1000) return (v / 1000).toFixed(1) + 'B z';
| |
| if (v >= 1) return v.toFixed(0) + 'M z';
| |
| return (v * 1000).toFixed(0) + 'k z';
| |
| }
| |
| | |
| var el_s = document.getElementById('result-session');
| |
| var el_d = document.getElementById('result-day');
| |
| var el_w = document.getElementById('result-week');
| |
| var el_b = document.getElementById('result-bar');
| |
| var el_p = document.getElementById('result-pct');
| |
| | |
| if (el_s) el_s.textContent = fmt(session);
| |
| if (el_d) el_d.textContent = fmt(day);
| |
| if (el_w) el_w.textContent = fmt(week);
| |
| | |
| /* Bar: max = endgame method * 12h * 7d * 1.5x booster */
| |
| var max = 95 * 1.5 * 12 * 7;
| |
| var pct = Math.min(100, Math.round((week / max) * 100));
| |
| if (el_b) el_b.style.width = pct + '%';
| |
| if (el_p) el_p.textContent = pct + '%';
| |
| }
| |
| | |
| /* ── Loadout Builder ─────────────────────────────── */
| |
| var loadoutTotal = 0;
| |
| var loadoutCount = 0;
| |
| | |
| function toggleLoadout(el) {
| |
| var cost = parseInt(el.dataset.cost) || 0;
| |
| var box = el.querySelector('.li-check');
| |
| var on = el.dataset.selected === '1';
| |
| | |
| if (on) {
| |
| el.dataset.selected = '0';
| |
| loadoutTotal -= cost;
| |
| loadoutCount--;
| |
| if (box) { box.textContent = ''; box.style.background = 'rgba(176,108,255,0.04)'; box.style.borderColor = 'rgba(176,108,255,0.30)'; }
| |
| el.style.background = 'rgba(255,255,255,0.03)';
| |
| el.style.borderColor = 'rgba(255,255,255,0.07)';
| |
| } else {
| |
| el.dataset.selected = '1';
| |
| loadoutTotal += cost;
| |
| loadoutCount++;
| |
| if (box) { box.textContent = '✓'; box.style.background = 'rgba(176,108,255,0.20)'; box.style.borderColor = 'rgba(176,108,255,0.50)'; box.style.color = '#b06cff'; }
| |
| el.style.background = 'rgba(176,108,255,0.07)';
| |
| el.style.borderColor = 'rgba(176,108,255,0.22)';
| |
| }
| |
| | |
| var tot = document.getElementById('loadout-total');
| |
| var cnt = document.getElementById('loadout-count');
| |
| if (tot) tot.textContent = loadoutTotal >= 1000
| |
| ? (loadoutTotal / 1000).toFixed(1) + 'M z'
| |
| : loadoutTotal + 'k z';
| |
| if (cnt) cnt.textContent = loadoutCount;
| |
| }
| |
| | |
| function clearLoadout() {
| |
| loadoutTotal = 0; loadoutCount = 0;
| |
| document.querySelectorAll('.loadout-item').forEach(function(el) {
| |
| el.dataset.selected = '0';
| |
| var box = el.querySelector('.li-check');
| |
| if (box) { box.textContent = ''; box.style.background = 'rgba(176,108,255,0.04)'; box.style.borderColor = 'rgba(176,108,255,0.30)'; box.style.color = ''; }
| |
| el.style.background = 'rgba(255,255,255,0.03)';
| |
| el.style.borderColor = 'rgba(255,255,255,0.07)';
| |
| });
| |
| var tot = document.getElementById('loadout-total'); if (tot) tot.textContent = '0k z';
| |
| var cnt = document.getElementById('loadout-count'); if (cnt) cnt.textContent = '0';
| |
| }
| |
| | |
| /* ── Efficiency bars animate on scroll ──────────── */
| |
| (function() {
| |
| var animated = false;
| |
| var observer = new IntersectionObserver(function(entries) {
| |
| entries.forEach(function(e) {
| |
| if (e.isIntersecting && !animated) {
| |
| animated = true;
| |
| document.querySelectorAll('.eff-bar').forEach(function(bar, i) {
| |
| var w = bar.style.width;
| |
| bar.style.width = '0';
| |
| bar.style.transition = 'width 0.8s ' + (i * 0.08) + 's cubic-bezier(0.22,1,0.36,1)';
| |
| setTimeout(function() { bar.style.width = w; }, 50);
| |
| });
| |
| }
| |
| });
| |
| }, { threshold: 0.2 });
| |
| var section = document.querySelector('.eff-bar');
| |
| if (section) observer.observe(section.closest('div') || section);
| |
| })();
| |
| | |
| /* ── Init ────────────────────────────────────────── */
| |
| document.addEventListener('DOMContentLoaded', function() {
| |
| var sb = document.getElementById('settingsButton'), sm = document.getElementById('settingsMenu');
| |
| if (sb && sm) sb.addEventListener('click', function() { sm.style.right = sm.style.right === '20px' ? '-300px' : '20px'; });
| |
| | |
| /* Init first method tab */
| |
| switchMethod('grind');
| |
| | |
| /* Init calculator */
| |
| updateCalc();
| |
| | |
| /* Smooth anchors */
| |
| document.querySelectorAll('a[href^="#"]').forEach(function(a) {
| |
| a.addEventListener('click', function(e) {
| |
| var id = this.getAttribute('href').slice(1), el = document.getElementById(id);
| |
| if (el) { e.preventDefault(); el.scrollIntoView({ behavior: 'smooth', block: 'start' }); }
| |
| });
| |
| });
| |
| | |
| /* Mobile padding */
| |
| if (window.innerWidth < 900) {
| |
| document.querySelectorAll(
| |
| '[style*="padding:52px 64px"],[style*="padding:48px 64px"],[style*="padding:28px 64px"]'
| |
| ).forEach(function(el) { el.style.paddingLeft = '18px'; el.style.paddingRight = '18px'; });
| |
| }
| |
| });
| |
| </script>
| |
|
| |
|
| [[Category:Guides]] | | [[Category:Guides]] |
| [[Category:Economy]] | | [[Category:Economy]] |
| [[Category:Farming]] | | [[Category:Farming]] |