Welcome,
Guest
. Please
login
or
register
. Did you miss your
activation email?
French forum
Home
Help
Search
Login
Register
SFML community forums
»
Help
»
Audio
»
Making sound play on a Keyboard Event.
Print
Pages: [
1
]
Author
Topic: Making sound play on a Keyboard Event. (Read 2689 times)
0 Members and 1 Guest are viewing this topic.
Greentoast
Newbie
Posts: 9
Making sound play on a Keyboard Event.
«
on:
May 17, 2015, 09:29:15 pm »
So basically I want the designated sound to play once I click right. I keep getting the errors
"Expect ; before buffer" ,"Sound Buffer is not a member of sf" and "Buffer was not declared on this scope"
http://pastebin.com/TXaW21MS
Please help me out! When I get experienced I will be sure to help out people too.
Logged
Greentoast
Newbie
Posts: 9
Re: Making sound play on a Keyboard Event.
«
Reply #1 on:
May 17, 2015, 09:35:11 pm »
Line 83-90 is where the issue is.
Logged
G.
Hero Member
Posts: 1593
Re: Making sound play on a Keyboard Event.
«
Reply #2 on:
May 17, 2015, 09:40:49 pm »
sf::SoundBuffer is part of the SFML audio module.
Include SFML/Audio.hpp if you want to use it.
Logged
Greentoast
Newbie
Posts: 9
Re: Making sound play on a Keyboard Event.
«
Reply #3 on:
May 17, 2015, 09:47:09 pm »
Thanks that worked!
Logged
Print
Pages: [
1
]
SFML community forums
»
Help
»
Audio
»
Making sound play on a Keyboard Event.