Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

speaker.playSound returns true when it should not #698

Closed
Jeuvke opened this issue Jan 26, 2021 · 1 comment
Closed

speaker.playSound returns true when it should not #698

Jeuvke opened this issue Jan 26, 2021 · 1 comment
Labels
area-Minecraft This affects CC's Minecraft-specific content. bug A problem or unexpected behaviour with the mod. wontfix A bug which I won't fix or an enhancement which won't be implemented.

Comments

@Jeuvke
Copy link

Jeuvke commented Jan 26, 2021

local speaker = peripheral.find("speaker")
print(speaker.playSound("notasound"))

will return true.
playSound will never return false, and only throws when using capital letters, some special characters, or spaces in the sound name.

@Jeuvke Jeuvke added the bug A problem or unexpected behaviour with the mod. label Jan 26, 2021
@SquidDev SquidDev added area-Minecraft This affects CC's Minecraft-specific content. wontfix A bug which I won't fix or an enhancement which won't be implemented. labels Jan 26, 2021
@SquidDev
Copy link
Member

This is sadly unavoidable. We've got to choose between playing modded sounds (see dan200/ComputerCraft#578) or returning something useful, and we went for the former.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
area-Minecraft This affects CC's Minecraft-specific content. bug A problem or unexpected behaviour with the mod. wontfix A bug which I won't fix or an enhancement which won't be implemented.
Projects
None yet
Development

No branches or pull requests

2 participants