diff --git a/.gitignore b/.gitignore
index f686db7..b1cbee9 100644
--- a/.gitignore
+++ b/.gitignore
@@ -23,8 +23,8 @@ bld/
[Oo]bj/
# Intermidate Building Things
-UniversalPropertyReplacement/[Dd]ebug/
-UniversalPropertyReplacement/[Rr]elease/
+UniversalPropertyEnhancer/[Dd]ebug/
+UniversalPropertyEnhancer/[Rr]elease/
# Visual Studio 2015 cache/options directory
.vs/
diff --git a/UniversalPropertyReplacement.sln b/UniversalPropertyEnhancer.sln
similarity index 92%
rename from UniversalPropertyReplacement.sln
rename to UniversalPropertyEnhancer.sln
index 1e11679..2ae92ba 100644
--- a/UniversalPropertyReplacement.sln
+++ b/UniversalPropertyEnhancer.sln
@@ -3,7 +3,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16
VisualStudioVersion = 16.0.29728.190
MinimumVisualStudioVersion = 10.0.40219.1
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "UniversalPropertyReplacement", "UniversalPropertyReplacement\UniversalPropertyReplacement.vcxproj", "{07FC5B61-B575-4207-B464-AFAE6AF3FC19}"
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "UniversalPropertyEnhancer", "UniversalPropertyEnhancer\UniversalPropertyEnhancer.vcxproj", "{07FC5B61-B575-4207-B464-AFAE6AF3FC19}"
ProjectSection(ProjectDependencies) = postProject
{F057451A-1413-4D68-AF56-1BF529933420} = {F057451A-1413-4D68-AF56-1BF529933420}
EndProjectSection
diff --git a/UniversalPropertyReplacement/ReadMe.txt b/UniversalPropertyEnhancer/ReadMe.txt
similarity index 78%
rename from UniversalPropertyReplacement/ReadMe.txt
rename to UniversalPropertyEnhancer/ReadMe.txt
index 4833c95..ccaff72 100644
--- a/UniversalPropertyReplacement/ReadMe.txt
+++ b/UniversalPropertyEnhancer/ReadMe.txt
@@ -1,20 +1,20 @@
========================================================================
- DYNAMIC LINK LIBRARY : UniversalPropertyReplacement Project Overview
+ DYNAMIC LINK LIBRARY : UniversalPropertyEnhancer Project Overview
========================================================================
-AppWizard has created this UniversalPropertyReplacement DLL for you.
+AppWizard has created this UniversalPropertyEnhancer DLL for you.
This file contains a summary of what you will find in each of the files that
-make up your UniversalPropertyReplacement application.
+make up your UniversalPropertyEnhancer application.
-UniversalPropertyReplacement.vcxproj
+UniversalPropertyEnhancer.vcxproj
This is the main project file for VC++ projects generated using an Application Wizard.
It contains information about the version of Visual C++ that generated the file, and
information about the platforms, configurations, and project features selected with the
Application Wizard.
-UniversalPropertyReplacement.vcxproj.filters
+UniversalPropertyEnhancer.vcxproj.filters
This is the filters file for VC++ projects generated using an Application Wizard.
It contains information about the association between the files in your project
and the filters. This association is used in the IDE to show grouping of files with
@@ -26,7 +26,7 @@ Other standard files:
StdAfx.h, StdAfx.cpp
These files are used to build a precompiled header (PCH) file
- named UniversalPropertyReplacement.pch and a precompiled types file named StdAfx.obj.
+ named UniversalPropertyEnhancer.pch and a precompiled types file named StdAfx.obj.
/////////////////////////////////////////////////////////////////////////////
Other notes:
diff --git a/UniversalPropertyReplacement/SdkPathConfig.props b/UniversalPropertyEnhancer/SdkPathConfig.props
similarity index 100%
rename from UniversalPropertyReplacement/SdkPathConfig.props
rename to UniversalPropertyEnhancer/SdkPathConfig.props
diff --git a/UniversalPropertyReplacement/UniversalPropertyReplacement.vcxproj b/UniversalPropertyEnhancer/UniversalPropertyEnhancer.vcxproj
similarity index 96%
rename from UniversalPropertyReplacement/UniversalPropertyReplacement.vcxproj
rename to UniversalPropertyEnhancer/UniversalPropertyEnhancer.vcxproj
index 1927899..cffe9c9 100644
--- a/UniversalPropertyReplacement/UniversalPropertyReplacement.vcxproj
+++ b/UniversalPropertyEnhancer/UniversalPropertyEnhancer.vcxproj
@@ -13,8 +13,9 @@
{07FC5B61-B575-4207-B464-AFAE6AF3FC19}
Win32Proj
- UniversalPropertyReplacement
+ UniversalPropertyEnhancer
10.0
+ UniversalPropertyEnhancer
@@ -100,6 +101,7 @@
+
@@ -116,6 +118,7 @@
Create
Create
+
diff --git a/UniversalPropertyReplacement/UniversalPropertyReplacement.vcxproj.filters b/UniversalPropertyEnhancer/UniversalPropertyEnhancer.vcxproj.filters
similarity index 73%
rename from UniversalPropertyReplacement/UniversalPropertyReplacement.vcxproj.filters
rename to UniversalPropertyEnhancer/UniversalPropertyEnhancer.vcxproj.filters
index e6d223f..0c1adbc 100644
--- a/UniversalPropertyReplacement/UniversalPropertyReplacement.vcxproj.filters
+++ b/UniversalPropertyEnhancer/UniversalPropertyEnhancer.vcxproj.filters
@@ -5,12 +5,12 @@
{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}
rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms
-
- {3880d018-2395-4502-abfe-4b83e0817aab}
-
{d62ad12d-69d8-4933-8342-03043c9adc22}
+
+ {3880d018-2395-4502-abfe-4b83e0817aab}
+
@@ -20,24 +20,30 @@
Internal
- UniversalPropertyReplacement
+ UniversalPropertyEnhancer
- UniversalPropertyReplacement
+ UniversalPropertyEnhancer
+
+
+ UniversalPropertyEnhancer
- UniversalPropertyReplacement
+ UniversalPropertyEnhancer
Internal
- UniversalPropertyReplacement
+ UniversalPropertyEnhancer
- UniversalPropertyReplacement
+ UniversalPropertyEnhancer
+
+
+ UniversalPropertyEnhancer
diff --git a/UniversalPropertyReplacement/UniversalPropertyReplacement.cpp b/UniversalPropertyEnhancer/UniversalPropertyReplacement.cpp
similarity index 96%
rename from UniversalPropertyReplacement/UniversalPropertyReplacement.cpp
rename to UniversalPropertyEnhancer/UniversalPropertyReplacement.cpp
index d5a3854..e156219 100644
--- a/UniversalPropertyReplacement/UniversalPropertyReplacement.cpp
+++ b/UniversalPropertyEnhancer/UniversalPropertyReplacement.cpp
@@ -1,9 +1,9 @@
/****************************************************************************
* Copyright (C) 2018, 2020 Zarklord
*
-* This file is part of UniversalPropertyReplacement.
+* This file is part of UniversalPropertyEnhancer.
*
-* UniversalPropertyReplacement is free software: you can redistribute it and/or modify
+* UniversalPropertyEnhancer is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
@@ -14,12 +14,11 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
-* along with UniversalPropertyReplacement. If not, see .
+* along with UniversalPropertyEnhancer. If not, see .
****************************************************************************/
#include "stdafx.h"
#include "UniversalPropertyReplacement.h"
-#include "VerificationCheat.h"
namespace UniversalPropertyReplacement {
long AttachDetours() {
@@ -31,7 +30,6 @@ namespace UniversalPropertyReplacement {
return result;
}
bool Inititalize() {
- CheatManager.AddCheat("VerifyUPR", new VerificationCheat());
uint32_t groupID = id("prop_overrides");
eastl::vector instanceList{};
PropManager.GetAllListIDs(groupID, instanceList);
@@ -126,18 +124,17 @@ namespace UniversalPropertyReplacement {
if (!result) continue;
colorRGBAValueMapOverride[replaceHash] = value;
} else if (typeString == "transform") {
- /*ManualBreakpoint();
- Transform value;
+ Transform* value;
result = propList->GetProperty(id(valueString.c_str()), out);
if (!result) continue;
- value = *(out->GetValueTransform());
- transformValueMapOverride[replaceHash] = value;*/
+ value = out->GetValueTransform();
+ transformValueMapArrayOverride[replaceHash] = eastl::pair {value, 1};
} else if (typeString == "bbox") {
- /*BoundingBox value;
+ BoundingBox* value;
result = propList->GetProperty(id(valueString.c_str()), out);
if (!result) continue;
- value = *(out->GetValueBBox());
- bBoxValueMapOverride[replaceHash] = value;*/
+ value = out->GetValueBBox();
+ bBoxValueMapArrayOverride[replaceHash] = eastl::pair {value, 1};
} else if (typeString == "bools") {
bool* value;
result = propList->GetProperty(id(valueString.c_str()), out);
@@ -360,12 +357,13 @@ void ApplyValueMapProperty(App::Property*& prop, uint32_t propertyID) {
case App::PropertyType::ColorRGBA: {
return ApplyTemplateValueMapProperty(prop, propertyID, colorRGBAValueMapOverride);
}
+ /* unreachable properties
case App::PropertyType::Transform: {
return ApplyTemplateValueMapProperty(prop, propertyID, transformValueMapOverride);
}
case App::PropertyType::BBox: {
return ApplyTemplateValueMapProperty(prop, propertyID, bBoxValueMapOverride);
- }
+ }*/
}
}
diff --git a/UniversalPropertyReplacement/UniversalPropertyReplacement.h b/UniversalPropertyEnhancer/UniversalPropertyReplacement.h
similarity index 90%
rename from UniversalPropertyReplacement/UniversalPropertyReplacement.h
rename to UniversalPropertyEnhancer/UniversalPropertyReplacement.h
index e347250..55caad5 100644
--- a/UniversalPropertyReplacement/UniversalPropertyReplacement.h
+++ b/UniversalPropertyEnhancer/UniversalPropertyReplacement.h
@@ -1,9 +1,9 @@
/****************************************************************************
* Copyright (C) 2018, 2020 Zarklord
*
-* This file is part of UniversalPropertyReplacement.
+* This file is part of UniversalPropertyEnhancer.
*
-* UniversalPropertyReplacement is free software: you can redistribute it and/or modify
+* UniversalPropertyEnhancer is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
@@ -14,7 +14,7 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
-* along with UniversalPropertyReplacement. If not, see .
+* along with UniversalPropertyEnhancer. If not, see .
****************************************************************************/
#pragma once
@@ -63,10 +63,8 @@ namespace UniversalPropertyReplacement {
static eastl::map colorRGBAValueMapOverride {};
static eastl::map> colorRGBAValueMapArrayOverride {};
- static eastl::map transformValueMapOverride {};
static eastl::map> transformValueMapArrayOverride {};
- static eastl::map bBoxValueMapOverride {};
static eastl::map> bBoxValueMapArrayOverride {};
member_detour(GetPropertyAlt__detour, App::PropertyList, bool(uint32_t propertyID, App::Property*& result)) {};
diff --git a/UniversalPropertyReplacement/VerificationCheat.cpp b/UniversalPropertyEnhancer/VerificationCheat.cpp
similarity index 90%
rename from UniversalPropertyReplacement/VerificationCheat.cpp
rename to UniversalPropertyEnhancer/VerificationCheat.cpp
index 9c3c26d..812a966 100644
--- a/UniversalPropertyReplacement/VerificationCheat.cpp
+++ b/UniversalPropertyEnhancer/VerificationCheat.cpp
@@ -1,9 +1,9 @@
/****************************************************************************
* Copyright (C) 2018, 2020 Zarklord
*
-* This file is part of UniversalPropertyReplacement.
+* This file is part of UniversalPropertyEnhancer.
*
-* UniversalPropertyReplacement is free software: you can redistribute it and/or modify
+* UniversalPropertyEnhancer is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
@@ -14,7 +14,7 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
-* along with UniversalPropertyReplacement. If not, see .
+* along with UniversalPropertyEnhancer. If not, see .
****************************************************************************/
#include "stdafx.h"
@@ -45,7 +45,7 @@ bool VerifyValue(char16_t*& toverify) {
return wcscmp((wchar_t*)toverify, L"1") == 0;
}
bool VerifyValue(ResourceKey& toverify) {
- return toverify.groupID == id("prop_overrides") && toverify.instanceID == id("VerifyUPROverrides") && toverify.typeID == id("prop");
+ return toverify.groupID == id("prop_overrides") && toverify.instanceID == id("VerifyUPEOverrides") && toverify.typeID == id("prop");
}
bool VerifyValue(LocalizedString& toverify) {
return toverify.GetText() == eastl::string16 {"Name Your Creature"};
@@ -91,12 +91,12 @@ uint32_t GetPropertyId(eastl::string str) {
void VerificationCheat::ParseLine(const ArgScript::Line& line) {
PropertyListPtr propList;
- PropManager.GetPropertyList(id("VerifyUPR"), id("VerifyUPR"), propList);
+ PropManager.GetPropertyList(id("VerifyUPE"), id("VerifyUPE"), propList);
App::Property* out;
bool testFailed = false;
- bool boolTest;
+ bool boolTest = false;
App::Property::GetBool(propList.get(), GetPropertyId("bool"), boolTest);
if (VerifyValue(boolTest)) {
ReportReplacementFailed("bool");
@@ -110,7 +110,7 @@ void VerificationCheat::ParseLine(const ArgScript::Line& line) {
}
uint32_t uint32Test;
App::Property::GetUInt32(propList.get(), GetPropertyId("uint32"), uint32Test);
- if (VerifyValue(boolTest)) {
+ if (VerifyValue(uint32Test)) {
ReportReplacementFailed("uint32");
testFailed = true;
}
@@ -186,22 +186,22 @@ void VerificationCheat::ParseLine(const ArgScript::Line& line) {
ReportReplacementFailed("colorRGBA");
testFailed = true;
}
- /*Transform transformTest;
+ Transform transformTest;
if (propList->GetProperty(GetPropertyId("transform"), out)) {
transformTest = *(out->GetValueTransform());
if (VerifyValue(transformTest)) {
ReportReplacementFailed("transform");
testFailed = true;
}
- }*/
- /*BoundingBox bBoxTest;
+ }
+ BoundingBox bBoxTest;
if (propList->GetProperty(GetPropertyId("bbox"), out)) {
bBoxTest = *(out->GetValueBBox());
if (VerifyValue(bBoxTest)) {
ReportReplacementFailed("bbox");
testFailed = true;
}
- }*/
+ }
uint32_t count;
@@ -344,4 +344,28 @@ void VerificationCheat::ParseLine(const ArgScript::Line& line) {
if (!testFailed) {
App::ConsolePrintF("no replacement tests failed!");
}
+
+ testFailed = false;
+ bool addTest = false;
+ App::Property::GetBool(propList.get(), id("postinitAdd"), addTest);
+ if (VerifyValue(addTest)) {
+ App::ConsolePrintF("Add Postinit failed!");
+ testFailed = true;
+ }
+ int32_t replaceTest;
+ App::Property::GetInt32(propList.get(), id("postinitReplace"), replaceTest);
+ if (VerifyValue(replaceTest)) {
+ App::ConsolePrintF("Replace Postinit failed!");
+ testFailed = true;
+ }
+ uint32_t remainTest;
+ App::Property::GetUInt32(propList.get(), id("postinitRemain"), remainTest);
+ if (VerifyValue(remainTest)) {
+ App::ConsolePrintF("Remain Postinit failed!");
+ testFailed = true;
+ }
+
+ if (!testFailed) {
+ App::ConsolePrintF("no postinit tests failed!");
+ }
}
\ No newline at end of file
diff --git a/UniversalPropertyReplacement/VerificationCheat.h b/UniversalPropertyEnhancer/VerificationCheat.h
similarity index 79%
rename from UniversalPropertyReplacement/VerificationCheat.h
rename to UniversalPropertyEnhancer/VerificationCheat.h
index 1cea0f7..d579f17 100644
--- a/UniversalPropertyReplacement/VerificationCheat.h
+++ b/UniversalPropertyEnhancer/VerificationCheat.h
@@ -1,9 +1,9 @@
/****************************************************************************
* Copyright (C) 2018, 2020 Zarklord
*
-* This file is part of UniversalPropertyReplacement.
+* This file is part of UniversalPropertyEnhancer.
*
-* UniversalPropertyReplacement is free software: you can redistribute it and/or modify
+* UniversalPropertyEnhancer is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
@@ -14,7 +14,7 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
-* along with UniversalPropertyReplacement. If not, see .
+* along with UniversalPropertyEnhancer. If not, see .
****************************************************************************/
#pragma once
diff --git a/UniversalPropertyReplacement/dllmain.cpp b/UniversalPropertyEnhancer/dllmain.cpp
similarity index 81%
rename from UniversalPropertyReplacement/dllmain.cpp
rename to UniversalPropertyEnhancer/dllmain.cpp
index 5298904..bba0f28 100644
--- a/UniversalPropertyReplacement/dllmain.cpp
+++ b/UniversalPropertyEnhancer/dllmain.cpp
@@ -1,9 +1,9 @@
/****************************************************************************
* Copyright (C) 2018, 2020 Zarklord
*
-* This file is part of UniversalPropertyReplacement.
+* This file is part of UniversalPropertyEnhancer.
*
-* UniversalPropertyReplacement is free software: you can redistribute it and/or modify
+* UniversalPropertyEnhancer is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
@@ -14,12 +14,14 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
-* along with UniversalPropertyReplacement. If not, see .
+* along with UniversalPropertyEnhancer. If not, see .
****************************************************************************/
// dllmain.cpp : Defines the entry point for the DLL application.
#include "stdafx.h"
#include "UniversalPropertyReplacement.h"
+#include "UniversalPropertyPostInit.h"
+#include "VerificationCheat.h"
void Initialize()
{
@@ -31,6 +33,8 @@ void Initialize()
// - Add new space tools
// - Change materials
UniversalPropertyReplacement::Inititalize();
+ UniversalPropertyPostInit::Inititalize();
+ CheatManager.AddCheat("VerifyUPE", new VerificationCheat());
}
void Dispose()
@@ -44,6 +48,7 @@ void AttachDetours()
// Call the attach() method on any detours you want to add
// For example: cViewer_SetRenderType_detour::attach(GetAddress(cViewer, SetRenderType));
UniversalPropertyReplacement::AttachDetours();
+ UniversalPropertyPostInit::AttachDetours();
}
diff --git a/UniversalPropertyReplacement/stdafx.cpp b/UniversalPropertyEnhancer/stdafx.cpp
similarity index 75%
rename from UniversalPropertyReplacement/stdafx.cpp
rename to UniversalPropertyEnhancer/stdafx.cpp
index 74caa47..a74dcb5 100644
--- a/UniversalPropertyReplacement/stdafx.cpp
+++ b/UniversalPropertyEnhancer/stdafx.cpp
@@ -1,9 +1,9 @@
/****************************************************************************
* Copyright (C) 2018 Zarklord
*
-* This file is part of UniversalPropertyReplacement.
+* This file is part of UniversalPropertyEnhancer.
*
-* UniversalPropertyReplacement is free software: you can redistribute it and/or modify
+* UniversalPropertyEnhancer is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
@@ -14,11 +14,11 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
-* along with UniversalPropertyReplacement. If not, see .
+* along with UniversalPropertyEnhancer. If not, see .
****************************************************************************/
// stdafx.cpp : source file that includes just the standard includes
-// UniversalPropertyReplacement.pch will be the pre-compiled header
+// UniversalPropertyEnhancer.pch will be the pre-compiled header
// stdafx.obj will contain the pre-compiled type information
#include "stdafx.h"
diff --git a/UniversalPropertyReplacement/stdafx.h b/UniversalPropertyEnhancer/stdafx.h
similarity index 83%
rename from UniversalPropertyReplacement/stdafx.h
rename to UniversalPropertyEnhancer/stdafx.h
index 5959e79..9df9e40 100644
--- a/UniversalPropertyReplacement/stdafx.h
+++ b/UniversalPropertyEnhancer/stdafx.h
@@ -1,9 +1,9 @@
/****************************************************************************
* Copyright (C) 2018 Zarklord
*
-* This file is part of UniversalPropertyReplacement.
+* This file is part of UniversalPropertyEnhancer.
*
-* UniversalPropertyReplacement is free software: you can redistribute it and/or modify
+* UniversalPropertyEnhancer is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
@@ -14,7 +14,7 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
-* along with UniversalPropertyReplacement. If not, see .
+* along with UniversalPropertyEnhancer. If not, see .
****************************************************************************/
// stdafx.h : include file for standard system include files,
diff --git a/UniversalPropertyReplacement/targetver.h b/UniversalPropertyEnhancer/targetver.h
similarity index 81%
rename from UniversalPropertyReplacement/targetver.h
rename to UniversalPropertyEnhancer/targetver.h
index be15128..3bbd5e9 100644
--- a/UniversalPropertyReplacement/targetver.h
+++ b/UniversalPropertyEnhancer/targetver.h
@@ -1,9 +1,9 @@
/****************************************************************************
* Copyright (C) 2018 Zarklord
*
-* This file is part of UniversalPropertyReplacement.
+* This file is part of UniversalPropertyEnhancer.
*
-* UniversalPropertyReplacement is free software: you can redistribute it and/or modify
+* UniversalPropertyEnhancer is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
@@ -14,7 +14,7 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
-* along with UniversalPropertyReplacement. If not, see .
+* along with UniversalPropertyEnhancer. If not, see .
****************************************************************************/
#pragma once