Drawaria 3D Cube

3D rotating cube for drawaria.online

您需要先安装一个扩展,例如 篡改猴Greasemonkey暴力猴,之后才能安装此脚本。

您需要先安装一个扩展,例如 篡改猴暴力猴,之后才能安装此脚本。

您需要先安装一个扩展,例如 篡改猴暴力猴,之后才能安装此脚本。

您需要先安装一个扩展,例如 篡改猴Userscripts ,之后才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。

您需要先安装用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

作者
YouTubeDrawaria
日安装量
0
总安装量
3
评分
0 0 0
版本
1.0
创建于
2025-01-30
更新于
2025-01-30
大小
3.5 KB
许可证
MIT
适用于

This userscript is designed to add a 3D rotating cube to the `drawaria.online` website. Here's a detailed explanation of how it works:

### 1. **Metadata Block**
- The script starts with a metadata block enclosed in `// ==UserScript==` and `// ==/UserScript==`. This block provides information about the script, such as its name, version, description, author, and the website it should run on (`@match`). It also specifies that no special permissions are required (`@grant none`).

### 2. **Creating the Cube Container**
- The script creates a `div` element (`cubeContainer`) to hold the 3D cube. This container is positioned fixed on the screen (20px from the top and right edges) and has a high `z-index` to ensure it appears above other elements. The cursor is set to `move` to indicate that the cube is draggable.

### 3. **Creating the Cube**
- The cube itself is another `div` element (`cube`) with the class `cube`. This element will be transformed in 3D space using CSS.

### 4. **Creating the Cube Faces**
- The cube has six faces: front, back, right, left, top, and bottom. The script creates a `div` for each face, assigns the appropriate class, and appends it to the cube.

### 5. **Adding Elements to the Page**
- The cube is appended to the `cubeContainer`, and the container is then appended to the `body` of the webpage.

### 6. **Adding Styles**
- The script dynamically creates a `