Update ThreeBSP.ts

Converted to TypeScript.