Skip to content
This repository has been archived by the owner on Feb 10, 2023. It is now read-only.

Commit

Permalink
fix(cannon): remove skip(1) but it's a little bit messy
Browse files Browse the repository at this point in the history
  • Loading branch information
nartc committed Apr 14, 2022
1 parent fa74fc2 commit cb367ea
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions libs/cannon/bodies/src/lib/body.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ import type {
VectorName,
} from '@pmndrs/cannon-worker-api';
import { CannonWorkerAPI } from '@pmndrs/cannon-worker-api';
import { combineLatest, skip } from 'rxjs';
import { combineLatest } from 'rxjs';
import * as THREE from 'three';

export type AtomicApi<K extends AtomicName> = {
Expand Down Expand Up @@ -384,8 +384,16 @@ export class NgtPhysicBody extends NgtComponentStore {
physicsStore.select((s) => s.worker),
ref.ref$,
isUsedRef.ref$,
// TODO: not sure why we need to skip 1 :(
]).pipe(skip(1))
])

/**
* .pipe(
* map((args, index) => {
* // console.log('-->', args, args[1]?.uuid, index);
* return args;
* })
* )
*/
);
});

Expand Down

0 comments on commit cb367ea

Please sign in to comment.