v© ±Ruùj0ÔÔê6ÆWÙêÊJ¬ cordQ text/html M¦<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Generative 3DORDI NFT</title>
<script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/1.4.0/p5.js"></script>
<script src="https://unpkg.com/bsv@1.5.0/bsv.min.js"></script>
<style>
body { margin: 0; background: #000; color: #fff; font-family: sans-serif; overflow: hidden; }
canvas { display: block; }
#controls {
position: absolute; top: 10px; left: 10px; background: rgba(0,0,0,0.8);
padding: 15px; border-radius: 8px; border: 1px solid #333; display: none;
z-index: 100; width: 250px;
}
.menu-btn {
position: absolute; top: 10px; left: 10px; z-index: 101;
padding: 8px 12px; background: #00e676; border: none; cursor: pointer; font-weight: bold;
}
label { font-size: 12px; color: #00e676; display: block; margin-top: 10px; }
input, select { width: 100%; margin-top: 5px; background: #222; color: #fff; border: 1px solid #444; }
#save-btn {
margin-top: 20px; width: 100%; padding: 10px; background: #00e676;
color: #000; border: none; font-weight: bold; cursor: pointer;
}
</style>
</head>
<body>
<button class="menu-btn" onclick="toggleMenu()">Param setting</button>
<div id="controls">
<h2 style="margin:0 0 10px 0; font-size: 16px;">NFT Configuration</h2>
<label>Particles (1,000 - 50,000)</label>
<input type="range" id="countInput" min="1000" max="50000" step="1000" value="5000">
<span id="countVal" style="font-size: 10px;">5000</span>
<label>Trail Effect</label>
<select id="trailInput">
<option value="40">Short</option>
<option value="20">Medium</option>
<option value="5">Long</option>
</select>
<label>Color Theme</label>
<select id="colorInput">
<option value="red">Red</option>
<option value="gold">Gold</option>
<option value="silver">Silver</option>
<option value="blue">Blue</option>
<option value="green">Green</option>
<option value="yellow">Yellow</option>
</select>
<button id="save-btn" onclick="saveToBSV()">UPDATE ON BSV</button>
<p id="status" style="font-size: 9px; color: #888; margin-top: 10px;"></p>
</div>
<script>
let particles = [];
let params = { count: 5000, trail: 20, color: 'gold' };
const palette = {
red: [255, 50, 50], gold: [212, 175, 55], silver: [192, 192, 192],
blue: [50, 150, 255], green: [50, 255, 150], yellow: [255, 255, 50]
};
function setup() {
createCanvas(windowWidth, windowHeight);
// Logic to load previous state from BSV could go here
loadFromBlockchain();
initSystem();
}
function draw() {
background(0, params.trail);
let c = palette[params.color];
stroke(c[0], c[1], c[2], 200);
for (let p of particles) {
p.move();
p.display();
}
}
function initSystem() {
particles = [];
for (let i = 0; i < params.count; i++) {
particles.push(new Particle());
}
background(0);
}
class Particle {
constructor() {
this.pos = createVector(random(width), random(height));
this.vel = createVector(random(-2, 2), random(-2, 2));
}
move() {
this.pos.add(this.vel);
if (this.pos.x < 0 || this.pos.x > width) this.vel.x *= -1;
if (this.pos.y < 0 || this.pos.y > height) this.vel.y *= -1;
}
display() {
point(this.pos.x, this.pos.y);
}
}
function toggleMenu() {
let m = document.getElementById('controls');
m.style.display = m.style.display === 'block' ? 'none' : 'block';
}
document.getElementById('countInput').oninput = function() {
document.getElementById('countVal').innerText = this.value;
};
// --- BSV / 3DORDI INTEGRATION ---
async function loadFromBlockchain() {
// In 3DORDI, you can fetch the latest UTXO state
// for this specific inscription ID.
console.log("Fetching latest state from BSV...");
}
async function saveToBSV() {
params.count = parseInt(document.getElementById('countInput').value);
params.trail = parseInt(document.getElementById('trailInput').value);
params.color = document.getElementById('colorInput').value;
initSystem(); // Update visual immediately
document.getElementById('status').innerText = "Requesting Wallet Signature...";
try {
// This is a generic example using the 'yours-wallet' or 'panda' provider
if (typeof window.bsv !== 'undefined' || window.panda) {
const wallet = window.panda || window.bsv;
// You would send a transaction to an 'Update' function or
// re-inscribe the state in a 1Sat Ordinal script.
const tx = await wallet.sendBitcoin({
to: "1KQXiRYFUVaWo25RqKc1PtS8UmbTYgmBKt",
satoshis: 1,
data: [JSON.stringify(params)] // Storing parameters in OP_RETURN
});
document.getElementById('status').innerText = "Saved to BSV: " + tx.txid;
} else {
alert("BSV Wallet not detected!");
}
} catch (e) {
document.getElementById('status').innerText = "Error: " + e.message;
}
}
</script>
</body>
</html>hj"1PuQa7K62MiKCtssSLKy1kh56WWU7MtUR5SETapp3D OrditypeordnameBSV parametric nft 3.0subTypecollectionItem royaltiesLY[{"type":"address","destination":"1KQXiRYFUVaWo25RqKc1PtS8UmbTYgmBKt","percentage":0.15}]subTypeDataL|{"collectionId":"876d54a6b837ded943b29dc80ff5bbcd79eef89df47958fad0f653fa461e87fc_0","mintNumber":"63","rarityLabel":"Epic"}|SIGMABSM!1smCUqmbb45QVqCPRgMAp427jdH7yxfyzAÄI*£8ü¶¯W9÷Â1ïð¤0¯"g# ¦%ÝJlJæõmÃeFQ³ÙÜy?cû&ᾡû"ärVE®Oà0
https://whatsonchain.com/tx/undefined