fixes
This commit is contained in:
1 parent
bfd691e7ab
commit
df76bb5f35
1 file changed
+4
-2
@@ -30,8 +30,10 @@ export function Banana({onCollide, id, ...props}) {
|
|||||||
type='fixed'
|
type='fixed'
|
||||||
position={props.position}
|
position={props.position}
|
||||||
sensor
|
sensor
|
||||||
onIntersectionEnter={() => {
|
onIntersectionEnter={({other}) => {
|
||||||
actions.setShouldSlowDown(true);
|
if(other.rigidBodyObject.name === "player"){
|
||||||
|
actions.setShouldSlowDown(true);
|
||||||
|
}
|
||||||
actions.removeBananaById(id);
|
actions.removeBananaById(id);
|
||||||
}}
|
}}
|
||||||
colliders={false}
|
colliders={false}
|
||||||
|
|||||||
Reference in new issue
Block a user