<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="de">
	<id>https://wiki.gegenerde.net/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Narvik</id>
	<title>Gor Wiki - Benutzerbeiträge [de]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.gegenerde.net/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Narvik"/>
	<link rel="alternate" type="text/html" href="https://wiki.gegenerde.net/wiki/Spezial:Beitr%C3%A4ge/Narvik"/>
	<updated>2026-04-17T10:19:14Z</updated>
	<subtitle>Benutzerbeiträge</subtitle>
	<generator>MediaWiki 1.44.2</generator>
	<entry>
		<id>https://wiki.gegenerde.net/index.php?title=MediaWiki:Common.js&amp;diff=1071</id>
		<title>MediaWiki:Common.js</title>
		<link rel="alternate" type="text/html" href="https://wiki.gegenerde.net/index.php?title=MediaWiki:Common.js&amp;diff=1071"/>
		<updated>2025-11-27T08:15:32Z</updated>

		<summary type="html">&lt;p&gt;Narvik: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;mw.loader.using([&#039;mediawiki.util&#039;], function () {&lt;br /&gt;
&lt;br /&gt;
    // Goreanische Konstanten&lt;br /&gt;
    const IHN_PER_EHN = 80;&lt;br /&gt;
    const EHN_PER_AHN = 40;&lt;br /&gt;
    const AHN_PER_DAY = 20;&lt;br /&gt;
&lt;br /&gt;
    const IHN_PER_AHN = IHN_PER_EHN * EHN_PER_AHN;   // 80 * 40 = 3200&lt;br /&gt;
    const IHN_PER_DAY = IHN_PER_AHN * AHN_PER_DAY;   // 3200 * 20 = 64000&lt;br /&gt;
&lt;br /&gt;
    // Erdtag (24h) → goreanischer Tag (64000 Ihn)&lt;br /&gt;
    const SEC_PER_IHN = 86400 / IHN_PER_DAY;         // ≈ 1,35 s pro Ihn&lt;br /&gt;
&lt;br /&gt;
    // Ziffernblatt-Konstanten für Ahn (10er-Blatt)&lt;br /&gt;
    const STEP_AHN = 360 / 10;   // 10 Felder&lt;br /&gt;
	const BASE_OFFSET_AHN = 0;&lt;br /&gt;
&lt;br /&gt;
	function getGoreanTime() {&lt;br /&gt;
    	const now = new Date();&lt;br /&gt;
	    const  seconds = (now.getHours() * 60 + now.getMinutes()) * 60 + now.getSeconds() + now.getMilliseconds() / 1000;&lt;br /&gt;
&lt;br /&gt;
    	const total_ihn = seconds / SEC_PER_IHN;&lt;br /&gt;
&lt;br /&gt;
    	const ahn = Math.floor( total_ihn / IHN_PER_AHN) + 1;&lt;br /&gt;
    	const rest = total_ihn - (ahn-1) * IHN_PER_AHN;&lt;br /&gt;
    	const ehn = Math.floor( rest / IHN_PER_EHN);&lt;br /&gt;
    	const ihn = rest - ehn * IHN_PER_EHN;&lt;br /&gt;
&lt;br /&gt;
    	return { ahn, ehn, ihn };&lt;br /&gt;
	}&lt;br /&gt;
&lt;br /&gt;
    function buildDial() {&lt;br /&gt;
        const clock = document.getElementById(&amp;quot;gorClock&amp;quot;);&lt;br /&gt;
        if (!clock) return;&lt;br /&gt;
&lt;br /&gt;
        if (clock.dataset.gorDialBuilt === &amp;quot;1&amp;quot;) return;&lt;br /&gt;
        clock.dataset.gorDialBuilt = &amp;quot;1&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
        const centerX = clock.clientWidth / 2;&lt;br /&gt;
        const centerY = clock.clientHeight / 2;&lt;br /&gt;
&lt;br /&gt;
        const radiusOuter = 100;  // 1–10&lt;br /&gt;
        const radiusInner = 78;   // 11–20&lt;br /&gt;
&lt;br /&gt;
        for (let i = 0; i &amp;lt; 10; i++) {&lt;br /&gt;
            // Winkel für 1–10 / 11–20 in 36°-Schritten, oben = 10/20&lt;br /&gt;
            const angle = BASE_OFFSET_AHN + STEP_AHN * i;&lt;br /&gt;
&lt;br /&gt;
            // Umrechnung auf Canvas-Math: oben = -90°&lt;br /&gt;
            const rad = (angle - 90) * Math.PI / 180;&lt;br /&gt;
&lt;br /&gt;
            // ÄUSSERE ZAHL (1–10)&lt;br /&gt;
            const numOuter = document.createElement(&amp;quot;div&amp;quot;);&lt;br /&gt;
            numOuter.className = &amp;quot;gor-number&amp;quot;;&lt;br /&gt;
            numOuter.textContent = i + 1;&lt;br /&gt;
&lt;br /&gt;
            numOuter.style.left = (centerX + radiusOuter * Math.cos(rad)) + &amp;quot;px&amp;quot;;&lt;br /&gt;
            numOuter.style.top  = (centerY + radiusOuter * Math.sin(rad)) + &amp;quot;px&amp;quot;;&lt;br /&gt;
            clock.appendChild(numOuter);&lt;br /&gt;
&lt;br /&gt;
            // INNERE ZAHL (11–20)&lt;br /&gt;
            const numInner = document.createElement(&amp;quot;div&amp;quot;);&lt;br /&gt;
            numInner.className = &amp;quot;gor-number gor-number-inner&amp;quot;;&lt;br /&gt;
            numInner.textContent = i + 11;&lt;br /&gt;
&lt;br /&gt;
            numInner.style.left = (centerX + radiusInner * Math.cos(rad)) + &amp;quot;px&amp;quot;;&lt;br /&gt;
            numInner.style.top  = (centerY + radiusInner * Math.sin(rad)) + &amp;quot;px&amp;quot;;&lt;br /&gt;
            clock.appendChild(numInner);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    function updateGoreanClock() {&lt;br /&gt;
        const handAhn = document.getElementById(&amp;quot;handAhn&amp;quot;);&lt;br /&gt;
        const handEhn = document.getElementById(&amp;quot;handEhn&amp;quot;);&lt;br /&gt;
        const handIhn = document.getElementById(&amp;quot;handIhn&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        if (!handAhn || !handEhn || !handIhn) return;&lt;br /&gt;
&lt;br /&gt;
        const t = getGoreanTime();&lt;br /&gt;
&lt;br /&gt;
        // === Ahn-Zeiger: 10er-Blatt, zwei Runden pro Tag, passend zum Ziffernblatt ===&lt;br /&gt;
        const ahnCycle = (t.ahn - 1) % 10; // 0..9 (1–10 / 11–20)&lt;br /&gt;
        const fractionInAhn =&lt;br /&gt;
            t.ehn / EHN_PER_AHN + t.ihn / IHN_PER_AHN; // Anteil innerhalb der aktuellen Ahn&lt;br /&gt;
&lt;br /&gt;
        const angleAhn = BASE_OFFSET_AHN + STEP_AHN * (ahnCycle + fractionInAhn);&lt;br /&gt;
&lt;br /&gt;
        // === Ehn-Zeiger (40 Ehn pro Umdrehung) ===&lt;br /&gt;
        const angleEhn = ((t.ehn + t.ihn / IHN_PER_EHN) / EHN_PER_AHN) * 360;&lt;br /&gt;
&lt;br /&gt;
        // === Ihn-Zeiger (80 Ihn pro Umdrehung) ===&lt;br /&gt;
        const angleIhn = (t.ihn / IHN_PER_EHN) * 360;&lt;br /&gt;
&lt;br /&gt;
        handAhn.style.transform = `translate(-50%, -100%) rotate(${angleAhn}deg)`;&lt;br /&gt;
        handEhn.style.transform = `translate(-50%, -100%) rotate(${angleEhn}deg)`;&lt;br /&gt;
        handIhn.style.transform = `translate(-50%, -100%) rotate(${angleIhn}deg)`;&lt;br /&gt;
&lt;br /&gt;
        // Digitale Ausgabe&lt;br /&gt;
        const pad2 = n =&amp;gt; String(Math.floor(n)).padStart(2, &amp;quot;0&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        const dAhn = document.getElementById(&amp;quot;digitalAhn&amp;quot;);&lt;br /&gt;
        const dEhn = document.getElementById(&amp;quot;digitalEhn&amp;quot;);&lt;br /&gt;
        const dIhn = document.getElementById(&amp;quot;digitalIhn&amp;quot;);&lt;br /&gt;
        const info = document.getElementById(&amp;quot;ahnInfo&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        if (dAhn) dAhn.textContent = &amp;quot;Ahn &amp;quot; + pad2(t.ahn);&lt;br /&gt;
        if (dEhn) dEhn.textContent = &amp;quot;Ehn &amp;quot; + pad2(t.ehn);&lt;br /&gt;
        if (dIhn) dIhn.textContent = &amp;quot;Ihn &amp;quot; + pad2(t.ihn);&lt;br /&gt;
&lt;br /&gt;
        if (info) {&lt;br /&gt;
            if (t.ahn === 10) {&lt;br /&gt;
                info.textContent = &amp;quot;10. Ahn – goreanischer Mittag&amp;quot;;&lt;br /&gt;
            } else if (t.ahn === 20) {&lt;br /&gt;
                info.textContent = &amp;quot;20. Ahn – goreanische Mitternacht&amp;quot;;&lt;br /&gt;
            } else {&lt;br /&gt;
                info.textContent = t.ahn + &amp;quot;. Ahn des goreanischen Tages&amp;quot;;&lt;br /&gt;
            }&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    function init() {&lt;br /&gt;
        if (!document.getElementById(&amp;quot;gorClock&amp;quot;)) return;&lt;br /&gt;
&lt;br /&gt;
        buildDial();&lt;br /&gt;
        updateGoreanClock();&lt;br /&gt;
        setInterval(updateGoreanClock, 300); // 300 ms = ok für Performance&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    mw.hook(&#039;wikipage.content&#039;).add(init);&lt;br /&gt;
});&lt;/div&gt;</summary>
		<author><name>Narvik</name></author>
	</entry>
	<entry>
		<id>https://wiki.gegenerde.net/index.php?title=MediaWiki:Common.js&amp;diff=923</id>
		<title>MediaWiki:Common.js</title>
		<link rel="alternate" type="text/html" href="https://wiki.gegenerde.net/index.php?title=MediaWiki:Common.js&amp;diff=923"/>
		<updated>2025-11-25T12:48:03Z</updated>

		<summary type="html">&lt;p&gt;Narvik: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;mw.loader.using([&#039;mediawiki.util&#039;], function () {&lt;br /&gt;
&lt;br /&gt;
    // Goreanische Konstanten&lt;br /&gt;
    const IHN_PER_EHN = 80;&lt;br /&gt;
    const EHN_PER_AHN = 40;&lt;br /&gt;
    const AHN_PER_DAY = 20;&lt;br /&gt;
&lt;br /&gt;
    const IHN_PER_AHN = IHN_PER_EHN * EHN_PER_AHN;&lt;br /&gt;
    const IHN_PER_DAY = IHN_PER_AHN * AHN_PER_DAY;&lt;br /&gt;
&lt;br /&gt;
    const SEC_PER_IHN = 86400 / IHN_PER_DAY;&lt;br /&gt;
&lt;br /&gt;
    function getGoreanTime() {&lt;br /&gt;
        const now = new Date();&lt;br /&gt;
        const midnight = new Date(now.getFullYear(), now.getMonth(), now.getDate());&lt;br /&gt;
        const elapsed = (now - midnight) / 1000;&lt;br /&gt;
&lt;br /&gt;
        const totalIhn = elapsed / SEC_PER_IHN;&lt;br /&gt;
        const dayIhn = ((totalIhn % IHN_PER_DAY) + IHN_PER_DAY) % IHN_PER_DAY;&lt;br /&gt;
&lt;br /&gt;
        const ahnIndex = Math.floor(dayIhn / IHN_PER_AHN);&lt;br /&gt;
        const rest = dayIhn % IHN_PER_AHN;&lt;br /&gt;
&lt;br /&gt;
        const ehn = Math.floor(rest / IHN_PER_EHN);&lt;br /&gt;
        const ihn = rest % IHN_PER_EHN;&lt;br /&gt;
&lt;br /&gt;
        const ahn = ahnIndex + 1;&lt;br /&gt;
&lt;br /&gt;
        return { ahnIndex, ahn, ehn, ihn };&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    function buildDial() {&lt;br /&gt;
        const clock = document.getElementById(&amp;quot;gorClock&amp;quot;);&lt;br /&gt;
        if (!clock) return;&lt;br /&gt;
&lt;br /&gt;
        if (clock.dataset.gorDialBuilt === &amp;quot;1&amp;quot;) return;&lt;br /&gt;
        clock.dataset.gorDialBuilt = &amp;quot;1&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
        const centerX = clock.clientWidth / 2;&lt;br /&gt;
        const centerY = clock.clientHeight / 2;&lt;br /&gt;
&lt;br /&gt;
        const radiusOuter = 100;  // 1–10&lt;br /&gt;
        const radiusInner = 78;   // 11–20&lt;br /&gt;
&lt;br /&gt;
        // Wir wollen: oben = 10 (außen) + 20 (innen)&lt;br /&gt;
        // Standard 0° = rechts, aber oben ist -90°&lt;br /&gt;
        // Wir verschieben um +180°, damit oben 10 erscheint&lt;br /&gt;
        const baseOffset = 36;&lt;br /&gt;
&lt;br /&gt;
        for (let i = 0; i &amp;lt; 10; i++) {&lt;br /&gt;
&lt;br /&gt;
            // Winkel für 1–10/11–20: 36° Schritte&lt;br /&gt;
            const angle = baseOffset + (360 / 10) * i;&lt;br /&gt;
&lt;br /&gt;
            // Umrechnung auf Kreis-Math-Winkel: oben = -90°&lt;br /&gt;
            const rad = (angle - 90) * Math.PI / 180;&lt;br /&gt;
&lt;br /&gt;
            // ÄUSSERE ZAHL (1–10)&lt;br /&gt;
            const numOuter = document.createElement(&amp;quot;div&amp;quot;);&lt;br /&gt;
            numOuter.className = &amp;quot;gor-number&amp;quot;;&lt;br /&gt;
            numOuter.textContent = i + 1;&lt;br /&gt;
&lt;br /&gt;
            numOuter.style.left = (centerX + radiusOuter * Math.cos(rad)) + &amp;quot;px&amp;quot;;&lt;br /&gt;
            numOuter.style.top  = (centerY + radiusOuter * Math.sin(rad)) + &amp;quot;px&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
            clock.appendChild(numOuter);&lt;br /&gt;
&lt;br /&gt;
            // INNERE ZAHL (11–20)&lt;br /&gt;
            const numInner = document.createElement(&amp;quot;div&amp;quot;);&lt;br /&gt;
            numInner.className = &amp;quot;gor-number gor-number-inner&amp;quot;;&lt;br /&gt;
            numInner.textContent = i + 11;&lt;br /&gt;
&lt;br /&gt;
            numInner.style.left = (centerX + radiusInner * Math.cos(rad)) + &amp;quot;px&amp;quot;;&lt;br /&gt;
            numInner.style.top  = (centerY + radiusInner * Math.sin(rad)) + &amp;quot;px&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
            clock.appendChild(numInner);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    function updateGoreanClock() {&lt;br /&gt;
        const handAhn = document.getElementById(&amp;quot;handAhn&amp;quot;);&lt;br /&gt;
        const handEhn = document.getElementById(&amp;quot;handEhn&amp;quot;);&lt;br /&gt;
        const handIhn = document.getElementById(&amp;quot;handIhn&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        if (!handAhn) return;&lt;br /&gt;
&lt;br /&gt;
        const t = getGoreanTime();&lt;br /&gt;
&lt;br /&gt;
        // Ahn-Zeiger: 10er-Blatt mit zwei Runden&lt;br /&gt;
        const ahnCycle = (t.ahn - 1) % 10;&lt;br /&gt;
        const angleAhn = ((ahnCycle + t.ehn / 40 + t.ihn / 3200) / 10) * 360;&lt;br /&gt;
&lt;br /&gt;
        // Ehn-Zeiger (40 Ehn)&lt;br /&gt;
        const angleEhn = ((t.ehn + t.ihn / 80) / 40) * 360;&lt;br /&gt;
&lt;br /&gt;
        // Ihn-Zeiger (80 Ihn)&lt;br /&gt;
        const angleIhn = (t.ihn / 80) * 360;&lt;br /&gt;
&lt;br /&gt;
        handAhn.style.transform = `translate(-50%, -100%) rotate(${angleAhn}deg)`;&lt;br /&gt;
        handEhn.style.transform = `translate(-50%, -100%) rotate(${angleEhn}deg)`;&lt;br /&gt;
        handIhn.style.transform = `translate(-50%, -100%) rotate(${angleIhn}deg)`;&lt;br /&gt;
&lt;br /&gt;
        // Digitale Ausgabe&lt;br /&gt;
        const pad2 = n =&amp;gt; String(Math.floor(n)).padStart(2, &amp;quot;0&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        document.getElementById(&amp;quot;digitalAhn&amp;quot;).textContent = &amp;quot;Ahn &amp;quot; + pad2(t.ahn);&lt;br /&gt;
        document.getElementById(&amp;quot;digitalEhn&amp;quot;).textContent = &amp;quot;Ehn &amp;quot; + pad2(t.ehn);&lt;br /&gt;
        document.getElementById(&amp;quot;digitalIhn&amp;quot;).textContent = &amp;quot;Ihn &amp;quot; + pad2(t.ihn);&lt;br /&gt;
&lt;br /&gt;
        const info = document.getElementById(&amp;quot;ahnInfo&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
        if (t.ahn === 10) info.textContent = &amp;quot;10. Ahn – goreanischer Mittag&amp;quot;;&lt;br /&gt;
        else if (t.ahn === 20) info.textContent = &amp;quot;20. Ahn – goreanische Mitternacht&amp;quot;;&lt;br /&gt;
        else info.textContent = t.ahn + &amp;quot;. Ahn des goreanischen Tages&amp;quot;;&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    function init() {&lt;br /&gt;
        if (!document.getElementById(&amp;quot;gorClock&amp;quot;)) return;&lt;br /&gt;
&lt;br /&gt;
        buildDial();&lt;br /&gt;
        updateGoreanClock();&lt;br /&gt;
        setInterval(updateGoreanClock, 300);&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    mw.hook(&#039;wikipage.content&#039;).add(init);&lt;br /&gt;
});&lt;/div&gt;</summary>
		<author><name>Narvik</name></author>
	</entry>
</feed>