changed AudioPlayer::PlaySound() to AudioPlayer::playSound()
This commit is contained in:
@@ -58,7 +58,7 @@ void mixaudio(void *unused, Uint8 *stream, int len)
|
||||
}
|
||||
}
|
||||
|
||||
void AudioPlayer::PlaySound(std::string fileString)
|
||||
void AudioPlayer::playSound(std::string fileString)
|
||||
{
|
||||
|
||||
if(initiated)
|
||||
|
||||
@@ -6,6 +6,6 @@ class AudioPlayer
|
||||
public:
|
||||
AudioPlayer(void);
|
||||
~AudioPlayer(void);
|
||||
static void PlaySound(std::string);
|
||||
static void playSound(std::string);
|
||||
static void init();
|
||||
};
|
||||
|
||||
108
G3DTest.vcproj
108
G3DTest.vcproj
@@ -234,30 +234,14 @@
|
||||
RelativePath=".\AudioPlayer.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BaseButtonInstance.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\ButtonListener.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\DataModelInstance.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Dialogs.rc"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\ImageButtonInstance.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Instance.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="main.cpp"
|
||||
>
|
||||
@@ -278,14 +262,38 @@
|
||||
/>
|
||||
</FileConfiguration>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\PhysicalInstance.cpp"
|
||||
<Filter
|
||||
Name="Instances"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TextButtonInstance.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BaseButtonInstance.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\DataModelInstance.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\ImageButtonInstance.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Instance.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\PhysicalInstance.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TextButtonInstance.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\WorkspaceInstance.cpp"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Header Files"
|
||||
@@ -295,38 +303,46 @@
|
||||
RelativePath=".\AudioPlayer.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BaseButtonInstance.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\ButtonListener.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\DataModelInstance.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\ImageButtonInstance.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Instance.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\PhysicalInstance.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\resource.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TextButtonInstance.h"
|
||||
<Filter
|
||||
Name="Instances"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\BaseButtonInstance.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\DataModelInstance.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\ImageButtonInstance.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Instance.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\PhysicalInstance.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TextButtonInstance.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\WorkspaceInstance.h"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Resource Files"
|
||||
|
||||
12
main.cpp
12
main.cpp
@@ -255,7 +255,7 @@ public:
|
||||
|
||||
void CameraButtonListener::onButton1MouseClick(BaseButtonInstance* button)
|
||||
{
|
||||
AudioPlayer::PlaySound(cameraSound);
|
||||
AudioPlayer::playSound(cameraSound);
|
||||
CoordinateFrame frame = usableApp->debugCamera.getCoordinateFrame();
|
||||
if(button->name == "CenterCam")
|
||||
centerCam = true;
|
||||
@@ -280,7 +280,7 @@ void GUDButtonListener::onButton1MouseClick(BaseButtonInstance* button)
|
||||
{
|
||||
if(selectedInstance != NULL)
|
||||
{
|
||||
AudioPlayer::PlaySound(dingSound);
|
||||
AudioPlayer::playSound(dingSound);
|
||||
if(button->name == "Duplicate")
|
||||
{
|
||||
|
||||
@@ -298,7 +298,7 @@ void RotateButtonListener::onButton1MouseClick(BaseButtonInstance* button)
|
||||
{
|
||||
if(selectedInstance != NULL)
|
||||
{
|
||||
AudioPlayer::PlaySound(clickSound);
|
||||
AudioPlayer::playSound(clickSound);
|
||||
if(selectedInstance->getClassName() == "Part")
|
||||
{
|
||||
PhysicalInstance* part = (PhysicalInstance*) selectedInstance;
|
||||
@@ -324,7 +324,7 @@ void deleteInstance()
|
||||
instances.erase(instances.begin() + i);
|
||||
delete deleting;
|
||||
selectedInstance = NULL;
|
||||
AudioPlayer::PlaySound(GetFileInPath("/content/sounds/pageturn.wav"));
|
||||
AudioPlayer::playSound(GetFileInPath("/content/sounds/pageturn.wav"));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1049,13 +1049,13 @@ void Demo::onUserInput(UserInput* ui) {
|
||||
|
||||
if(ui->keyPressed(SDL_MOUSE_WHEEL_UP_KEY))
|
||||
{
|
||||
AudioPlayer::PlaySound(cameraSound);
|
||||
AudioPlayer::playSound(cameraSound);
|
||||
CoordinateFrame frame = app->debugCamera.getCoordinateFrame();
|
||||
cameraPos = cameraPos + frame.lookVector()*2;
|
||||
}
|
||||
if(ui->keyPressed(SDL_MOUSE_WHEEL_DOWN_KEY))
|
||||
{
|
||||
AudioPlayer::PlaySound(cameraSound);
|
||||
AudioPlayer::playSound(cameraSound);
|
||||
CoordinateFrame frame = app->debugCamera.getCoordinateFrame();
|
||||
cameraPos = cameraPos - frame.lookVector()*2;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user