Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ A native 3D chess game for Omarchy, built with C++ and Qt Quick 3D. Play against

The sets have individually sculpted pieces: swept metal panels, orbital rings and a crescent queen; carved wood and ivory horses; woodland foxes, owls, acorn sprites and antlered royalty; and glossy candy pieces with curled manes and gold crowns.

Pieces glide into place, knights hop, captures shrink away, and check gets a brief pulse. Reduced motion is available in Settings. The interface follows Omarchy's theme and language; the board's materials follow the selected set.
Every set moves in its own manner. Orbital craft hover over their squares with pulsing lights, bank into a glide and scan when chosen. Midnight Atelier's pieces are handled under flickering candlelight: tilted in unseen fingers, set down with a rock, and tipped over when taken. Moss & Myth's creatures breathe and stir, turn to watch a neighbour being picked, and leap. Candy Kingdom's sweets wobble like jelly and pop. Knights jump highest everywhere, and check gets a brief pulse. Reduced motion is available in Settings. The interface follows Omarchy's theme and language; the board's materials follow the selected set.

## Play

Expand Down
19 changes: 17 additions & 2 deletions src/BoardView.qml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,16 @@ Item {
property var frames: ["#28343f", "#432b22", "#5b4934", "#f0dccb"]
property var accents: ["#dcad62", "#cba265", "#9baa6b", "#dca6ab"]
property bool sceneReady: false
// The board keeps time for its figures, which hover, breathe, stir and watch one another while the window has the player's attention.
property bool lively: motion
// Midnight Atelier is lit by a flame, which is never quite steady.
property real flicker: lively && design === 1 ? .04 * Math.sin(clock * 7.3) * Math.sin(clock * 2.1) + .018 * Math.sin(clock * 13.7) : 0
property real clock: 0
FrameAnimation { running: board.lively; onTriggered: board.clock += frameTime }
Timer {
interval: 1700; repeat: true; running: board.lively
onTriggered: if (Math.random() < .75) figures.objectAt(Math.floor(Math.random() * 32)).fidget()
}
Component.onCompleted: Qt.callLater(function() { sceneReady = true })
clip: true
focus: true
Expand Down Expand Up @@ -107,7 +117,7 @@ Item {
DirectionalLight {
eulerRotation: Qt.vector3d(-45,-35,0)
color: "#ffebd2"
brightness: 1.05
brightness: 1.05 * (1 + board.flicker)
castsShadow: true
shadowMapQuality: Light.ShadowMapQualityHigh
shadowFactor: 80
Expand Down Expand Up @@ -159,12 +169,15 @@ Item {
source: "#Cylinder"
visible: parent.target
y: 56
scale: Qt.vector3d(.23,1.1,.23)
// Markers swell and settle so the way forward is never static.
property real swell: board.lively && visible ? .23 * (1 + .09 * Math.sin(board.clock * 3.1 + tile.index)) : .23
scale: Qt.vector3d(swell,1.1,swell)
materials: PrincipledMaterial { baseColor: board.accents[board.design]; opacity: .8; lighting: PrincipledMaterial.NoLighting }
}
}
}
Repeater3D {
id: figures
model: 32
ChessPiece {
required property int index
Expand All @@ -173,6 +186,8 @@ Item {
design: board.design
seat: board.seat
motion: board.motion
clock: board.clock
attention: backend.selected
selected: backend.selected === record.square && record.alive
}
}
Expand Down
Loading
Loading