Skip to content

Repository files navigation

La Caja de Marcos (Marcos' Box)

An educational and therapeutic Android game designed specifically for children with autism. This project focuses on providing a calm, failure-free learning environment through intuitive drag-and-drop mechanics.

Project Intent

The primary goal of La Caja de Marcos is to help children with autism develop cognitive and fine motor skills by identifying and categorizing everyday elements like letters, numbers, shapes, colors, and animals.

Key Design Principles

  • No Failure States: There are no "wrong" answers that lead to negative feedback. If an item is dropped in the wrong place, it simply springs back to its original position.
  • Calm Visuals: Uses a soft, pastel color palette to avoid sensory overload.
  • Progressive Difficulty: Levels start with 3 items and gradually increase up to 8 based on successful completion.
  • Responsive Design: Optimized for both tablets and phones, with layouts that adapt to portrait and landscape orientations.
  • Sensory Safety First: No sounds by design. Optional haptic feedback on correct drops, disabled by default and hidden on devices without a vibration motor.
  • Parental Control: Settings include feature toggles (letters, numbers, haptic) with plain-language explanations.

Features

  • Multiple Categories: Letters, Numbers, Shapes, Colors, and Animals.
  • Interactive Drag & Drop: Intuitive mechanics with smooth animations and density-independent drop detection.
  • Parental Gate: Settings access is protected by a 5-second long-press mechanism to prevent accidental configuration changes.
  • Multi-language Support: Fully localized in Spanish (default), English, Catalan, Basque, and Galician.
  • Skippable Splash: Splash screen shows progress and can be tapped to skip.
  • Accessibility: All emoji buttons and category cards have localized content descriptions for screen readers.

Tech Stack

  • Language: Kotlin
  • UI Framework: Jetpack Compose (Declarative UI)
  • Architecture: MVVM (ViewModel + StateFlow)
  • Build System: Gradle (Kotlin DSL)
  • Minimum SDK: 24 (Android 7.0)
  • Target SDK: 36 (Android 16)

Getting Started

Prerequisites

  • Android Studio Ladybug (or newer)
  • JDK 17
  • Android SDK 36

Local Build Instructions

  1. Clone the repository:

    git clone <repository-url>
    cd marcos-box
  2. Build the project: Use the Gradle wrapper to build the debug APK:

    ./gradlew assembleDebug
  3. Run Tests:

    • Unit Tests: ./gradlew test (JVM + Robolectric, no device needed)
    • Instrumented Tests: ./gradlew connectedAndroidTest (requires a connected device or emulator)
  4. Code Quality: Run lint and Compose-specific checks:

    ./gradlew lint

Project Structure

  • app/src/main/java/com/lacajademarcos/ui/: Contains the UI screens (Home, Game, Celebration, Settings).
  • app/src/main/java/com/lacajademarcos/game/: Core game logic, state management, and level progression.
  • app/src/main/java/com/lacajademarcos/data/: Static data pools (ItemSets) for each category.
  • app/src/main/java/com/lacajademarcos/components/: Reusable Compose components like DraggableItem, DropTarget, and GameDrawer.
  • app/src/main/res/: Android resources including strings (5 locales), colors, and drawables.
  • app/src/test/: Unit tests (GameViewModel, LevelManager, GameState, ItemSets).
  • app/src/androidTest/: Instrumented UI tests (HomeScreen, GameScreen, SettingsScreen, MainActivity).

Contributing

If you wish to add a new language, please check TRANSLATIONS.md for instructions.

Every new business-logic function must include a unit test before merge. The full test suite must pass before any PR is accepted.

License

This project is licensed under the MIT License - see the LICENSE.md file for details.

About

Android game for children with Autism Spectrum Disorder (ASD)

Resources

Stars

Watchers

Forks

Releases

Packages

Used by

Contributors

Languages