gaesup-world 0.6.76 → 0.6.77

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -9,10 +9,10 @@ var __assign = (this && this.__assign) || function () {
9
9
  };
10
10
  return __assign.apply(this, arguments);
11
11
  };
12
- import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
12
+ import { jsx as _jsx } from "react/jsx-runtime";
13
13
  import { useFrame } from "@react-three/fiber";
14
14
  import { quat } from "@react-three/rapier";
15
- import { useMemo, useRef } from "react";
15
+ import { useRef } from "react";
16
16
  import { AirplaneInnerRef } from "../../inner/airplane";
17
17
  export function PassiveAirplane(props) {
18
18
  var rigidBodyRef = useRef(null);
@@ -39,13 +39,10 @@ export function PassiveAirplane(props) {
39
39
  : 0.1, false);
40
40
  }
41
41
  });
42
- var memorized = useMemo(function () {
43
- return (_jsx(AirplaneInnerRef, __assign({ isActive: false, componentType: "airplane", name: "airplane", controllerOptions: props.controllerOptions || {
44
- lerp: {
45
- cameraTurn: 1,
46
- cameraPosition: 1,
47
- },
48
- }, position: props.position.clone(), rotation: props.rotation.clone(), currentAnimation: props.currentAnimation }, props, refs, { children: props.children })));
49
- }, [props.position, props.rotation, props.currentAnimation]);
50
- return _jsx(_Fragment, { children: memorized });
42
+ return (_jsx(AirplaneInnerRef, __assign({ isActive: false, componentType: "airplane", name: "airplane", controllerOptions: props.controllerOptions || {
43
+ lerp: {
44
+ cameraTurn: 1,
45
+ cameraPosition: 1,
46
+ },
47
+ }, position: props.position.clone(), rotation: props.rotation.clone(), currentAnimation: props.currentAnimation }, props, refs, { children: props.children })));
51
48
  }
@@ -9,8 +9,8 @@ var __assign = (this && this.__assign) || function () {
9
9
  };
10
10
  return __assign.apply(this, arguments);
11
11
  };
12
- import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
13
- import { useEffect, useMemo, useRef } from "react";
12
+ import { jsx as _jsx } from "react/jsx-runtime";
13
+ import { useEffect, useRef } from "react";
14
14
  import { CharacterInnerRef } from "../../inner/character";
15
15
  export function PassiveCharacter(props) {
16
16
  var rigidBodyRef = useRef(null);
@@ -28,13 +28,10 @@ export function PassiveCharacter(props) {
28
28
  rigidBodyRef.current.setEnabledRotations(false, false, false, false);
29
29
  }
30
30
  }, []);
31
- var memorized = useMemo(function () {
32
- return (_jsx(CharacterInnerRef, __assign({ isActive: false, componentType: "character", controllerOptions: props.controllerOptions || {
33
- lerp: {
34
- cameraTurn: 1,
35
- cameraPosition: 1,
36
- },
37
- }, position: props.position.clone(), rotation: props.rotation.clone(), currentAnimation: props.currentAnimation }, refs, props, { children: props.children })));
38
- }, [props.position, props.rotation, props.currentAnimation]);
39
- return _jsx(_Fragment, { children: memorized });
31
+ return (_jsx(CharacterInnerRef, __assign({ isActive: false, componentType: "character", controllerOptions: props.controllerOptions || {
32
+ lerp: {
33
+ cameraTurn: 1,
34
+ cameraPosition: 1,
35
+ },
36
+ }, position: props.position.clone(), rotation: props.rotation.clone(), currentAnimation: props.currentAnimation }, refs, props, { children: props.children })));
40
37
  }
@@ -9,12 +9,10 @@ var __assign = (this && this.__assign) || function () {
9
9
  };
10
10
  return __assign.apply(this, arguments);
11
11
  };
12
- import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
13
- import { useContext, useMemo, useRef } from "react";
14
- import { GaesupWorldContext } from "../../../world/context";
12
+ import { jsx as _jsx } from "react/jsx-runtime";
13
+ import { useRef } from "react";
15
14
  import { VehicleInnerRef } from "../../inner/vehicle";
16
15
  export function PassiveVehicle(props) {
17
- var states = useContext(GaesupWorldContext).states;
18
16
  var rigidBodyRef = useRef(null);
19
17
  var outerGroupRef = useRef(null);
20
18
  var innerGroupRef = useRef(null);
@@ -25,13 +23,10 @@ export function PassiveVehicle(props) {
25
23
  innerGroupRef: innerGroupRef,
26
24
  colliderRef: colliderRef,
27
25
  };
28
- var memorized = useMemo(function () {
29
- return (_jsx(VehicleInnerRef, __assign({ isActive: false, componentType: "vehicle", name: "vehicle", controllerOptions: props.controllerOptions || {
30
- lerp: {
31
- cameraTurn: 1,
32
- cameraPosition: 1,
33
- },
34
- }, position: props.position.clone(), rotation: props.rotation.clone(), currentAnimation: props.currentAnimation }, props, refs, { children: props.children })));
35
- }, [props.position, props.rotation, props.currentAnimation]);
36
- return _jsx(_Fragment, { children: memorized });
26
+ return (_jsx(VehicleInnerRef, __assign({ isActive: false, componentType: "vehicle", name: "vehicle", controllerOptions: props.controllerOptions || {
27
+ lerp: {
28
+ cameraTurn: 1,
29
+ cameraPosition: 1,
30
+ },
31
+ }, position: props.position.clone(), rotation: props.rotation.clone(), currentAnimation: props.currentAnimation }, props, refs, { children: props.children })));
37
32
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gaesup-world",
3
- "version": "0.6.76",
3
+ "version": "0.6.77",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",