Użytkownik:DudeValenzetti/Kostka: Różnice pomiędzy wersjami

Z Nonsensopedii, polskiej encyklopedii humoru
M (By nie było wartości 360°)
(Dokumentacja (po angielsku) i dostosowanie boku 4)
 
Linia 6: Linia 6:


<div style="perspective:600px"><!--Perspective container-->
<div style="perspective:600px"><!--Perspective container-->
<div style="margin:3em auto;transform-style:preserve-3d;width:200px;height:200px;font-size:60px;line-height:200px;transform:rotateX({{#expr: {{Get}} mod 1000}}deg) rotateY({{#expr: {{Get}} div 1000 mod 1000}}deg)">
<div style="margin:3em auto;transform-style:preserve-3d;width:200px;height:200px;font-size:60px;line-height:200px;transform:rotateX({{#expr: {{Get}} mod 1000}}deg) rotateY({{#expr: {{Get}} div 1000 mod 1000}}deg)"><!--Cube core div: this stores the rotation of the cube-->
<div style="position:absolute;text-align:center;border:1px solid black;width:200px;height:200px;background:rgba(129,134,138,0.6);transform:translateZ(100px)">1</div>
<div style="position:absolute;text-align:center;border:1px solid black;width:200px;height:200px;background:rgba(129,134,138,0.6);transform:translateZ(100px)">1</div>
<div style="position:absolute;text-align:center;border:1px solid black;width:200px;height:200px;background:rgba(129,134,138,0.6);transform:rotateX(90deg) translateZ(100px)">2</div>
<div style="position:absolute;text-align:center;border:1px solid black;width:200px;height:200px;background:rgba(129,134,138,0.6);transform:rotateX(90deg) translateZ(100px)">2</div>
<div style="position:absolute;text-align:center;border:1px solid black;width:200px;height:200px;background:rgba(129,134,138,0.6);transform:rotateY(90deg) translateZ(100px)">3</div>
<div style="position:absolute;text-align:center;border:1px solid black;width:200px;height:200px;background:rgba(129,134,138,0.6);transform:rotateY(90deg) translateZ(100px)">3</div>
<div style="position:absolute;text-align:center;border:1px solid black;width:200px;height:200px;background:rgba(129,134,138,0.6);transform:rotateX(-90deg) translateZ(100px)">5</div>
<div style="position:absolute;text-align:center;border:1px solid black;width:200px;height:200px;background:rgba(129,134,138,0.6);transform:rotateX(-90deg) translateZ(100px)">5</div>
<div style="position:absolute;text-align:center;border:1px solid black;width:200px;height:200px;background:rgba(129,134,138,0.6);transform:rotateY(-90deg) translateZ(100px)">4</div>
<div style="position:absolute;text-align:center;border:1px solid black;width:200px;height:200px;background:rgba(129,134,138,0.6);transform:rotateY(-90deg) rotateZ(180deg) translateZ(100px)">4</div>
<div style="position:absolute;text-align:center;border:1px solid black;width:200px;height:200px;background:rgba(129,134,138,0.6);transform:rotateX(180deg) translateZ(100px)">6</div>
<div style="position:absolute;text-align:center;border:1px solid black;width:200px;height:200px;background:rgba(129,134,138,0.6);transform:rotateX(180deg) translateZ(100px)">6</div><!--These divs are the sides of the cube-->
</div>
</div>
</div>
</div>
Linia 33: Linia 33:
| style="width:12.5%;height:50px;" | {{Idź|{{#ifexpr:{{Get}} div 1000 mod 1000 < 315|{{#expr: {{Get}} + 45000}}|{{#expr: {{Get}} - 315000}} }}|45||color:black}}°
| style="width:12.5%;height:50px;" | {{Idź|{{#ifexpr:{{Get}} div 1000 mod 1000 < 315|{{#expr: {{Get}} + 45000}}|{{#expr: {{Get}} - 315000}} }}|45||color:black}}°
|}
|}
<!--Implementation: The last three digits of the offset store rotateX (the pitch, in degrees: up/down). The first three digits store rotateY (the yaw, in degrees: up/down). The movement links change their respective digits of the offset and keep it between 0° and 359° for each axis.-->

</div>
</div>
</div>
</div>

Aktualna wersja na dzień 23:25, 8 maj 2018

Wypociny: Kostka sześcienna
niedziela, 24 listopada 2024 – 03:36

Obracaj sobie kostkę. Zaimplementowane na offsetach. Wymagana w miarę nowa przeglądarka.

1
2
3
5
4
6
-45° -15° -5° x: 0° 5° 15° 45°
-45° -15° -5° y: 0° 5° 15° 45°