Skip to content

Instantly share code, notes, and snippets.

View csanz's full-sized avatar
🎯
Focusing

Christian Sanz csanz

🎯
Focusing
View GitHub Profile
@csanz
csanz / at-at-tow-cable-gameplay-prd.md
Last active August 9, 2026 00:39
PRD — Harpoon & Tow Cable

PRD — The Harpoon Run, Choreographed

Battle of Hoth Simulator · an AI wingman flies the cable; the player watches it happen

Status: v3 — client decisions applied: purely cinematic (no player kill window), Rogue 3 cannot be downed, callouts arrive as client-provided video transmissions, and the player is Luke Skywalker — interactivity follows the story Baseline: main @ 9c73330. The opening/transmission machinery is in active flux (d4e9305 removed the second Luke transmission; the clip is still hosted) — symbols authoritative, line numbers advisory for main.js. The player-skill Harpoon PRD v5 remains the spec for a separate future game app (client decision). Walker geometry and the collapse carry over from it unchanged.


@csanz
csanz / hoth-mobile-performance-optimization.md
Created August 8, 2026 13:36
Battle of Hoth Mobile + Performance Optimization

Before making any changes, create a new git branch dedicated to mobile support, loading, and performance optimization.

Use ultracode throughout.

Perform a full /loop optimization pass over the Battle of Hoth Three.js/WebGL2 implementation.

The project already has performance instrumentation, quality presets, resolution scaling, touch controls, and a coarse-pointer mobile fallback. Improve and extend what exists rather than replacing it.

Prioritize measurable bottlenecks:

  • Startup/loading time, asset fetching/decoding, shader compilation, GPU warm-up
@csanz
csanz / at-at-tow-cable-gameplay.md
Last active August 9, 2026 00:41
AT-AT Tow Cable Gameplay Mechanic

Use ultracode throughout.

Implement the AT-AT tow-cable cinematic sequence defined in this PRD:

https://gist.github.com/csanz/473e9858b399b3a0bc2a22a186d55403

Read and understand the entire PRD and inspect the existing codebase before making changes. Treat the PRD as the source of truth for the implementation.

This is NOT player-controlled gameplay. It is a cinematic in-world sequence performed by one of the AI wingmen during the battle.

@csanz
csanz / collision-crash-physics-overhaul.md
Created August 8, 2026 13:11
Collision & Crash Physics Overhaul

Before making any changes, create a new git branch dedicated to the collision/crash physics work. Do not modify the current working branch directly.

Use ultracode throughout.

The X feedback is correct: objects like the ship can phase through the walkers.

/loop through the entire scene and add accurate hitboxes and collision physics to every moving or interactive object. Make sure fast-moving objects cannot tunnel or phase through other objects.

Fan out sub-agents across non-overlapping objects/systems.

@csanz
csanz / cursor-rules.md
Created May 2, 2025 22:50
Cursor Rules / General

Codebase Maintenance Rules

General

  • Use appropriate development servers for the project type (e.g., http-server for static sites, webpack-dev-server for JS apps)
  • Choose frameworks and libraries based on project requirements and team expertise
  • Always confirm with the user before starting any servers or services
  • Follow established patterns in the existing codebase
  • Prioritize maintainability and readability over clever solutions
@csanz
csanz / sample-anyproxy-rule-for-son.js
Created April 17, 2020 18:21
Rule I created to block some sites on my son's computer at home.
/*
sample:
redirect all https://www.roblox.com/t requests to http://localhost:3000/
redirect all https://www.roblox.com/t requests to http://localhost:3000/
test:
curl https://www.roblox.com/ --proxy http://192.168.1.84:8001
curl https://www.yahoo.com/ --proxy http://192.168.1.84:8001
expected response:
@csanz
csanz / mac-osx-system-proxy-via-terminal.md
Created April 16, 2020 23:03
Updating Mac OSX System Proxy via Terminal

Updating Mac OSX Proxy via the Terminal

I'm using AnyProxy to block websites on my son's computer. I also use it block safe websites like roblox or youtube, just so he can do his home work... Right now i"m seeting up a proxy with some rules and I go and ssh to turn the proxy on and off... I found this last night at 2am and put it on a gitst, but I'll make it public now.

You simply just use the networksetup command. You can find the params you need to you this way

networksetup -setwebproxy | grep "setproxy"

networksetup -setwebproxy

@csanz
csanz / DeliveryArchitect.md
Last active January 20, 2020 22:40
Delivery Architect

Senior /Lead Delivery Architect

we are looking for a seasoned nodejs and linux engineer/leader who can help us take our web technology to the next level of scale

your focus will be to:

  • Assure things are being built the right way (reusable code, project/library structure, database schema, authentication flow, unit tests, documentation, patterns, etc)
  • Assure best practices are enforced (logging, error messaging, unit testing, etc)
  • Assure releases go out on time (deployment process, QA, documentation, communication across departments)
@csanz
csanz / check_for_changes2.sh
Created May 6, 2019 21:30
Another way to check if the repo was updated.
# picked up from stackoverflow
UPSTREAM=${1:-'@{u}'}
LOCAL=$(git rev-parse @)
REMOTE=$(git rev-parse "$UPSTREAM")
BASE=$(git merge-base @ "$UPSTREAM")
if [ $LOCAL = $REMOTE ]; then
echo "Up-to-date"
elif [ $LOCAL = $BASE ]; then
@csanz
csanz / check_for_changes.sh
Created May 6, 2019 17:42
check if you need to pull new version from branch
#!/bin/sh
git fetch --quiet
CHANGES=(`git rev-list HEAD..origin/production --count`)
echo $CHANGES
# now you can check if the value is higher than 0, if yes, then you can git pull