Skip to content

Commit

Permalink
final
Browse files Browse the repository at this point in the history
  • Loading branch information
joanmarquesbesses committed May 12, 2024
1 parent db8a626 commit c10bb4b
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 6 deletions.
4 changes: 2 additions & 2 deletions Game/Source/Audio.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -197,8 +197,8 @@ void Audio::ChangeFxVolume(float percent)

void Audio::UnloadFx(unsigned int id)
{
Mix_FreeChunk(fx[id]);
fx[id] = nullptr;
//Mix_FreeChunk(fx[id]);
//fx[id] = nullptr;
}

void Audio::StopFx(unsigned int channel)
Expand Down
1 change: 0 additions & 1 deletion Game/Source/Intro.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ bool Intro::Awake(pugi::xml_node config)
animation.loop = false;
animation.PushBack({0,0,1280,720});
animation.PushBack({ 1280,0,1280,720 });
animation.PushBack({ 0,720,1280,720 });
animation.PushBack({ 1280,720,1280,720 });
return true;
}
Expand Down
7 changes: 7 additions & 0 deletions Game/Source/InventoryMenu.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,13 @@ bool InventoryMenu::PostUpdate()
}
}

app->render->DrawText("health:", 300, 120, 130, 20, 255, 255, 255, 0);
app->render->DrawText("3", 440, 120, 20, 20, 255, 255, 255, 0);
app->render->DrawText("damge:", 300, 145, 110, 20, 255, 255, 255, 0);
app->render->DrawText("1", 440, 145, 20, 20, 255, 255, 255, 0);
app->render->DrawText("mvp:", 300, 170, 70, 20, 255, 255, 255, 0);
app->render->DrawText("3", 440, 170, 20, 20, 255, 255, 255, 0);

return true;
}

Expand Down
2 changes: 1 addition & 1 deletion Game/Source/LoseScreen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ bool LoseScreen::Start()
app->render->camera.x = 0;
app->render->camera.y = 0;
app->win->GetWindowSize(windowW, windowH);
app->audio->PlayMusic(sceneconfig.attribute("audio").as_string());
app->audio->PlayMusic(sceneconfig.attribute("audio").as_string(),0);
return true;
}

Expand Down
2 changes: 1 addition & 1 deletion Game/Source/Player.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ bool Player::Update(float dt)
switch (exploringState)
{
case ExploringState::IDLE:

//app->audio->StopFx(sandChannel);
ResetPath();

if (PosState == Direction::UL || PosState == Direction::UR) {
Expand Down
2 changes: 1 addition & 1 deletion Game/Source/QuestManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ bool QuestManager::PostUpdate()

bool QuestManager::CleanUp()
{
app->audio->UnloadFx(questComplete);
//app->audio->UnloadFx(questComplete);
for (size_t i = 0; i < activeQuests.size(); i++)
{
delete activeQuests.at(i);
Expand Down

0 comments on commit c10bb4b

Please sign in to comment.