Inspiration
We were inspired by Google Deepmind's MaleCNS v1.0 connectome, which is the first complete wiring map of a male fruit fly's brain. It contains more than 166,000 neurons and 125 million connections. Instead of using a static brain diagram, we wanted to build a game allowing players to directly interact with the brain. HackUMBC’s royal theme also inspired us. We imagined a fruit fly prince whose entire nervous system had been mapped. His name became Prince Hamlet. Four players would become his Royal Council, with each person responsible for one part of his movement or perception in an adventurous co-op game. This setup also allowed us a way to approach alcohol education. As underage alcohol consumption gets more prevalent, we decided this was an opportunity to show the effects of substances on a real brain by altering movement and sensing behaviors. His Royal Flyness aims to visually teach the effects of alcohol on the brain while engaging players in the adventurous, chaotic gameplay. The characters also comes from biology. Hamlet, miranda, prospero, tinman, rutabaga, and cheapdate are all names related to real fruit fly genes. Their personalities and roles are fictional, but each character introduction explains the real gene behind the name.
What it does
His Royal Flyness is a cooperative party game where four people share control of Prince Hamlet, a fruit fly trying to reach Princess Miranda. Players join from their phones, and the full game runs on a shared Godot screen. Each player becomes a member of Prince Hamlet’s council and controls his movement:
- The Royal Helmsman controls left and right.
- The Royal Liftmaster controls up and down.
- The Royal Wingmaster controls forward movement and reverse.
- The Royal Seer acts as his senses, and receives private information about approaching attacks and Princess Miranda.
The players have to communicate to move one fly through gardens, hallways, walls, giant encounters, and a boss fight. No single player can do the challenge alone, which leads to chaos as players try to coordinate their moves. Alcohol education is part of the gameplay. The rival characters ask questions about balance, memory, and whether coffee removes alcohol’s effects. A wrong answer adds another level of impairment. Hamlet takes longer to stop, responds later to controls, drifts with a slow sway, and experiences a stronger visual wobble. The game also displays a live diagram of Hamlet’s brain. It highlights areas connected to his eyes, memory, balance, and body. During the questions, it focuses on the regions related to that lesson. The game allows users to understand which parts of the fly brain are impaired by the alcohol and see its effects in real time. The campaign begins in the Royal Garden. The team learns the controls by collecting four grapes and carrying them to the Royal Harvest Chalice. Each grape introduces a different part of movement before the game asks the team to combine everything. Hamlet is then blamed for appearing drunk after a grape-related accident. Duke Prospero refuses to let him enter the banquet until he proves himself. Hamlet travels through castle passages, answers questions from rival suitors, flies through solid wall openings, races a closing gate, and eventually faces a human-sized Giant. The Giant attacks with increasingly difficult volleys. The first attacks use one hand. Later attacks can arrive in groups of two or three. The hand locks its path when the attack begins, so it never follows or cheats toward the fly. Only the Seer receives the direction and timing warning. If the team survives the Giant, Hamlet must still face Prospero’s final test, with flaming fireballs attacking him.
How we built it
We built the shared game screen in Godot 4 using GDScript. The game uses a front-facing 2D perspective. This means that the scale, overlap, parallax, and moving scenery create depth without using a 3D world. The visual style is using pixel art at a base resolution of 640 by 360. The environments include the Royal Garden, Castle Passages, a Banquet Hall, a storm-filled Giant arena, and Prospero’s dungeon for the final encounter. The phone controllers use plain HTML, CSS, and JavaScript. There is no app to install, and each person joins with a QR code. Each role receives a different controller screen with large touch targets. A WebSocket relay manages room codes, player names, role selection, reconnection, and private messages. If a phone sleeps or refreshes, it can reclaim its previous seat. Inputs are also cleared when a button is released, a page is hidden, or a connection disappears. This prevents Hamlet from continuing to fly because of a phone input that's stuck. A Python server controls the full game state. It receives each of the three movement inputs, simulates Hamlet’s motion, checks wall collisions, runs the campaign, controls quizzes, resolves attacks, and decides who wins or loses. We have Godot then render the result and display it on the shared screen. For the Royal Seer, we built a rate-based neural model from the MaleCNS wiring data. The model uses the real connection structure and synapse counts of 166,606 neurons. Each game event stimulates groups of neurons connected to vision, looming threats, and antennal sensing. We then read the activity from neurons related to steering and escape, and warn the Seer about incoming attacks. The brain diagram uses a second copy of the neural model. It only receives Hamlet’s public movement, so it cannot reveal the Seer’s private information. For the alcohol visualization, we apply a clearly disclosed modeling assumption to inhibitory and excitatory output. We show the result as an experiment, not as a measured biological effect. We used ElevenLabs extensively in the game. ElevenLabs creates a character voice dialogue for every campaign scene, with unique characters. We incorporate ElevenLab's sound effects for every character's flying, sensing, and fighting reactions. The game includes 148 voiced lines and a soundtrack that changes between the garden, basement, quizzes, Giant fight, Prospero fight, and endings. We used GitHub to combine the phone app, Python server, neural model, Godot project, and audio.
Challenges we ran into
One of our biggest challenges was dividing one character across four people. Every role needed to matter, but the game still needed to be understandable within a short demo. The movement system could not feel perfectly mechanical, as that would make cooperation too easy. It also could not feel random. That’s why we added acceleration, momentum, drag, and a small amount of overshoot. This makes communication important while still allowing the team to recover from mistakes. Phone networking created another challenge. Mobile browsers sleep, reload, lose pointer events, and briefly disconnect from Wi-Fi. The early versions would leave an input stuck or freeze updates when one phone stopped responding. We added repeated input messages, automatic neutral states, timeouts, seat recovery, and non-blocking network sends. Running the complete brain model in real time was also difficult. One neural step processes the entire nervous system. If it ran inside the main network loop, it could slow the controllers and Godot display. We moved the model to its own thread and used fixed update schedules. This kept the shared screen close to 30 frames per second even when the brain was active. Keeping the Seer’s information private required careful design. The shared screen cannot show an incoming hand, its shadow, its direction, or a warning sound before impact. Other phones cannot receive Seer data either. We added routing rules and tests to prevent information from leaking through the interface. The Giant fight created a similar design problem. An attack must feel threatening without being unfair. Each hand chooses its target at the start of the attack and then follows a straight path. It does not track Hamlet afterward. The Seer receives enough warning to call a direction, while the other players still need to react together. Wall collision and impairment needed extensive tuning. We made walls to stop Hamlet without trapping him. Openings must be large enough for four-player coordination but narrow enough to feel competitive. Impairment must be noticeable without making the controls useless. We also had to be careful with our scientific claims. The connectome wiring and synapse counts are real. The rate model, game inputs, neurotransmitter effects, and alcohol visualization include our assumptions. We created a Royal Decree screen that tells players exactly what comes from data and what comes from us. Finally, we had to make the education fit naturally into the story. We used the rival suitors to ask the questions, where Tinman asks about one aspect, Rutabaga asks about another, and Cheapdate asks another as well. Their questions match the traits of the real genes behind their names.
Accomplishments that we're proud of
We are proud that we were able to make four ordinary phones combine into one controller. This took a lot of technical debugging and problem solving. Players now scan a code, choose a role, and then immediately become part of one character. We are also very proud of the Royal Seer. The Seer does not directly use the game's motion to alert for attacks. Instead, its signals come from activity moving through the fly’s neural network wiring. This allows the brain connectome to become part of the gameplay. We also built a complete story around the mechanics, which took a long time to make. The campaign now includes a cast introduction, a four-part tutorial, three educational questions, two wall courses, two major encounters, comic-style scenes, voiced dialogue, dynamic music, weather effects, and a final boss fight. The Giant and Percival's challenges are especially hard to complete, as all players have a limited time to react to each of their attacks. We're proud that we were able to make the game at the right level of competitiveness and fun. During the end of the hackathon, we worked on a lot of small details that make the experience reliable and remove friction: Rooms use fresh four-letter codes. Players can reconnect and reclaim their roles. Waiting phones can see seats open in real time. Inputs expire if a controller disappears. Finally, we are proud that the educational idea of alcohol consumption on the brain is visible in play. A wrong answer does not only change a score. It changes how Hamlet moves and how the team must communicate.
What we learned
We learned that every role needs feedback in the game. A player should be able to tell whether the game received their input, even when they cannot see the complete state on their phone. Not only that, but we also came to the insight that browser controllers require more defensive programming than expected. A mobile browser can pause without warning. A finger can leave a button without sending the expected release event. Reliable multiplayer controls require recovery paths for all of those cases. We also learned how much care and time is needed when turning scientific data into a game. A model can be based on real data and still contain assumptions, like a high baseline for detecting movement. Addressing those assumptions made the project work better. Our educational mechanics taught us that facts are easier to remember when they affect an immediate decision. Players can hear that alcohol makes coordination worse, answer the question, and then feel how extra stopping distance changes the next obstacle. Finally, we learned that story can explain complicated technology. The players do not need to understand every neuron before playing. They only need to know that their Seer is reading Hamlet’s nervous system and that the team must trust what the Seer says.
What's next for His Royal Flyness
Our first priority is more playtesting with four physical phones. We want to measure how quickly new players understand their roles, how much their own network delays they experience, and whether the wall openings and warning windows in-game feel fair to them. We also want to tune the impairment system. It currently affect vision, stopping distance, reaction delay, and balance in similar ways, but changes affect each one differently in real life. This would help connect the educational material to real life. The current game is designed for four separate roles. A future version could support two or three players by combining movement responsibilities while keeping the Seer separate. This would make the game easier to demonstrate with smaller groups. We want to add more environments and challenges. A garden course could include moving leaves, fountains, spiderwebs, birds, and flower pollen. New castle sections could use closing doors, swinging banners, candles, servants, and moving dishes. Every obstacle would still need a readable escape path. We plan to improve the live brain display so players can explore it after a round. They could replay important moments, compare sober and impaired movement, and see which neural groups became active during a Princess sighting or Giant attack. For the educational side, we want to add more questions, sources, and short explanations. A classroom mode could let a facilitator choose topics and review what happened after each round. We also want to deploy the relay online. That would let players join through a public link instead of requiring every phone to be on the same local network.
Built With
- ellevenlab
- gdscript
- github
- godot
- malecns
- matplotlib
- numpy
- python
- websockets

Log in or sign up for Devpost to join the conversation.