javascript(ultra32): added rotate
Signed-off-by: prescientmoon <git@moonythm.dev>
This commit is contained in:
parent
edd15321fa
commit
2ecbd6d4b4
64
javascript/ultra32/.gitignore
vendored
64
javascript/ultra32/.gitignore
vendored
|
@ -1,61 +1,3 @@
|
||||||
# Logs
|
node_modules
|
||||||
logs
|
app.ts
|
||||||
*.log
|
tsconfig.json
|
||||||
npm-debug.log*
|
|
||||||
yarn-debug.log*
|
|
||||||
yarn-error.log*
|
|
||||||
|
|
||||||
# Runtime data
|
|
||||||
pids
|
|
||||||
*.pid
|
|
||||||
*.seed
|
|
||||||
*.pid.lock
|
|
||||||
|
|
||||||
# Directory for instrumented libs generated by jscoverage/JSCover
|
|
||||||
lib-cov
|
|
||||||
|
|
||||||
# Coverage directory used by tools like istanbul
|
|
||||||
coverage
|
|
||||||
|
|
||||||
# nyc test coverage
|
|
||||||
.nyc_output
|
|
||||||
|
|
||||||
# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
|
|
||||||
.grunt
|
|
||||||
|
|
||||||
# Bower dependency directory (https://bower.io/)
|
|
||||||
bower_components
|
|
||||||
|
|
||||||
# node-waf configuration
|
|
||||||
.lock-wscript
|
|
||||||
|
|
||||||
# Compiled binary addons (https://nodejs.org/api/addons.html)
|
|
||||||
build/Release
|
|
||||||
|
|
||||||
# Dependency directories
|
|
||||||
node_modules/
|
|
||||||
jspm_packages/
|
|
||||||
|
|
||||||
# TypeScript v1 declaration files
|
|
||||||
typings/
|
|
||||||
|
|
||||||
# Optional npm cache directory
|
|
||||||
.npm
|
|
||||||
|
|
||||||
# Optional eslint cache
|
|
||||||
.eslintcache
|
|
||||||
|
|
||||||
# Optional REPL history
|
|
||||||
.node_repl_history
|
|
||||||
|
|
||||||
# Output of 'npm pack'
|
|
||||||
*.tgz
|
|
||||||
|
|
||||||
# Yarn Integrity file
|
|
||||||
.yarn-integrity
|
|
||||||
|
|
||||||
# dotenv environment variables file
|
|
||||||
.env
|
|
||||||
|
|
||||||
# next.js build output
|
|
||||||
.next
|
|
||||||
|
|
|
@ -35,3 +35,10 @@ function mirror(vector) {
|
||||||
return vector;
|
return vector;
|
||||||
}
|
}
|
||||||
exports.mirror = mirror;
|
exports.mirror = mirror;
|
||||||
|
function rotate(vector) {
|
||||||
|
const oldx = vector[0];
|
||||||
|
vector[0] = Math.cos(vector[0]) - Math.sin(vector[1]);
|
||||||
|
vector[1] = Math.sin(oldx) + Math.cos(vector[1]);
|
||||||
|
return vector;
|
||||||
|
}
|
||||||
|
exports.rotate = rotate;
|
||||||
|
|
Loading…
Reference in a new issue