Header Image

Health Intervention Minigame Framework (HIMF)

A framework for integrating health activities into entertainment-based mobile games

HIMF Overview

The Health Intervention Minigame Framework (HIMF) is a framework for game engines that establishes a bidirectional communication layer between games and digital health intervention applications. By enabling data exchange between the two, HIMF allows real-world health behaviors to influence gameplay mechanics, embedding health activities directly into the game loop. This integration incentivizes players to engage in healthy behaviors as part of the entertainment experience.

Key Features

Key Contributions

Research Context

Motivation

Sustaining engagement is one of the main challenges in digital health interventions. While these interventions promote positive behavior change, they often lack the engagement mechanisms that make entertainment games so successful. HIMF was developed to connect these two worlds, allowing entertainment games to act as engagement engines for digital health interventions. By integrating health activities into gameplay, the framework makes health-promoting actions rewarding and seamlessly part of play.

Theoretical Underpinning

The HIMF framework is grounded in established theories of behavior change that explain how intrinsic motivation can be leveraged to promote sustained engagement in health behaviors. The Self-Determination Theory (SDT) forms the motivational foundation, emphasizing that individuals are more likely to engage in and maintain behaviors when their needs for autonomy, competence, and relatedness are supported. The COM-B model complements this by describing behavior as a function of capability, opportunity, and motivation. HIMF operationalizes these principles by embedding health activities into entertainment games that are already intrinsically engaging, thus enhancing opportunity and maintaining motivation through enjoyable, autonomy-supportive experiences.

Technical Description

System Overview

The HIMF architecture enables seamless bidirectional communication between a digital health intervention platform and an online entertainment game. As shown in the diagram below, the system consists of three main components: the health intervention application platform, the online game build, and the game files. Together, these components form a communication pipeline that allows real-world health data to influence gameplay and, conversely, gameplay data to update the health intervention platform.

This modular design minimizes integration complexity and allows existing games to be retrofitted with HIMF functionality with minimal code changes. By using standardized interfaces between layers, the framework ensures that both health and entertainment systems can evolve independently while maintaining interoperability.

HIMF System Overview

Core Technologies and Frameworks

HIMF is implemented as a Unity3D plugin and operates within WebGL builds to allow seamless web-based deployment. The communication layer relies on JavaScript interoperability (JSPlugin) to enable secure data exchange between Unity and external APIs. In the current prototype, HIMF connects to the GameBus digital health intervention platform to support health data exchange and adaptive gameplay. The architecture is designed to be extensible, enabling future compatibility with additional engines and backends through standardized APIs and modular data structures.

Demonstration Scenario: Integrating Health Activities into the Confusing Arrows Game

In the Confusing Arrows game, players begin with a limited number of hearts that determine how many attempts they can make before the session ends. Each unsuccessful round reduces the number of available hearts, creating natural gameplay pauses that structure the experience. When all hearts are lost, the player is presented with two options: wait for a cooldown period before continuing or restore hearts immediately by performing real-world health activities linked to the intervention platform. This setup transforms the traditional “lives” mechanic into a meaningful engagement loop that connects playtime with health-promoting behavior.

Players can choose from a set of short, achievable activities to regain hearts, such as walking a certain distance, stretching, or completing a mindfulness exercise. Once an activity is completed, the game automatically restores hearts, allowing the player to continue without interruption. This direct feedback reinforces the idea that healthy behaviors are part of the game experience rather than external requirements. The sense of progression remains consistent: players stay engaged with the game world while simultaneously contributing to their own well-being.

Minigame

For developers, the Confusing Arrows scenario illustrates how gameplay variables can respond dynamically to health-related data. The number of hearts, available currency, or even the difficulty of certain levels can be adjusted based on user behavior received from the connected intervention system. This flexibility allows designers to align traditional engagement mechanics, such as rewards or pacing, with health-related progress, maintaining balance between challenge and motivation. In Confusing Arrows, this approach enables a design where health activities directly influence not only the player’s ability to continue but also the variety of content they encounter.

How to Use

HIMF is open source and can be adapted to different entertainment and health applications. Developers can integrate HIMF into their Unity projects using the provided unity example of implementations:

Related Publications