Notice: after bumping up to three 0.180.0 with @types/three 0.180.0,
Argument of type 'Group<Object3DEventMap>' is not assignable to parameter of type 'Object3D<Object3DEventMap>'.
Type 'Group<Object3DEventMap>' is missing the following properties from type 'Object3D<Object3DEventMap>': setPointerCapture, releasePointerCapture, hasPointerCapture
Currently, AFAIK, clearly, three, and @types/three doesn't have the setPointerCapture, releasePointerCapture, hasPointerCapture method / getters
The only place I found on GitHub, points out that https://github.com/pmndrs/xr/blob/456aa380206e93888cd3a5741a1534e672ae3106/packages/pointer-events/src/pointer.ts#L69-L100 declares
```js
declare module 'three' {
interface Object3D {
setPointerCapture(pointerId: number): void
releasePointerCapture(pointerId: number): void
hasPointerCapture(pointerId: number): boolean
intersectChildren?: boolean
interactableDescendants?: Array<Object3D>
/**
* @deprecated
*/
ancestorsHaveListeners?: boolean
ancestorsHavePointerListeners?: boolean
ancestorsHaveWheelListeners?: boolean
}
}
```
And in @tresjs/core v5, it uses the @pmndrs/pointer-events internally.
Somehow the Object3D from @types/three and the one augmented by @pmndrs/pointer-events are not compatible.
`new Object3D() as unknown as Object3D` works as workaround here but there should be no need to do such a thing since these two Object3D should be the same.
With no updates from `typescript`, I assume there is no breaking change or regression from `typescript` side.
discord-bot
Allow アイリ to talk to you and many other users in Discord voice channels.
Getting started
git clone git@github.com:moeru-ai/airi.git
pnpm i
Create a .env.local file:
cd services/discord-bot
cp .env .env.local
Fill-in the following credentials as configurations:
DISCORD_TOKEN=''
DISCORD_BOT_CLIENT_ID=''
OPENAI_MODEL=''
OPENAI_API_KEY=''
OPENAI_API_BASE_URL=''
ELEVENLABS_API_KEY=''
ELEVENLABS_API_BASE_URL=''
pnpm run -F @proj-airi/discord-bot start
Other similar projects
Acknowledgements
- Implementation of Audio handling and processing https://github.com/TheTrueSCP/CharacterAIVoice/blob/54d6a41b4e0eba9ad996c5f9ddcc6230277af2f8/src/VoiceHandler.js
- Example of usage https://github.com/discordjs/voice-examples/blob/da0c3b419107d41053501a4dddf3826ad53c03f7/radio-bot/src/bot.ts
- Excellent library https://github.com/discordjs/discord.js