Troy Lu

Projects

chuuni keys

Rhythm Game Level Maker + Online Platform

A rhythm game where you tap your keyboard to the beat.

It comes with a built in editor to make your own levels (charts), which can be published to the chart listing.

The chart listing is a place to browse, share, and download charts made by other players.

My understanding of React deepened so much after struggling with complex UI like the level editor. I didn’t realize there were so many different ways a stale state bug can happen…

For the online platform, I went for a simple Flask + SQLite setup. It was fun messing around with Docker to self-host on my spare laptop.

nearsay

Geolocation-Based Message Board + Chat

Place notes on a map of the world for others to find - you can only place notes near your current location!

Notes disappear after a week, but can live longer via likes, dislikes, and views.

nearsay map showcase post screenshot nearsay user placing note

I decided on MongoDB partly for its easy to use geospatial queries, but also because I was curious about the biggest non-SQL DBMS.

I was worried that the free-flowing nature of MongoDB would clash with the strictness of Rust, but luckily using the MongoDB Rust driver was very straightforward.

Since server requests happen very rapidly as users pan around the map, I implemented caching via Redis for repeated queries near the same geographic area. I was shocked when the app’s performance dropped heavily, until I discovered Redis’s pipelining feature.

CircuitCat

Logic Circuit Simulation + Learning App

An educational tool for building and simulating logic circuits, complete with lessons to teach users how each logic gate works and a charming cat mascot.

This app was built with a team of 4 at the University of Utah, using C++ and Qt.

circuit simulator showcase

While writing the code for the circuit simulation, I discovered that wire segments can be thought of as logic gates whose sole output (at one end of the wire) mirrors its sole input (at the other end).

This realization allowed me to elegantly use a single graph traversal algorithm to update the states of all logic gates without needing to write too much additional code for dealing with wires and logic gates separately.

These little moments of discovery and problem solving are what makes up the joy of programming.

troylu.com

My website. You’re here right now!

For the sake of adventure, I decided to try writing this website in Svelte. My previous two projects used React, which is familiar but boring.

I ended up liking Svelte more than I expected. Svelte runes feel much simpler than React hooks.

React