Rubiks Cube - Play rubiks cube in 3D

Short description

Play rubiks cube in 3D :smiley:

Picture of all the blocks

Docs

Docs for: RubiksCube

Methods

StopAnimation

Stops an in-progress animation. No operation if an animation is not in progress.

AnimateMoveReversed

Animates in reverse (i.e. with opposite twisting direction) only the previous move from the move sequence. When it has completed, the next one is not automatically started.

AnimateMove

Animates only the next move from the move sequence. When it has completed, the next one is not automatically started.

ApplyMove

Instantly applies the next move on the cube, without animation.

ApplyMoveSequenceReversed

Instantly applies the whole move sequence in reverse, on the cube, without animation.

SetMoveSequence

Sets the move sequence. Note you still have to use one of the blocks starting with animate.
Params

sequence | text


AnimateMoveSequenceReversed

Animates all the moves in the currently set move sequence one move at a time, in reverse (i.e. from end to start with opposite twisting direction).

ApplyMoveSequence

Instantly applies the whole move sequence on the cube, without animation.

GenerateRandomMoves

Params

numOfMoves | number

Return type : text


ResetToInitialState

Resets the cube to solved position. Note : this does not include animation.

RefreshWithNewProperties

Refreshes the rubiks cube with new properties set.

AnimateMoveSequence

Animates all the moves in the currently set move sequence one move at a time. When a move has completed, the next one is automatically started.

ApplyMoveReversed

Instantly applies the previous move on reverse, on the cube, without animation.

SetupRubiksCube

Sets up Rubiks cube in a layout with porperties set.
Params

layout | component


Properties

SetDoubleRotationSpeed

Sets the rotation speed of a double rotation. This property allows to customize the speed of face turns separately from quarter turns.

Property Type : write-only
Accepts : number


SetFaceletsBorderColor

Sets border color of the facelets in rubik cube.

Property Type : write-only
Accepts : number


SetBackFacesDistance

Sets back faces distance from the cube. Typically, a value smaller than 2 means they won't be visible.

Property Type : write-only
Accepts : number


SetSingleRotationSpeed

Sets the rotation speed of a single rotation. This porperty allows to customize the speed of quarter turn separately from face turns.

Property Type : write-only
Accepts : number


SetBackgroundColor

Sets background colors of the rubik cube view.

Property Type : write-only
Accepts : number


SetEditable

Sets if rubiks cube can be changed by user or not.

Property Type : write-only
Accepts : boolean


SetCubeColors

Sets the list of colors given.

Property Type : write-only
Accepts : list


Docs for: RubiksCube

Methods

StopAnimation

Stops an in-progress animation. No operation if an animation is not in progress.

AnimateMoveReversed

Animates in reverse (i.e. with opposite twisting direction) only the previous move from the move sequence. When it has completed, the next one is not automatically started.

AnimateMove

Animates only the next move from the move sequence. When it has completed, the next one is not automatically started.

ApplyMove

Instantly applies the next move on the cube, without animation.

ApplyMoveSequenceReversed

Instantly applies the whole move sequence in reverse, on the cube, without animation.

SetMoveSequence

Sets the move sequence. Note you still have to use one of the blocks starting with animate.
Params

sequence | text


AnimateMoveSequenceReversed

Animates all the moves in the currently set move sequence one move at a time, in reverse (i.e. from end to start with opposite twisting direction).

ApplyMoveSequence

Instantly applies the whole move sequence on the cube, without animation.

GenerateRandomMoves

Generates random move sequence according to numOfMoves param to be used in SetMoveSequence.
Params

numOfMoves | number

Return type : text


ResetToInitialState

Resets the cube to solved position. Note : this does not include animation.

RefreshWithNewProperties

Refreshes the rubiks cube with new properties set.

AnimateMoveSequence

Animates all the moves in the currently set move sequence one move at a time. When a move has completed, the next one is automatically started.

ApplyMoveReversed

Instantly applies the previous move on reverse, on the cube, without animation.

SetupRubiksCube

Sets up Rubiks cube in a layout with porperties set.
Params

layout | component


Properties

SetDoubleRotationSpeed

Sets the rotation speed of a double rotation. This property allows to customize the speed of face turns separately from quarter turns.

Property Type : write-only
Accepts : number


SetFaceletsBorderColor

Sets border color of the facelets in rubik cube.

Property Type : write-only
Accepts : number


SetBackFacesDistance

Sets back faces distance from the cube. Typically, a value smaller than 2 means they won't be visible.

Property Type : write-only
Accepts : number


SetSingleRotationSpeed

Sets the rotation speed of a single rotation. This porperty allows to customize the speed of quarter turn separately from face turns.

Property Type : write-only
Accepts : number


SetBackgroundColor

Sets background colors of the rubik cube view.

Property Type : write-only
Accepts : number


SetEditable

Sets if rubiks cube can be changed by user or not.

Property Type : write-only
Accepts : boolean


SetCubeColors

Sets the list of colors given.

Property Type : write-only
Accepts : list


Instructions to use extension

Note if you change any property of extension except editable property then use refresh block
For the set Move Sequence block you can set algorithm using - Rubik's Cube Algorithms

Download link

com.aktech.rubikscube.aix (30.2 KB)

Demo Blocks

Output

Aia -
rubiks.aia (32.9 KB)

Apk -
rubiks.apk (5.1 MB)

Credits

This extension is made on AnimCube library by Catalin Jurjiu.

Made with Rush
Thank you

32 Likes

2 Minute Silence :zipper_mouth_face: for such an Awesome Performance :heart:

:kodular:eep :kodular:oding …!
:wink:

3 Likes

Thanks for your comment @Technical_Zone :smiley:

1 Like

ur most welcome, btw, How did you made it? Did you used some api or webview something? :thinking:

3 Likes

It is made with a lib but honestly i had to change lots of code of the lib to integrate it as a extension and no webview or api it is made with surfaceview class of android :wink:

2 Likes

Mind Blowing @luv.ak.tech
It’s awesome :wink::wink:

2 Likes

Thank you @ilovecoding :smiley:

1 Like

It’s out of imagination :joy:

1 Like

awesome extension :clap: :+1:

3 Likes

add some events like when cube complete or anything like that to record the movement.
Lovely Extension

2 Likes

Amazing extension.

2 Likes

Thank you @Shreya.ig @Balajidev @AJOY_DAS

i will see if i can make any :sweat_smile:

2 Likes

WoW br0.:scream: :scream: :scream: :scream: :scream: :scream:

1 Like

Currently out of likes to like your comment :smiley: thanks for comment

2 Likes

Amazing Extension :slightly_smiling_face:

2 Likes

Thank you @Anu

1 Like

epic work @luv.ak.tech keep it up :+1:

2 Likes

Thanks @Yashsehgal022

2 Likes

New Blocks added to move cube through blocks -
image
and docs are on first post

5 Likes

outstanding work :boom: :boom:

2 Likes