// CODE & GAMES

Code & Games

Small programs and games I build to learn — and because they're fun to share. Play them right here in the browser; the source is on GitHub.

STACK // PythonJavaScriptPyScriptHTML5 CanvasGit

3D Flight Simulator

A high-fidelity 3D flight simulator featuring realistic aerodynamics, volumetric clouds, and procedural generation.

P-51 Mustang Dogfight

Authentic P-51 model (Yellow Nose / Silver Body). Infinite procedural terrain. Press SPACE to fire machine guns at enemy drones.

FLIGHT CONTROLS

W / S: Pitch Down / Up
A / D: Roll Left / Right
SHIFT / CTRL: Throttle Up / Down
SPACE: Fire Machine Guns
C / F: Camera / Fullscreen

Astro Shooter

A top-down 2D space shooter game. Control your spaceship, dodge incoming asteroids, and blast them with lasers to score points!

Score: 0 | Lives: 3
Press START to Play

Classic Snake

The classic grid-based arcade game built with HTML5 Canvas and JavaScript. Features score tracking, WASD/arrow controls, and increasing speed.

Score: 0
Press START to Play

Tower Defense

A strategic game where you place defensive turrets to defend your base against waves of incoming robot enemies.

Gold: 100 | Base Health: 10
Press START to Play
Click on the grid to build Turrets (Cost: 50 Gold). They will auto-fire at enemies!

Unit Converter (Python)

A lightweight python script running in-browser via PyScript. Converts between metric and imperial units (temperature, distance, and weight).

// READOUT: Unit Converter (Python)
SOURCE CODE
def convert_temp(val, to_unit):
    if to_unit.lower() == 'c':
        return (val - 32) * 5/9
    return (val * 9/5) + 32

def convert_dist(val, to_unit):
    if to_unit.lower() == 'm': # meters to feet
        return val * 3.28084
    return val / 3.28084 # feet to meters

print("--- PYTHON CONVERTER ---")
print("Converting 100 Fahrenheit to Celsius:")
print(f"100 F = {convert_temp(100, 'c'):.2f} C")
print("\nConverting 10 Meters to Feet:")
print(f"10 m = {convert_dist(10, 'm'):.2f} ft")
print("\nConverting 32 Feet to Meters:")
print(f"32 ft = {convert_dist(32, 'f'):.2f} m")
CONSOLE OUTPUT
Ready. Click "RUN PROGRAM" above.