#weird issue
1 messages · Page 1 of 1 (latest)
Because location 0 0 0 is not loaded
But it can't be 0,0,0
let first = currentLoc[0];
let second = currentLoc[1];
let third = currentLoc[2];
let rotation = 0 //yaw
let degree = 180 - rotation + 180 - Math.atan2(second/-third);
let xvalue = Math.cos(degree) * Math.sqrt((second * second) + (third * third));
let yvalue = Math.sin(degree) * Math.sqrt((second * second) + (third * third));
let FinalVec = Vector.add(parseVector({
x: first, y: yvalue, z: xvalue
}, entity.getViewDirection()), entity.location);```
It does have an pass vector function too, it did work when I just used the not rotated offset
But since I tried to rotate the offset it doesn't work anymore even though it shouldn't change anything
With rotation being 0 the offset values should all stay the same and it should still work
Where's line 264?
Is where the entity spawns
Show the code
Program Output
(node:22) Warning: To load an ES module, set "type": "module" in the package.json or use the .mjs extension.
(Use ​`node --trace-warnings ...​` to show where the warning was created)
/home/jail/prog.js:1
import {
^^^^^^
SyntaxError: Cannot use impor
ID#9576 | javascript | nodejs-16.14.0 | wandbox.org
@violet field this includes all
Seems looking fine, idk why it's got error
😫
Whyyy
What to do now
@violet field
What does NaN mean again?
Not a number
Probably you didn't turn string into number
Damn, how do I do that again?