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

BotConfig.EnableAudio is required to be true for using SendFriendMessage/SendGroupMessage #142

Closed
EtherealAO opened this issue Apr 2, 2022 · 2 comments
Assignees
Labels
question (゚Д゚*)ノ Further information is requested

Comments

@EtherealAO
Copy link

Describe features you've considered / 新功能描述
A clear and concise description of any features you've considered.

BotConfig.EnableAudio is required to be true for using SendFriendMessage/SendGroupMessage, but it is false now by default. Is it better to set EnableAudio to true by default? Or give a warn when invoking them without EnableAudio? It took me 90 minutes to figure it out.

Additional context / 附加资源
Add any other context or screenshots about the feature request here.
nope

@TheSnowfield TheSnowfield added the question (゚Д゚*)ノ Further information is requested label Apr 2, 2022
@TheSnowfield TheSnowfield self-assigned this Apr 2, 2022
@TheSnowfield
Copy link
Member

I'm so sorry to hear about we had brought trouble to you.
In the current situation, we have no time to write docs for users cuz we're cost a lot of time on the development.

The reason that we default set EnableAudio to false is the audio codec is an additional function of the core,
If you hope to use the audio function you need to build the libSilkCodec library for the core, we do even not offer the binaries.

The warning you can figure it out in the main branch:
https://github.com/KonataDev/Konata.Core/blob/main/Konata.Core/Components/Logics/Model/MessagingLogic.cs#L355-L361

// Return false if audio configuration not enabled
if (!ConfigComponent.GlobalConfig.EnableAudio)
{
    Context.LogW(TAG, "The audio function is currently disabled. " +
                      "Lack of codec library.");
    return false;
}

So I guess the problem may caused while you create a RecordChain?
If you're using an mp3 to create a record chain, probably you can get the error.

@EtherealAO
Copy link
Author

Yes i saw the warning, but can't associate it with SendFriendMessage, hope this issue can help the others

@TheSnowfield TheSnowfield pinned this issue Apr 2, 2022
@TheSnowfield TheSnowfield changed the title [feature request] BotConfig.EnableAudio is required to be true for using SendFriendMessage/SendGroupMessage BotConfig.EnableAudio is required to be true for using SendFriendMessage/SendGroupMessage Apr 2, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
question (゚Д゚*)ノ Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants