2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-08 22:27:43 +00:00

string_view refactor

This commit is contained in:
Jack Andersen
2017-11-12 20:19:18 -10:00
parent 742ab2514f
commit f7ec7bdc0c
345 changed files with 907 additions and 921 deletions

View File

@@ -5,6 +5,8 @@ namespace DataSpec
namespace DNAMP1
{
using namespace std::literals;
bool AGSC::Extract(PAKEntryReadStream& rs, const hecl::ProjectPath& outPath)
{
Header head;
@@ -48,12 +50,12 @@ bool AGSC::Cook(const hecl::ProjectPath& inPath, const hecl::ProjectPath& outPat
return false;
hecl::ProjectPath woExt = inPath.getWithExtension(nullptr, true);
std::string lastComp = woExt.getLastComponentUTF8();
std::string lastComp = std::string(woExt.getLastComponentUTF8());
if (hecl::StringUtils::EndsWith(lastComp, "_AGSC"))
lastComp.assign(lastComp.cbegin(), lastComp.cend() - 5);
Header head;
head.audioDir = "Audio/";
head.audioDir = "Audio/"sv;
head.groupName = lastComp;
head.write(w);