11000+款5星资源

8.5万+用户参与评分

10万+社区成员鼎力支持

每款资源都经过 Unity 审核

首页
模板
此内容由第三方提供商托管,该第三方提供商在未接受Targeting Cookies的情况下不允许观看视频。如果您想观看来自这些提供商的视频,请将“Targeting Cookie”的Cookie偏好设置为“是”。
1/16
loading
loading
loading
loading
loading
loading
This package contains all assets and code required to create an interactive Rubik Cube of varying sizes.

WebGL demo

This package has two main goals:
• Providing you with a starting point to build your own interactive Rubik cube application
• Act as a learning project for those interested in the 3D math behind implementing such a cube

The package provides an optimized implementation that allows for cubes of arbitrary sizes without the use of extensive ray casting (the provided sample scene demonstrates cube sizes 2 to 9, but you can go higher if you wish). In addition the package is divided in clear classes that can be reused as is, or adapted to your needs as you see fit.

Contents
• Clear, cohesive and extensively documented classes (note that reading the comments and understanding the source code does require a fundamental understanding of vectors, matrices, dots, crossproducts and left & right handed coordinate systems).
• A UV-ed cublet mesh with realistic albedo, normal and smoothness textures (.psd included)
• A cublet.blend file with high and low poly cublet meshes included
• A sample scene demonstrating all the features

Most important classes and features
• RubikCube class: contains core cube definition, rotation and undo features and the ability to check if the cube is solved or not
• DiscRotator: transforms your mouse actions into disc rotation actions on the RubikCube
• CubeRotator: transforms your mouse actions into 90 degree rotations on the cube as a whole
• CameraMouseOrbit: transforms your mouse actions into free orbit camera movements
• AxisDisplay: shows the orientation of your cube on the top right of your screen as a gizmo
• RubikCubeInitializer: shows you how to spawn a cube of a specific size and handle its lifetime

Package limitations:
• This package doesn't come with a cube solving algorithm
• All the rubik cubes are built up dynamically using the same prefab for every cublet, in other words there is no distinction between corner, edge and center pieces.
• There is no side introspection mechanism included, in other words, the cube can tell you whether it is solved or not, but you can't say "Give me the color of cublet R(2,2)" for example.
• The current controls are mouse based but located centrally and easily changed.

WebGL demo

Interactive Rubik Cube (x * x * x)

(暂无评分)
60 users have favourite this asset
(60)
$7.99
增值税将在结算时计算
许可证类型:Single Entity
一个实体
适用于个人或小型企业。
多个实体
适用于大型企业或多用户。
退款政策
该资源受Unity资源商店退款政策约束。有关详细信息,请参见《最终用户许可协议》(EULA)中的第2.9.3节。
安全结账方式:
Supported payment methods: Visa, Mastercard, Maestro, Paypal, Amex
许可证类型
文件大小
1.5 MB
最新版本
1.0
最新发布日期
2020年10月13日
原始 Unity 版本
2018.4.26
高品质资源
11000+款5星资源
深受用户信赖
8.5万+用户参与评分
强大的社区支持
10万+社区成员鼎力支持
Unity logo
语言
反馈
合作伙伴计划
合作伙伴
USD
EUR
Copyright © 2025 Unity Technologies
所有价格不包含税
USD
EUR
$7.99