An argument of type 'import("c:/Users/User/AppData/Local/Packages/Microsoft.MinecraftUWP_8wekyb3d8bbwe/LocalState/games/com.mojang/development_behavior_packs/!\uBB34\uAE30\uAC15\uD654/node_modules/@minecraft/server/index").Player' cannot be assigned to a parameter of type 'import("c:/Users/User/AppData/Local/Packages/Microsoft.MinecraftUWP_8wekyb3d8bbwe/LocalState/games/com.mojang/development_behavior_packs/!\uBB34\uAE30\uAC15\uD654/node_modules/@minecraft/server-ui/node_modules/@minecraft/server/index").Player'. The type of 'camera.setCamera' is incompatible between these types. The type '(cameraPreset: string, setOptions?: CameraDefaultOptions | CameraFixedBoomOptions | CameraSetFacingOptions |
...
#The player classes from @minecraft/server and @minecraft/server-ui isn't the same
1 messages · Page 1 of 1 (latest)
try deleting @minecraft/server from the @minecraft/server-ui's directory (in node modules)
Add this to your package.json file
"overrides": {
"@minecraft/server": "$@minecraft/server"
}
And run npm install again. This will tell NPM to use the version of @minecraft/server you have specified in your package.json file for all of your dependencies