pmndrs / pmndrs/ecctrl

How to define the character/player collision box/cuboid?

Open
#56 12 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
797
Forks
98
Avg merge
8m
Merged PRs (30d)
1

Description

I have a custom character model (who will have animations at a later date)
I visualise the cuboid with a Box.
I add the CuboidCollider inside Ecctrl.
The player finds the floor very bouncy and flies into the sky.

<Ecctrl debug ref={ecctrlRef} autoBalance={false} animated position={pos} jumpVel={0}>
    {/* <EcctrlAnimation characterURL={characterURL} animationSet={animationSet}> */}
    <CuboidCollider args={[1,2.15,1]} mass={0} position={[0,0.5,0]}/>
    <Box args={[1,2.15,1]} position={[0,0.5,0]} />
    <BaseMale scale={0.8} position={[0,-0.9,0]}/>
    {/* </EcctrlAnimation> */}
  </Ecctrl>

Screenshot 2024-05-04 075608

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the bouncing-floor behavior using the Ecctrl and CuboidCollider setup shown in the issue, then inspect the controller's collision handling and collider placement. Done means identifying the correct collision-box configuration for the custom character and confirming that the player no longer launches upward.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
game-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.