<!DOCTYPE html>&#10;<html>&#10;<head>&#10;<meta content="width=device-width,initial-scale=1.0,user-scalable=no" name="viewport"/>&#10;<meta charset="utf-8"/>&#10;<style>
    * { margin: 0; padding: 0; box-sizing: border-box; }
    body { font-family: "Times New Roman", serif; background-color: transparent; color: #fff; overflow: hidden; touch-action: none; width: 100vw; height: 100vh; }
    .mod-menu { 
        position: fixed; 
        top: 50%; 
        left: 50%; 
        transform: translate(-50%, -50%); 
        background-color: rgba(0, 0, 0, 0.90); /* 透明度を変更 */
        z-index: 1000; 
        width: calc(220px - 19px);
        border: 1px solid #333; 
        font-size: 14px;
        border-radius: 8px; 
        box-shadow: 0 0 20px rgba(0, 0, 0, 0.90);
    }
    .mod-header { padding: 10px; cursor: grab; user-select: none; text-align: left; border-bottom: 1px solid #888; display: flex; align-items: center; } /* ボーダー色変更 */
    .scroll-container { overflow-y: auto; max-height: 70vh; }
    .switch-container { 
        padding: 12px 15px; 
        min-height: 44px; 
        display: flex; 
        align-items: center; 
        justify-content: center;
        border-bottom: 1px solid #888; /* ボーダー色変更 */
        position: relative;
    }
    .first-item { border-top: 1px solid #888; } /* ボーダー色変更 */
    .switch-label { 
        color: #fff; 
        font-family: "Times New Roman", serif; 
        font-size: 14px; 
        width: 100%;
        text-align: center;
        white-space: nowrap; /* 改行防止 */
    }
    .switch-container.active { background-color: rgba(255, 0, 0, 0.8); }
    .mod-title { 
      font-size: 18px;
      font-family: -apple-system, sans-serif;
      font-weight: bold;
      margin: 0;
      padding: 0;
    }
    .title-image {
      width: 24px;
      height: 24px;
      margin-right: 8px;
      background-size: contain;
      background-repeat: no-repeat;
    }
    .section-header {
      pointer-events: none;
      background-color: rgba(0, 0, 0, 0.90); /* 背景色変更 */
    }
    .section-header .switch-label {
      color: #FFD700;
      font-weight: bold;
    }
    .small-text {
      font-size: 12px; /* 小さい文字サイズ */
    }
</style>&#10;</head>&#10;<body>&#10;<div class="mod-menu" id="mod-menu">&#10;&#32;&#32;<div class="mod-header" id="mod-header">&#10;&#32;&#32;&#32;&#32;<div class="title-image"></div>&#10;&#32;&#32;&#32;&#32;<h2 class="mod-title">&#84;&#115;&#117;&#109;&#32;&#80;&#101;&#110;&#105;&#32;&#77;&#111;&#100;</h2>&#10;&#32;&#32;</div>&#10;&#32;&#32;<div class="scroll-container">&#10;&#32;&#32;&#32;&#32;<!-- 代行セクション -->&#10;&#32;&#32;&#32;&#32;<div class="switch-container first-item section-header">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#9473;&#32;&#20195;&#34892;&#32;&#9473;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('coin1')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#12467;&#12452;&#12531;&#49;&#20740;&#22266;&#23450;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('coin2')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#12467;&#12452;&#12531;&#50;&#20740;&#22266;&#23450;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('medal1')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#12513;&#12480;&#12523;&#49;&#20740;&#22266;&#23450;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('medal')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#12513;&#12480;&#12523;&#50;&#20740;&#22266;&#23450;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('maxScore')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#12473;&#12467;&#12450;&#50;&#49;&#20740;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('tsumCount')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#12484;&#12512;&#29554;&#24471;&#25968;&#53;&#19975;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('levelMax')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#12503;&#12524;&#12452;&#12516;&#12540;&#76;&#118;&#77;&#97;&#120;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#10;&#32;&#32;&#32;&#32;<!-- プレイ内設定セクション -->&#10;&#32;&#32;&#32;&#32;<div class="switch-container section-header">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#9473;&#32;&#12503;&#12524;&#12452;&#20869;&#35373;&#23450;&#32;&#9473;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('autoChain')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#12458;&#12540;&#12488;&#12481;&#12455;&#12540;&#12531;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('singleClear')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#49;&#12388;&#28040;&#12375;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('allChain')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#20840;&#12484;&#12512;&#12481;&#12455;&#12540;&#12531;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('tsumBoost')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#12484;&#12512;&#22679;&#37327;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('instantEnd')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#21363;&#32066;&#20102;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('oneTsumEnd')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#49;&#12484;&#12512;&#28040;&#12375;&#32066;&#20102;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('speed100x')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#36895;&#24230;&#215;&#49;&#48;&#48;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<!-- 非表示/スキップセクション -->&#10;&#32;&#32;&#32;&#32;<div class="switch-container section-header">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#9473;&#32;&#38750;&#34920;&#31034;&#32;&#47;&#32;&#12473;&#12461;&#12483;&#12503;&#32;&#9473;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('hideItems')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#12450;&#12452;&#12486;&#12512;&#38750;&#34920;&#31034;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('informationDelete')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#105;&#110;&#102;&#111;&#114;&#109;&#97;&#116;&#105;&#111;&#110;&#21066;&#38500;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('levelUnlock')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label small-text">&#12484;&#12512;&#12524;&#12505;&#12523;&#12525;&#12483;&#12463;&#35299;&#38500;&#12473;&#12461;&#12483;&#12503;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('gachaSkip')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#12460;&#12481;&#12515;&#12473;&#12461;&#12483;&#12503;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('pickupSkip')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#12500;&#12483;&#12463;&#12450;&#12483;&#12503;&#12473;&#12461;&#12483;&#12503;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('resultSkip')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#12522;&#12470;&#12523;&#12488;&#12473;&#12461;&#12483;&#12503;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('matchSkip')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#35430;&#21512;&#32080;&#26524;&#12473;&#12461;&#12483;&#12503;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('rootAlert')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#12523;&#12540;&#12488;&#26908;&#20986;&#21066;&#38500;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;&#32;&#32;<div class="switch-container" onclick="toggleFunction('lineBypass')">&#10;&#32;&#32;&#32;&#32;&#32;&#32;<span class="switch-label">&#76;&#73;&#78;&#69;&#21516;&#24847;&#98;&#121;&#112;&#97;&#115;&#115;</span>&#10;&#32;&#32;&#32;&#32;</div>&#10;&#32;&#32;</div>&#10;</div>&#10;<script>
    h5gg.require(7.9); 
    var h5frida = h5gg.loadPlugin("h5frida", "h5frida-15.1.24.dylib");
    if (!h5frida) throw "Failed to load h5frida plugin";

    function ActiveCodePatch(fpath, vaddr, bytes) {
      if (!h5frida.ActiveCodePatch(fpath, vaddr, bytes)) {
        var result = h5frida.ApplyCodePatch(fpath, vaddr, bytes);
        alert(fpath + ":0x" + vaddr.toString(16) + "-変更失敗!\n" + fpath + ":0x" + vaddr.toString(16) + "-PatchFailed!\n" + result);
        return false;
      }
      return true;
    }

    function DeactiveCodePatch(fpath, vaddr, bytes) {
      return h5frida.DeactiveCodePatch(fpath, vaddr, bytes);
    }

    const functionStates = {
      coin1: false, coin2: false, medal1: false, medal: false, levelMax: false, 
      maxScore: false, tsumCount: false, autoChain: false, singleClear: false,
      allChain: false, tsumBoost: false, instantEnd: false, oneTsumEnd: false,
      gachaSkip: false, pickupSkip: false, resultSkip: false, matchSkip: false,
      rootAlert: false, lineBypass: false, hideItems: false, speed100x: false,
      informationDelete: false, levelUnlock: false
    };

    function toggleFunction(funcName) {
      const container = event.currentTarget;
      functionStates[funcName] = !functionStates[funcName];
      container.classList.toggle('active');

      const patchData = patches[funcName];
      const fpath = patchData[0];
      
      if (functionStates[funcName]) {
        for (let i = 1; i < patchData.length; i += 2) {
          ActiveCodePatch(fpath, patchData[i], patchData[i+1]);
        }
      } else {
        for (let i = 1; i < patchData.length; i += 2) {
          DeactiveCodePatch(fpath, patchData[i], patchData[i+1]);
        }
      }
    }

    const menu = document.getElementById('mod-menu');
    const header = document.getElementById('mod-header');
    let isDragging = false;
    let startX, startY, initialX, initialY;

    header.addEventListener('mousedown', (e) => {
      isDragging = true;
      const rect = menu.getBoundingClientRect();
      startX = e.clientX;
      startY = e.clientY;
      initialX = rect.left;
      initialY = rect.top;
      header.style.cursor = 'grabbing';
      e.preventDefault();
    });

    document.addEventListener('mousemove', (e) => {
      if (!isDragging) return;
      const dx = e.clientX - startX;
      const dy = e.clientY - startY;
      menu.style.left = `${initialX + dx}px`;
      menu.style.top = `${initialY + dy}px`;
      menu.style.transform = 'none';
    });

    document.addEventListener('mouseup', () => {
      isDragging = false;
      header.style.cursor = 'grab';
    });

    header.addEventListener('touchstart', (e) => {
      isDragging = true;
      const touch = e.touches[0];
      const rect = menu.getBoundingClientRect();
      startX = touch.clientX;
      startY = touch.clientY;
      initialX = rect.left;
      initialY = rect.top;
    }, { passive: false });

    document.addEventListener('touchmove', (e) => {
      if (!isDragging) return;
      const touch = e.touches[0];
      const dx = touch.clientX - startX;
      const dy = touch.clientY - startY;
      menu.style.left = `${initialX + dx}px`;
      menu.style.top = `${initialY + dy}px`;
      menu.style.transform = 'none';
      e.preventDefault();
    }, { passive: false });

    document.addEventListener('touchend', () => {
      isDragging = false;
    });
</script>&#10;</body>&#10;</html>