| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8" /> | |
| <link rel="icon" type="image/svg+xml" href="/favicon.svg" /> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0" /> | |
| <title>Shadow Duel AI</title> | |
| <script type="module" crossorigin src="/assets/index-Dp4pBtge.js"></script> | |
| <link rel="stylesheet" crossorigin href="/assets/index-DUDqKLMt.css"> | |
| <script> | |
| // AI Bridge: receives AI_RESPONSE from Gradio parent and forwards to game | |
| window.addEventListener("message", function(e) { | |
| if (e.data && e.data.type === "AI_RESPONSE") { | |
| window.dispatchEvent(new CustomEvent("ai-response", { detail: e.data })); | |
| } | |
| }); | |
| window.sendAIRequest = function(sequence) { | |
| try { | |
| window.parent.postMessage({ | |
| type: 'AI_REQUEST', | |
| sequence: sequence | |
| }, '*'); | |
| } catch(e) {} | |
| }; | |
| </script> | |
| </head> | |
| <body> | |
| <div id="root"></div> | |
| </body> | |
| </html> | |