My Apps

Enigma 抖音计算器

  • Web
  • Live

It Was Supposed to Be a Calculator

By EnigmaViruz · 30 October–18 November 2026

Explore Enigma 抖音计算器

I built Enigma 抖音计算器 as a small subscription web app for Douyin streamers in mainland China. The idea was to give them four tools they could use live without having to do mental arithmetic while pretending everything was under control.

Seventy-four commits later, it had a server, a gift catalogue, private messages, a music player, and a dragon in charge of shared playlists. I still call it a calculator. At this point, the calculator is showing remarkable restraint by letting me.

The features and timeline come from 74 commits and my project notes. The mishaps and dialogue marked Imagined are fictional.

Main menu

The Journey

Songs, ranks, hall counts and messages in the screenshots are demo data, not the live site's real data.

  1. Chapter 1Before V2

    Two HTML files and a very small universe

    V1 ran on one computer. Streamers had Enigma.html, and I had Enigma Admin.html. The four core tools were already there. PK计算器 handled battles, 段位计算器 handled rank calculations, 展馆玩法 tracked gallery gifts, and 礼物推荐目录 let streamers browse about 480 Douyin gifts. The whole thing ran locally. Accounts, a server and cross-device syncing came with V2.

    V1 still exists as my offline fallback, untouched by V2. If I break something ambitious enough, there’s still a version I can open by double-clicking a file. I find that comforting. The server may have other feelings about it.

  2. Chapter 230 October · Launch

    I gave it a server. It gave me an admin job.

    In one day, I rebuilt V1 as a website on a VPS. I chose that setup so streamers in mainland China could access it without my having to host it there or go through the 备案 process. I moved all four tools onto the server and seeded PostgreSQL with V1’s 482 gifts, the gallery board, targets and archive.

    I create each subscriber’s account with a user ID and password. From the admin console I can set an expiry date, disable the account, reset its password or sign it out. Each account can use one computer and one phone at a time. I can see the last login, recent activity, online status, sign-in IP, approximate location and sign-in history. Streamers can see their own last login under 上次登录.

    Gallery counts moved to the server, where each account gets its own tally. Every Monday at midnight Beijing time, the counts reset automatically. The app opens in Chinese by default and can switch to English. I also made the rank entry match Douyin’s display, let streamers or me upload their avatars, and gave the tools new banner artwork featuring a throne, a gallery, a PK scene and a desert.

    Then I gave the app two looks. Classic kept the gold, the intros and the golden scroll menu. Hero used navy and bright blue, followed my phone-first mockups and opened straight into the app. I can set the theme for everyone and preview the other one on my own account. Every tool behaves the same in both themes, and I added a switch to skip the intros on my account. Designing a grand entrance was fun. Watching myself make it for the twentieth time was less rewarding.

    Screenshots · 17

    Login
    PK calculator
    Rank calculator
    Gift hall
    Gift catalogue
    My account
    Admin users
    Sign-in history
    Edit user
    Site theme
    Gift import
    Gift archive
    Login phone
    Main menu phone
    Hall phone
    Rank phone
    PK phone
  3. Chapter 331 October · Streamer features

    The gifts came back from the dead

    I added 新上架 for new gifts and 重生 for gifts that returned. Later came 涨价, 降价 and 改名, plus a 最近调价 filter and a full price history in the admin view.

    I added scheduled notices, a rank tracker that saves daily records, and 使用统计 for tool opens and active users. 消息 gave streamers and me a private place to talk and send attachments. Nightly backups covered the database, gift icons, avatars and chat files. If something vanished overnight, I wanted the option of restoring it before holding a service.

    The app became installable on phones and computers and could keep working offline for up to seven days. Gallery taps queue up and sync once the connection returns. The 展馆点亮清单 became shareable as text or as an image card. 礼物详情 could open from the catalogue, PK suggestions or the gallery board, and 本周概览 moved to the top of the main menu.

    Screenshots · 16

    Notices on the menu
    Gift badges
    Gift detail
    Rank tracker
    Messages
    Install as an app
    Share list
    Weekly overview
    Notices admin
    Usage stats
    Gift price history
    Messages admin
    Act as streamer (button)
    Acting banner
    Admin log
    Messages phone
  4. Chapter 413 November · Song list

    Douyin gave me 50 characters to work with

    After roughly two weeks away, I came back to build 歌单, a private song list for my own use. It’s searchable, works offline and accepts imports from text, CSV and Excel. I organised it into 粤语 / 中文 / 英语 / 闽南 and put all adding, editing and deleting in a separate 歌单管理 page. The browsing view got 全部 / 喜欢 / 新歌 filters, a red heart for favourites and a 新歌 ribbon that lasts seven days.

    The copy button went through three formats. I started with two lines, tried adding a 👇👇👇 lead-in, then settled on 👉 🎵 歌曲:… | 🎤 歌手:… after discovering that Douyin chat strips line breaks.

    Douyin chat also has a 50-character limit. The app now drops emojis and labels one at a time until the line fits. If even the shortest version is too long, 歌单管理 warns me. There’s a particular indignity in spending an evening writing code to decide which emoji gets laid off first.

    Around the same time, my PC got stuck on an older build. That led to the 新版本可用 bar, which tells users when an update is ready on any page they already have open. I had finally found a way to make my computer admit it was living in the past.

    Screenshots · 11

    Song list
    Favourites filter
    New songs filter
    Search all categories
    Copy for Douyin chat
    Manage songs
    Add song (too long warning)
    Import preview
    Update bar
    Song list phone
    Copy phone
  5. Chapter 514–16 November · Family music player

    I built a music player and ended up running a help desk

    音乐 started as a way for selected Streamers to stream songs from my own library. It runs in Hero and is available to accounts I enable. The first version had library pages, playlists, 喜欢, lock-screen controls and playback positions remembered separately for each listener. I could upload songs from the browser, delete or restore them in 音乐库, and use 遥控 to control someone’s player while they listened or build a locked playlist for them.

    14 November — Getting the first song to start

    Real use in China exposed an iPhone play-button issue and slow song starts. I fixed the ▶ button, added per-song speed logging, made smaller audio copies for slower connections and kept the originals available through 高品质. The player also started preparing the next track in advance.

    15 November — MP3, remote control and a dragon

    The smaller files switched to MP3 after I found that iPhones were waiting for the whole .m4a file before playing. I rebuilt 遥控 into three columns based on my mockup. The playlist editor gained covers, a 清空 action and a 保存 button that lets me stage changes before applying them. I could see and edit playlists created by streamers, check each player’s version and use 推送更新 to send it an update.

    The 播放队列 gained 加入播放队列, 存为歌单 and a four-hour session reset. I made row dragging work in Safari and had menus open upward so they could clear the player bar. My playlists gained a rename pencil and 更换封面, along with several fixes for Safari’s cover layout.

    分享歌单 let me send a playlist to a streamer. They get an acceptance popup with my artwork, the shared playlist stays up to date, and it sits inside a dragon frame marked 已分享给 N 人.

    16 November — A manual for the people brave enough to call me

    I wrote a Chinese 音乐 user manual covering desktop and phone. I also added the ⠿ drag handle so listeners could reorder their queue on either device.

    Screenshots · 20

    Music home
    Songs
    Albums
    Album page
    Artists
    Shared playlist page
    Playlists
    Player bar + queue
    Share dialog
    Upload songs
    Music library
    Deleted songs
    Remote control
    Remote playlist editor
    Share invitation popup
    Her playlists (locked + shared)
    Playlists phone
    Mini player phone
    Full-screen player phone
    Queue phone (drag ⠿)
  6. Chapter 616–18 November · New address & lyrics

    The calculator moved out and learned the lyrics

    On 16 November, the app moved to dy.e-nigma.cloud. My first setup also redirected the main e-nigma.cloud address to the calculator. On 17 November, I corrected it so the app lives at dy. and e-nigma.cloud serves as my main site. I made a 新网址通知 image to show streamers where to sign in and how to reinstall the app.

    For about a day, visitors looking for my creative work were sent straight to a calculator. As personal introductions go, “please show your working” is refreshingly hostile.

    On 17 November, I added synced 歌词. The current line lights up and follows the song, and tapping a line jumps to that point. The server looks up lyrics once per song using NetEase or LRCLIB, and I can paste in or correct them myself. I also changed uploaded songs to group by album artist + album after two different songs titled 《獨角戲》 were filed under one album. Apparently the software thought two solo acts would be happier together.

    On 18 November, I added an admin password-reset script in case I forgot my own password. Every account had a recovery plan. Eventually, so did the man who built the recovery plan. I also made song-start reports stick around for 180 days, so I could compare slow days without asking streamers how many cups of tea a track took to load.

    Screenshots · 4

    Lyrics (computer)
    Lyrics editor
    New address notice
    Lyrics phone

V2 went from two local files to an installable app for multiple streamers in two days. In under three weeks it had a private song list for my own use and a music player with remote control, live playlist sharing and synced lyrics. It still does the maths. You have to admire its ability to stay focused through all of this.

Main menu

Main menu1 / 69

Want to try it?

It may open up to members of this site, depending on interest. If you'd like to try it, let me know.

Let me know