Rubik's Cube and Rubik's Revenge include file

This include file defines two macros which can be used to create a Rubik's Cube (3x3x3) and a Rubik's Revenge (4x4x4):


The parameter is a string containing rotations (an empty string is ok).

Uses actual measures of the real Rubik's cubes:

Rotation syntax:


WRC_RubiksCube("F2 D L2 D R U R L' B' D U' B' R' F2 R' U2")
WRC_RubiksRevenge("U L' F f L2 F2 D")

The last rotation can be made incomplete by declaring the following float identifier before calling the macros:


The value should be a factor between 0 and 1, where 0 means that the last rotation is not made at all, and 1 means that it's done as normal. Values between 0 and 1 will rotate it by that relative amount. (Note that in the parameter string there must not be any whitespace after the last rotation for this to work.)