summaryrefslogtreecommitdiff
path: root/ZAPD/ZCutscene.cpp
diff options
context:
space:
mode:
authorRandom <28494085+Random06457@users.noreply.github.com>2021-09-12 22:25:37 +0200
committerGitHub <noreply@github.com>2021-09-12 16:25:37 -0400
commit90662f3cbade844c8edc3943ab8252e334b6166a (patch)
treecc794d60659a4640d36af52b580228891515e0dc /ZAPD/ZCutscene.cpp
parent5da00201f261f8ac4927064f1390e886672cda58 (diff)
Fix compilation with -Wextra (#164)
* add -Wextra -Werror * remove void arg in GfxdCallback_FormatSingleEntry * mark CRC32 functions as maybe_unused * remove useless comment * fix clang warnings * replace (void) with [[maybe_unused]] * run make format
Diffstat (limited to 'ZAPD/ZCutscene.cpp')
-rw-r--r--ZAPD/ZCutscene.cpp33
1 files changed, 17 insertions, 16 deletions
diff --git a/ZAPD/ZCutscene.cpp b/ZAPD/ZCutscene.cpp
index 9d182fb..01eab16 100644
--- a/ZAPD/ZCutscene.cpp
+++ b/ZAPD/ZCutscene.cpp
@@ -85,7 +85,7 @@ CutsceneCommandSceneTransFX::~CutsceneCommandSceneTransFX()
{
}
-std::string ZCutscene::GetBodySourceCode()
+std::string ZCutscene::GetBodySourceCode() const
{
std::string output = "";
size_t size = 0;
@@ -448,7 +448,8 @@ ZResourceType ZCutscene::GetResourceType() const
return ZResourceType::Cutscene;
}
-CutsceneCommand::CutsceneCommand(const std::vector<uint8_t>& rawData, uint32_t rawDataIndex)
+CutsceneCommand::CutsceneCommand([[maybe_unused]] const std::vector<uint8_t>& rawData,
+ [[maybe_unused]] uint32_t rawDataIndex)
{
}
@@ -523,7 +524,7 @@ std::string CutsceneCommandSetCameraPos::GetCName()
return "";
}
-std::string CutsceneCommandSetCameraPos::GenerateSourceCode(uint32_t baseAddress)
+std::string CutsceneCommandSetCameraPos::GenerateSourceCode([[maybe_unused]] uint32_t baseAddress)
{
std::string result = "";
@@ -614,7 +615,7 @@ std::string CutsceneCommandFadeBGM::GetCName()
return "CsCmdMusicFade";
}
-std::string CutsceneCommandFadeBGM::GenerateSourceCode(uint32_t baseAddress)
+std::string CutsceneCommandFadeBGM::GenerateSourceCode([[maybe_unused]] uint32_t baseAddress)
{
std::string result = "";
@@ -667,7 +668,7 @@ CutsceneCommandPlayBGM::CutsceneCommandPlayBGM(const std::vector<uint8_t>& rawDa
}
}
-std::string CutsceneCommandPlayBGM::GenerateSourceCode(uint32_t baseAddress)
+std::string CutsceneCommandPlayBGM::GenerateSourceCode([[maybe_unused]] uint32_t baseAddress)
{
std::string result = "";
@@ -710,7 +711,7 @@ CutsceneCommandStopBGM::CutsceneCommandStopBGM(const std::vector<uint8_t>& rawDa
}
}
-std::string CutsceneCommandStopBGM::GenerateSourceCode(uint32_t baseAddress)
+std::string CutsceneCommandStopBGM::GenerateSourceCode([[maybe_unused]] uint32_t baseAddress)
{
std::string result = "";
@@ -768,7 +769,7 @@ CutsceneCommandEnvLighting::CutsceneCommandEnvLighting(const std::vector<uint8_t
}
}
-std::string CutsceneCommandEnvLighting::GenerateSourceCode(uint32_t baseAddress)
+std::string CutsceneCommandEnvLighting::GenerateSourceCode([[maybe_unused]] uint32_t baseAddress)
{
std::string result = "";
@@ -824,7 +825,7 @@ CutsceneCommandUnknown9::CutsceneCommandUnknown9(const std::vector<uint8_t>& raw
}
}
-std::string CutsceneCommandUnknown9::GenerateSourceCode(uint32_t baseAddress)
+std::string CutsceneCommandUnknown9::GenerateSourceCode([[maybe_unused]] uint32_t baseAddress)
{
std::string result = "";
@@ -882,7 +883,7 @@ CutsceneCommandUnknown::CutsceneCommandUnknown(const std::vector<uint8_t>& rawDa
}
}
-std::string CutsceneCommandUnknown::GenerateSourceCode(uint32_t baseAddress)
+std::string CutsceneCommandUnknown::GenerateSourceCode([[maybe_unused]] uint32_t baseAddress)
{
std::string result = "";
@@ -940,7 +941,7 @@ std::string CutsceneCommandDayTime::GetCName()
return "CsCmdDayTime";
}
-std::string CutsceneCommandDayTime::GenerateSourceCode(uint32_t baseAddress)
+std::string CutsceneCommandDayTime::GenerateSourceCode([[maybe_unused]] uint32_t baseAddress)
{
std::string result = "";
@@ -991,7 +992,7 @@ std::string CutsceneCommandTextbox::GetCName()
return "CsCmdTextbox";
}
-std::string CutsceneCommandTextbox::GenerateSourceCode(uint32_t baseAddress)
+std::string CutsceneCommandTextbox::GenerateSourceCode([[maybe_unused]] uint32_t baseAddress)
{
std::string result = "";
@@ -1057,7 +1058,7 @@ CutsceneCommandActorAction::CutsceneCommandActorAction(const std::vector<uint8_t
}
}
-std::string CutsceneCommandActorAction::GenerateSourceCode(uint32_t baseAddress)
+std::string CutsceneCommandActorAction::GenerateSourceCode([[maybe_unused]] uint32_t baseAddress)
{
std::string result = "";
std::string subCommand = "";
@@ -1114,7 +1115,7 @@ std::string CutsceneCommandTerminator::GetCName()
return "CsCmdBase";
}
-std::string CutsceneCommandTerminator::GenerateSourceCode(uint32_t baseAddress)
+std::string CutsceneCommandTerminator::GenerateSourceCode([[maybe_unused]] uint32_t baseAddress)
{
std::string result = "";
@@ -1136,7 +1137,7 @@ CutsceneCommandEnd::CutsceneCommandEnd(const std::vector<uint8_t>& rawData, uint
endFrame = (uint16_t)BitConverter::ToInt16BE(rawData, rawDataIndex + 4);
}
-std::string CutsceneCommandEnd::GenerateSourceCode(uint32_t baseAddress)
+std::string CutsceneCommandEnd::GenerateSourceCode([[maybe_unused]] uint32_t baseAddress)
{
std::string result = "";
@@ -1190,7 +1191,7 @@ CutsceneCommandSpecialAction::CutsceneCommandSpecialAction(const std::vector<uin
}
}
-std::string CutsceneCommandSpecialAction::GenerateSourceCode(uint32_t baseAddress)
+std::string CutsceneCommandSpecialAction::GenerateSourceCode([[maybe_unused]] uint32_t baseAddress)
{
std::string result = "";
@@ -1249,7 +1250,7 @@ CutsceneCommandSceneTransFX::CutsceneCommandSceneTransFX(const std::vector<uint8
endFrame = (uint16_t)BitConverter::ToInt16BE(rawData, rawDataIndex + 4);
}
-std::string CutsceneCommandSceneTransFX::GenerateSourceCode(uint32_t baseAddress)
+std::string CutsceneCommandSceneTransFX::GenerateSourceCode([[maybe_unused]] uint32_t baseAddress)
{
return StringHelper::Sprintf("CS_SCENE_TRANS_FX(%i, %i, %i),\n", base, startFrame, endFrame);
}