feat: add carpet

This commit is contained in:
2026-07-03 21:56:34 +03:30
parent 5160deb973
commit 7acd72c286
21 changed files with 536 additions and 156 deletions
@@ -69,14 +69,18 @@ class HokmGame extends FlameGame {
double _hbAccum = 0; // انباشتِ زمان برای تکرارِ منظمِ ضربان تا پایانِ نوبت
bool _wasMyTurn = false;
HokmGame(this.cubit, {this.skin = 'simple'});
/// فرشِ انتخابی؛ 'classic' یعنی سطحِ میزِ ترسیمی. فرشِ تصویری به‌عنوانِ سطحِ
/// میز (بریده در شکلِ میز) روی زمینِ لاجوردی کشیده می‌شود.
final String carpet;
HokmGame(this.cubit, {this.skin = 'simple', this.carpet = 'classic'});
@override
Color backgroundColor() => AppColors.lapisNight;
@override
Future<void> onLoad() async {
add(Felt());
add(Felt(carpet: carpet));
_sub = cubit.stream.listen((ui) {
if (ui.state == null) return;
final s = ui.state!;