<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Modest Ticu</title>
    <description>The latest articles on DEV Community by Modest Ticu (@modestus).</description>
    <link>https://dev.to/modestus</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3840807%2Fed6322aa-6784-4488-b0b7-ad7a11a22f0e.png</url>
      <title>DEV Community: Modest Ticu</title>
      <link>https://dev.to/modestus</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/modestus"/>
    <language>en</language>
    <item>
      <title>I finished 6 JavaScript games… and decided to sell them (with full source code)</title>
      <dc:creator>Modest Ticu</dc:creator>
      <pubDate>Mon, 23 Mar 2026 22:43:44 +0000</pubDate>
      <link>https://dev.to/modestus/i-finished-6-javascript-games-and-decided-to-sell-them-with-full-source-code-3dkm</link>
      <guid>https://dev.to/modestus/i-finished-6-javascript-games-and-decided-to-sell-them-with-full-source-code-3dkm</guid>
      <description>&lt;p&gt;For a long time I had multiple small game projects sitting around at like 70–80% done.&lt;/p&gt;

&lt;p&gt;You probably know this situation where the core idea works, gameplay is there, but polish, fixes, and "final push" never happens ...&lt;br&gt;
And since I have some times on my hands I said ok… let`s finish them and if I still finish them anyway… why not also sell the source code?&lt;br&gt;
So that’s what I did.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why no frameworks?
&lt;/h2&gt;

&lt;p&gt;One important rule I gave myself from the start: Everything must be written in &lt;u&gt;pure Vanilla JS&lt;/u&gt;. No frameworks.&lt;/p&gt;

&lt;p&gt;Yes, I know — using a framework would make some things easier: asset loading or state management or rendering helpers.&lt;br&gt;
But the goal here was different.&lt;br&gt;
I wanted to prove (mostly to myself) that you can build full games in the browser with your own mini-engine, no dependencies.&lt;br&gt;
The only APIs I used: Web Audio API (for sound) and TSS (only in one game)&lt;br&gt;
That’s it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Challenges I ran into:
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. Mobile performance (particles are evil and annoying but a must :) )
&lt;/h3&gt;

&lt;p&gt;One of the biggest problems I ran into was too many particles on screen = mobile devices struggle.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;explosions&lt;/li&gt;
&lt;li&gt;effects&lt;/li&gt;
&lt;li&gt;bullet impacts&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Solutions I used:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;pre-render particles to offscreen canvas where possible&lt;/li&gt;
&lt;li&gt;reduce opacity / brightness on mobile&lt;/li&gt;
&lt;li&gt;limit particle pools (no dynamic allocation)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;In one game I even used a fixed 600-particle pool to avoid garbage collection during gameplay.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Assets and CORS issues
&lt;/h3&gt;

&lt;p&gt;Another annoying problem was loading assets locally which caused CORS issues. So I went for a different approach: convert everything to base64 and bundle it directly into the game.&lt;br&gt;
Therefor, I built myself a small tool that:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;takes files (images/audio)&lt;/li&gt;
&lt;li&gt;converts them to base64&lt;/li&gt;
&lt;li&gt;generates an asset.js file
Then the game just imports that file and everything works offline, no requests.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  3. No design focus (placeholders everywhere)
&lt;/h3&gt;

&lt;p&gt;I’m not a designer.&lt;br&gt;
So instead of wasting time trying to make things "pretty", I used placeholders where possible so I can focuse on gameplay and systems.&lt;/p&gt;

&lt;p&gt;Some games even use:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;emojis as characters&lt;/li&gt;
&lt;li&gt;simple shapes&lt;/li&gt;
&lt;li&gt;procedural visuals&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;And honestly… it works fine.&lt;/p&gt;

&lt;h3&gt;
  
  
  4. Procedural audio (yes, really)
&lt;/h3&gt;

&lt;p&gt;Instead of always using music files, I experimented with generating sound using the Web Audio API&lt;/p&gt;

&lt;p&gt;For example:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;shooting sounds&lt;/li&gt;
&lt;li&gt;footsteps&lt;/li&gt;
&lt;li&gt;background noise (even music kind off...)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Of course an MP3 is easier and usually sounds better, but this was more about experimenting.&lt;/p&gt;

&lt;h3&gt;
  
  
  5. Commenting the code (harder than coding)
&lt;/h3&gt;

&lt;p&gt;This was surprisingly one of the hardest parts.&lt;br&gt;
Writing code for yourself is easy. Explaining it to someone else is not.&lt;br&gt;
Especially if that someone is a beginner. So I tried to comment all important systems, explain "why" not just "what" - Still not perfect, but definitely better than nothing.&lt;/p&gt;

&lt;h2&gt;
  
  
  What you can find
&lt;/h2&gt;

&lt;p&gt;Here are a few things (you can find in the bundle) that might be useful if you're into game dev (learning how to or just use it elsewhere):&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpe82ow6u7ohu8aza1s9g.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpe82ow6u7ohu8aza1s9g.jpg" alt="amoeba survival" width="501" height="225"&gt;&lt;/a&gt;&lt;br&gt;
&lt;strong&gt;Amoeba Survival&lt;/strong&gt;&lt;br&gt;
Infinite procedural map using chunk system&lt;br&gt;
Only visible area is loaded → keeps memory low&lt;br&gt;
Hero evolves through 8 different shapes&lt;br&gt;
Everything is auto-fire → gameplay is about positioning&lt;br&gt;
Also:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;enemies scale with score&lt;/li&gt;
&lt;li&gt;up to 200 enemies at the same time&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7axv04wctyomm59ccz33.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7axv04wctyomm59ccz33.jpg" alt="emoji blaster" width="501" height="225"&gt;&lt;/a&gt;&lt;br&gt;
&lt;strong&gt;Emoji Blaster&lt;/strong&gt;&lt;br&gt;
This one is probably the weirdest :))&lt;/p&gt;

&lt;p&gt;Entire game is one JS file (~2000 lines)&lt;br&gt;
Uses emojis as main graphics&lt;br&gt;
One-button control system (tap &amp;amp; hold)&lt;/p&gt;

&lt;p&gt;Interesting parts:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;procedural dungeon (rooms generated on the fly)&lt;/li&gt;
&lt;li&gt;only current room exists in memory&lt;/li&gt;
&lt;li&gt;explosion physics that push objects instead of damaging&lt;/li&gt;
&lt;li&gt;TTS voice lines on boss kills&lt;/li&gt;
&lt;li&gt;32 achievements&lt;/li&gt;
&lt;li&gt;full run + stats saved in localStorage&lt;/li&gt;
&lt;/ul&gt;




&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fw4kqq4yulet1f36kprnc.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fw4kqq4yulet1f36kprnc.jpg" alt="void invaders" width="501" height="225"&gt;&lt;/a&gt;&lt;br&gt;
&lt;strong&gt;Void Invaders&lt;/strong&gt;&lt;br&gt;
Classic vertical shooter, but everything in a single JS file, 9:16 canvas → mobile friendly and ships with different stats (HP, damage, inertia)&lt;/p&gt;

&lt;p&gt;Technical stuff:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;pre-rendered enemies and ships (offscreen canvas)&lt;/li&gt;
&lt;li&gt;parallax background&lt;/li&gt;
&lt;li&gt;procedural fallback music if audio files missing&lt;/li&gt;
&lt;li&gt;save system (continue run)&lt;/li&gt;
&lt;li&gt;scaling difficulty based on wave&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Demos
&lt;/h2&gt;

&lt;p&gt;For demos of each game please check the urls on the bundle page:&lt;br&gt;
&lt;a href="https://payhip.com/b/vxgFd" rel="noopener noreferrer"&gt;PayHip&lt;/a&gt; or &lt;a href="https://vmtbits.itch.io/vanilla-js-game-pack-2026" rel="noopener noreferrer"&gt;Itch&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Final decision: no license&lt;/strong&gt; - This was another conscious choice.&lt;/p&gt;

&lt;p&gt;That means:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;you can modify the code&lt;/li&gt;
&lt;li&gt;reuse systems&lt;/li&gt;
&lt;li&gt;sell your own versions&lt;/li&gt;
&lt;li&gt;do whatever you want
Once you buy it: it’s fully yours&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I want to share this information not just to sell the bundle, but also to show that:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;you don’t need big engines&lt;/li&gt;
&lt;li&gt;you don’t need frameworks&lt;/li&gt;
&lt;li&gt;you don’t need perfect design&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You just need: consistency + finishing what you start!&lt;br&gt;
(Because honestly, the hardest part wasn’t coding, was finishing the projects...)&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>gamedev</category>
      <category>web</category>
      <category>programming</category>
    </item>
  </channel>
</rss>
