diff --git a/.gitignore b/.gitignore
index b942c2f42e..24af068c53 100644
--- a/.gitignore
+++ b/.gitignore
@@ -2,14 +2,14 @@
.vscode/
__pycache__
AssetProcessorTemp/**
-build/**
-Cache/**
+[Bb]uild/**
+[Cc]ache/
Editor/EditorEventLog.xml
Editor/EditorLayout.xml
Tools/**/*egg-info/**
Tools/**/*egg-link
UserSettings.xml
-user/Registry/**
+[Uu]ser/
FrameCapture/**
.DS_Store
user*.cfg
@@ -17,4 +17,4 @@ user*.cfg
_savebackup/
#Output folder for test results when running Automated Tests
TestResults/**
-*.swatches
\ No newline at end of file
+*.swatches
diff --git a/AssetProcessorPlatformConfig.setreg b/AssetProcessorPlatformConfig.setreg
index c075342b98..d3cf6d6272 100644
--- a/AssetProcessorPlatformConfig.setreg
+++ b/AssetProcessorPlatformConfig.setreg
@@ -22,7 +22,7 @@
"AssetProcessor": {
"Settings": {
"Platform pc": {
- "tags": "tools,renderer,dx12,vulkan"
+ "tags": "tools,renderer,dx12,vulkan,null"
},
"Platform es3": {
"tags": "android,mobile,renderer,vulkan"
@@ -31,7 +31,7 @@
"tags": "mobile,renderer,metal"
},
"Platform osx_gl": {
- "tags": "tools,renderer,metal"
+ "tags": "tools,renderer,metal,null"
},
// this is an example of a headless platform that has no renderer.
// To use this you would still need to make sure 'assetplatform' in your startup params in your main() chooses this 'server' platform as your server 'assets' flavor
@@ -104,7 +104,7 @@
"ScanFolder Game": {
"watch": "@PROJECTROOT@",
- "display": "@PROJECTROOT@",
+ "display": "@PROJECTNAME@",
"recursive": 1,
"order": 0
},
@@ -172,6 +172,9 @@
"Exclude Build": {
"pattern": ".*/[Bb]uild/.*"
},
+ "Exclude UserSettings": {
+ "pattern": ".*/UserSettings.xml"
+ },
// ------------------------------------------------------------------------------
// Large Worlds Test
diff --git a/AutomatedReview/Jenkinsfile b/AutomatedReview/Jenkinsfile
index 26e9c4b9b6..9ab7263945 100644
--- a/AutomatedReview/Jenkinsfile
+++ b/AutomatedReview/Jenkinsfile
@@ -16,6 +16,8 @@ INCREMENTAL_BUILD_SCRIPT_PATH = 'scripts/build/bootstrap/incremental_build_util.
EMPTY_JSON = readJSON text: '{}'
+ENGINE_REPOSITORY_NAME = env.DEFAULT_REPOSITORY_NAME
+
def pipelineProperties = []
def pipelineParameters = [
@@ -117,7 +119,7 @@ def RegexMatcher(str, regex) {
def LoadPipelineConfig(String pipelineName, String branchName, String scmType) {
echo 'Loading pipeline config'
if (scmType == 'codecommit') {
- PullFilesFromGit(PIPELINE_CONFIG_FILE, branchName)
+ PullFilesFromGit(PIPELINE_CONFIG_FILE, branchName, true, ENGINE_REPOSITORY_NAME)
}
def pipelineConfig = {}
pipelineConfig = readJSON file: PIPELINE_CONFIG_FILE
@@ -132,7 +134,7 @@ def LoadPipelineConfig(String pipelineName, String branchName, String scmType) {
}
echo "Downloading platform pipeline configs ${pipeline_config}"
if (scmType == 'codecommit') {
- PullFilesFromGit(pipeline_config, branchName)
+ PullFilesFromGit(pipeline_config, branchName, false, ENGINE_REPOSITORY_NAME)
}
echo "Searching platform pipeline configs in ${pipeline_config} using ${platform_regex}"
for (pipeline_config_path in findFiles(glob: pipeline_config)) {
@@ -154,7 +156,7 @@ def LoadPipelineConfig(String pipelineName, String branchName, String scmType) {
}
echo "Downloading configs ${build_config}"
if (scmType == 'codecommit') {
- PullFilesFromGit(build_config, branchName)
+ PullFilesFromGit(build_config, branchName, false, ENGINE_REPOSITORY_NAME)
}
echo "Searching configs in ${build_config} using ${platform_regex}"
for (build_config_path in findFiles(glob: build_config)) {
@@ -193,29 +195,14 @@ def GetBuildEnvVars(Map platformEnv, Map buildTypeEnv, String pipelineName) {
// This may override the above one if there is an entry defined by the job
envVarMap[var.key] = var.value
}
- return envVarMap
-}
+
+ // Environment that only applies to to Jenkins tweaks.
+ // For 3rdParty downloads, we store them in the EBS volume so we can reuse them across node
+ // instances. This allow us to scale up and down without having to re-download 3rdParty
+ envVarMap['LY_PACKAGE_DOWNLOAD_CACHE_LOCATION'] = "${envVarMap['WORKSPACE']}/3rdParty/downloaded_packages"
+ envVarMap['LY_PACKAGE_UNPACK_LOCATION'] = "${envVarMap['WORKSPACE']}/3rdParty/packages"
-def CheckoutBootstrapScripts(String branchName) {
- checkout([$class: "GitSCM",
- branches: [[name: "*/${branchName}"]],
- doGenerateSubmoduleConfigurations: false,
- extensions: [
- [
- $class: "SparseCheckoutPaths",
- sparseCheckoutPaths: [
- [ $class: "SparseCheckoutPath", path: "AutomatedReview/" ],
- [ $class: "SparseCheckoutPath", path: "scripts/build/bootstrap/" ],
- [ $class: "SparseCheckoutPath", path: "Tools/build/JenkinsScripts/build/Platform" ]
- ]
- ],
- [
- $class: "CloneOption", depth: 1, noTags: false, reference: "", shallow: true
- ]
- ],
- submoduleCfg: [],
- userRemoteConfigs: scm.userRemoteConfigs
- ])
+ return envVarMap
}
def GetEnvStringList(Map envVarMap) {
@@ -229,7 +216,7 @@ def GetEnvStringList(Map envVarMap) {
// Pulls/downloads files from the repo through codecommit. Despite Glob matching is NOT supported, '*' is supported
// as a folder or filename (not a portion, it has to be the whole folder or filename)
def PullFilesFromGit(String filenamePath, String branchName, boolean failIfNotFound = true, String repositoryName = env.DEFAULT_REPOSITORY_NAME) {
- echo "PullFilesFromGit filenamePath=${filenamePath} branchName=${branchName}"
+ echo "PullFilesFromGit filenamePath=${filenamePath} branchName=${branchName} repositoryName=${repositoryName}"
def folderPathParts = filenamePath.tokenize('/')
def filename = folderPathParts[folderPathParts.size()-1]
folderPathParts.remove(folderPathParts.size()-1) // remove the filename
@@ -320,18 +307,42 @@ def SetLfsCredentials(cmd, lbl = '') {
}
}
-def CheckoutRepo(boolean disableSubmodules = false) {
- palSh('git lfs uninstall', 'Git LFS Uninstall') // Prevent git from pulling lfs objects during checkout
+def CheckoutBootstrapScripts(String branchName) {
+ checkout([$class: "GitSCM",
+ branches: [[name: "*/${branchName}"]],
+ doGenerateSubmoduleConfigurations: false,
+ extensions: [
+ [
+ $class: "SparseCheckoutPaths",
+ sparseCheckoutPaths: [
+ [ $class: "SparseCheckoutPath", path: "AutomatedReview/" ],
+ [ $class: "SparseCheckoutPath", path: "scripts/build/bootstrap/" ],
+ [ $class: "SparseCheckoutPath", path: "Tools/build/JenkinsScripts/build/Platform" ]
+ ]
+ ],
+ [
+ $class: "CloneOption", depth: 1, noTags: false, reference: "", shallow: true
+ ]
+ ],
+ submoduleCfg: [],
+ userRemoteConfigs: scm.userRemoteConfigs
+ ])
+}
- if(fileExists('.git')) {
- // If the repository after checkout is locked, likely we took a snapshot while git was running,
- // to leave the repo in a usable state, garbagecollect. This also helps in situations where
- def indexLockFile = '.git/index.lock'
- if(fileExists(indexLockFile)) {
- palSh('git gc', 'Git GarbageCollect')
- }
- if(fileExists(indexLockFile)) { // if it is still there, remove it
- palRm(indexLockFile)
+def CheckoutRepo(boolean disableSubmodules = false) {
+ dir(ENGINE_REPOSITORY_NAME) {
+ palSh('git lfs uninstall', 'Git LFS Uninstall') // Prevent git from pulling lfs objects during checkout
+
+ if(fileExists('.git')) {
+ // If the repository after checkout is locked, likely we took a snapshot while git was running,
+ // to leave the repo in a usable state, garbagecollect. This also helps in situations where
+ def indexLockFile = '.git/index.lock'
+ if(fileExists(indexLockFile)) {
+ palSh('git gc', 'Git GarbageCollect')
+ }
+ if(fileExists(indexLockFile)) { // if it is still there, remove it
+ palRm(indexLockFile)
+ }
}
}
@@ -344,41 +355,52 @@ def CheckoutRepo(boolean disableSubmodules = false) {
retryAttempt = retryAttempt + 1
if(params.PULL_REQUEST_ID) {
// This is a pull request build. Perform merge with destination branch before building.
- checkout scm: [
- $class: 'GitSCM',
- branches: scm.branches,
- extensions: [
- [$class: 'PreBuildMerge', options: [mergeRemote: 'origin', mergeTarget: params.DESTINATION_BRANCH]],
- [$class: 'SubmoduleOption', disableSubmodules: disableSubmodules, recursiveSubmodules: true],
- [$class: 'CheckoutOption', timeout: 60]
- ],
- userRemoteConfigs: scm.userRemoteConfigs
- ]
+ dir(ENGINE_REPOSITORY_NAME) {
+ checkout scm: [
+ $class: 'GitSCM',
+ branches: scm.branches,
+ extensions: [
+ [$class: 'PreBuildMerge', options: [mergeRemote: 'origin', mergeTarget: params.DESTINATION_BRANCH]],
+ [$class: 'SubmoduleOption', disableSubmodules: disableSubmodules, recursiveSubmodules: true],
+ [$class: 'CheckoutOption', timeout: 60]
+ ],
+ userRemoteConfigs: scm.userRemoteConfigs
+ ]
+ }
} else {
- checkout scm: [
- $class: 'GitSCM',
- branches: scm.branches,
- extensions: [
- [$class: 'SubmoduleOption', disableSubmodules: disableSubmodules, recursiveSubmodules: true],
- [$class: 'CheckoutOption', timeout: 60]
- ],
- userRemoteConfigs: scm.userRemoteConfigs
- ]
+ dir(ENGINE_REPOSITORY_NAME) {
+ checkout scm: [
+ $class: 'GitSCM',
+ branches: scm.branches,
+ extensions: [
+ [$class: 'SubmoduleOption', disableSubmodules: disableSubmodules, recursiveSubmodules: true],
+ [$class: 'CheckoutOption', timeout: 60]
+ ],
+ userRemoteConfigs: scm.userRemoteConfigs
+ ]
+ }
}
}
- // Run lfs in a separate step. Jenkins is unable to load the credentials for the custom LFS endpoint
- withCredentials([usernamePassword(credentialsId: "${env.GITHUB_USER}", passwordVariable: 'accesstoken', usernameVariable: 'username')]) {
- SetLfsCredentials("git config -f .lfsconfig lfs.url https://${username}:${accesstoken}@${env.LFS_URL}", 'Set credentials')
- }
- palSh('git lfs install', 'Git LFS Install')
- palSh('git lfs pull', 'Git LFS Pull')
+ // Add folder where we will store the 3rdParty downloads and packages
+ if(!fileExists('3rdParty')) {
+ palMkdir('3rdParty')
+ }
- // CHANGE_ID is used by some scripts to identify uniquely the current change (usually metric jobs)
- palSh('git rev-parse HEAD > commitid', 'Getting commit id')
- env.CHANGE_ID = readFile file: 'commitid'
- env.CHANGE_ID = env.CHANGE_ID.trim()
- palRm('commitid')
+ dir(ENGINE_REPOSITORY_NAME) {
+ // Run lfs in a separate step. Jenkins is unable to load the credentials for the custom LFS endpoint
+ withCredentials([usernamePassword(credentialsId: "${env.GITHUB_USER}", passwordVariable: 'accesstoken', usernameVariable: 'username')]) {
+ SetLfsCredentials("git config -f .lfsconfig lfs.url https://${username}:${accesstoken}@${env.LFS_URL}", 'Set credentials')
+ }
+ palSh('git lfs install', 'Git LFS Install')
+ palSh('git lfs pull', 'Git LFS Pull')
+
+ // CHANGE_ID is used by some scripts to identify uniquely the current change (usually metric jobs)
+ palSh('git rev-parse HEAD > commitid', 'Getting commit id')
+ env.CHANGE_ID = readFile file: 'commitid'
+ env.CHANGE_ID = env.CHANGE_ID.trim()
+ palRm('commitid')
+ }
}
def PreBuildCommonSteps(String pipeline, String branchName, String platform, String buildType, String workspace, boolean mount = true, boolean disableSubmodules = false) {
@@ -409,7 +431,10 @@ def PreBuildCommonSteps(String pipeline, String branchName, String platform, Str
"""
}
}
- if(params.CLEAN_WORKSPACE) {
+
+ // Cleanup previous repo location, we are currently at the root of the workspace, if we have a .git folder
+ // we need to cleanup. Once all branches take this relocation, we can remove this
+ if(params.CLEAN_WORKSPACE || fileExists("${workspace}/.git")) {
if(fileExists(workspace)) {
palRmDir(workspace)
}
@@ -420,19 +445,21 @@ def PreBuildCommonSteps(String pipeline, String branchName, String platform, Str
CheckoutRepo(disableSubmodules)
// Get python
- if(env.IS_UNIX) {
+ dir(ENGINE_REPOSITORY_NAME) {
+ if(env.IS_UNIX) {
sh label: 'Getting python',
script: 'python/get_python.sh'
- } else {
- bat label: 'Getting python',
- script: 'python/get_python.bat'
+ } else {
+ bat label: 'Getting python',
+ script: 'python/get_python.bat'
+ }
}
}
}
def Build(Map options, String platform, String type, String workspace) {
def command = "${options.BUILD_ENTRY_POINT} --platform ${platform} --type ${type}"
- dir(workspace) {
+ dir("${workspace}/${ENGINE_REPOSITORY_NAME}") {
if (env.IS_UNIX) {
sh label: "Running ${platform} ${type}",
script: "${options.PYTHON_DIR}/python.sh -u ${command}"
@@ -445,8 +472,8 @@ def Build(Map options, String platform, String type, String workspace) {
def TestMetrics(Map options, String workspace, String branchName, String repoName, String buildJobName, String outputDirectory, String configuration) {
catchError(buildResult: null, stageResult: null) {
- def cmakeBuildDir = [workspace, outputDirectory].join('/')
- dir(workspace) {
+ def cmakeBuildDir = [workspace, ENGINE_REPOSITORY_NAME, outputDirectory].join('/')
+ dir("${workspace}/${ENGINE_REPOSITORY_NAME}") {
checkout scm: [
$class: 'GitSCM',
branches: [[name: '*/main']],
@@ -468,7 +495,7 @@ def PostBuildCommonSteps(String workspace, boolean mount = true) {
echo 'Starting post-build common steps...'
if(params.PULL_REQUEST_ID) {
- dir(workspace) {
+ dir("${workspace}/${ENGINE_REPOSITORY_NAME}") {
if(fileExists('.git')) {
palSh('git reset --hard HEAD', 'Discard PR merge, git reset')
}
@@ -565,7 +592,7 @@ try {
// Stash the INCREMENTAL_BUILD_SCRIPT_PATH since all nodes will use it
if (scmType == 'codecommit') {
- PullFilesFromGit(INCREMENTAL_BUILD_SCRIPT_PATH, branchName)
+ PullFilesFromGit(INCREMENTAL_BUILD_SCRIPT_PATH, branchName, true, ENGINE_REPOSITORY_NAME)
}
stash name: 'incremental_build_script',
includes: INCREMENTAL_BUILD_SCRIPT_PATH
@@ -612,12 +639,13 @@ try {
} else {
CreateBuildStage(pipelineConfig, platform.key, build_job.key, envVars).call()
}
+
if (env.MARS_REPO && platform.key == 'Windows' && build_job_name.startsWith('test')) {
def output_directory = platform.value.build_types[build_job_name].PARAMETERS.OUTPUT_DIRECTORY
def configuration = platform.value.build_types[build_job_name].PARAMETERS.CONFIGURATION
CreateTestMetricsStage(pipelineConfig, branchName, envVars, build_job_name, output_directory, configuration).call()
}
- }
+ }
catch(Exception e) {
// https://github.com/jenkinsci/jenkins/blob/master/core/src/main/java/hudson/model/Result.java
// {SUCCESS,UNSTABLE,FAILURE,NOT_BUILT,ABORTED}
diff --git a/AutomatedTesting/Gem/PythonTests/CMakeLists.txt b/AutomatedTesting/Gem/PythonTests/CMakeLists.txt
index a787fb84fa..19c6eb260e 100644
--- a/AutomatedTesting/Gem/PythonTests/CMakeLists.txt
+++ b/AutomatedTesting/Gem/PythonTests/CMakeLists.txt
@@ -21,7 +21,7 @@ add_subdirectory(assetpipeline)
if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS)
ly_add_pytest(
NAME AutomatedTesting::PhysicsTests
- TEST_SUITE main
+ TEST_SUITE sandbox
TEST_SERIAL
PATH ${CMAKE_CURRENT_LIST_DIR}/physics/TestSuite_Active.py
TIMEOUT 3600
diff --git a/AutomatedTesting/Gem/PythonTests/EditorPythonBindings/ComponentPropertyCommands_test_enum.py b/AutomatedTesting/Gem/PythonTests/EditorPythonBindings/ComponentPropertyCommands_test_enum.py
index 4fa9356b93..3d51444500 100755
--- a/AutomatedTesting/Gem/PythonTests/EditorPythonBindings/ComponentPropertyCommands_test_enum.py
+++ b/AutomatedTesting/Gem/PythonTests/EditorPythonBindings/ComponentPropertyCommands_test_enum.py
@@ -53,7 +53,7 @@ typeIdsList = editor.EditorComponentAPIBus(bus.Broadcast, 'FindComponentTypeIdsB
addComponentsOutcome = editor.EditorComponentAPIBus(bus.Broadcast, 'AddComponentsOfType', entityId, typeIdsList)
print_result("Components added to entity", addComponentsOutcome.IsSuccess())
-# fetch the Vegetation Distance Between Filter
+# fetch the Vegetation Distance Between Filter
vegDistTypeIdList = editor.EditorComponentAPIBus(bus.Broadcast, 'FindComponentTypeIdsByEntityType', ["Vegetation Distance Between Filter"], entity.EntityType().Game)
componentOutcome = editor.EditorComponentAPIBus(bus.Broadcast, 'GetComponentsOfType', entityId, vegDistTypeIdList[0])
print_result('Found Vegetation Distance Between Filter', componentOutcome.IsSuccess())
diff --git a/AutomatedTesting/Gem/PythonTests/automatedtesting_shared/hydra_test_utils.py b/AutomatedTesting/Gem/PythonTests/automatedtesting_shared/hydra_test_utils.py
index 2c88d5d1dc..caf109571e 100755
--- a/AutomatedTesting/Gem/PythonTests/automatedtesting_shared/hydra_test_utils.py
+++ b/AutomatedTesting/Gem/PythonTests/automatedtesting_shared/hydra_test_utils.py
@@ -52,8 +52,9 @@ def launch_and_validate_results(request, test_directory, editor, editor_script,
test_case = os.path.join(test_directory, editor_script)
request.addfinalizer(lambda: teardown_editor(editor))
logger.debug("Running automated test: {}".format(editor_script))
- editor.args.extend(["--skipWelcomeScreenDialog", "--regset=/Amazon/Settings/EnableSourceControl=false",
- run_python, test_case, "--runpythonargs", " ".join(cfg_args)])
+ editor.args.extend(["--skipWelcomeScreenDialog", "--regset=/Amazon/Settings/EnableSourceControl=false",
+ "--regset=/Amazon/Preferences/EnablePrefabSystem=false", run_python, test_case,
+ "--runpythonargs", " ".join(cfg_args)])
if auto_test_mode:
editor.args.extend(["--autotest_mode"])
if null_renderer:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C14195074_ScriptCanvas_PostUpdateEvent.py b/AutomatedTesting/Gem/PythonTests/physics/C14195074_ScriptCanvas_PostUpdateEvent.py
index 9f64f70fe0..4beca8845d 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C14195074_ScriptCanvas_PostUpdateEvent.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C14195074_ScriptCanvas_PostUpdateEvent.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
"""
# Test case ID : C14195074
-# Test Case Title : Verify Post Update Events
+# Test Case Title : Verify Postsimulate Events
# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/14195074
# fmt: off
@@ -29,7 +29,7 @@ class Tests:
def C14195074_ScriptCanvas_PostUpdateEvent():
"""
- Summary: Verifies that Post Update Event node in Script Canvas works as expected.
+ Summary: Verifies that Postsimulate Event node in Script Canvas works as expected.
Level Description:
Lead_Sphere - Directly next to Follow_sphere on the +x axis; has rigid body(gravity disabled), sphere shape
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C14902097_ScriptCanvas_PreUpdateEvent.py b/AutomatedTesting/Gem/PythonTests/physics/C14902097_ScriptCanvas_PreUpdateEvent.py
index 323bbb9318..4c9c7de263 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C14902097_ScriptCanvas_PreUpdateEvent.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C14902097_ScriptCanvas_PreUpdateEvent.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
"""
# Test case ID : C14902097
-# Test Case Title : Verify Pre Update Events
+# Test Case Title : Verify Presimulate Events
# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/14902097
# fmt: off
@@ -29,7 +29,7 @@ class Tests:
def C14902097_ScriptCanvas_PreUpdateEvent():
"""
- Summary: Verifies that Pre Update Event node in Script Canvas works as expected.
+ Summary: Verifies that Presimulate node in Script Canvas works as expected.
Level Description:
Lead_Sphere - Directly next to Follow_sphere on the +x axis; has rigid body (gravity disabled), sphere shape
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C14902098_ScriptCanvas_PostPhysicsUpdate.py b/AutomatedTesting/Gem/PythonTests/physics/C14902098_ScriptCanvas_PostPhysicsUpdate.py
index 44da1373b0..669ff3d84d 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C14902098_ScriptCanvas_PostPhysicsUpdate.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C14902098_ScriptCanvas_PostPhysicsUpdate.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C14902098
-# Test Case Title : Check that force region simulation with PostPhysicsUpdate works independently from rendering tick
+# Test Case Title : Check that force region simulation with Postsimulate works independently from rendering tick
# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/14902098
@@ -41,7 +41,7 @@ def C14902098_ScriptCanvas_PostPhysicsUpdate():
"""
Summary:
- Check that force region simulation with PostPhysicsUpdate works independently from rendering tick.
+ Check that force region simulation with Postsimulate works independently from rendering tick.
Level Description:
A Sphere is placed inside a Force Region. The "Fixed Time Step" in PhysX Configuration is set to 0.05.
@@ -49,7 +49,7 @@ def C14902098_ScriptCanvas_PostPhysicsUpdate():
Box Shape components
Sphere (entity) - Entity with PhysX Rigid Body, PhysX Collider, Mesh and 2 Script Canvas components
Script Canvas:
- onpostphysicsupdate - The script checks the position of the sphere on every On Post Physics Update event and prints
+ onpostphysicsupdate - The script checks the position of the sphere on every On Postsimulate event and prints
debug statements as per the position of the sphere relative to its previous position.
ontick - The script checks the position of the sphere on every On Tick event and prints
debug statements as per the position of the sphere relative to its previous position.
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C28978033_Ragdoll_WorldBodyBusTests.py b/AutomatedTesting/Gem/PythonTests/physics/C28978033_Ragdoll_WorldBodyBusTests.py
index f82e211525..9f595616e7 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C28978033_Ragdoll_WorldBodyBusTests.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C28978033_Ragdoll_WorldBodyBusTests.py
@@ -37,7 +37,7 @@ def C28978033_Ragdoll_WorldBodyBusTests():
- RayEnd: entity that points where to end the raycast_correct
| ( ) |
- o - - - | ¦ | - - > o
+ o - - - | | | - - > o
RayStart | / \ | RayEnd
TestRagdoll
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4044697_Material_PerfaceMaterialValidation.py b/AutomatedTesting/Gem/PythonTests/physics/C4044697_Material_PerfaceMaterialValidation.py
index 114be00012..9ae4122eef 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4044697_Material_PerfaceMaterialValidation.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4044697_Material_PerfaceMaterialValidation.py
@@ -253,7 +253,7 @@ def C4044697_Material_PerfaceMaterialValidation():
# 3) Create entity objects
sphere_0 = Entity("Sphere_0", math.Vector3(0.0, -10.0, 0.0), math.Vector3(0.0, 0.0, 0.0))
- sphere_1 = Entity("Sphere_1", math.Vector3(-10.0, 0.0, 0.0), math.Vector3(8.35, -0.71, 4.56))
+ sphere_1 = Entity("Sphere_1", math.Vector3(-10.0, 0.0, 0.0), math.Vector3(10.09, 1.85, 1.18))
sphere_2 = Entity("Sphere_2", math.Vector3(10.0, 0.0, 0.0), math.Vector3(-5.0, 0.0, 0.0))
perface_entity = Entity("Perface_Entity")
entity_list = [sphere_0, sphere_1, sphere_2, perface_entity]
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5959763_ForceRegion_ForceRegionImpulsesCube.py b/AutomatedTesting/Gem/PythonTests/physics/C5959763_ForceRegion_ForceRegionImpulsesCube.py
index f9a0687cc5..2b7bf49278 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5959763_ForceRegion_ForceRegionImpulsesCube.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5959763_ForceRegion_ForceRegionImpulsesCube.py
@@ -148,7 +148,7 @@ def C5959763_ForceRegion_ForceRegionImpulsesCube():
Report.failure(Tests.tests_completed)
else:
- # Did Force Region succeed. True if vector z ≈ 1 and force region magnitude ≈ magnitude applied on cube
+ # Did Force Region succeed. True if vector z is close to 1 and force region magnitude is close to magnitude applied on cube
force_region_result = (
ifVectorClose(RegionObject.force_vector.z, UPWARD_Z_VECTOR) and RegionObject.force_region_in_range()
)
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5959764_ForceRegion_ForceRegionImpulsesCapsule.py b/AutomatedTesting/Gem/PythonTests/physics/C5959764_ForceRegion_ForceRegionImpulsesCapsule.py
index 7ff62e7cb2..02bba2f848 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5959764_ForceRegion_ForceRegionImpulsesCapsule.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5959764_ForceRegion_ForceRegionImpulsesCapsule.py
@@ -148,7 +148,7 @@ def C5959764_ForceRegion_ForceRegionImpulsesCapsule():
Report.failure(Tests.tests_completed)
else:
- # Did Force Region succeed. True if vector z ≈ 1 and force region magnitude ≈ magnitude applied on Capsule
+ # Did Force Region succeed. True if vector z is close to 1 and force region magnitude is close to magnitude applied on Capsule
force_region_result = (
ifVectorClose(RegionObject.force_vector.z, UPWARD_Z_VECTOR) and RegionObject.force_region_in_range()
)
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5959765_ForceRegion_AssetGetsImpulsed.py b/AutomatedTesting/Gem/PythonTests/physics/C5959765_ForceRegion_AssetGetsImpulsed.py
index 8268440521..1afd7b4536 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5959765_ForceRegion_AssetGetsImpulsed.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5959765_ForceRegion_AssetGetsImpulsed.py
@@ -153,7 +153,7 @@ def C5959765_ForceRegion_AssetGetsImpulsed():
Report.failure(Tests.tests_completed)
else:
- # Did Force Region succeed. True if vector z ≈ 1 and force region magnitude ≈ magnitude applied on Asset
+ # Did Force Region succeed. True if vector z is close to 1 and force region magnitude is close to magnitude applied on Asset
force_region_result = (
ifVectorAxisClose(RegionObject.force_vector.z, UPWARD_Z_VECTOR) and RegionObject.force_region_in_range()
)
diff --git a/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Active.py b/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Active.py
index 23a892b29d..2b93dc4a6f 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Active.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Active.py
@@ -27,7 +27,7 @@ from base import TestAutomationBase
revert_physics_config = fm.file_revert_list(['physxdebugconfiguration.setreg', 'physxdefaultsceneconfiguration.setreg', 'physxsystemconfiguration.setreg'], 'AutomatedTesting/Registry')
-@pytest.mark.SUITE_main
+@pytest.mark.SUITE_sandbox
@pytest.mark.parametrize("launcher_platform", ['windows_editor'])
@pytest.mark.parametrize("project", ["AutomatedTesting"])
class TestAutomation(TestAutomationBase):
@@ -263,11 +263,6 @@ class TestAutomation(TestAutomationBase):
from . import C4976243_Collision_SameCollisionGroupDiffCollisionLayers as test_module
self._run_test(request, workspace, editor, test_module)
- @revert_physics_config
- def test_C6224408_ScriptCanvas_EntitySpawn(self, request, workspace, editor, launcher_platform):
- from . import C6224408_ScriptCanvas_EntitySpawn as test_module
- self._run_test(request, workspace, editor, test_module)
-
@revert_physics_config
def test_C12712455_ScriptCanvas_ShapeCastVerification(self, request, workspace, editor, launcher_platform):
from . import C12712455_ScriptCanvas_ShapeCastVerification as test_module
@@ -324,6 +319,10 @@ class TestAutomation(TestAutomationBase):
from . import C5968759_ForceRegion_ExertsSeveralForcesOnRigidBody as test_module
self._run_test(request, workspace, editor, test_module)
+ # Marking the test as an expected failure due to sporadic failure on Automated Review: LYN-2580
+ # The test still runs, but a failure of the test doesn't result in the test run failing
+ @pytest.mark.xfail(
+ reason="This test needs new physics asset with multiple materials to be more stable.")
@revert_physics_config
def test_C4044697_Material_PerfaceMaterialValidation(self, request, workspace, editor, launcher_platform):
from . import C4044697_Material_PerfaceMaterialValidation as test_module
@@ -402,9 +401,6 @@ class TestAutomation(TestAutomationBase):
from . import C4976244_Collider_SameGroupSameLayerCollision as test_module
self._run_test(request, workspace, editor, test_module)
- @pytest.mark.xfail(
- reason="This test seems to fail sometimes due to reliance on non-deterministic movement calculations."
- "Need to figure out the reason why this is the case")
@revert_physics_config
@fm.file_override('physxdefaultsceneconfiguration.setreg','C14195074_ScriptCanvas_PostUpdateEvent.setreg', 'AutomatedTesting/Registry')
def test_C14195074_ScriptCanvas_PostUpdateEvent(self, request, workspace, editor, launcher_platform):
@@ -428,9 +424,6 @@ class TestAutomation(TestAutomationBase):
from . import C3510644_Collider_CollisionGroups as test_module
self._run_test(request, workspace, editor, test_module)
- @pytest.mark.xfail(
- reason="This test seems to fail sometimes due to reliance on non-deterministic movement calculations."
- "Need to figure out the reason why this is the case")
@revert_physics_config
@fm.file_override('physxdefaultsceneconfiguration.setreg','C14902097_ScriptCanvas_PreUpdateEvent.setreg', 'AutomatedTesting/Registry')
def test_C14902097_ScriptCanvas_PreUpdateEvent(self, request, workspace, editor, launcher_platform):
diff --git a/AutomatedTesting/Levels/Physics/C12712452_ScriptCanvas_CollisionEvents/C12712452_ScriptCanvas_CollisionEvents.ly b/AutomatedTesting/Levels/Physics/C12712452_ScriptCanvas_CollisionEvents/C12712452_ScriptCanvas_CollisionEvents.ly
index 15986210b7..b34e483067 100644
--- a/AutomatedTesting/Levels/Physics/C12712452_ScriptCanvas_CollisionEvents/C12712452_ScriptCanvas_CollisionEvents.ly
+++ b/AutomatedTesting/Levels/Physics/C12712452_ScriptCanvas_CollisionEvents/C12712452_ScriptCanvas_CollisionEvents.ly
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:00f8a158fcfb667b060c902ed2129024f5041816e299c9cace2370f4ac60287d
-size 10762
+oid sha256:ec428aee9c49ffd58a00fdcbb0625185a22f5690f7b2e81326ef5443699019e6
+size 10945
diff --git a/AutomatedTesting/Levels/Physics/C12712452_ScriptCanvas_CollisionEvents/collision_events_script.scriptcanvas b/AutomatedTesting/Levels/Physics/C12712452_ScriptCanvas_CollisionEvents/collision_events_script.scriptcanvas
index 4cda3349c0..a422f072a5 100644
--- a/AutomatedTesting/Levels/Physics/C12712452_ScriptCanvas_CollisionEvents/collision_events_script.scriptcanvas
+++ b/AutomatedTesting/Levels/Physics/C12712452_ScriptCanvas_CollisionEvents/collision_events_script.scriptcanvas
@@ -3,7 +3,7 @@
-
+
@@ -16,21 +16,21 @@
-
+
-
+
-
+
-
+
-
+
@@ -39,9 +39,23 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
@@ -67,7 +81,7 @@
-
+
@@ -78,7 +92,7 @@
-
+
@@ -104,7 +118,7 @@
-
+
@@ -114,7 +128,7 @@
-
+
@@ -141,7 +155,7 @@
-
+
@@ -151,7 +165,7 @@
-
+
@@ -178,7 +192,7 @@
-
+
@@ -188,8 +202,8 @@
-
-
+
+
@@ -201,7 +215,7 @@
-
+
@@ -215,7 +229,81 @@
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
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+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -6347,7 +7310,7 @@
-
+
@@ -6367,7 +7330,7 @@
-
+
@@ -6381,99 +7344,27 @@
-
+
-
-
-
-
+
+
+
-
-
-
-
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -6484,22 +7375,10 @@
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -6507,83 +7386,41 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
-
+
-
-
-
+
+
+
+
-
-
-
+
+
+
+
@@ -6593,6 +7430,38 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -6602,41 +7471,17 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
diff --git a/AutomatedTesting/Levels/Physics/C12712452_ScriptCanvas_CollisionEvents/leveldata/TimeOfDay.xml b/AutomatedTesting/Levels/Physics/C12712452_ScriptCanvas_CollisionEvents/leveldata/TimeOfDay.xml
index 3a083a6882..6ea168cc6b 100644
--- a/AutomatedTesting/Levels/Physics/C12712452_ScriptCanvas_CollisionEvents/leveldata/TimeOfDay.xml
+++ b/AutomatedTesting/Levels/Physics/C12712452_ScriptCanvas_CollisionEvents/leveldata/TimeOfDay.xml
@@ -1,17 +1,17 @@
-
+
-
+
-
+
-
+
@@ -20,31 +20,31 @@
-
+
-
+
-
+
-
+
-
+
-
+
-
+
@@ -56,7 +56,7 @@
-
+
@@ -83,10 +83,10 @@
-
+
-
+
@@ -104,7 +104,7 @@
-
+
@@ -140,7 +140,7 @@
-
+
@@ -149,7 +149,7 @@
-
+
@@ -158,76 +158,76 @@
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
@@ -239,10 +239,10 @@
-
+
-
+
@@ -251,7 +251,7 @@
-
+
@@ -263,7 +263,7 @@
-
+
@@ -275,10 +275,10 @@
-
+
-
+
@@ -287,7 +287,7 @@
-
+
@@ -341,7 +341,7 @@
-
+
@@ -350,7 +350,7 @@
-
+
diff --git a/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/C12712455_ScriptCanvas_ShapeCastVerification.ly b/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/C12712455_ScriptCanvas_ShapeCastVerification.ly
index 5c93e231d5..5088b67628 100644
--- a/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/C12712455_ScriptCanvas_ShapeCastVerification.ly
+++ b/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/C12712455_ScriptCanvas_ShapeCastVerification.ly
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:f096ae6620bbb17e9a1c98f7f476f62762753e1359a1dfe84192ba3e052e6404
-size 10036
+oid sha256:6df3d83f5b9dd43118aba5cef3a8fe9ee42ee253f7bd3886fc7c88f41c504fff
+size 8802
diff --git a/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/filelist.xml b/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/filelist.xml
index 362bfb7b51..36bb23e8d4 100644
--- a/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/filelist.xml
+++ b/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/filelist.xml
@@ -1,6 +1,6 @@
-
+
diff --git a/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/level.pak b/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/level.pak
index 6945bded24..cc9a49f622 100644
--- a/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/level.pak
+++ b/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/level.pak
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:8cdc13062aba6712ebbcc2f32f49295cd1e872f7313a02994f8d06baf7765bd0
-size 39334
+oid sha256:625b55f2edc3e8eabeea7d87575119590fe7ed88db70a6125eb6bf9d891d743f
+size 39113
diff --git a/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/leveldata/TimeOfDay.xml b/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/leveldata/TimeOfDay.xml
index 456d609b8a..6ea168cc6b 100644
--- a/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/leveldata/TimeOfDay.xml
+++ b/AutomatedTesting/Levels/Physics/C12712455_ScriptCanvas_ShapeCastVerification/leveldata/TimeOfDay.xml
@@ -1,356 +1,356 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
-
+
+
-
+
-
+
-
-
+
+
-
-
+
+
-
-
+
+
-
+
-
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
+
-
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
+
-
+
-
-
+
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
-
+
+
-
-
+
+
-
-
+
+
-
+
-
+
-
-
+
+
-
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
-
+
+
-
+
-
+
-
+
-
-
+
+
-
-
+
+
-
+
-
+
-
-
+
+
-
+
-
-
+
+
-
+
-
-
+
+
-
+
-
+
-
+
-
-
+
+
-
-
+
+
-
+
-
+
-
-
+
+
-
-
+
+
-
-
+
+
-
+
-
-
+
+
-
+
-
-
+
+
-
+
-
-
+
+
-
+
-
-
+
+
-
+
-
+
-
+
-
-
+
+
-
+
-
-
+
+
-
+
-
-
+
+
-
+
-
+
-
-
+
+
diff --git a/AutomatedTesting/Levels/Physics/C14902098_ScriptCanvas_PostPhysicsUpdate/onpostphysicsupdate.scriptcanvas b/AutomatedTesting/Levels/Physics/C14902098_ScriptCanvas_PostPhysicsUpdate/onpostphysicsupdate.scriptcanvas
index e973421d1d..88e3333298 100644
--- a/AutomatedTesting/Levels/Physics/C14902098_ScriptCanvas_PostPhysicsUpdate/onpostphysicsupdate.scriptcanvas
+++ b/AutomatedTesting/Levels/Physics/C14902098_ScriptCanvas_PostPhysicsUpdate/onpostphysicsupdate.scriptcanvas
@@ -3,7 +3,7 @@
-
+
@@ -16,21 +16,1638 @@
-
+
-
+
-
+
-
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
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+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -3138,6 +3290,48 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -3158,9 +3352,22 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -3170,11 +3377,15 @@
-
+
-
+
+
+
+
+
@@ -3182,11 +3393,11 @@
-
+
-
+
@@ -3204,7 +3415,7 @@
-
+
diff --git a/AutomatedTesting/Levels/Physics/C4044697_Material_PerfaceMaterialValidation/C4044697_Material_PerfaceMaterialValidation.ly b/AutomatedTesting/Levels/Physics/C4044697_Material_PerfaceMaterialValidation/C4044697_Material_PerfaceMaterialValidation.ly
index 48958d519b..0de21e7ffa 100644
--- a/AutomatedTesting/Levels/Physics/C4044697_Material_PerfaceMaterialValidation/C4044697_Material_PerfaceMaterialValidation.ly
+++ b/AutomatedTesting/Levels/Physics/C4044697_Material_PerfaceMaterialValidation/C4044697_Material_PerfaceMaterialValidation.ly
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:c96e192861177f27edcd4dde87612645f328cb4d53ee31fb188cb75a0da7496b
-size 9974
+oid sha256:1f42344cdf0092eac6fc43bff66a2e0d9706511865da89490abfb2d054a1b5db
+size 9647
diff --git a/AutomatedTesting/Levels/Simple/Simple.cry b/AutomatedTesting/Levels/Simple/Simple.ly
similarity index 100%
rename from AutomatedTesting/Levels/Simple/Simple.cry
rename to AutomatedTesting/Levels/Simple/Simple.ly
diff --git a/AutomatedTesting/Registry/editorpreferences.setreg b/AutomatedTesting/Registry/editorpreferences.setreg
new file mode 100644
index 0000000000..b338d6acad
--- /dev/null
+++ b/AutomatedTesting/Registry/editorpreferences.setreg
@@ -0,0 +1,7 @@
+{
+ "Amazon": {
+ "Preferences": {
+ "EnablePrefabSystem": false
+ }
+ }
+}
\ No newline at end of file
diff --git a/AutomatedTesting/ScriptCanvas/C12712455_ScriptCanvas_ShapeCastVerification.scriptcanvas b/AutomatedTesting/ScriptCanvas/C12712455_ScriptCanvas_ShapeCastVerification.scriptcanvas
index 2383fb043f..ff9fe5c64c 100644
--- a/AutomatedTesting/ScriptCanvas/C12712455_ScriptCanvas_ShapeCastVerification.scriptcanvas
+++ b/AutomatedTesting/ScriptCanvas/C12712455_ScriptCanvas_ShapeCastVerification.scriptcanvas
@@ -3,7 +3,7 @@
-
+
@@ -16,1051 +16,7 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-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
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -2690,20 +2796,16 @@
-
-
-
-
-
+
-
+
@@ -2711,7 +2813,11 @@
-
+
+
+
+
+
diff --git a/AutomatedTesting/ScriptCanvas/C14195074_ScriptCanvas_PostUpdateEvent.scriptcanvas b/AutomatedTesting/ScriptCanvas/C14195074_ScriptCanvas_PostUpdateEvent.scriptcanvas
index 97c2213cc0..988184109a 100644
--- a/AutomatedTesting/ScriptCanvas/C14195074_ScriptCanvas_PostUpdateEvent.scriptcanvas
+++ b/AutomatedTesting/ScriptCanvas/C14195074_ScriptCanvas_PostUpdateEvent.scriptcanvas
@@ -3,7 +3,7 @@
-
+
@@ -16,7 +16,1334 @@
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
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+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -2063,6 +2263,15 @@
+
+
+
+
+
+
+
+
+
@@ -2074,12 +2283,20 @@
+
+
+
+
-
+
+
+
+
+
diff --git a/AutomatedTesting/ScriptCanvas/C14902097_ScriptCanvas_PreUpdateEvent.scriptcanvas b/AutomatedTesting/ScriptCanvas/C14902097_ScriptCanvas_PreUpdateEvent.scriptcanvas
index 9613504689..a5b927dfc1 100644
--- a/AutomatedTesting/ScriptCanvas/C14902097_ScriptCanvas_PreUpdateEvent.scriptcanvas
+++ b/AutomatedTesting/ScriptCanvas/C14902097_ScriptCanvas_PreUpdateEvent.scriptcanvas
@@ -3,7 +3,7 @@
-
+
@@ -16,7 +16,149 @@
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -232,7 +374,7 @@
-
+
@@ -602,12 +744,827 @@
-
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+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
@@ -1902,22 +2263,20 @@
-
+
-
-
-
-
+
+
+
-
-
-
-
+
+
+
@@ -1928,15 +2287,17 @@
-
-
-
+
+
+
+
-
-
-
+
+
+
+
@@ -1962,15 +2323,20 @@
+
+
+
+
+
+
+
+
+
-
-
-
-
-
+
@@ -1978,7 +2344,19 @@
-
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/AutomatedTesting/physicssurfaces/default_phys_materials.physmaterial b/AutomatedTesting/physicssurfaces/default_phys_materials.physmaterial
new file mode 100644
index 0000000000..3c39d5521e
--- /dev/null
+++ b/AutomatedTesting/physicssurfaces/default_phys_materials.physmaterial
@@ -0,0 +1,22 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 801aa0447c..dfc299e144 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -10,7 +10,7 @@
#
# Cmake version 3.17 is the minimum version needed for all of lumberyard's supported platforms
-cmake_minimum_required(VERSION 3.17)
+cmake_minimum_required(VERSION 3.19)
# CMP0111 introduced in 3.19 has a bug that produces the policy to warn every time there is an
# INTERFACE IMPORTED library. We use this type of libraries for handling 3rdParty. The rest of
diff --git a/Code/CryEngine/Cry3DEngine/3dEngine.h b/Code/CryEngine/Cry3DEngine/3dEngine.h
index 5cd6c20e10..a8e46c32ae 100644
--- a/Code/CryEngine/Cry3DEngine/3dEngine.h
+++ b/Code/CryEngine/Cry3DEngine/3dEngine.h
@@ -559,7 +559,7 @@ public:
virtual bool Init();
virtual void OnFrameStart();
virtual void Update();
- virtual void RenderWorld(const int nRenderFlags, const SRenderingPassInfo& passInfo, const char* szDebugName);
+ virtual void RenderWorld(int nRenderFlags, const SRenderingPassInfo& passInfo, const char* szDebugName);
virtual void PreWorldStreamUpdate(const CCamera& cam);
virtual void WorldStreamUpdate();
virtual void ShutDown();
@@ -570,7 +570,7 @@ public:
virtual void PostLoadLevel();
virtual bool InitLevelForEditor(const char* szFolderName, const char* szMissionName);
virtual bool LevelLoadingInProgress();
- virtual void DisplayInfo(float& fTextPosX, float& fTextPosY, float& fTextStepY, const bool bEnhanced);
+ virtual void DisplayInfo(float& fTextPosX, float& fTextPosY, float& fTextStepY, bool bEnhanced);
virtual void DisplayMemoryStatistics();
virtual void SetupDistanceFog();
virtual IStatObj* LoadStatObjUnsafeManualRef(const char* fileName, const char* geomName = nullptr, /*[Out]*/ IStatObj::SSubObject** subObject = nullptr,
@@ -893,7 +893,7 @@ public:
void UpdatePostRender(const SRenderingPassInfo& passInfo);
virtual void RenderScene(const int nRenderFlags, const SRenderingPassInfo& passInfo);
- virtual void RenderSceneReflection(const int nRenderFlags, const SRenderingPassInfo& passInfo);
+ virtual void RenderSceneReflection(int nRenderFlags, const SRenderingPassInfo& passInfo);
virtual void DebugDraw_UpdateDebugNode();
void DebugDraw_Draw();
diff --git a/Code/CryEngine/Cry3DEngine/3dEngineLoad.cpp b/Code/CryEngine/Cry3DEngine/3dEngineLoad.cpp
index a3cb04dea0..215fe602c9 100644
--- a/Code/CryEngine/Cry3DEngine/3dEngineLoad.cpp
+++ b/Code/CryEngine/Cry3DEngine/3dEngineLoad.cpp
@@ -38,7 +38,9 @@
#include
#include
#include
-#include "AzCore/Component/TickBus.h"
+
+#include
+#include
//------------------------------------------------------------------------------
#define LEVEL_DATA_FILE "LevelData.xml"
@@ -154,6 +156,9 @@ bool C3DEngine::InitLevelForEditor([[maybe_unused]] const char* szFolderName, [[
ClearDebugFPSInfo();
+ bool usePrefabSystemEnabled = false;
+ AzFramework::ApplicationRequests::Bus::BroadcastResult(
+ usePrefabSystemEnabled, &AzFramework::ApplicationRequests::IsPrefabSystemEnabled);
if (!szFolderName || !szFolderName[0])
{
@@ -161,7 +166,7 @@ bool C3DEngine::InitLevelForEditor([[maybe_unused]] const char* szFolderName, [[
return 0;
}
- if (!szMissionName || !szMissionName[0])
+ if (!usePrefabSystemEnabled && (!szMissionName || !szMissionName[0]))
{
Warning("C3DEngine::LoadLevel: Mission name is not specified");
}
@@ -248,6 +253,17 @@ bool C3DEngine::LevelLoadingInProgress()
bool C3DEngine::LoadCompiledOctreeForEditor()
{
+ bool usePrefabSystemForLevels = false;
+ AzFramework::ApplicationRequests::Bus::BroadcastResult(
+ usePrefabSystemForLevels, &AzFramework::ApplicationRequests::IsPrefabSystemForLevelsEnabled);
+
+ if (usePrefabSystemForLevels)
+ {
+ // Prefab levels don't use any of the legacy level data.
+ return true;
+ }
+
+
// Load LevelData.xml File.
XmlNodeRef xmlLevelData = GetSystem()->LoadXmlFromFile(GetLevelFilePath(LEVEL_DATA_FILE));
@@ -257,18 +273,8 @@ bool C3DEngine::LoadCompiledOctreeForEditor()
return false;
}
- std::vector* pStatObjTable = NULL;
- std::vector<_smart_ptr >* pMatTable = NULL;
-
- int nSID = 0;
-
- XmlNodeRef nodeRef = xmlLevelData->findChild("SurfaceTypes");
-
LoadCollisionClasses(xmlLevelData->findChild("CollisionClasses"));
- SAFE_DELETE(pStatObjTable);
- SAFE_DELETE(pMatTable);
-
return true;
}
@@ -617,6 +623,11 @@ bool C3DEngine::LoadLevel(const char* szFolderName, const char* szMissionName)
GetISystem()->LoadConfiguration(GetLevelFilePath(LEVEL_CONFIG_FILE));
}
+ bool usePrefabSystemForLevels = false;
+ AzFramework::ApplicationRequests::Bus::BroadcastResult(
+ usePrefabSystemForLevels, &AzFramework::ApplicationRequests::IsPrefabSystemForLevelsEnabled);
+
+ if (!usePrefabSystemForLevels)
{ // check is LevelData.xml file exist
char sMapFileName[_MAX_PATH];
cry_strcpy(sMapFileName, m_szLevelFolder);
@@ -659,12 +670,16 @@ bool C3DEngine::LoadLevel(const char* szFolderName, const char* szMissionName)
}
// Load LevelData.xml File.
- XmlNodeRef xmlLevelData = GetSystem()->LoadXmlFromFile(GetLevelFilePath(LEVEL_DATA_FILE));
-
- if (xmlLevelData == 0)
+ XmlNodeRef xmlLevelData;
+ if (!usePrefabSystemForLevels)
{
- Error("C3DEngine::LoadLevel: xml file not found (files missing?)"); // files missing ?
- return false;
+ xmlLevelData = GetSystem()->LoadXmlFromFile(GetLevelFilePath(LEVEL_DATA_FILE));
+
+ if (xmlLevelData == 0)
+ {
+ Error("C3DEngine::LoadLevel: xml file not found (files missing?)"); // files missing ?
+ return false;
+ }
}
// re-create decal manager
@@ -690,41 +705,48 @@ bool C3DEngine::LoadLevel(const char* szFolderName, const char* szMissionName)
m_pObjManager->PreloadLevelObjects();
}
- std::vector* pStatObjTable = NULL;
- std::vector<_smart_ptr >* pMatTable = NULL;
-
- int nSID = 0;
-
- // load terrain
- XmlNodeRef nodeRef = xmlLevelData->findChild("SurfaceTypes");
-
- LoadCollisionClasses(xmlLevelData->findChild("CollisionClasses"));
+ if (!usePrefabSystemForLevels)
+ {
+ LoadCollisionClasses(xmlLevelData->findChild("CollisionClasses"));
+ }
gEnv->pSystem->SetSystemGlobalState(ESYSTEM_GLOBAL_STATE_LEVEL_LOAD_START_STATIC_WORLD);
-#if defined(FEATURE_SVO_GI)
- if (gEnv->pConsole->GetCVar("e_GI")->GetIVal())
+ if (usePrefabSystemForLevels)
{
- // Load SVOGI settings
- char szFileName[256];
- azsprintf(szFileName, "mission_%s.xml", szMissionName);
- XmlNodeRef xmlMission = GetSystem()->LoadXmlFromFile(Get3DEngine()->GetLevelFilePath(szFileName));
- if (xmlMission)
- {
- LoadTISettings(xmlMission->findChild("Environment"));
- }
+ // When using the prefab system, just initialize a default manager instead of loading values from the indoor.dat file.
+ m_pVisAreaManager = new CVisAreaManager();
}
+ else
+ {
+#if defined(FEATURE_SVO_GI)
+ if (gEnv->pConsole->GetCVar("e_GI")->GetIVal())
+ {
+ // Load SVOGI settings
+ char szFileName[256];
+ azsprintf(szFileName, "mission_%s.xml", szMissionName);
+ XmlNodeRef xmlMission = GetSystem()->LoadXmlFromFile(Get3DEngine()->GetLevelFilePath(szFileName));
+ if (xmlMission)
+ {
+ LoadTISettings(xmlMission->findChild("Environment"));
+ }
+ }
#endif
- // load indoors
- if (!LoadVisAreas(&pStatObjTable, &pMatTable))
- {
- Error("VisAreas file (%s) not found or file version error, please try to re-export the level", COMPILED_VISAREA_MAP_FILE_NAME);
- return false;
+ // load indoors
+ std::vector* pStatObjTable = NULL;
+ std::vector<_smart_ptr>* pMatTable = NULL;
+
+ if (!LoadVisAreas(&pStatObjTable, &pMatTable))
+ {
+ Error("VisAreas file (%s) not found or file version error, please try to re-export the level", COMPILED_VISAREA_MAP_FILE_NAME);
+ return false;
+ }
+
+ SAFE_DELETE(pStatObjTable);
+ SAFE_DELETE(pMatTable);
}
- SAFE_DELETE(pStatObjTable);
- SAFE_DELETE(pMatTable);
//Update loading screen and important tick functions
SYNCHRONOUS_LOADING_TICK();
@@ -737,29 +759,37 @@ bool C3DEngine::LoadLevel(const char* szFolderName, const char* szMissionName)
// load leveldata.xml
m_pTerrainWaterMat = 0;
m_nWaterBottomTexId = 0;
+
+ // This call is needed whether or not the prefab system is used for levels. If prefabs are used, it will initialize the
+ // environment and time of day managers with default values. With legacy levels, they will intialize from the saved xml files.
LoadMissionDataFromXMLNode(szMissionName);
//Update loading screen and important tick functions
SYNCHRONOUS_LOADING_TICK();
-
- // init water if not initialized already (if no mission was found)
- if (!GetOcean())
+ if (!usePrefabSystemForLevels)
{
- PrintMessage("===== Creating Ocean =====");
- CreateOcean(m_pTerrainWaterMat, COcean::GetWaterLevelInfo());
- }
+ // init water if not initialized already (if no mission was found)
+ if (!GetOcean())
+ {
+ PrintMessage("===== Creating Ocean =====");
+ CreateOcean(m_pTerrainWaterMat, COcean::GetWaterLevelInfo());
+ }
- PrintMessage("===== Load level physics data =====");
- LoadFlaresData();
+ PrintMessage("===== Load level physics data =====");
+ LoadFlaresData();
+ }
// restore game state
EnableOceanRendering(true);
m_pObjManager->SetLockCGFResources(false);
- PrintMessage("===== loading occlusion mesh =====");
+ if (!usePrefabSystemForLevels)
+ {
+ PrintMessage("===== loading occlusion mesh =====");
- GetObjManager()->LoadOcclusionMesh(szFolderName);
+ GetObjManager()->LoadOcclusionMesh(szFolderName);
+ }
PrintMessage("===== Finished loading static world =====");
@@ -817,7 +847,9 @@ void C3DEngine::LoadMissionDataFromXMLNode(const char* szMissionName)
}
else
{
- Error("C3DEngine::LoadMissionDataFromXMLNode: Mission file not found: %s", szFileName);
+ // XML file couldn't be found, just use the defaults for everything.
+ LoadEnvironmentSettingsFromXML(nullptr, GetDefSID());
+ LoadTimeOfDaySettingsFromXML(nullptr);
}
}
else
@@ -832,10 +864,13 @@ char* C3DEngine::GetXMLAttribText(XmlNodeRef pInputNode, const char* szLevel1, c
cry_strcpy(szResText, szDefaultValue);
- XmlNodeRef nodeLevel = pInputNode->findChild(szLevel1);
- if (nodeLevel && nodeLevel->haveAttr(szLevel2))
+ if (pInputNode)
{
- cry_strcpy(szResText, nodeLevel->getAttr(szLevel2));
+ XmlNodeRef nodeLevel = pInputNode->findChild(szLevel1);
+ if (nodeLevel && nodeLevel->haveAttr(szLevel2))
+ {
+ cry_strcpy(szResText, nodeLevel->getAttr(szLevel2));
+ }
}
return szResText;
@@ -847,13 +882,16 @@ char* C3DEngine::GetXMLAttribText(XmlNodeRef pInputNode, const char* szLevel1, c
cry_strcpy(szResText, szDefaultValue);
- XmlNodeRef nodeLevel = pInputNode->findChild(szLevel1);
- if (nodeLevel)
+ if (pInputNode)
{
- nodeLevel = nodeLevel->findChild(szLevel2);
+ XmlNodeRef nodeLevel = pInputNode->findChild(szLevel1);
if (nodeLevel)
{
- cry_strcpy(szResText, nodeLevel->getAttr(szLevel3));
+ nodeLevel = nodeLevel->findChild(szLevel2);
+ if (nodeLevel)
+ {
+ cry_strcpy(szResText, nodeLevel->getAttr(szLevel3));
+ }
}
}
@@ -904,7 +942,7 @@ void C3DEngine::LoadEnvironmentSettingsFromXML(XmlNodeRef pInputNode, [[maybe_un
{
char moonTexture[256];
- cry_strcpy(moonTexture, GetXMLAttribText(pInputNode, "Moon", "Texture", ""));
+ cry_strcpy(moonTexture, GetXMLAttribText(pInputNode, "Moon", "Texture", "Textures/Skys/Night/half_moon.dds"));
ITexture* pTex(0);
if (moonTexture[0] != '\0')
@@ -923,14 +961,14 @@ void C3DEngine::LoadEnvironmentSettingsFromXML(XmlNodeRef pInputNode, [[maybe_un
m_volFogGlobalDensityMultiplierLDR = (float)max(atof(GetXMLAttribText(pInputNode, "Fog", "LDRGlobalDensMult", "1.0")), 0.0);
// SkyBox
- const string skyMaterialName = GetXMLAttribText(pInputNode, "SkyBox", "Material", "Materials/Sky/Sky");
- const string skyLowSpecMaterialName = GetXMLAttribText(pInputNode, "SkyBox", "MaterialLowSpec", "Materials/Sky/Sky");
+ const string skyMaterialName = GetXMLAttribText(pInputNode, "SkyBox", "Material", "EngineAssets/Materials/Sky/Sky");
+ const string skyLowSpecMaterialName = GetXMLAttribText(pInputNode, "SkyBox", "MaterialLowSpec", "EngineAssets/Materials/Sky/Sky");
SetSkyMaterialPath(skyMaterialName);
SetSkyLowSpecMaterialPath(skyLowSpecMaterialName);
LoadSkyMaterial();
m_fSkyBoxAngle = (float)atof(GetXMLAttribText(pInputNode, "SkyBox", "Angle", "0.0"));
- m_fSkyBoxStretching = (float)atof(GetXMLAttribText(pInputNode, "SkyBox", "Stretching", "1.0"));
+ m_fSkyBoxStretching = (float)atof(GetXMLAttribText(pInputNode, "SkyBox", "Stretching", "0.5"));
// set terrain water (aka the infinite ocean), sun road and bottom shaders
if (OceanToggle::IsActive())
diff --git a/Code/CryEngine/Cry3DEngine/Cry_LegacyPhysUtils.cpp b/Code/CryEngine/Cry3DEngine/Cry_LegacyPhysUtils.cpp
index 8919486095..7a85244397 100644
--- a/Code/CryEngine/Cry3DEngine/Cry_LegacyPhysUtils.cpp
+++ b/Code/CryEngine/Cry3DEngine/Cry_LegacyPhysUtils.cpp
@@ -37,7 +37,7 @@ namespace LegacyCryPhysicsUtils
strided_pointer pts = strided_pointer((Vec3mem*)_pts.data, _pts.iStride);
ptitem* pt, * ptmax, * ptdeleted, * ptlist = npts > sizeof(ptbuf) / sizeof(ptbuf[0]) ? new ptitem[npts] : ptbuf;
- qhtritem* tr, * trnext, * trend, * trnew, * trdata = trbuf, * trstart = 0, * trlast, * trbest;
+ qhtritem* tr, * trnext, * trend, * trnew, * trdata = trbuf, * trstart = 0, * trlast, * trbest = nullptr;
int i, j, k, ti, trdatasz = sizeof(trbuf) / sizeof(trbuf[0]), bidx[6], n, next_iter, delbuds;
qhtritem** tmparr_ptr = tmparr_ptr_buf;
int* tmparr_idx = tmparr_idx_buf, tmparr_sz = 512;
@@ -679,7 +679,7 @@ namespace LegacyCryPhysicsUtils
{
return 0;
}
- vtxthunk* pThunks, * pPrevThunk, * pContStart, ** pSags, ** pBottoms, * pPinnacle, * pBounds[2], * pPrevBounds[2], * ptr, * ptr_next;
+ vtxthunk* pThunks, * pPrevThunk, * pContStart, ** pSags, ** pBottoms, * pPinnacle = nullptr, * pBounds[2], * pPrevBounds[2], * ptr, * ptr_next;
vtxthunk bufThunks[32], * bufSags[16], * bufBottoms[16];
int i, nThunks, nBottoms = 0, nSags = 0, iBottom = 0, nConts = 0, j, isag, nThunks0, nTris = 0, nPrevSags, nTrisCnt, iter, nDegenTris = 0;
float ymax, ymin, e, area0 = 0, area1 = 0, cntarea, minCntArea;
diff --git a/Code/CryEngine/Cry3DEngine/ObjMan.cpp b/Code/CryEngine/Cry3DEngine/ObjMan.cpp
index fcee5a2946..f3d9a21fb5 100644
--- a/Code/CryEngine/Cry3DEngine/ObjMan.cpp
+++ b/Code/CryEngine/Cry3DEngine/ObjMan.cpp
@@ -281,46 +281,49 @@ void CObjManager::PreloadLevelObjects()
//////////////////////////////////////////////////////////////////////////
// Request objects loading from Streaming System.
- if (const char* pCgfName = pResList->GetFirst())
+ if (pResList)
{
- while (pCgfName)
+ if (const char* pCgfName = pResList->GetFirst())
{
- if (strstr(pCgfName, ".cgf"))
+ while (pCgfName)
{
- const char* sLodName = strstr(pCgfName, "_lod");
- if (sLodName && (sLodName[4] >= '0' && sLodName[4] <= '9'))
+ if (strstr(pCgfName, ".cgf"))
{
- // Ignore Lod files.
- pCgfName = pResList->GetNext();
- continue;
- }
-
- cgfFilename = pCgfName;
-
- if (bVerboseLogging)
- {
- CryLog("%s", cgfFilename.c_str());
- }
- IStatObj* pStatObj = GetObjManager()->LoadStatObjUnsafeManualRef(cgfFilename.c_str(), NULL, 0, true, 0);
- if (pStatObj)
- {
- if (pStatObj->IsMeshStrippedCGF())
+ const char* sLodName = strstr(pCgfName, "_lod");
+ if (sLodName && (sLodName[4] >= '0' && sLodName[4] <= '9'))
{
- nInLevelCacheCount++;
+ // Ignore Lod files.
+ pCgfName = pResList->GetNext();
+ continue;
}
+
+ cgfFilename = pCgfName;
+
+ if (bVerboseLogging)
+ {
+ CryLog("%s", cgfFilename.c_str());
+ }
+ IStatObj* pStatObj = GetObjManager()->LoadStatObjUnsafeManualRef(cgfFilename.c_str(), NULL, 0, true, 0);
+ if (pStatObj)
+ {
+ if (pStatObj->IsMeshStrippedCGF())
+ {
+ nInLevelCacheCount++;
+ }
+ }
+ // cgfStreamer.StartStreaming(cgfFilename.c_str());
+ nCgfCounter++;
+
+ // This loop can take a few seconds, so we should refresh the loading screen and call the loading tick functions to
+ // ensure that no big gaps in coverage occur.
+ SYNCHRONOUS_LOADING_TICK();
}
- //cgfStreamer.StartStreaming(cgfFilename.c_str());
- nCgfCounter++;
- //This loop can take a few seconds, so we should refresh the loading screen and call the loading tick functions to ensure that no big gaps in coverage occur.
- SYNCHRONOUS_LOADING_TICK();
+ pCgfName = pResList->GetNext();
}
-
- pCgfName = pResList->GetNext();
}
}
-
// PrintMessage("Finished requesting level CGF's: %d objects in %.1f sec", nCgfCounter, GetCurAsyncTimeSec()-fStartTime);
// Continue updating streaming system until all CGF's are loaded
diff --git a/Code/CryEngine/CryCommon/AnimKey.h b/Code/CryEngine/CryCommon/AnimKey.h
index 52bc636f67..ae7c3146f3 100644
--- a/Code/CryEngine/CryCommon/AnimKey.h
+++ b/Code/CryEngine/CryCommon/AnimKey.h
@@ -344,61 +344,18 @@ struct ICaptureKey
{
friend class AnimSerializer;
- enum CaptureBufferType
- {
- Color = 0,
- ColorWithAlpha,
- NumCaptureBufferTypes // keep this last
- };
- enum CaptureFileFormat
- {
- Jpg = 0,
- Tga,
- Tif,
- NumCaptureFileFormats // keep this last
- };
+ AZStd::string folder;
+ AZStd::string prefix;
float duration;
float timeStep;
- AZStd::string folder;
bool once;
- AZStd::string prefix;
- CaptureBufferType captureBufferIndex;
- const char* GetFormat() const
- { return format.c_str(); }
-
- void FormatJPG()
- { format = "jpg"; }
- void FormatTIF()
- { format = "tif"; }
- void FormatTGA()
- { format = "tga"; }
- void FormatHDR()
- {
- // deprecated
- if (gEnv->pLog)
- {
- gEnv->pLog->LogWarning("'hdr' capture format is deprecated.");
- }
- format = "hdr";
- }
- void FormatBMP()
- {
- // deprecated
- if (gEnv->pLog)
- {
- gEnv->pLog->LogWarning("'bmp' capture format is deprecated.");
- }
- format = "bmp";
- }
ICaptureKey()
: IKey()
- , duration(0)
+ , duration(0.0f)
, timeStep(0.033f)
, once(false)
- , captureBufferIndex(Color)
{
- FormatTGA();
ICVar* pCaptureFolderCVar = gEnv->pConsole->GetCVar("capture_folder");
if (pCaptureFolderCVar != NULL && pCaptureFolderCVar->GetString())
{
@@ -409,11 +366,6 @@ struct ICaptureKey
{
prefix = pCaptureFilePrefixCVar->GetString();
}
- ICVar* pCaptureFileFormatCVar = gEnv->pConsole->GetCVar("capture_file_format");
- if (pCaptureFileFormatCVar != NULL)
- {
- format = pCaptureFileFormatCVar->GetString();
- }
}
ICaptureKey(const ICaptureKey& other)
@@ -423,13 +375,8 @@ struct ICaptureKey
, duration(other.duration)
, timeStep(other.timeStep)
, once(other.once)
- , format(other.format)
- , captureBufferIndex(other.captureBufferIndex)
{
}
-
-private:
- AZStd::string format;
};
//! Boolean key.
diff --git a/Code/CryEngine/CryCommon/I3DEngine.h b/Code/CryEngine/CryCommon/I3DEngine.h
index 533c4bdfa3..a9c231c51a 100644
--- a/Code/CryEngine/CryCommon/I3DEngine.h
+++ b/Code/CryEngine/CryCommon/I3DEngine.h
@@ -1309,9 +1309,9 @@ struct I3DEngine
// SetCamera
// Arguments:
// szDebugName - name that can be visualized for debugging purpose, must not be 0
- virtual void RenderWorld(const int nRenderFlags, const SRenderingPassInfo& passInfo, const char* szDebugName) = 0;
+ virtual void RenderWorld(int nRenderFlags, const SRenderingPassInfo& passInfo, const char* szDebugName) = 0;
- virtual void RenderSceneReflection(const int nRenderFlags, const SRenderingPassInfo& passInfo) = 0;
+ virtual void RenderSceneReflection(int nRenderFlags, const SRenderingPassInfo& passInfo) = 0;
// Summary:
// Prepares for the world stream update, should be called before rendering
@@ -1816,7 +1816,7 @@ struct I3DEngine
// fTextPosY - Y position for the text
// fTextStepY - Amount of pixels to distance each line
// bEnhanced - false=normal, true=more interesting information
- virtual void DisplayInfo(float& fTextPosX, float& fTextPosY, float& fTextStepY, const bool bEnhanced) = 0;
+ virtual void DisplayInfo(float& fTextPosX, float& fTextPosY, float& fTextStepY, bool bEnhanced) = 0;
// Summary:
// Displays CPU and GPU memory usage statistics on screen
diff --git a/Code/CryEngine/CryCommon/IAudioSystem.h b/Code/CryEngine/CryCommon/IAudioSystem.h
index 0e68ae88d4..1e67d7c78d 100644
--- a/Code/CryEngine/CryCommon/IAudioSystem.h
+++ b/Code/CryEngine/CryCommon/IAudioSystem.h
@@ -844,21 +844,21 @@ namespace Audio
{
virtual ~IAudioProxy() = default;
- virtual void Initialize(const char* const sObjectName, const bool bInitAsync = true) = 0;
+ virtual void Initialize(const char* sObjectName, bool bInitAsync = true) = 0;
virtual void Release() = 0;
virtual void Reset() = 0;
virtual void ExecuteSourceTrigger(TAudioControlID nTriggerID, const SAudioSourceInfo& rSourceInfo, const SAudioCallBackInfos& rCallbackInfos = SAudioCallBackInfos::GetEmptyObject()) = 0;
- virtual void ExecuteTrigger(const TAudioControlID nTriggerID, const SAudioCallBackInfos& rCallbackInfos = SAudioCallBackInfos::GetEmptyObject()) = 0;
+ virtual void ExecuteTrigger(TAudioControlID nTriggerID, const SAudioCallBackInfos& rCallbackInfos = SAudioCallBackInfos::GetEmptyObject()) = 0;
virtual void StopAllTriggers() = 0;
- virtual void StopTrigger(const TAudioControlID nTriggerID) = 0;
- virtual void SetSwitchState(const TAudioControlID nSwitchID, const TAudioSwitchStateID nStateID) = 0;
- virtual void SetRtpcValue(const TAudioControlID nRtpcID, const float fValue) = 0;
- virtual void SetObstructionCalcType(const EAudioObjectObstructionCalcType eObstructionType) = 0;
+ virtual void StopTrigger(TAudioControlID nTriggerID) = 0;
+ virtual void SetSwitchState(TAudioControlID nSwitchID, TAudioSwitchStateID nStateID) = 0;
+ virtual void SetRtpcValue(TAudioControlID nRtpcID, float fValue) = 0;
+ virtual void SetObstructionCalcType(EAudioObjectObstructionCalcType eObstructionType) = 0;
virtual void SetPosition(const SATLWorldPosition& rPosition) = 0;
virtual void SetPosition(const AZ::Vector3& rPosition) = 0;
virtual void SetMultiplePositions(const MultiPositionParams& params) = 0;
- virtual void SetEnvironmentAmount(const TAudioEnvironmentID nEnvironmentID, const float fAmount) = 0;
+ virtual void SetEnvironmentAmount(TAudioEnvironmentID nEnvironmentID, float fAmount) = 0;
virtual void SetCurrentEnvironments() = 0;
virtual void ResetRtpcValues() = 0;
virtual TAudioObjectID GetAudioObjectID() const = 0;
@@ -907,37 +907,37 @@ namespace Audio
virtual void AddRequestListener(
AudioRequestCallbackType callBack,
- void* const objectToListenTo,
- const EAudioRequestType requestType = eART_AUDIO_ALL_REQUESTS,
- const TATLEnumFlagsType specificRequestMask = ALL_AUDIO_REQUEST_SPECIFIC_TYPE_FLAGS) = 0;
+ void* objectToListenTo,
+ EAudioRequestType requestType = eART_AUDIO_ALL_REQUESTS,
+ TATLEnumFlagsType specificRequestMask = ALL_AUDIO_REQUEST_SPECIFIC_TYPE_FLAGS) = 0;
virtual void RemoveRequestListener(
AudioRequestCallbackType callBack,
- void* const requestOwner) = 0;
+ void* requestOwner) = 0;
- virtual TAudioControlID GetAudioTriggerID(const char* const sAudioTriggerName) const = 0;
- virtual TAudioControlID GetAudioRtpcID(const char* const sAudioRtpcName) const = 0;
- virtual TAudioControlID GetAudioSwitchID(const char* const sAudioSwitchName) const = 0;
- virtual TAudioSwitchStateID GetAudioSwitchStateID(const TAudioControlID nSwitchID, const char* const sAudioSwitchStateName) const = 0;
- virtual TAudioPreloadRequestID GetAudioPreloadRequestID(const char* const sAudioPreloadRequestName) const = 0;
- virtual TAudioEnvironmentID GetAudioEnvironmentID(const char* const sAudioEnvironmentName) const = 0;
+ virtual TAudioControlID GetAudioTriggerID(const char* sAudioTriggerName) const = 0;
+ virtual TAudioControlID GetAudioRtpcID(const char* sAudioRtpcName) const = 0;
+ virtual TAudioControlID GetAudioSwitchID(const char* sAudioSwitchName) const = 0;
+ virtual TAudioSwitchStateID GetAudioSwitchStateID(TAudioControlID nSwitchID, const char* sAudioSwitchStateName) const = 0;
+ virtual TAudioPreloadRequestID GetAudioPreloadRequestID(const char* sAudioPreloadRequestName) const = 0;
+ virtual TAudioEnvironmentID GetAudioEnvironmentID(const char* sAudioEnvironmentName) const = 0;
virtual bool ReserveAudioListenerID(TAudioObjectID& rAudioObjectID) = 0;
- virtual bool ReleaseAudioListenerID(const TAudioObjectID nAudioObjectID) = 0;
- virtual bool SetAudioListenerOverrideID(const TAudioObjectID nAudioObjectID) = 0;
+ virtual bool ReleaseAudioListenerID(TAudioObjectID nAudioObjectID) = 0;
+ virtual bool SetAudioListenerOverrideID(TAudioObjectID nAudioObjectID) = 0;
virtual void GetInfo(SAudioSystemInfo& rAudioSystemInfo) = 0;
virtual const char* GetControlsPath() const = 0;
virtual void UpdateControlsPath() = 0;
- virtual void RefreshAudioSystem(const char* const levelName) = 0;
+ virtual void RefreshAudioSystem(const char* levelName) = 0;
virtual IAudioProxy* GetFreeAudioProxy() = 0;
- virtual void FreeAudioProxy(IAudioProxy* const pIAudioProxy) = 0;
+ virtual void FreeAudioProxy(IAudioProxy* pIAudioProxy) = 0;
virtual TAudioSourceId CreateAudioSource(const SAudioInputConfig& sourceConfig) = 0;
virtual void DestroyAudioSource(TAudioSourceId sourceId) = 0;
- virtual const char* GetAudioControlName(const EAudioControlType controlType, const TATLIDType atlID) const = 0;
- virtual const char* GetAudioSwitchStateName(const TAudioControlID switchID, const TAudioSwitchStateID stateID) const = 0;
+ virtual const char* GetAudioControlName(EAudioControlType controlType, TATLIDType atlID) const = 0;
+ virtual const char* GetAudioSwitchStateName(TAudioControlID switchID, TAudioSwitchStateID stateID) const = 0;
};
using AudioSystemRequestBus = AZ::EBus;
diff --git a/Code/CryEngine/CryCommon/IConsole.h b/Code/CryEngine/CryCommon/IConsole.h
index 2b04b51054..17ebd672d6 100644
--- a/Code/CryEngine/CryCommon/IConsole.h
+++ b/Code/CryEngine/CryCommon/IConsole.h
@@ -282,7 +282,7 @@ struct IConsole
// show/hide the console
// @param specifies if the window must be (true=show,false=hide)
// @param specifies iRequestScrollMax <=0 if not used, otherwise it sets SetScrollMax temporary to the given value
- virtual void ShowConsole(bool show, const int iRequestScrollMax = -1) = 0;
+ virtual void ShowConsole(bool show, int iRequestScrollMax = -1) = 0;
////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// Dump all console-variables to a callback-interface
// @param Callback callback-interface which needs to be called for each element
@@ -318,7 +318,7 @@ struct IConsole
// @param indwBufferSize 1.. size of the buffer
// @return true=line was returned, false=there are no more lines
- virtual bool GetLineNo(const int indwLineNo, char* outszBuffer, const int indwBufferSize) const = 0;
+ virtual bool GetLineNo(int indwLineNo, char* outszBuffer, int indwBufferSize) const = 0;
// @return current number of lines in the console
virtual int GetLineCount() const = 0;
@@ -408,7 +408,7 @@ struct IConsole
// bDeferExecution - true=the command is stored in special fifo that allows delayed execution
// by using wait_seconds and wait_frames commands
//
- virtual void ExecuteString(const char* command, const bool bSilentMode = false, const bool bDeferExecution = false) = 0;
+ virtual void ExecuteString(const char* command, bool bSilentMode = false, bool bDeferExecution = false) = 0;
////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// Print a message into the log and abort the execution of the application
@@ -489,7 +489,7 @@ struct IConsole
// \param bUpOrDown true=after pressed "up", false=after pressed "down"
// \return 0 if there is no history line or pointer to the null terminated history line
- virtual const char* GetHistoryElement(const bool bUpOrDown) = 0;
+ virtual const char* GetHistoryElement(bool bUpOrDown) = 0;
//! \param szCommand must not be 0
virtual void AddCommandToHistory(const char* szCommand) = 0;
@@ -602,11 +602,11 @@ struct ICVar
////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// set the float value of the variable
// @param s float representation the value
- virtual void Set(const float f) = 0;
+ virtual void Set(float f) = 0;
////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// set the float value of the variable
// @param s integer representation the value
- virtual void Set(const int i) = 0;
+ virtual void Set(int i) = 0;
////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// clear the specified bits in the flag field
virtual void ClearFlags (int flags) = 0;
@@ -659,7 +659,7 @@ struct ICVar
//////////////////////////////////////////////////////////////////////////
// Removes an on change functor
// returns true if removal was successful.
- virtual bool RemoveOnChangeFunctor(const uint64 nFunctorId) = 0;
+ virtual bool RemoveOnChangeFunctor(uint64 nFunctorId) = 0;
//////////////////////////////////////////////////////////////////////////
// Get the current callback function.
diff --git a/Code/CryEngine/CryCommon/ILevelSystem.h b/Code/CryEngine/CryCommon/ILevelSystem.h
index 74458277de..13d274b243 100644
--- a/Code/CryEngine/CryCommon/ILevelSystem.h
+++ b/Code/CryEngine/CryCommon/ILevelSystem.h
@@ -20,8 +20,8 @@
#include
#include
+#include
-struct ILevelRotationFile;
struct IConsoleCmdArgs;
namespace AZ::IO
@@ -29,212 +29,75 @@ namespace AZ::IO
struct IArchive;
}
-struct ILevelRotation
-{
- virtual ~ILevelRotation() {}
- typedef uint32 TExtInfoId;
-
- struct IExtendedInfo
- {
- };
-
-
- typedef uint8 TRandomisationFlags;
-
- enum EPlaylistRandomisationFlags
- {
- ePRF_None = 0,
- ePRF_Shuffle = 1 << 0,
- ePRF_MaintainPairs = 1 << 1,
- };
-
- virtual bool Load([[maybe_unused]] ILevelRotationFile* file) { return false; }
- virtual bool LoadFromXmlRootNode(const XmlNodeRef rootNode, [[maybe_unused]] const char* altRootTag) { return false; }
-
- virtual void Reset() {}
- virtual int AddLevel([[maybe_unused]] const char* level) { return 0; }
- virtual void AddGameMode([[maybe_unused]] int level, [[maybe_unused]] const char* gameMode) {}
-
- virtual int AddLevel([[maybe_unused]] const char* level, [[maybe_unused]] const char* gameMode) { return 0; }
-
-
- //call to set the playlist ready for a new session
- virtual void Initialise([[maybe_unused]] int nSeed) {}
-
- virtual bool First() { return false; }
- virtual bool Advance() { return false; }
- virtual bool AdvanceAndLoopIfNeeded() { return false; }
-
- virtual const char* GetNextLevel() const { return nullptr; }
- virtual const char* GetNextGameRules() const { return nullptr; }
- virtual int GetLength() const { return 0; }
- virtual int GetTotalGameModeEntries() const { return 0; }
- virtual int GetNext() const { return 0; }
-
- virtual const char* GetLevel([[maybe_unused]] uint32 idx, [[maybe_unused]] bool accessShuffled = true) const { return nullptr; }
- virtual int GetNGameRulesForEntry([[maybe_unused]] uint32 idx, [[maybe_unused]] bool accessShuffled = true) const { return 0; }
- virtual const char* GetGameRules([[maybe_unused]] uint32 idx, [[maybe_unused]] uint32 iMode, [[maybe_unused]] bool accessShuffled = true) const { return nullptr; }
-
- virtual const char* GetNextGameRulesForEntry([[maybe_unused]] int idx) const { return nullptr; }
-
- virtual const int NumAdvancesTaken() const { return 0; }
- virtual void ResetAdvancement() {}
-
- virtual bool IsRandom() const { return false; }
-
- virtual ILevelRotation::TRandomisationFlags GetRandomisationFlags() const { return ePRF_None; }
- virtual void SetRandomisationFlags([[maybe_unused]] TRandomisationFlags flags) {}
-
- virtual void ChangeLevel([[maybe_unused]] IConsoleCmdArgs* pArgs = NULL) {}
-
- virtual bool NextPairMatch() const { return false; }
-};
-
-
+// [LYN-2376] Remove once legacy slice support is removed
struct ILevelInfo
{
- virtual ~ILevelInfo() {}
- typedef std::vector TStringVec;
-
- struct TGameTypeInfo
- {
- string name;
- string xmlFile;
- int cgfCount;
- void GetMemoryUsage(ICrySizer* pSizer) const
- {
- pSizer->AddObject(name);
- pSizer->AddObject(xmlFile);
- }
- };
-
- struct SMinimapInfo
- {
- SMinimapInfo()
- : fStartX(0)
- , fStartY(0)
- , fEndX(1)
- , fEndY(1)
- , fDimX(1)
- , fDimY(1)
- , iWidth(1024)
- , iHeight(1024) {}
-
- string sMinimapName;
- int iWidth;
- int iHeight;
- float fStartX;
- float fStartY;
- float fEndX;
- float fEndY;
- float fDimX;
- float fDimY;
- };
+ virtual ~ILevelInfo() = default;
virtual const char* GetName() const = 0;
- virtual const bool IsOfType(const char* sType) const = 0;
virtual const char* GetPath() const = 0;
- virtual const char* GetPaks() const = 0;
- virtual const char* GetDisplayName() const = 0;
- virtual const char* GetPreviewImagePath() const = 0;
- virtual const char* GetBackgroundImagePath() const = 0;
- virtual const char* GetMinimapImagePath() const = 0;
- //virtual const ILevelInfo::TStringVec& GetMusicLibs() const = 0; // Gets reintroduced when level specific music data loading is implemented.
- virtual const bool MetadataLoaded() const = 0;
- virtual bool GetIsModLevel() const = 0;
- virtual const uint32 GetScanTag() const = 0;
- virtual const uint32 GetLevelTag() const = 0;
-
- virtual int GetGameTypeCount() const = 0;
- virtual const ILevelInfo::TGameTypeInfo* GetGameType(int gameType) const = 0;
- virtual bool SupportsGameType(const char* gameTypeName) const = 0;
- virtual const ILevelInfo::TGameTypeInfo* GetDefaultGameType() const = 0;
- virtual ILevelInfo::TStringVec GetGameRules() const = 0;
- virtual bool HasGameRules() const = 0;
-
- virtual const ILevelInfo::SMinimapInfo& GetMinimapInfo() const = 0;
-
- virtual const char* GetDefaultGameRules() const = 0;
+ virtual const char* GetAssetName() const = 0;
};
-struct ILevel
-{
- virtual ~ILevel() {}
- virtual void Release() = 0;
- virtual ILevelInfo* GetLevelInfo() = 0;
-};
-
/*!
* Extend this class and call ILevelSystem::AddListener() to receive level system related events.
*/
struct ILevelSystemListener
{
- virtual ~ILevelSystemListener() {}
+ virtual ~ILevelSystemListener() = default;
//! Called when loading a level fails due to it not being found.
virtual void OnLevelNotFound([[maybe_unused]] const char* levelName) {}
//! Called after ILevelSystem::PrepareNextLevel() completes.
- virtual void OnPrepareNextLevel([[maybe_unused]] ILevelInfo* pLevel) {}
+ virtual void OnPrepareNextLevel([[maybe_unused]] const char* levelName) {}
//! Called after ILevelSystem::OnLoadingStart() completes, before the level actually starts loading.
- virtual void OnLoadingStart([[maybe_unused]] ILevelInfo* pLevel) {}
+ virtual void OnLoadingStart([[maybe_unused]] const char* levelName) {}
//! Called after the level finished
- virtual void OnLoadingComplete([[maybe_unused]] ILevel* pLevel) {}
+ virtual void OnLoadingComplete([[maybe_unused]] const char* levelName) {}
//! Called when there's an error loading a level, with the level info and a description of the error.
- virtual void OnLoadingError([[maybe_unused]] ILevelInfo* pLevel, [[maybe_unused]] const char* error) {}
+ virtual void OnLoadingError([[maybe_unused]] const char* levelName, [[maybe_unused]] const char* error) {}
//! Called whenever the loading status of a level changes. progressAmount goes from 0->100.
- virtual void OnLoadingProgress([[maybe_unused]] ILevelInfo* pLevel, [[maybe_unused]] int progressAmount) {}
+ virtual void OnLoadingProgress([[maybe_unused]] const char* levelName, [[maybe_unused]] int progressAmount) {}
//! Called after a level is unloaded, before the data is freed.
- virtual void OnUnloadComplete([[maybe_unused]] ILevel* pLevel) {}
+ virtual void OnUnloadComplete([[maybe_unused]] const char* levelName) {}
void GetMemoryUsage([[maybe_unused]] ICrySizer* pSizer) const { }
};
struct ILevelSystem
- : public ILevelSystemListener
{
- enum
- {
- TAG_MAIN = 'MAIN',
- TAG_UNKNOWN = 'ZZZZ'
- };
-
- static constexpr char LevelsDirectoryName[] = "levels";
- static constexpr char LevelPakName[] = "level.pak";
+ virtual ~ILevelSystem() = default;
virtual void Release() = 0;
- virtual void Rescan(const char* levelsFolder, const uint32 tag) = 0;
- virtual void ScanFolder(const char* subfolder, bool modFolder, const uint32 tag) = 0;
- virtual void PopulateLevels(string searchPattern, string& folder, AZ::IO::IArchive* pPak, bool& modFolder, const uint32& tag, bool fromFileSystemOnly) = 0;
- virtual void LoadRotation() {}
- virtual int GetLevelCount() = 0;
- virtual DynArray* GetLevelTypeList() = 0;
- virtual ILevelInfo* GetLevelInfo(int level) = 0;
- virtual ILevelInfo* GetLevelInfo(const char* levelName) = 0;
virtual void AddListener(ILevelSystemListener* pListener) = 0;
virtual void RemoveListener(ILevelSystemListener* pListener) = 0;
- virtual ILevel* GetCurrentLevel() const = 0;
- virtual ILevel* LoadLevel(const char* levelName) = 0;
- virtual void UnLoadLevel() = 0;
- virtual ILevel* SetEditorLoadedLevel(const char* levelName, bool bReadLevelInfoMetaData = false) = 0;
+ virtual bool LoadLevel(const char* levelName) = 0;
+ virtual void UnloadLevel() = 0;
virtual bool IsLevelLoaded() = 0;
- virtual void PrepareNextLevel(const char* levelName) = 0;
-
- virtual ILevelRotation* GetLevelRotation() { return nullptr; }
-
- virtual ILevelRotation* FindLevelRotationForExtInfoId([[maybe_unused]] const ILevelRotation::TExtInfoId findId) { return nullptr; }
-
- virtual bool AddExtendedLevelRotationFromXmlRootNode(const XmlNodeRef rootNode, [[maybe_unused]] const char* altRootTag, [[maybe_unused]] const ILevelRotation::TExtInfoId extInfoId) { return false; }
- virtual void ClearExtendedLevelRotations() {}
- virtual ILevelRotation* CreateNewRotation([[maybe_unused]] const ILevelRotation::TExtInfoId id) { return nullptr; }
-
- // Retrieve`s last level level loading time.
- virtual float GetLastLevelLoadTime() = 0;
+ virtual const char* GetCurrentLevelName() const = 0;
// If the level load failed then we need to have a different shutdown procedure vs when a level is naturally unloaded
virtual void SetLevelLoadFailed(bool loadFailed) = 0;
virtual bool GetLevelLoadFailed() = 0;
+
+ virtual AZ::Data::AssetType GetLevelAssetType() const = 0;
+
+ static const char* GetLevelsDirectoryName()
+ {
+ return LevelsDirectoryName;
+ }
+
+ // [LYN-2376] Deprecated methods, to be removed once slices are removed:
+ virtual void Rescan(const char* levelsFolder) = 0;
+ virtual int GetLevelCount() = 0;
+ virtual ILevelInfo* GetLevelInfo(int level) = 0;
+ virtual ILevelInfo* GetLevelInfo(const char* levelName) = 0;
+
+protected:
+
+ static constexpr const char* LevelsDirectoryName = "levels";
};
#endif // CRYINCLUDE_CRYACTION_ILEVELSYSTEM_H
diff --git a/Code/CryEngine/CryCommon/IMiniLog.h b/Code/CryEngine/CryCommon/IMiniLog.h
index 57cde63c66..ca494430eb 100644
--- a/Code/CryEngine/CryCommon/IMiniLog.h
+++ b/Code/CryEngine/CryCommon/IMiniLog.h
@@ -40,9 +40,9 @@ struct IMiniLog
//
// Notes:
// You only have to implement this function.
- virtual void LogV (const ELogType nType, const char* szFormat, va_list args) PRINTF_PARAMS(3, 0) = 0;
+ virtual void LogV(ELogType nType, const char* szFormat, va_list args) PRINTF_PARAMS(3, 0) = 0;
- virtual void LogV (const ELogType nType, int flags, const char* szFormat, va_list args) PRINTF_PARAMS(4, 0) = 0;
+ virtual void LogV(ELogType nType, int flags, const char* szFormat, va_list args) PRINTF_PARAMS(4, 0) = 0;
// Summary:
// Logs using type.
@@ -123,8 +123,8 @@ struct CNullMiniLog
// The default implementation just won't do anything
//##@{
void LogV([[maybe_unused]] const char* szFormat, [[maybe_unused]] va_list args) {}
- void LogV([[maybe_unused]] const ELogType nType, [[maybe_unused]] const char* szFormat, [[maybe_unused]] va_list args) {}
- void LogV ([[maybe_unused]] const ELogType nType, [[maybe_unused]] int flags, [[maybe_unused]] const char* szFormat, [[maybe_unused]] va_list args) {}
+ void LogV([[maybe_unused]] ELogType nType, [[maybe_unused]] const char* szFormat, [[maybe_unused]] va_list args) {}
+ void LogV ([[maybe_unused]] ELogType nType, [[maybe_unused]] int flags, [[maybe_unused]] const char* szFormat, [[maybe_unused]] va_list args) {}
//##@}
};
diff --git a/Code/CryEngine/CryCommon/IProcess.h b/Code/CryEngine/CryCommon/IProcess.h
index aa1c063f55..bade01ccf5 100644
--- a/Code/CryEngine/CryCommon/IProcess.h
+++ b/Code/CryEngine/CryCommon/IProcess.h
@@ -29,7 +29,7 @@ struct IProcess
virtual ~IProcess(){}
virtual bool Init() = 0;
virtual void Update() = 0;
- virtual void RenderWorld(const int nRenderFlags, const SRenderingPassInfo& passInfo, const char* szDebugName) = 0;
+ virtual void RenderWorld(int nRenderFlags, const SRenderingPassInfo& passInfo, const char* szDebugName) = 0;
virtual void ShutDown() = 0;
virtual void SetFlags(int flags) = 0;
virtual int GetFlags(void) = 0;
diff --git a/Code/CryEngine/CryCommon/IRenderer.h b/Code/CryEngine/CryCommon/IRenderer.h
index e3b20e9fa3..01c2b2149d 100644
--- a/Code/CryEngine/CryCommon/IRenderer.h
+++ b/Code/CryEngine/CryCommon/IRenderer.h
@@ -1119,8 +1119,8 @@ struct IRenderer
//Sums DIP counts for the EFSLIST_* passes that match the submitted mask.
//Compose the mask with bitwise arithmetic, use (1 << EFSLIST_*) per list.
//e.g. to sum general and transparent, pass in ( (1 << EFSLIST_GENERAL) | (1 << EFSLIST_TRANSP) )
- virtual int GetCurrentNumberOfDrawCalls(const uint32 EFSListMask) const = 0;
- virtual float GetCurrentDrawCallRTTimes(const uint32 EFSListMask) const = 0;
+ virtual int GetCurrentNumberOfDrawCalls(uint32 EFSListMask) const = 0;
+ virtual float GetCurrentDrawCallRTTimes(uint32 EFSListMask) const = 0;
virtual void SetDebugRenderNode(IRenderNode* pRenderNode) = 0;
virtual bool IsDebugRenderNode(IRenderNode* pRenderNode) const = 0;
@@ -1211,7 +1211,7 @@ struct IRenderer
// Summary:
// Draws user primitives.
- virtual void DrawDynVB(SVF_P3F_C4B_T2F* pBuf, uint16* pInds, int nVerts, int nInds, const PublicRenderPrimitiveType nPrimType) = 0;
+ virtual void DrawDynVB(SVF_P3F_C4B_T2F* pBuf, uint16* pInds, int nVerts, int nInds, PublicRenderPrimitiveType nPrimType) = 0;
struct DynUiPrimitive : public AZStd::intrusive_slist_node
{
@@ -1242,7 +1242,7 @@ struct IRenderer
// Summary:
// Sets delta gamma.
- virtual bool SetGammaDelta(const float fGamma) = 0;
+ virtual bool SetGammaDelta(float fGamma) = 0;
// Summary:
// Restores gamma
@@ -1442,7 +1442,7 @@ struct IRenderer
virtual void FontRestoreRenderingState(bool overrideViewProjMatrices, const TransformationMatrices& restoringMatrices) = 0;
virtual bool FlushRTCommands(bool bWait, bool bImmediatelly, bool bForce) = 0;
- virtual void DrawStringU(IFFont_RenderProxy* pFont, float x, float y, float z, const char* pStr, const bool asciiMultiLine, const STextDrawContext& ctx) const = 0;
+ virtual void DrawStringU(IFFont_RenderProxy* pFont, float x, float y, float z, const char* pStr, bool asciiMultiLine, const STextDrawContext& ctx) const = 0;
virtual int RT_CurThreadList() = 0;
@@ -1522,8 +1522,8 @@ struct IRenderer
virtual ITexture* EF_GetTextureByName(const char* name, uint32 flags = 0) = 0;
// Summary:
// Loads the texture for name(nameTex).
- virtual ITexture* EF_LoadTexture(const char* nameTex, const uint32 flags = 0) = 0;
- virtual ITexture* EF_LoadCubemapTexture(const char* nameTex, const uint32 flags = 0) = 0;
+ virtual ITexture* EF_LoadTexture(const char* nameTex, uint32 flags = 0) = 0;
+ virtual ITexture* EF_LoadCubemapTexture(const char* nameTex, uint32 flags = 0) = 0;
// Summary:
// Loads default texture whose life cycle is managed by Texture Manager, do not try to release them by yourself!
virtual ITexture* EF_LoadDefaultTexture(const char* nameTex) = 0;
@@ -1556,9 +1556,9 @@ struct IRenderer
virtual void EF_AddEf (IRenderElement* pRE, SShaderItem& pSH, CRenderObject* pObj, const SRenderingPassInfo& passInfo, int nList, int nAW, const SRendItemSorter& rendItemSorter) = 0;
//! Draw all shaded REs in the list
- virtual void EF_EndEf3D (const int nFlags, const int nPrecacheUpdateId, const int nNearPrecacheUpdateId, const SRenderingPassInfo& passInfo) = 0;
+ virtual void EF_EndEf3D (int nFlags, int nPrecacheUpdateId, int nNearPrecacheUpdateId, const SRenderingPassInfo& passInfo) = 0;
- virtual void EF_InvokeShadowMapRenderJobs(const int nFlags) = 0;
+ virtual void EF_InvokeShadowMapRenderJobs(int nFlags) = 0;
// Dynamic lights
void EF_ClearLightsList() {}; // For FC Compatibility.
@@ -1570,9 +1570,9 @@ struct IRenderer
// Deferred lights/vis areas
virtual int EF_AddDeferredLight(const CDLight& pLight, float fMult, const SRenderingPassInfo& passInfo, const SRendItemSorter& rendItemSorter) = 0;
- virtual uint32 EF_GetDeferredLightsNum(const eDeferredLightType eLightType = eDLT_DeferredLight) = 0;
+ virtual uint32 EF_GetDeferredLightsNum(eDeferredLightType eLightType = eDLT_DeferredLight) = 0;
virtual void EF_ClearDeferredLightsList() = 0;
- virtual TArray* EF_GetDeferredLights(const SRenderingPassInfo& passInfo, const eDeferredLightType eLightType = eDLT_DeferredLight) = 0;
+ virtual TArray* EF_GetDeferredLights(const SRenderingPassInfo& passInfo, eDeferredLightType eLightType = eDLT_DeferredLight) = 0;
virtual uint8 EF_AddDeferredClipVolume(const IClipVolume* pClipVolume) = 0;
virtual bool EF_SetDeferredClipVolumeBlendData(const IClipVolume* pClipVolume, const SClipVolumeBlendInfo& blendInfo) = 0;
@@ -1605,13 +1605,13 @@ struct IRenderer
//////////////////////////////////////////////////////////////////////////
- virtual void EF_AddWaterSimHit(const Vec3& vPos, const float scale, const float strength) = 0;
+ virtual void EF_AddWaterSimHit(const Vec3& vPos, float scale, float strength) = 0;
virtual void EF_DrawWaterSimHits() = 0;
/////////////////////////////////////////////////////////////////////////////////
// 2d interface for the shaders
/////////////////////////////////////////////////////////////////////////////////
- virtual void EF_EndEf2D(const bool bSort) = 0;
+ virtual void EF_EndEf2D(bool bSort) = 0;
// Summary:
// Returns various Renderer Settings, see ERenderQueryTypes.
@@ -1771,7 +1771,7 @@ struct IRenderer
virtual void UpdateTextureInVideoMemory(uint32 tnum, const byte* newdata, int posx, int posy, int w, int h, ETEX_Format eTFSrc = eTF_B8G8R8, int posz = 0, int sizez = 1) = 0;
virtual bool DXTCompress(const byte* raw_data, int nWidth, int nHeight, ETEX_Format eTF, bool bUseHW, bool bGenMips, int nSrcBytesPerPix, MIPDXTcallback callback) = 0;
- virtual bool DXTDecompress(const byte* srcData, const size_t srcFileSize, byte* dstData, int nWidth, int nHeight, int nMips, ETEX_Format eSrcTF, bool bUseHW, int nDstBytesPerPix) = 0;
+ virtual bool DXTDecompress(const byte* srcData, size_t srcFileSize, byte* dstData, int nWidth, int nHeight, int nMips, ETEX_Format eSrcTF, bool bUseHW, int nDstBytesPerPix) = 0;
virtual void RemoveTexture(unsigned int TextureId) = 0;
virtual void DeleteFont(IFFont* font) = 0;
@@ -2219,7 +2219,7 @@ struct IRenderer
virtual void EndScreenShot([[maybe_unused]] int e_ScreenShot) {};
// Sets a renderer tracked cvar
- virtual void SetRendererCVar(ICVar* pCVar, const char* pArgText, const bool bSilentMode = false) = 0;
+ virtual void SetRendererCVar(ICVar* pCVar, const char* pArgText, bool bSilentMode = false) = 0;
// Get the render piepline
virtual SRenderPipeline* GetRenderPipeline() = 0;
@@ -2303,7 +2303,7 @@ struct IRenderer
virtual long FX_SetVertexDeclaration(int StreamMask, const AZ::Vertex::Format& vertexFormat) = 0;
// Draw indexed prim
- virtual void FX_DrawIndexedPrimitive(const eRenderPrimitiveType eType, const int nVBOffset, const int nMinVertexIndex, const int nVerticesCount, const int nStartIndex, const int nNumIndices, bool bInstanced = false) = 0;
+ virtual void FX_DrawIndexedPrimitive(eRenderPrimitiveType eType, int nVBOffset, int nMinVertexIndex, int nVerticesCount, int nStartIndex, int nNumIndices, bool bInstanced = false) = 0;
// Set Index stream
virtual long FX_SetIStream(const void* pB, uint32 nOffs, RenderIndexType idxType) = 0;
@@ -2312,7 +2312,7 @@ struct IRenderer
virtual long FX_SetVStream(int nID, const void* pB, uint32 nOffs, uint32 nStride, uint32 nFreq = 1) = 0;
// Draw primitives
- virtual void FX_DrawPrimitive(const eRenderPrimitiveType eType, const int nStartVertex, const int nVerticesCount, const int nInstanceVertices = 0) = 0;
+ virtual void FX_DrawPrimitive(eRenderPrimitiveType eType, int nStartVertex, int nVerticesCount, int nInstanceVertices = 0) = 0;
// Clear texture
virtual void FX_ClearTarget(ITexture* pTex) = 0;
@@ -2370,7 +2370,7 @@ struct IRenderer
virtual void ApplyDepthTextureState(int unit, int nFilter, bool clamp) = 0;
virtual ITexture* GetZTargetTexture() = 0;
virtual int GetTextureState(const STexState& TS) = 0;
- virtual uint32 TextureDataSize(uint32 nWidth, uint32 nHeight, uint32 nDepth, uint32 nMips, uint32 nSlices, const ETEX_Format eTF, ETEX_TileMode eTM = eTM_None) = 0;
+ virtual uint32 TextureDataSize(uint32 nWidth, uint32 nHeight, uint32 nDepth, uint32 nMips, uint32 nSlices, ETEX_Format eTF, ETEX_TileMode eTM = eTM_None) = 0;
virtual void ApplyForID(int nID, int nTUnit, int nTState, int nTexMaterialSlot, int nSUnit, bool useWhiteDefault) = 0;
virtual ITexture* Create3DTexture(const char* szName, int nWidth, int nHeight, int nDepth, int nMips, int nFlags, const byte* pData, ETEX_Format eTFSrc, ETEX_Format eTFDst) = 0;
virtual bool IsTextureExist(const ITexture* pTex) = 0;
diff --git a/Code/CryEngine/CryCommon/ISystem.h b/Code/CryEngine/CryCommon/ISystem.h
index 679dc66327..2519aae1c3 100644
--- a/Code/CryEngine/CryCommon/ISystem.h
+++ b/Code/CryEngine/CryCommon/ISystem.h
@@ -1267,7 +1267,7 @@ struct ISystem
// Arguments:
// bValue - Set to true when running on a cheat protected server or a client that is connected to it (not used in singleplayer).
- virtual void SetForceNonDevMode(const bool bValue) = 0;
+ virtual void SetForceNonDevMode(bool bValue) = 0;
// Return Value:
// True when running on a cheat protected server or a client that is connected to it (not used in singleplayer).
virtual bool GetForceNonDevMode() const = 0;
@@ -1386,12 +1386,12 @@ struct ISystem
// Summary:
// Changes current configuration platform.
- virtual void SetConfigPlatform(const ESystemConfigPlatform platform) = 0;
+ virtual void SetConfigPlatform(ESystemConfigPlatform platform) = 0;
//////////////////////////////////////////////////////////////////////////
// Summary:
// Detects and set optimal spec.
- virtual void AutoDetectSpec(const bool detectResolution) = 0;
+ virtual void AutoDetectSpec(bool detectResolution) = 0;
// Summary:
// Thread management for subsystems
@@ -1519,7 +1519,7 @@ struct ISystem
// it adds a line to "MemoryCoverage.bmp" (generated the first time, there is a max line count).
virtual void DumpMemoryCoverage() = 0;
virtual ESystemGlobalState GetSystemGlobalState(void) = 0;
- virtual void SetSystemGlobalState(const ESystemGlobalState systemGlobalState) = 0;
+ virtual void SetSystemGlobalState(ESystemGlobalState systemGlobalState) = 0;
// Summary:
// Asynchronous memcpy
diff --git a/Code/CryEngine/CryCommon/ITexture.h b/Code/CryEngine/CryCommon/ITexture.h
index 1f37bf61da..a5aa8d20f5 100644
--- a/Code/CryEngine/CryCommon/ITexture.h
+++ b/Code/CryEngine/CryCommon/ITexture.h
@@ -323,7 +323,7 @@ public:
/*LATER*/
}
- virtual void SetKeepSystemCopy(const bool bKeepSystemCopy) = 0;
+ virtual void SetKeepSystemCopy(bool bKeepSystemCopy) = 0;
virtual void UpdateTextureRegion(const uint8_t* data, int nX, int nY, int nZ, int USize, int VSize, int ZSize, ETEX_Format eTFSrc) = 0;
virtual CDeviceTexture* GetDevTexture() const = 0;
diff --git a/Code/CryEngine/CryCommon/MaterialUtils.h b/Code/CryEngine/CryCommon/MaterialUtils.h
index 901a517094..60752de8c5 100644
--- a/Code/CryEngine/CryCommon/MaterialUtils.h
+++ b/Code/CryEngine/CryCommon/MaterialUtils.h
@@ -87,7 +87,7 @@ namespace MaterialUtils
if (cachedGameName[0] == 0)
{
// at least substitute something so that unit tests can make this assumption:
- azstrcpy(cachedGameName, AZ_MAX_PATH_LEN, "SamplesProject/");
+ azstrcpy(cachedGameName, AZ_MAX_PATH_LEN, "AutomatedTesting/");
}
removals[removalSize - 1] = cachedGameName;
diff --git a/Code/CryEngine/CryCommon/Mocks/I3DEngineMock.h b/Code/CryEngine/CryCommon/Mocks/I3DEngineMock.h
index f0e49739a1..b0936ddbdd 100644
--- a/Code/CryEngine/CryCommon/Mocks/I3DEngineMock.h
+++ b/Code/CryEngine/CryCommon/Mocks/I3DEngineMock.h
@@ -69,9 +69,9 @@ public:
MOCK_METHOD0(Release,
void());
MOCK_METHOD3(RenderWorld,
- void(const int nRenderFlags, const SRenderingPassInfo& passInfo, const char* szDebugName));
+ void(int nRenderFlags, const SRenderingPassInfo& passInfo, const char* szDebugName));
MOCK_METHOD2(RenderSceneReflection,
- void(const int nRenderFlags, const SRenderingPassInfo& passInfo));
+ void(int nRenderFlags, const SRenderingPassInfo& passInfo));
MOCK_METHOD1(PreWorldStreamUpdate,
void(const CCamera& cam));
MOCK_METHOD0(WorldStreamUpdate,
@@ -262,7 +262,7 @@ public:
MOCK_METHOD1(GetLevelFilePath,
const char*(const char* szFileName));
MOCK_METHOD4(DisplayInfo,
- void(float& fTextPosX, float& fTextPosY, float& fTextStepY, const bool bEnhanced));
+ void(float& fTextPosX, float& fTextPosY, float& fTextStepY, bool bEnhanced));
MOCK_METHOD0(DisplayMemoryStatistics,
void());
diff --git a/Code/CryEngine/CryCommon/Mocks/IAudioSystemMock.h b/Code/CryEngine/CryCommon/Mocks/IAudioSystemMock.h
index 2735548e00..5995b2ecc0 100644
--- a/Code/CryEngine/CryCommon/Mocks/IAudioSystemMock.h
+++ b/Code/CryEngine/CryCommon/Mocks/IAudioSystemMock.h
@@ -19,16 +19,16 @@ namespace Audio
struct AudioProxyMock
: public IAudioProxy
{
- MOCK_METHOD2(Initialize, void(const char* const sObjectName, const bool bInitAsync /* = true */));
+ MOCK_METHOD2(Initialize, void(const char* const sObjectName, bool bInitAsync /* = true */));
MOCK_METHOD0(Release, void());
MOCK_METHOD0(Reset, void());
- MOCK_METHOD1(StopTrigger, void(const TAudioControlID nTriggerID));
- MOCK_METHOD2(SetSwitchState, void(const TAudioControlID nSwitchID, const TAudioSwitchStateID nStateID));
- MOCK_METHOD2(SetRtpcValue, void(const TAudioControlID nRtpcID, const float fValue));
- MOCK_METHOD1(SetObstructionCalcType, void(const EAudioObjectObstructionCalcType eObstructionType));
+ MOCK_METHOD1(StopTrigger, void(TAudioControlID nTriggerID));
+ MOCK_METHOD2(SetSwitchState, void(TAudioControlID nSwitchID, TAudioSwitchStateID nStateID));
+ MOCK_METHOD2(SetRtpcValue, void(TAudioControlID nRtpcID, float fValue));
+ MOCK_METHOD1(SetObstructionCalcType, void(EAudioObjectObstructionCalcType eObstructionType));
MOCK_METHOD1(SetPosition, void(const SATLWorldPosition& rPosition));
MOCK_METHOD1(SetPosition, void(const AZ::Vector3& rPosition));
- MOCK_METHOD2(SetEnvironmentAmount, void(const TAudioEnvironmentID nEnvironmentID, const float fAmount));
+ MOCK_METHOD2(SetEnvironmentAmount, void(TAudioEnvironmentID nEnvironmentID, float fAmount));
MOCK_METHOD0(SetCurrentEnvironments, void());
MOCK_CONST_METHOD0(GetAudioObjectID, TAudioObjectID());
};
@@ -39,25 +39,25 @@ namespace Audio
MOCK_METHOD0(Initialize, bool());
MOCK_METHOD0(Release, void());
MOCK_METHOD1(PushRequest, void(const SAudioRequest& rAudioRequestData));
- MOCK_METHOD4(AddRequestListener, void(AudioRequestCallbackType func, void* const pObjectToListenTo, const EAudioRequestType requestType /* = eART_AUDIO_ALL_REQUESTS */, const TATLEnumFlagsType specificRequestMask /* = ALL_AUDIO_REQUEST_SPECIFIC_TYPE_FLAGS */));
- MOCK_METHOD2(RemoveRequestListener, void(AudioRequestCallbackType func, void* const pObjectToListenTo));
+ MOCK_METHOD4(AddRequestListener, void(AudioRequestCallbackType func, void* pObjectToListenTo, EAudioRequestType requestType /* = eART_AUDIO_ALL_REQUESTS */, TATLEnumFlagsType specificRequestMask /* = ALL_AUDIO_REQUEST_SPECIFIC_TYPE_FLAGS */));
+ MOCK_METHOD2(RemoveRequestListener, void(AudioRequestCallbackType func, void* pObjectToListenTo));
MOCK_METHOD0(ExternalUpdate, void());
- MOCK_CONST_METHOD1(GetAudioTriggerID, TAudioControlID(const char* const sAudioTriggerName));
- MOCK_CONST_METHOD1(GetAudioRtpcID, TAudioControlID(const char* const sAudioRtpcName));
- MOCK_CONST_METHOD1(GetAudioSwitchID, TAudioControlID(const char* const sAudioSwitchName));
- MOCK_CONST_METHOD2(GetAudioSwitchStateID, TAudioSwitchStateID(const TAudioControlID nSwitchID, const char* const sAudioStateName));
- MOCK_CONST_METHOD1(GetAudioPreloadRequestID, TAudioPreloadRequestID(const char* const sAudioPreloadRequestName));
- MOCK_CONST_METHOD1(GetAudioEnvironmentID, TAudioEnvironmentID(const char* const sAudioEnvironmentName));
+ MOCK_CONST_METHOD1(GetAudioTriggerID, TAudioControlID(const char* sAudioTriggerName));
+ MOCK_CONST_METHOD1(GetAudioRtpcID, TAudioControlID(const char* sAudioRtpcName));
+ MOCK_CONST_METHOD1(GetAudioSwitchID, TAudioControlID(const char* sAudioSwitchName));
+ MOCK_CONST_METHOD2(GetAudioSwitchStateID, TAudioSwitchStateID(const TAudioControlID nSwitchID, const char* sAudioStateName));
+ MOCK_CONST_METHOD1(GetAudioPreloadRequestID, TAudioPreloadRequestID(const char* sAudioPreloadRequestName));
+ MOCK_CONST_METHOD1(GetAudioEnvironmentID, TAudioEnvironmentID(const char* sAudioEnvironmentName));
MOCK_METHOD1(ReserveAudioListenerID, bool(TAudioObjectID& rAudioListenerID));
- MOCK_METHOD1(ReleaseAudioListenerID, bool(const TAudioObjectID nAudioObjectID));
+ MOCK_METHOD1(ReleaseAudioListenerID, bool(TAudioObjectID nAudioObjectID));
MOCK_METHOD1(OnCVarChanged, void(ICVar* const pCVar));
MOCK_METHOD1(GetInfo, void(SAudioSystemInfo& rAudioSystemInfo));
MOCK_CONST_METHOD0(GetControlsPath, const char*());
MOCK_METHOD0(UpdateControlsPath, void());
MOCK_METHOD0(GetFreeAudioProxy, IAudioProxy*());
- MOCK_METHOD1(FreeAudioProxy, void(IAudioProxy* const pIAudioProxy));
- MOCK_CONST_METHOD2(GetAudioControlName, const char*(const EAudioControlType eAudioEntityType, const TATLIDType nAudioEntityID));
- MOCK_CONST_METHOD2(GetAudioSwitchStateName, const char*(const TAudioControlID switchID, const TAudioSwitchStateID stateID));
+ MOCK_METHOD1(FreeAudioProxy, void(IAudioProxy* pIAudioProxy));
+ MOCK_CONST_METHOD2(GetAudioControlName, const char*(EAudioControlType eAudioEntityType, TATLIDType nAudioEntityID));
+ MOCK_CONST_METHOD2(GetAudioSwitchStateName, const char*(TAudioControlID switchID, TAudioSwitchStateID stateID));
};
} // namespace Audio
diff --git a/Code/CryEngine/CryCommon/Mocks/ICVarMock.h b/Code/CryEngine/CryCommon/Mocks/ICVarMock.h
index 1a72b45435..beeb0a31e4 100644
--- a/Code/CryEngine/CryCommon/Mocks/ICVarMock.h
+++ b/Code/CryEngine/CryCommon/Mocks/ICVarMock.h
@@ -29,8 +29,8 @@ public:
MOCK_CONST_METHOD0(GetDataProbeString, const char*());
MOCK_METHOD1(Set, void(const char*));
MOCK_METHOD1(ForceSet, void(const char*));
- MOCK_METHOD1(Set, void(const float));
- MOCK_METHOD1(Set, void(const int));
+ MOCK_METHOD1(Set, void(float));
+ MOCK_METHOD1(Set, void(int));
MOCK_METHOD1(ClearFlags, void(const int));
MOCK_CONST_METHOD0(GetFlags, int());
MOCK_METHOD1(SetFlags, int(const int));
diff --git a/Code/CryEngine/CryCommon/Mocks/IConsoleMock.h b/Code/CryEngine/CryCommon/Mocks/IConsoleMock.h
index 6042c3de83..31509ca6ba 100644
--- a/Code/CryEngine/CryCommon/Mocks/IConsoleMock.h
+++ b/Code/CryEngine/CryCommon/Mocks/IConsoleMock.h
@@ -36,14 +36,14 @@ public:
MOCK_METHOD1(SetScrollMax, void(int value));
MOCK_METHOD1(AddOutputPrintSink, void(IOutputPrintSink * inpSink));
MOCK_METHOD1(RemoveOutputPrintSink, void(IOutputPrintSink * inpSink));
- MOCK_METHOD2(ShowConsole, void(bool show, const int iRequestScrollMax));
+ MOCK_METHOD2(ShowConsole, void(bool show, int iRequestScrollMax));
MOCK_METHOD2(DumpCVars, void(ICVarDumpSink * pCallback, unsigned int nFlagsFilter));
MOCK_METHOD2(CreateKeyBind, void(const char* sCmd, const char* sRes));
MOCK_METHOD2(SetImage, void (ITexture * pImage, bool bDeleteCurrent));
MOCK_METHOD0(GetImage, ITexture * ());
MOCK_METHOD1(StaticBackground, void (bool bStatic));
MOCK_METHOD1(SetLoadingImage, void(const char* szFilename));
- MOCK_CONST_METHOD3(GetLineNo, bool(const int indwLineNo, char* outszBuffer, const int indwBufferSize));
+ MOCK_CONST_METHOD3(GetLineNo, bool(int indwLineNo, char* outszBuffer, int indwBufferSize));
MOCK_CONST_METHOD0(GetLineCount, int ());
MOCK_METHOD1(GetCVar, ICVar * (const char* name));
MOCK_METHOD3(GetVariable, char*(const char* szVarName, const char* szFileName, const char* def_val));
@@ -57,7 +57,7 @@ public:
MOCK_METHOD4(AddCommand, bool (const char* sCommand, ConsoleCommandFunc func, int nFlags, const char* sHelp));
MOCK_METHOD4(AddCommand, bool (const char* sName, const char* sScriptFunc, int nFlags, const char* sHelp));
MOCK_METHOD1(RemoveCommand, void (const char* sName));
- MOCK_METHOD3(ExecuteString, void (const char* command, const bool bSilentMode, const bool bDeferExecution ));
+ MOCK_METHOD3(ExecuteString, void (const char* command, bool bSilentMode, bool bDeferExecution ));
MOCK_METHOD0(IsOpened, bool ());
MOCK_METHOD0(GetNumVars, int());
MOCK_METHOD0(GetNumVisibleVars, int());
@@ -83,7 +83,7 @@ public:
MOCK_METHOD1(GetCheatVarAt, char* (uint32 nOffset));
MOCK_METHOD1(AddConsoleVarSink, void (IConsoleVarSink * pSink));
MOCK_METHOD1(RemoveConsoleVarSink, void (IConsoleVarSink * pSink));
- MOCK_METHOD1(GetHistoryElement, const char*(const bool bUpOrDown));
+ MOCK_METHOD1(GetHistoryElement, const char*(bool bUpOrDown));
MOCK_METHOD1(AddCommandToHistory, void (const char* szCommand));
MOCK_METHOD2(LoadConfigVar, void (const char* sVariable, const char* sValue));
MOCK_METHOD1(EnableActivationKey, void (bool bEnable));
diff --git a/Code/CryEngine/CryCommon/Mocks/ILogMock.h b/Code/CryEngine/CryCommon/Mocks/ILogMock.h
index 1d2b5dd7d8..5d8b6d41b6 100644
--- a/Code/CryEngine/CryCommon/Mocks/ILogMock.h
+++ b/Code/CryEngine/CryCommon/Mocks/ILogMock.h
@@ -17,9 +17,9 @@ class LogMock
{
public:
MOCK_METHOD3(LogV,
- void(const ELogType nType, const char* szFormat, va_list args));
+ void(ELogType nType, const char* szFormat, va_list args));
MOCK_METHOD4(LogV,
- void(const ELogType nType, int flags, const char* szFormat, va_list args));
+ void(ELogType nType, int flags, const char* szFormat, va_list args));
MOCK_METHOD0(Release,
void());
MOCK_METHOD2(SetFileName,
diff --git a/Code/CryEngine/CryCommon/Mocks/IRendererMock.h b/Code/CryEngine/CryCommon/Mocks/IRendererMock.h
index 1d2e49ad66..2021e96172 100644
--- a/Code/CryEngine/CryCommon/Mocks/IRendererMock.h
+++ b/Code/CryEngine/CryCommon/Mocks/IRendererMock.h
@@ -63,9 +63,9 @@ public:
MOCK_CONST_METHOD2(GetCurrentNumberOfDrawCalls,
void(int& nGeneral, int& nShadowGen));
MOCK_CONST_METHOD1(GetCurrentNumberOfDrawCalls,
- int(const uint32 EFSListMask));
+ int(uint32 EFSListMask));
MOCK_CONST_METHOD1(GetCurrentDrawCallRTTimes,
- float(const uint32 EFSListMask));
+ float(uint32 EFSListMask));
MOCK_METHOD1(SetDebugRenderNode,
void(IRenderNode * pRenderNode));
MOCK_CONST_METHOD1(IsDebugRenderNode,
@@ -135,7 +135,7 @@ public:
MOCK_METHOD1(ApplyViewParameters,
void(const CameraViewParameters& viewParameters));
MOCK_METHOD5(DrawDynVB,
- void(SVF_P3F_C4B_T2F * pBuf, uint16 * pInds, int nVerts, int nInds, const PublicRenderPrimitiveType nPrimType));
+ void(SVF_P3F_C4B_T2F * pBuf, uint16 * pInds, int nVerts, int nInds, PublicRenderPrimitiveType nPrimType));
// Hand-edit: google mock has issues with DynUiPrimitiveList
void DrawDynUiPrimitiveList([[maybe_unused]] DynUiPrimitiveList& primitives, [[maybe_unused]] int totalNumVertices, [[maybe_unused]] int totalNumIndices) override { return; }
@@ -147,7 +147,7 @@ public:
MOCK_METHOD1(GetRenderViewForThread,
CRenderView * (int nThreadID));
MOCK_METHOD1(SetGammaDelta,
- bool(const float fGamma));
+ bool(float fGamma));
MOCK_METHOD0(RestoreGamma,
void(void));
MOCK_METHOD3(ChangeDisplay,
@@ -255,7 +255,7 @@ public:
MOCK_METHOD3(FlushRTCommands,
bool(bool bWait, bool bImmediatelly, bool bForce));
MOCK_CONST_METHOD7(DrawStringU,
- void(IFFont_RenderProxy * pFont, float x, float y, float z, const char* pStr, const bool asciiMultiLine, const STextDrawContext& ctx));
+ void(IFFont_RenderProxy * pFont, float x, float y, float z, const char* pStr, bool asciiMultiLine, const STextDrawContext& ctx));
MOCK_METHOD0(RT_CurThreadList,
int());
MOCK_METHOD6(EF_PrecacheResource,
@@ -343,9 +343,9 @@ public:
MOCK_METHOD7(EF_AddEf,
void(IRenderElement * pRE, SShaderItem & pSH, CRenderObject * pObj, const SRenderingPassInfo& passInfo, int nList, int nAW, const SRendItemSorter& rendItemSorter));
MOCK_METHOD4(EF_EndEf3D,
- void(const int nFlags, const int nPrecacheUpdateId, const int nNearPrecacheUpdateId, const SRenderingPassInfo& passInfo));
+ void(int nFlags, int nPrecacheUpdateId, int nNearPrecacheUpdateId, const SRenderingPassInfo& passInfo));
MOCK_METHOD1(EF_InvokeShadowMapRenderJobs,
- void(const int nFlags));
+ void(int nFlags));
MOCK_METHOD1(EF_IsFakeDLight,
bool(const CDLight * Source));
MOCK_METHOD2(EF_ADDDlight,
@@ -393,11 +393,11 @@ public:
MOCK_METHOD0(EF_DisableTemporalEffects,
void());
MOCK_METHOD3(EF_AddWaterSimHit,
- void(const Vec3& vPos, const float scale, const float strength));
+ void(const Vec3& vPos, float scale, float strength));
MOCK_METHOD0(EF_DrawWaterSimHits,
void());
MOCK_METHOD1(EF_EndEf2D,
- void(const bool bSort));
+ void(bool bSort));
MOCK_METHOD0(ForceGC,
void());
MOCK_CONST_METHOD0(GetPolyCount,
@@ -532,7 +532,7 @@ public:
MOCK_METHOD8(DXTCompress,
bool(const byte * raw_data, int nWidth, int nHeight, ETEX_Format eTF, bool bUseHW, bool bGenMips, int nSrcBytesPerPix, MIPDXTcallback callback));
MOCK_METHOD9(DXTDecompress,
- bool(const byte * srcData, const size_t srcFileSize, byte * dstData, int nWidth, int nHeight, int nMips, ETEX_Format eSrcTF, bool bUseHW, int nDstBytesPerPix));
+ bool(const byte * srcData, size_t srcFileSize, byte * dstData, int nWidth, int nHeight, int nMips, ETEX_Format eSrcTF, bool bUseHW, int nDstBytesPerPix));
MOCK_METHOD1(RemoveTexture,
void(unsigned int TextureId));
MOCK_METHOD1(DeleteFont,
@@ -727,7 +727,7 @@ public:
MOCK_METHOD1(EndScreenShot,
void(int e_ScreenShot));
MOCK_METHOD3(SetRendererCVar,
- void(ICVar*, const char*, const bool));
+ void(ICVar*, const char*, bool));
MOCK_METHOD0(GetRenderPipeline,
SRenderPipeline * ());
MOCK_METHOD0(GetShaderManager,
diff --git a/Code/CryEngine/CryCommon/Mocks/ITextureMock.h b/Code/CryEngine/CryCommon/Mocks/ITextureMock.h
index af8719892d..bf51279b52 100644
--- a/Code/CryEngine/CryCommon/Mocks/ITextureMock.h
+++ b/Code/CryEngine/CryCommon/Mocks/ITextureMock.h
@@ -107,7 +107,7 @@ public:
MOCK_METHOD3(GetLowResSystemCopy,
const ColorB * (uint16 & nWidth, uint16 & nHeight, int** ppLowResSystemCopyAtlasId));
MOCK_METHOD1(SetKeepSystemCopy,
- void(const bool bKeepSystemCopy));
+ void(bool bKeepSystemCopy));
MOCK_METHOD8(UpdateTextureRegion,
void(const uint8_t * data, int nX, int nY, int nZ, int USize, int VSize, int ZSize, ETEX_Format eTFSrc));
MOCK_CONST_METHOD0(GetDevTexture,
diff --git a/Code/CryEngine/CryCommon/ResourceCompilerHelper.cpp b/Code/CryEngine/CryCommon/ResourceCompilerHelper.cpp
index b69002dd7b..33373f7460 100644
--- a/Code/CryEngine/CryCommon/ResourceCompilerHelper.cpp
+++ b/Code/CryEngine/CryCommon/ResourceCompilerHelper.cpp
@@ -401,8 +401,8 @@ IResourceCompilerHelper::ERcCallResult CResourceCompilerHelper::CallResourceComp
[[maybe_unused]] const wchar_t* szRootPath)
{
#if defined(AZ_PLATFORM_WINDOWS)
- HANDLE hChildStdOutRd, hChildStdOutWr;
- HANDLE hChildStdInRd, hChildStdInWr;
+ HANDLE hChildStdOutRd = INVALID_HANDLE_VALUE, hChildStdOutWr = INVALID_HANDLE_VALUE;
+ HANDLE hChildStdInRd = INVALID_HANDLE_VALUE, hChildStdInWr = INVALID_HANDLE_VALUE;
PROCESS_INFORMATION pi;
#else
FILE* hChildStdOutRd;
diff --git a/Code/CryEngine/CryCommon/physinterface.h b/Code/CryEngine/CryCommon/physinterface.h
index 0efcb084c2..036f7e29ab 100644
--- a/Code/CryEngine/CryCommon/physinterface.h
+++ b/Code/CryEngine/CryCommon/physinterface.h
@@ -2112,7 +2112,7 @@ struct pe_status_area
{
type_id = ePE_status_area
};
- pe_status_area() { type = type_id; bUniformOnly = false; ctr.zero(); size.zero(); vel.zero(); MARK_UNUSED gravity, pb; pLockUpdate = 0; pSurface = 0; }
+ pe_status_area() { type = type_id; bUniformOnly = false; ctr.zero(); size.zero(); vel.zero(); MARK_UNUSED gravity; pLockUpdate = 0; pSurface = 0; }
// inputs.
Vec3 ctr, size; // query bounds
diff --git a/Code/CryEngine/CrySystem/AsyncPakManager.cpp b/Code/CryEngine/CrySystem/AsyncPakManager.cpp
index 0ead1bfbe1..40928715d8 100644
--- a/Code/CryEngine/CrySystem/AsyncPakManager.cpp
+++ b/Code/CryEngine/CrySystem/AsyncPakManager.cpp
@@ -19,6 +19,7 @@
#include "System.h"
#include "IStreamEngine.h"
#include
+#include
#include "ResourceManager.h"
#define MEGA_BYTE 1024* 1024
@@ -360,20 +361,37 @@ void CAsyncPakManager::StreamAsyncOnComplete(
}
else
{
- //
- // ugly hack - depending on the pak file pak may need special root info / open flags
- //
- if (pLayerPak->layername.find("level.pak") != string::npos)
+ bool usePrefabSystemForLevels = false;
+ AzFramework::ApplicationRequests::Bus::BroadcastResult(
+ usePrefabSystemForLevels,
+ &AzFramework::ApplicationRequests::IsPrefabSystemForLevelsEnabled);
+
+ if (usePrefabSystemForLevels)
{
- gEnv->pCryPak->OpenPack({ pLayerPak->filename.c_str(), pLayerPak->filename.size() }, AZ::IO::IArchive::FLAGS_FILENAMES_AS_CRC32, NULL);
- }
- else if (pLayerPak->layername.find("levelshadercache.pak") != string::npos)
- {
- gEnv->pCryPak->OpenPack("@assets@", { pLayerPak->filename.c_str(), pLayerPak->filename.size() }, AZ::IO::IArchive::FLAGS_PATH_REAL, NULL);
+ gEnv->pCryPak->OpenPack(
+ "@assets@", {pLayerPak->filename.c_str(), pLayerPak->filename.size()}, AZ::IO::IArchive::FLAGS_FILENAMES_AS_CRC32, NULL);
}
else
{
- gEnv->pCryPak->OpenPack("@assets@", { pLayerPak->filename.c_str(), pLayerPak->filename.size() }, AZ::IO::IArchive::FLAGS_FILENAMES_AS_CRC32, NULL);
+ //
+ // ugly hack - depending on the pak file pak may need special root info / open flags
+ //
+ if (pLayerPak->layername.find("level.pak") != string::npos)
+ {
+ gEnv->pCryPak->OpenPack(
+ {pLayerPak->filename.c_str(), pLayerPak->filename.size()}, AZ::IO::IArchive::FLAGS_FILENAMES_AS_CRC32, NULL);
+ }
+ else if (pLayerPak->layername.find("levelshadercache.pak") != string::npos)
+ {
+ gEnv->pCryPak->OpenPack(
+ "@assets@", {pLayerPak->filename.c_str(), pLayerPak->filename.size()}, AZ::IO::IArchive::FLAGS_PATH_REAL, NULL);
+ }
+ else
+ {
+ gEnv->pCryPak->OpenPack(
+ "@assets@", {pLayerPak->filename.c_str(), pLayerPak->filename.size()}, AZ::IO::IArchive::FLAGS_FILENAMES_AS_CRC32,
+ NULL);
+ }
}
gEnv->pCryPak->LoadPakToMemory(pLayerPak->filename.c_str(), AZ::IO::IArchive::eInMemoryPakLocale_GPU, pLayerPak->pData);
}
diff --git a/Code/CryEngine/CrySystem/LevelSystem/LevelSystem.cpp b/Code/CryEngine/CrySystem/LevelSystem/LevelSystem.cpp
index f029060ee1..996dee7810 100644
--- a/Code/CryEngine/CrySystem/LevelSystem/LevelSystem.cpp
+++ b/Code/CryEngine/CrySystem/LevelSystem/LevelSystem.cpp
@@ -11,6 +11,8 @@
*/
// Original file Copyright Crytek GMBH or its affiliates, used under license.
+// [LYN-2376] Remove the entire file once legacy slice support is removed
+
#include "CrySystem_precompiled.h"
#include "LevelSystem.h"
#include
@@ -25,9 +27,11 @@
#include
#include
+#include
#include
#include
#include
+#include
#include "MainThreadRenderRequestBus.h"
#include
@@ -43,47 +47,88 @@
namespace LegacyLevelSystem
{
+static constexpr const char* ArchiveExtension = ".pak";
-int CLevelSystem::s_loadCount = 0;
-const char* ArchiveExtension = ".pak";
-const char TerrarinTexturePakName[] = "terraintexture.pak";
-
-//------------------------------------------------------------------------
-bool CLevelInfo::SupportsGameType(const char* gameTypeName) const
+void CLevelInfo::GetMemoryUsage(ICrySizer* pSizer) const
{
- //read level meta data
- for (int i = 0; i < m_gamerules.size(); ++i)
- {
- if (!azstricmp(m_gamerules[i].c_str(), gameTypeName))
- {
- return true;
- }
- }
- return false;
+ pSizer->AddObject(m_levelName);
+ pSizer->AddObject(m_levelPath);
}
-//------------------------------------------------------------------------
-const char* CLevelInfo::GetDisplayName() const
+//////////////////////////////////////////////////////////////////////////
+bool CLevelInfo::OpenLevelPak()
{
- return m_levelDisplayName.c_str();
+ LOADING_TIME_PROFILE_SECTION;
+
+ bool usePrefabSystemForLevels = false;
+ AzFramework::ApplicationRequests::Bus::BroadcastResult(
+ usePrefabSystemForLevels, &AzFramework::ApplicationRequests::IsPrefabSystemForLevelsEnabled);
+
+ // The prefab system doesn't use level.pak
+ if (usePrefabSystemForLevels)
+ {
+ return false;
+ }
+
+ AZStd::string levelpak(m_levelPath);
+ levelpak += "/level.pak";
+ AZStd::fixed_string fullLevelPakPath;
+ bool bOk = gEnv->pCryPak->OpenPack(
+ levelpak.c_str(), m_isPak ? AZ::IO::IArchive::FLAGS_LEVEL_PAK_INSIDE_PAK : (unsigned)0, NULL, &fullLevelPakPath, false);
+ m_levelPakFullPath.assign(fullLevelPakPath.c_str());
+ return bOk;
+}
+
+//////////////////////////////////////////////////////////////////////////
+void CLevelInfo::CloseLevelPak()
+{
+ LOADING_TIME_PROFILE_SECTION;
+
+ bool usePrefabSystemForLevels = false;
+ AzFramework::ApplicationRequests::Bus::BroadcastResult(
+ usePrefabSystemForLevels, &AzFramework::ApplicationRequests::IsPrefabSystemForLevelsEnabled);
+
+ // The prefab system doesn't use level.pak
+ if (usePrefabSystemForLevels)
+ {
+ return;
+ }
+
+ if (!m_levelPakFullPath.empty())
+ {
+ gEnv->pCryPak->ClosePack(m_levelPakFullPath.c_str(), AZ::IO::IArchive::FLAGS_PATH_REAL);
+ m_levelPakFullPath.clear();
+ }
}
//////////////////////////////////////////////////////////////////////////
bool CLevelInfo::ReadInfo()
{
- string levelPath = m_levelPath;
- string xmlFile = levelPath + string("/LevelInfo.xml");
+ bool usePrefabSystemForLevels = false;
+ AzFramework::ApplicationRequests::Bus::BroadcastResult(
+ usePrefabSystemForLevels, &AzFramework::ApplicationRequests::IsPrefabSystemForLevelsEnabled);
+
+ if (usePrefabSystemForLevels)
+ {
+ // Set up a default game type for legacy code.
+ m_defaultGameTypeName = "Mission0";
+ return true;
+ }
+
+
+ AZStd::string levelPath(m_levelPath);
+ AZStd::string xmlFile(levelPath);
+ xmlFile += "/LevelInfo.xml";
XmlNodeRef rootNode = GetISystem()->LoadXmlFromFile(xmlFile.c_str());
if (rootNode)
{
- m_heightmapSize = atoi(rootNode->getAttr("HeightmapSize"));
-
- string dataFile = levelPath + string("/LevelDataAction.xml");
+ AZStd::string dataFile(levelPath);
+ dataFile += "/LevelDataAction.xml";
XmlNodeRef dataNode = GetISystem()->LoadXmlFromFile(dataFile.c_str());
if (!dataNode)
{
- dataFile = levelPath + string("/LevelData.xml");
+ dataFile = levelPath + "/LevelData.xml";
dataNode = GetISystem()->LoadXmlFromFile(dataFile.c_str());
}
@@ -93,8 +138,7 @@ bool CLevelInfo::ReadInfo()
if ((gameTypesNode != 0) && (gameTypesNode->getChildCount() > 0))
{
- m_gameTypes.clear();
- //m_musicLibs.clear();
+ m_defaultGameTypeName.clear();
for (int i = 0; i < gameTypesNode->getChildCount(); i++)
{
@@ -106,37 +150,11 @@ bool CLevelInfo::ReadInfo()
if (gameTypeName)
{
- ILevelInfo::TGameTypeInfo info;
-
- info.cgfCount = 0;
- gameTypeNode->getAttr("CGFCount", info.cgfCount);
- info.name = gameTypeNode->getAttr("Name");
- info.xmlFile = gameTypeNode->getAttr("File");
- m_gameTypes.push_back(info);
+ m_defaultGameTypeName = gameTypeName;
+ break;
}
}
}
-
- // Gets reintroduced when level specific music data loading is implemented.
- /*XmlNodeRef musicLibraryNode = dataNode->findChild("MusicLibrary");
-
- if ((musicLibraryNode!=0) && (musicLibraryNode->getChildCount() > 0))
- {
- for (int i = 0; i < musicLibraryNode->getChildCount(); i++)
- {
- XmlNodeRef musicLibrary = musicLibraryNode->getChild(i);
-
- if (musicLibrary->isTag("Library"))
- {
- const char *musicLibraryName = musicLibrary->getAttr("File");
-
- if (musicLibraryName)
- {
- m_musicLibs.push_back(string("music/") + musicLibraryName);
- }
- }
- }
- }*/
}
}
}
@@ -144,130 +162,12 @@ bool CLevelInfo::ReadInfo()
}
//////////////////////////////////////////////////////////////////////////
-void CLevelInfo::ReadMetaData()
-{
- string fullPath(GetPath());
- int slashPos = fullPath.find_last_of("\\/");
- string mapName = fullPath.substr(slashPos + 1, fullPath.length() - slashPos);
- fullPath.append("/");
- fullPath.append(mapName);
- fullPath.append(".xml");
-
- m_levelDisplayName = string("@ui_") + mapName;
-
- if (!gEnv->pCryPak->IsFileExist(fullPath.c_str()))
- {
- return;
- }
-
- XmlNodeRef mapInfo = GetISystem()->LoadXmlFromFile(fullPath.c_str());
- //retrieve the coordinates of the map
- bool foundMinimapInfo = false;
- if (mapInfo)
- {
- for (int n = 0; n < mapInfo->getChildCount(); ++n)
- {
- XmlNodeRef rulesNode = mapInfo->getChild(n);
- const char* name = rulesNode->getTag();
- if (!azstricmp(name, "Gamerules"))
- {
- for (int a = 0; a < rulesNode->getNumAttributes(); ++a)
- {
- const char* key, * value;
- rulesNode->getAttributeByIndex(a, &key, &value);
- m_gamerules.push_back(value);
- }
- }
- else if (!azstricmp(name, "Display"))
- {
- XmlString v;
- if (rulesNode->getAttr("Name", v))
- {
- m_levelDisplayName = v.c_str();
- }
- }
- else if (!azstricmp(name, "PreviewImage"))
- {
- const char* pFilename = NULL;
- if (rulesNode->getAttr("Filename", &pFilename))
- {
- m_previewImagePath = pFilename;
- }
- }
- else if (!azstricmp(name, "BackgroundImage"))
- {
- const char* pFilename = NULL;
- if (rulesNode->getAttr("Filename", &pFilename))
- {
- m_backgroundImagePath = pFilename;
- }
- }
- else if (!azstricmp(name, "Minimap"))
- {
- foundMinimapInfo = true;
-
- const char* minimap_dds = "";
- foundMinimapInfo &= rulesNode->getAttr("Filename", &minimap_dds);
- m_minimapImagePath = minimap_dds;
- m_minimapInfo.sMinimapName = GetPath();
- m_minimapInfo.sMinimapName.append("/");
- m_minimapInfo.sMinimapName.append(minimap_dds);
-
- foundMinimapInfo &= rulesNode->getAttr("startX", m_minimapInfo.fStartX);
- foundMinimapInfo &= rulesNode->getAttr("startY", m_minimapInfo.fStartY);
- foundMinimapInfo &= rulesNode->getAttr("endX", m_minimapInfo.fEndX);
- foundMinimapInfo &= rulesNode->getAttr("endY", m_minimapInfo.fEndY);
- foundMinimapInfo &= rulesNode->getAttr("width", m_minimapInfo.iWidth);
- foundMinimapInfo &= rulesNode->getAttr("height", m_minimapInfo.iHeight);
- m_minimapInfo.fDimX = m_minimapInfo.fEndX - m_minimapInfo.fStartX;
- m_minimapInfo.fDimY = m_minimapInfo.fEndY - m_minimapInfo.fStartY;
- m_minimapInfo.fDimX = m_minimapInfo.fDimX > 0 ? m_minimapInfo.fDimX : 1;
- m_minimapInfo.fDimY = m_minimapInfo.fDimY > 0 ? m_minimapInfo.fDimY : 1;
- }
- else if (!azstricmp(name, "Tag"))
- {
- m_levelTag = ILevelSystem::TAG_UNKNOWN;
- SwapEndian(m_levelTag, eBigEndian);
- const char* pTag = NULL;
- if (rulesNode->getAttr("Value", &pTag))
- {
- m_levelTag = 0;
- memcpy(&m_levelTag, pTag, std::min(sizeof(m_levelTag), strlen(pTag)));
- }
- }
- else if (!azstricmp(name, "LevelType"))
- {
- const char* levelType;
- if (rulesNode->getAttr("value", &levelType))
- {
- m_levelTypeList.push_back(levelType);
- }
- }
- }
- m_bMetaDataRead = true;
- }
- if (!foundMinimapInfo)
- {
- gEnv->pLog->LogWarning("Map %s: Missing or invalid minimap info!", mapName.c_str());
- }
-}
-
-//------------------------------------------------------------------------
-const ILevelInfo::TGameTypeInfo* CLevelInfo::GetDefaultGameType() const
-{
- if (!m_gameTypes.empty())
- {
- return &m_gameTypes[0];
- }
-
- return 0;
-};
/// Used by console auto completion.
struct SLevelNameAutoComplete
: public IConsoleArgumentAutoComplete
{
- std::vector levels;
+ AZStd::vector levels;
virtual int GetCount() const { return levels.size(); };
virtual const char* GetValue(int nIndex) const { return levels[nIndex].c_str(); };
};
@@ -281,7 +181,7 @@ static void LoadMap(IConsoleCmdArgs* args)
{
if (args->GetArgCount() > 1)
{
- gEnv->pSystem->GetILevelSystem()->UnLoadLevel();
+ gEnv->pSystem->GetILevelSystem()->UnloadLevel();
gEnv->pSystem->GetILevelSystem()->LoadLevel(args->GetArg(1));
}
}
@@ -292,7 +192,7 @@ static void UnloadMap([[maybe_unused]] IConsoleCmdArgs* args)
{
if (gEnv->pSystem && gEnv->pSystem->GetILevelSystem() && !gEnv->IsEditor())
{
- gEnv->pSystem->GetILevelSystem()->UnLoadLevel();
+ gEnv->pSystem->GetILevelSystem()->UnloadLevel();
if (gEnv->p3DEngine)
{
gEnv->p3DEngine->LoadEmptyLevel();
@@ -309,29 +209,12 @@ CLevelSystem::CLevelSystem(ISystem* pSystem, const char* levelsFolder)
LOADING_TIME_PROFILE_SECTION;
CRY_ASSERT(pSystem);
- //Load user defined level types
- if (XmlNodeRef levelTypeNode = m_pSystem->LoadXmlFromFile("Libs/Levels/leveltypes.xml"))
- {
- for (unsigned int i = 0; i < levelTypeNode->getChildCount(); ++i)
- {
- XmlNodeRef child = levelTypeNode->getChild(i);
- const char* levelType;
-
- if (child->getAttr("value", &levelType))
- {
- m_levelTypeList.push_back(string(levelType));
- }
- }
- }
-
//if (!gEnv->IsEditor())
- Rescan(levelsFolder, ILevelSystem::TAG_MAIN);
+ Rescan(levelsFolder);
m_fLastLevelLoadTime = 0;
- m_fFilteredProgress = 0;
m_fLastTime = 0;
m_bLevelLoaded = false;
- m_bRecordingFileOpens = false;
m_levelLoadStartTime.SetValue(0);
@@ -355,10 +238,9 @@ CLevelSystem::CLevelSystem(ISystem* pSystem, const char* levelsFolder)
for (AZStd::string dir : levelDirs)
{
AZ::StringFunc::Path::StripComponent(dir, true);
- string searchPattern = string(dir.c_str(), dir.size()) + AZ_FILESYSTEM_SEPARATOR_WILDCARD;
+ AZStd::string searchPattern = dir + AZ_FILESYSTEM_SEPARATOR_WILDCARD;
bool modFolder = false;
- string rootFolder(dir.c_str(), dir.size());
- PopulateLevels(searchPattern, rootFolder, gEnv->pCryPak, modFolder, ILevelSystem::TAG_MAIN, false);
+ PopulateLevels(searchPattern, dir, gEnv->pCryPak, modFolder, false);
}
});
m_levelPackOpenHandler.Connect(*levelPakOpenEvent);
@@ -368,7 +250,7 @@ CLevelSystem::CLevelSystem(ISystem* pSystem, const char* levelsFolder)
{
m_levelPackCloseHandler = AZ::IO::IArchive::LevelPackCloseEvent::Handler([this](AZStd::string_view)
{
- Rescan(ILevelSystem::LevelsDirectoryName, ILevelSystem::TAG_MAIN);
+ Rescan(ILevelSystem::LevelsDirectoryName);
});
m_levelPackCloseHandler.Connect(*levelPakCloseEvent);
}
@@ -380,7 +262,7 @@ CLevelSystem::~CLevelSystem()
}
//------------------------------------------------------------------------
-void CLevelSystem::Rescan(const char* levelsFolder, const uint32 tag)
+void CLevelSystem::Rescan(const char* levelsFolder)
{
if (levelsFolder)
{
@@ -388,9 +270,9 @@ void CLevelSystem::Rescan(const char* levelsFolder, const uint32 tag)
{
if (m_pSystem->IsMODValid(pModArg->GetValue()))
{
- m_levelsFolder.Format("Mods/%s/%s", pModArg->GetValue(), levelsFolder);
+ m_levelsFolder.format("Mods/%s/%s", pModArg->GetValue(), levelsFolder);
m_levelInfos.clear();
- ScanFolder(0, true, tag);
+ ScanFolder(0, true);
}
}
@@ -400,25 +282,25 @@ void CLevelSystem::Rescan(const char* levelsFolder, const uint32 tag)
CRY_ASSERT(!m_levelsFolder.empty());
m_levelInfos.clear();
m_levelInfos.reserve(64);
- ScanFolder(0, false, tag);
+ ScanFolder(0, false);
g_LevelNameAutoComplete->levels.clear();
for (int i = 0; i < (int)m_levelInfos.size(); i++)
{
- g_LevelNameAutoComplete->levels.push_back(PathUtil::GetFileName(m_levelInfos[i].GetName()));
+ g_LevelNameAutoComplete->levels.push_back(AZStd::string(PathUtil::GetFileName(m_levelInfos[i].GetName()).c_str()));
}
}
//-----------------------------------------------------------------------
-void CLevelSystem::ScanFolder(const char* subfolder, bool modFolder, const uint32 tag)
+void CLevelSystem::ScanFolder(const char* subfolder, bool modFolder)
{
- string folder;
+ AZStd::string folder;
if (subfolder && subfolder[0])
{
folder = subfolder;
}
- string search(m_levelsFolder);
+ AZStd::string search(m_levelsFolder);
if (!folder.empty())
{
if (AZ::StringFunc::StartsWith(folder.c_str(), m_levelsFolder.c_str()))
@@ -427,7 +309,7 @@ void CLevelSystem::ScanFolder(const char* subfolder, bool modFolder, const uint3
}
else
{
- search += string("/") + folder;
+ search += "/" + folder;
}
}
search += "/*";
@@ -453,12 +335,13 @@ void CLevelSystem::ScanFolder(const char* subfolder, bool modFolder, const uint3
AZ::StringFunc::Path::Split(handle.m_filename.data(), nullptr, nullptr, &levelName, &extension);
if (extension == ArchiveExtension)
{
- if (AZ::StringFunc::Equal(handle.m_filename.data(), ILevelSystem::LevelPakName) || AZ::StringFunc::Equal(handle.m_filename.data(), TerrarinTexturePakName))
+ if (AZ::StringFunc::Equal(handle.m_filename.data(), LevelPakName))
{
- // level folder contain pak files like 'level.pak' and 'terraintexture.pak'
+ // level folder contain pak files like 'level.pak'
// which we only want to load during level loading.
continue;
}
+
AZStd::string levelContainerPakPath;
AZ::StringFunc::Path::Join("@assets@", m_levelsFolder.c_str(), levelContainerPakPath);
if (subfolder && subfolder[0])
@@ -482,101 +365,93 @@ void CLevelSystem::ScanFolder(const char* subfolder, bool modFolder, const uint3
}
// Levels in bundles now take priority over levels outside of bundles.
- PopulateLevels(search, folder, pPak, modFolder, tag, false);
+ PopulateLevels(search, folder, pPak, modFolder, false);
// Load levels outside of the bundles to maintain backward compatibility.
- PopulateLevels(search, folder, pPak, modFolder, tag, true);
+ PopulateLevels(search, folder, pPak, modFolder, true);
}
-void CLevelSystem::PopulateLevels(string searchPattern, string& folder, AZ::IO::IArchive* pPak, bool& modFolder, const uint32& tag, bool fromFileSystemOnly)
+void CLevelSystem::PopulateLevels(
+ AZStd::string searchPattern, AZStd::string& folder, AZ::IO::IArchive* pPak, bool& modFolder, bool fromFileSystemOnly)
{
- // allow this find first to actually touch the file system
- // (causes small overhead but with minimal amount of levels this should only be around 150ms on actual DVD Emu)
- AZ::IO::ArchiveFileIterator handle = pPak->FindFirst(searchPattern.c_str(), 0, fromFileSystemOnly);
-
- if (handle)
{
- do
+ // allow this find first to actually touch the file system
+ // (causes small overhead but with minimal amount of levels this should only be around 150ms on actual DVD Emu)
+ AZ::IO::ArchiveFileIterator handle = pPak->FindFirst(searchPattern.c_str(), 0, fromFileSystemOnly);
+
+ if (handle)
{
- if ((handle.m_fileDesc.nAttrib & AZ::IO::FileDesc::Attribute::Subdirectory) != AZ::IO::FileDesc::Attribute::Subdirectory || handle.m_filename == "." || handle.m_filename == "..")
+ do
{
- continue;
- }
-
- string levelFolder;
- if (fromFileSystemOnly)
- {
- levelFolder = (folder.empty() ? "" : (folder + "/")) + string(handle.m_filename.data(), handle.m_filename.size());
- }
- else
- {
- AZStd::string levelName = AZ::IO::PathView(handle.m_filename).Filename().Native();
- levelFolder = (folder.empty() ? "" : (folder + "/")) + string(levelName.c_str());
- }
-
- string levelPath;
- if (AZ::StringFunc::StartsWith(levelFolder.c_str(), m_levelsFolder.c_str()))
- {
- levelPath = levelFolder;
- }
- else
- {
- levelPath = m_levelsFolder + "/" + levelFolder;
- }
- string paks = levelPath + string("/*.pak");
-
- const string levelPakName = levelPath + "/level.pak";
- const string levelInfoName = levelPath + "/levelinfo.xml";
-
- if (!pPak->IsFileExist(levelPakName.c_str(), fromFileSystemOnly ? AZ::IO::IArchive::eFileLocation_OnDisk : AZ::IO::IArchive::eFileLocation_InPak) && !pPak->IsFileExist(levelInfoName.c_str(), fromFileSystemOnly ? AZ::IO::IArchive::eFileLocation_OnDisk : AZ::IO::IArchive::eFileLocation_InPak))
- {
- ScanFolder(levelFolder.c_str(), modFolder, tag);
- continue;
- }
-
- CLevelInfo levelInfo;
- levelInfo.m_levelPath = levelPath;
- levelInfo.m_levelPaks = paks;
- levelInfo.m_levelName = levelFolder;
- levelInfo.m_levelName = UnifyName(levelInfo.m_levelName);
- levelInfo.m_isModLevel = modFolder;
- levelInfo.m_scanTag = tag;
- levelInfo.m_levelTag = ILevelSystem::TAG_UNKNOWN;
- levelInfo.m_isPak = !fromFileSystemOnly;
-
- SwapEndian(levelInfo.m_scanTag, eBigEndian);
- SwapEndian(levelInfo.m_levelTag, eBigEndian);
-
- CLevelInfo* pExistingInfo = GetLevelInfoInternal(levelInfo.m_levelName);
- if (pExistingInfo && pExistingInfo->MetadataLoaded() == false)
- {
- //Reload metadata if it failed to load
- pExistingInfo->ReadMetaData();
- }
-
- // Don't add the level if it is already in the list
- if (pExistingInfo == NULL)
- {
- levelInfo.ReadMetaData();
-
- m_levelInfos.push_back(levelInfo);
- }
- else
- {
- // Levels in bundles take priority over levels outside bundles.
- if (!pExistingInfo->m_isPak && levelInfo.m_isPak)
+ if ((handle.m_fileDesc.nAttrib & AZ::IO::FileDesc::Attribute::Subdirectory) != AZ::IO::FileDesc::Attribute::Subdirectory ||
+ handle.m_filename == "." || handle.m_filename == "..")
{
- *pExistingInfo = levelInfo;
+ continue;
+ }
+
+ AZStd::string levelFolder;
+ if (fromFileSystemOnly)
+ {
+ levelFolder =
+ (folder.empty() ? "" : (folder + "/")) + AZStd::string(handle.m_filename.data(), handle.m_filename.size());
}
else
{
- // Update the scan tag
- pExistingInfo->m_scanTag = tag;
+ AZStd::string levelName(AZ::IO::PathView(handle.m_filename).Filename().Native());
+ levelFolder = (folder.empty() ? "" : (folder + "/")) + levelName;
}
- }
- } while (handle = pPak->FindNext(handle));
- pPak->FindClose(handle);
+ AZStd::string levelPath;
+ if (AZ::StringFunc::StartsWith(levelFolder.c_str(), m_levelsFolder.c_str()))
+ {
+ levelPath = levelFolder;
+ }
+ else
+ {
+ levelPath = m_levelsFolder + "/" + levelFolder;
+ }
+
+ const AZStd::string levelPakName = levelPath + "/" + LevelPakName;
+ const AZStd::string levelInfoName = levelPath + "/levelinfo.xml";
+
+ if (!pPak->IsFileExist(
+ levelPakName.c_str(),
+ fromFileSystemOnly ? AZ::IO::IArchive::eFileLocation_OnDisk : AZ::IO::IArchive::eFileLocation_InPak) &&
+ !pPak->IsFileExist(
+ levelInfoName.c_str(),
+ fromFileSystemOnly ? AZ::IO::IArchive::eFileLocation_OnDisk : AZ::IO::IArchive::eFileLocation_InPak))
+ {
+ ScanFolder(levelFolder.c_str(), modFolder);
+ continue;
+ }
+
+ // With the level.pak workflow, levelPath and levelName will point to a directory.
+ // levelPath: levels/mylevel
+ // levelName: mylevel
+ CLevelInfo levelInfo;
+ levelInfo.m_levelPath = levelPath;
+ levelInfo.m_levelName = levelFolder;
+ levelInfo.m_isPak = !fromFileSystemOnly;
+
+ CLevelInfo* pExistingInfo = GetLevelInfoInternal(levelInfo.m_levelName);
+
+ // Don't add the level if it is already in the list
+ if (pExistingInfo == NULL)
+ {
+ m_levelInfos.push_back(levelInfo);
+ }
+ else
+ {
+ // Levels in bundles take priority over levels outside bundles.
+ if (!pExistingInfo->m_isPak && levelInfo.m_isPak)
+ {
+ *pExistingInfo = levelInfo;
+ }
+ }
+ } while (handle = pPak->FindNext(handle));
+
+ pPak->FindClose(handle);
+ }
}
}
@@ -610,34 +485,36 @@ ILevelInfo* CLevelSystem::GetLevelInfo(const char* levelName)
}
//------------------------------------------------------------------------
-CLevelInfo* CLevelSystem::GetLevelInfoInternal(const char* levelName)
+CLevelInfo* CLevelSystem::GetLevelInfoInternal(const AZStd::string& levelName)
{
// If level not found by full name try comparing with only filename
- for (std::vector::iterator it = m_levelInfos.begin(); it != m_levelInfos.end(); ++it)
+ for (AZStd::vector::iterator it = m_levelInfos.begin(); it != m_levelInfos.end(); ++it)
{
- if (!azstricmp(it->GetName(), levelName))
+ if (!azstricmp(it->GetName(), levelName.c_str()))
{
return &(*it);
}
}
//////////////////////////////////////////////////////////////////////////
- for (std::vector::iterator it = m_levelInfos.begin(); it != m_levelInfos.end(); ++it)
+ for (AZStd::vector::iterator it = m_levelInfos.begin(); it != m_levelInfos.end(); ++it)
{
- if (!azstricmp(PathUtil::GetFileName(it->GetName()), levelName))
{
- return &(*it);
+ if (!azstricmp(PathUtil::GetFileName(it->GetName()), levelName.c_str()))
+ {
+ return &(*it);
+ }
}
}
// Try stripping out the folder to find the raw filename
- string sLevelName(levelName);
+ AZStd::string sLevelName(levelName);
size_t lastSlash = sLevelName.find_last_of('\\');
- if (lastSlash == string::npos)
+ if (lastSlash == AZStd::string::npos)
{
lastSlash = sLevelName.find_last_of('/');
}
- if (lastSlash != string::npos)
+ if (lastSlash != AZStd::string::npos)
{
sLevelName = sLevelName.substr(lastSlash + 1, sLevelName.size() - lastSlash - 1);
return GetLevelInfoInternal(sLevelName.c_str());
@@ -649,7 +526,7 @@ CLevelInfo* CLevelSystem::GetLevelInfoInternal(const char* levelName)
//------------------------------------------------------------------------
void CLevelSystem::AddListener(ILevelSystemListener* pListener)
{
- std::vector::iterator it = std::find(m_listeners.begin(), m_listeners.end(), pListener);
+ AZStd::vector::iterator it = AZStd::find(m_listeners.begin(), m_listeners.end(), pListener);
if (it == m_listeners.end())
{
@@ -661,7 +538,7 @@ void CLevelSystem::AddListener(ILevelSystemListener* pListener)
//------------------------------------------------------------------------
void CLevelSystem::RemoveListener(ILevelSystemListener* pListener)
{
- std::vector::iterator it = std::find(m_listeners.begin(), m_listeners.end(), pListener);
+ AZStd::vector::iterator it = AZStd::find(m_listeners.begin(), m_listeners.end(), pListener);
if (it != m_listeners.end())
{
@@ -669,18 +546,24 @@ void CLevelSystem::RemoveListener(ILevelSystemListener* pListener)
if (m_listeners.empty())
{
- stl::free_container(m_listeners);
+ m_listeners.shrink_to_fit();
}
}
}
//------------------------------------------------------------------------
-ILevel* CLevelSystem::LoadLevel(const char* _levelName)
+bool CLevelSystem::LoadLevel(const char* _levelName)
{
if (gEnv->IsEditor())
{
AZ_TracePrintf("CrySystem::CLevelSystem", "LoadLevel for %s was called in the editor - not actually loading.\n", _levelName);
- return nullptr;
+ return false;
+ }
+
+ // If a level is currently loaded, unload it before loading the next one.
+ if (IsLevelLoaded())
+ {
+ UnloadLevel();
}
gEnv->pSystem->GetISystemEventDispatcher()->OnSystemEvent(ESYSTEM_EVENT_LEVEL_LOAD_PREPARE, 0, 0);
@@ -689,10 +572,10 @@ ILevel* CLevelSystem::LoadLevel(const char* _levelName)
ILevel* level = LoadLevelInternal(_levelName);
if (level)
{
- OnLoadingComplete(level);
+ OnLoadingComplete(_levelName);
}
- return level;
+ return (level != nullptr);
}
//------------------------------------------------------------------------
ILevel* CLevelSystem::LoadLevelInternal(const char* _levelName)
@@ -724,7 +607,7 @@ ILevel* CLevelSystem::LoadLevelInternal(const char* _levelName)
m_bLevelLoaded = false;
- const bool bLoadingSameLevel = m_lastLevelName.compareNoCase(levelName) == 0;
+ const bool bLoadingSameLevel = azstricmp(m_lastLevelName.c_str(), levelName) == 0;
m_lastLevelName = levelName;
delete m_pCurrentLevel;
@@ -736,7 +619,7 @@ ILevel* CLevelSystem::LoadLevelInternal(const char* _levelName)
// Read main level info.
if (!pLevelInfo->ReadInfo())
{
- OnLoadingError(pLevelInfo, "Failed to read level info (level.pak might be corrupted)!");
+ OnLoadingError(levelName, "Failed to read level info (level.pak might be corrupted)!");
return 0;
}
//[AlexMcC|19.04.10]: Update the level's LevelInfo
@@ -762,12 +645,12 @@ ILevel* CLevelSystem::LoadLevelInternal(const char* _levelName)
m_pSystem->SetViewCamera(defaultCam);
m_pLoadingLevelInfo = pLevelInfo;
- OnLoadingStart(pLevelInfo);
+ OnLoadingStart(levelName);
auto pPak = gEnv->pCryPak;
- string levelPath = pLevelInfo->GetPath();
+ AZStd::string levelPath(pLevelInfo->GetPath());
/*
ICVar *pFileCache = gEnv->pConsole->GetCVar("sys_FileCache"); CRY_ASSERT(pFileCache);
@@ -793,20 +676,20 @@ ILevel* CLevelSystem::LoadLevelInternal(const char* _levelName)
if (gEnv->p3DEngine)
{
- bool is3DEngineLoaded = gEnv->IsEditor() ? gEnv->p3DEngine->InitLevelForEditor(pLevelInfo->GetPath(), pLevelInfo->GetDefaultGameType()->name)
- : gEnv->p3DEngine->LoadLevel(pLevelInfo->GetPath(), pLevelInfo->GetDefaultGameType()->name);
+ bool is3DEngineLoaded = gEnv->IsEditor() ? gEnv->p3DEngine->InitLevelForEditor(pLevelInfo->GetPath(), pLevelInfo->m_defaultGameTypeName.c_str())
+ : gEnv->p3DEngine->LoadLevel(pLevelInfo->GetPath(), pLevelInfo->m_defaultGameTypeName.c_str());
if (!is3DEngineLoaded)
{
- OnLoadingError(pLevelInfo, "3DEngine failed to handle loading the level");
+ OnLoadingError(levelName, "3DEngine failed to handle loading the level");
return 0;
}
}
// Parse level specific config data.
- string const sLevelNameOnly = PathUtil::GetFileName(levelName);
+ AZStd::string const sLevelNameOnly(PathUtil::GetFileName(levelName));
- if (!sLevelNameOnly.empty() && sLevelNameOnly.compareNoCase("Untitled") != 0)
+ if (!sLevelNameOnly.empty())
{
const char* controlsPath = nullptr;
Audio::AudioSystemRequestBus::BroadcastResult(controlsPath, &Audio::AudioSystemRequestBus::Events::GetControlsPath);
@@ -838,22 +721,29 @@ ILevel* CLevelSystem::LoadLevelInternal(const char* _levelName)
}
}
- string missionXml = pLevelInfo->GetDefaultGameType()->xmlFile;
- string xmlFile = string(pLevelInfo->GetPath()) + "/" + missionXml;
-
- if (!gEnv->IsEditor())
{
- AZStd::string entitiesFilename = AZStd::string::format("%s/%s.entities_xml", pLevelInfo->GetPath(), pLevelInfo->GetDefaultGameType()->name.c_str());
- AZStd::vector fileBuffer;
- CCryFile entitiesFile;
- if (entitiesFile.Open(entitiesFilename.c_str(), "rt"))
- {
- fileBuffer.resize(entitiesFile.GetLength());
+ AZStd::string missionXml("Mission_");
+ missionXml += pLevelInfo->m_defaultGameTypeName;
+ missionXml += ".xml";
+ AZStd::string xmlFile(pLevelInfo->GetPath());
+ xmlFile += "/";
+ xmlFile += missionXml;
- if (fileBuffer.size() == entitiesFile.ReadRaw(fileBuffer.begin(), fileBuffer.size()))
+ if (!gEnv->IsEditor())
+ {
+ AZStd::string entitiesFilename =
+ AZStd::string::format("%s/%s.entities_xml", pLevelInfo->GetPath(), pLevelInfo->m_defaultGameTypeName.c_str());
+ AZStd::vector fileBuffer;
+ CCryFile entitiesFile;
+ if (entitiesFile.Open(entitiesFilename.c_str(), "rt"))
{
- AZ::IO::ByteContainerStream > fileStream(&fileBuffer);
- EBUS_EVENT(AzFramework::GameEntityContextRequestBus, LoadFromStream, fileStream, false);
+ fileBuffer.resize(entitiesFile.GetLength());
+
+ if (fileBuffer.size() == entitiesFile.ReadRaw(fileBuffer.begin(), fileBuffer.size()))
+ {
+ AZ::IO::ByteContainerStream> fileStream(&fileBuffer);
+ EBUS_EVENT(AzFramework::GameEntityContextRequestBus, LoadFromStream, fileStream, false);
+ }
}
}
}
@@ -907,33 +797,6 @@ ILevel* CLevelSystem::LoadLevelInternal(const char* _levelName)
return m_pCurrentLevel;
}
-//------------------------------------------------------------------------
-ILevel* CLevelSystem::SetEditorLoadedLevel(const char* levelName, bool bReadLevelInfoMetaData)
-{
- CLevelInfo* pLevelInfo = GetLevelInfoInternal(levelName);
-
- if (!pLevelInfo)
- {
- gEnv->pLog->LogError("Failed to get level info for level %s!", levelName);
- return 0;
- }
-
- if (bReadLevelInfoMetaData)
- {
- pLevelInfo->ReadMetaData();
- }
-
- m_lastLevelName = levelName;
-
- SAFE_DELETE(m_pCurrentLevel);
- CLevel* pLevel = new CLevel();
- pLevel->m_levelInfo = *pLevelInfo;
- m_pCurrentLevel = pLevel;
- m_bLevelLoaded = true;
-
- return m_pCurrentLevel;
-}
-
//------------------------------------------------------------------------
void CLevelSystem::PrepareNextLevel(const char* levelName)
{
@@ -954,56 +817,52 @@ void CLevelSystem::PrepareNextLevel(const char* levelName)
pLevelInfo->OpenLevelPak();
// switched to level heap, so now imm start the loading screen (renderer will be reinitialized in the levelheap)
- gEnv->pSystem->GetISystemEventDispatcher()->OnSystemEvent(ESYSTEM_EVENT_LEVEL_LOAD_START_LOADINGSCREEN, (UINT_PTR)pLevelInfo, 0);
+ gEnv->pSystem->GetISystemEventDispatcher()->OnSystemEvent(ESYSTEM_EVENT_LEVEL_LOAD_START_LOADINGSCREEN, 0, 0);
gEnv->pSystem->SetSystemGlobalState(ESYSTEM_GLOBAL_STATE_LEVEL_LOAD_START_PREPARE);
// Inform resource manager about loading of the new level.
GetISystem()->GetIResourceManager()->PrepareLevel(pLevelInfo->GetPath(), pLevelInfo->GetName());
}
- for (std::vector::const_iterator it = m_listeners.begin(); it != m_listeners.end(); ++it)
+ for (AZStd::vector::const_iterator it = m_listeners.begin(); it != m_listeners.end(); ++it)
{
- (*it)->OnPrepareNextLevel(pLevelInfo);
+ (*it)->OnPrepareNextLevel(pLevelInfo->GetName());
}
}
//------------------------------------------------------------------------
void CLevelSystem::OnLevelNotFound(const char* levelName)
{
- for (std::vector::const_iterator it = m_listeners.begin(); it != m_listeners.end(); ++it)
+ for (AZStd::vector::const_iterator it = m_listeners.begin(); it != m_listeners.end(); ++it)
{
(*it)->OnLevelNotFound(levelName);
}
}
//------------------------------------------------------------------------
-void CLevelSystem::OnLoadingStart(ILevelInfo* pLevelInfo)
+void CLevelSystem::OnLoadingStart(const char* levelName)
{
if (gEnv->pCryPak->GetRecordFileOpenList() == AZ::IO::IArchive::RFOM_EngineStartup)
{
gEnv->pCryPak->RecordFileOpen(AZ::IO::IArchive::RFOM_Level);
}
- m_fFilteredProgress = 0.f;
m_fLastTime = gEnv->pTimer->GetAsyncCurTime();
GetISystem()->GetISystemEventDispatcher()->OnSystemEvent(ESYSTEM_EVENT_LEVEL_LOAD_START, 0, 0);
LOADING_TIME_PROFILE_SECTION(gEnv->pSystem);
- for (std::vector::const_iterator it = m_listeners.begin(); it != m_listeners.end(); ++it)
+ for (AZStd::vector::const_iterator it = m_listeners.begin(); it != m_listeners.end(); ++it)
{
- (*it)->OnLoadingStart(pLevelInfo);
+ (*it)->OnLoadingStart(levelName);
}
}
//------------------------------------------------------------------------
-void CLevelSystem::OnLoadingError(ILevelInfo* pLevelInfo, const char* error)
+void CLevelSystem::OnLoadingError(const char* levelName, const char* error)
{
- if (!pLevelInfo)
- {
- pLevelInfo = m_pLoadingLevelInfo;
- }
+ ILevelInfo* pLevelInfo = m_pLoadingLevelInfo;
if (!pLevelInfo)
{
CRY_ASSERT(false);
@@ -1015,25 +874,17 @@ void CLevelSystem::OnLoadingError(ILevelInfo* pLevelInfo, const char* error)
gEnv->pRenderer->SetTexturePrecaching(false);
}
- for (std::vector::const_iterator it = m_listeners.begin(); it != m_listeners.end(); ++it)
+ for (AZStd::vector::const_iterator it = m_listeners.begin(); it != m_listeners.end(); ++it)
{
- (*it)->OnLoadingError(pLevelInfo, error);
+ (*it)->OnLoadingError(levelName, error);
}
((CLevelInfo*)pLevelInfo)->CloseLevelPak();
}
//------------------------------------------------------------------------
-void CLevelSystem::OnLoadingComplete(ILevel* pLevelInfo)
+void CLevelSystem::OnLoadingComplete(const char* levelName)
{
- if (m_bRecordingFileOpens)
- {
- // Stop recoding file opens.
- gEnv->pCryPak->RecordFileOpen(AZ::IO::IArchive::RFOM_Disabled);
- // Save recorded list.
- SaveOpenedFilesList();
- }
-
CTimeValue t = gEnv->pTimer->GetAsyncTime();
m_fLastLevelLoadTime = (t - m_levelLoadStartTime).GetSeconds();
@@ -1044,9 +895,9 @@ void CLevelSystem::OnLoadingComplete(ILevel* pLevelInfo)
// Hide console after loading.
gEnv->pConsole->ShowConsole(false);
- for (std::vector::const_iterator it = m_listeners.begin(); it != m_listeners.end(); ++it)
+ for (AZStd::vector::const_iterator it = m_listeners.begin(); it != m_listeners.end(); ++it)
{
- (*it)->OnLoadingComplete(pLevelInfo);
+ (*it)->OnLoadingComplete(levelName);
}
#if AZ_LOADSCREENCOMPONENT_ENABLED
@@ -1055,32 +906,23 @@ void CLevelSystem::OnLoadingComplete(ILevel* pLevelInfo)
}
//------------------------------------------------------------------------
-void CLevelSystem::OnLoadingProgress(ILevelInfo* pLevel, int progressAmount)
+void CLevelSystem::OnLoadingProgress(const char* levelName, int progressAmount)
{
- for (std::vector::const_iterator it = m_listeners.begin(); it != m_listeners.end(); ++it)
+ for (AZStd::vector::const_iterator it = m_listeners.begin(); it != m_listeners.end(); ++it)
{
- (*it)->OnLoadingProgress(pLevel, progressAmount);
+ (*it)->OnLoadingProgress(levelName, progressAmount);
}
}
//------------------------------------------------------------------------
-void CLevelSystem::OnUnloadComplete(ILevel* pLevel)
+void CLevelSystem::OnUnloadComplete(const char* levelName)
{
- for (std::vector::const_iterator it = m_listeners.begin(); it != m_listeners.end(); ++it)
+ for (AZStd::vector::const_iterator it = m_listeners.begin(); it != m_listeners.end(); ++it)
{
- (*it)->OnUnloadComplete(pLevel);
+ (*it)->OnUnloadComplete(levelName);
}
}
-//------------------------------------------------------------------------
-string& CLevelSystem::UnifyName(string& name)
-{
- //name.MakeLower();
- name.replace('\\', '/');
-
- return name;
-}
-
//////////////////////////////////////////////////////////////////////////
void CLevelSystem::LogLoadingTime()
{
@@ -1103,8 +945,8 @@ void CLevelSystem::LogLoadingTime()
sChain = " (Chained)";
}
- string text;
- text.Format("Game Level Load Time: [%s] Level %s loaded in %.2f seconds%s", vers, m_lastLevelName.c_str(), m_fLastLevelLoadTime, sChain);
+ AZStd::string text;
+ text.format("Game Level Load Time: [%s] Level %s loaded in %.2f seconds%s", vers, m_lastLevelName.c_str(), m_fLastLevelLoadTime, sChain);
gEnv->pLog->Log(text.c_str());
}
@@ -1116,77 +958,8 @@ void CLevelSystem::GetMemoryUsage(ICrySizer* pSizer) const
pSizer->AddObject(m_listeners);
}
-void CLevelInfo::GetMemoryUsage(ICrySizer* pSizer) const
-{
- pSizer->AddObject(m_levelName);
- pSizer->AddObject(m_levelPath);
- pSizer->AddObject(m_levelPaks);
- //pSizer->AddObject(m_musicLibs);
- pSizer->AddObject(m_gamerules);
- pSizer->AddObject(m_gameTypes);
-}
-
-
//////////////////////////////////////////////////////////////////////////
-bool CLevelInfo::OpenLevelPak()
-{
- LOADING_TIME_PROFILE_SECTION;
-
- string levelpak = m_levelPath + string("/level.pak");
- AZStd::fixed_string fullLevelPakPath;
- bool bOk = gEnv->pCryPak->OpenPack(levelpak.c_str(), m_isPak ? AZ::IO::IArchive::FLAGS_LEVEL_PAK_INSIDE_PAK : (unsigned)0, NULL, &fullLevelPakPath, false);
- m_levelPakFullPath.assign(fullLevelPakPath.c_str());
- return bOk;
-}
-
-//////////////////////////////////////////////////////////////////////////
-void CLevelInfo::CloseLevelPak()
-{
- LOADING_TIME_PROFILE_SECTION;
- if (!m_levelPakFullPath.empty())
- {
- gEnv->pCryPak->ClosePack(m_levelPakFullPath.c_str(), AZ::IO::IArchive::FLAGS_PATH_REAL);
- stl::free_container(m_levelPakFullPath);
- }
-}
-
-const bool CLevelInfo::IsOfType(const char* sType) const
-{
- for (unsigned int i = 0; i < m_levelTypeList.size(); ++i)
- {
- if (strcmp(m_levelTypeList[i], sType) == 0)
- {
- return true;
- }
- }
-
- return false;
-}
-
-//////////////////////////////////////////////////////////////////////////
-void CLevelSystem::SaveOpenedFilesList()
-{
- if (!m_pLoadingLevelInfo)
- {
- return;
- }
-
- // Write resource list to file.
- string filename = PathUtil::Make(m_pLoadingLevelInfo->GetPath(), "resourcelist.txt");
- AZ::IO::HandleType fileHandle = fxopen(filename.c_str(), "wt", true);
- if (fileHandle != AZ::IO::InvalidHandle)
- {
- auto pResList = gEnv->pCryPak->GetResourceList(AZ::IO::IArchive::RFOM_Level);
- for (const char* fname = pResList->GetFirst(); fname; fname = pResList->GetNext())
- {
- AZ::IO::Print(fileHandle, "%s\n", fname);
- }
- gEnv->pFileIO->Close(fileHandle);
- }
-}
-
-//////////////////////////////////////////////////////////////////////////
-void CLevelSystem::UnLoadLevel()
+void CLevelSystem::UnloadLevel()
{
if (gEnv->IsEditor())
{
@@ -1197,7 +970,7 @@ void CLevelSystem::UnLoadLevel()
return;
}
- CryLog("UnLoadLevel Start");
+ CryLog("UnloadLevel Start");
INDENT_LOG_DURING_SCOPE();
// Flush core buses. We're about to unload Cry modules and need to ensure we don't have module-owned functions left behind.
@@ -1286,7 +1059,7 @@ void CLevelSystem::UnLoadLevel()
CCamera defaultCam;
m_pSystem->SetViewCamera(defaultCam);
- OnUnloadComplete(m_pCurrentLevel);
+ OnUnloadComplete(m_lastLevelName.c_str());
// -- kenzo: this will close all pack files for this level
// (even the ones which were not added through here, if this is not desired,
@@ -1297,7 +1070,7 @@ void CLevelSystem::UnLoadLevel()
m_pLoadingLevelInfo = NULL;
}
- stl::free_container(m_lastLevelName);
+ m_lastLevelName.clear();
GetISystem()->GetIResourceManager()->UnloadLevel();
@@ -1352,7 +1125,7 @@ void CLevelSystem::UnLoadLevel()
m_bLevelLoaded = false;
CTimeValue tUnloadTime = gEnv->pTimer->GetAsyncTime() - tBegin;
- CryLog("UnLoadLevel End: %.1f sec", tUnloadTime.GetSeconds());
+ CryLog("UnloadLevel End: %.1f sec", tUnloadTime.GetSeconds());
// Must be sent last.
// Cleanup all containers
@@ -1360,9 +1133,4 @@ void CLevelSystem::UnLoadLevel()
AzFramework::InputChannelRequestBus::Broadcast(&AzFramework::InputChannelRequests::ResetState);
}
-DynArray* CLevelSystem::GetLevelTypeList()
-{
- return &m_levelTypeList;
-}
-
} // namespace LegacyLevelSystem
diff --git a/Code/CryEngine/CrySystem/LevelSystem/LevelSystem.h b/Code/CryEngine/CrySystem/LevelSystem/LevelSystem.h
index ba39b41df0..2b3f454da5 100644
--- a/Code/CryEngine/CrySystem/LevelSystem/LevelSystem.h
+++ b/Code/CryEngine/CrySystem/LevelSystem/LevelSystem.h
@@ -16,6 +16,8 @@
#include "ILevelSystem.h"
#include
+// [LYN-2376] Remove the entire file once legacy slice support is removed
+
namespace LegacyLevelSystem
{
@@ -24,75 +26,38 @@ class CLevelInfo
{
friend class CLevelSystem;
public:
- CLevelInfo()
- : m_heightmapSize(0)
- , m_bMetaDataRead(false)
- , m_isModLevel(false)
- , m_scanTag(ILevelSystem::TAG_UNKNOWN)
- , m_levelTag(ILevelSystem::TAG_UNKNOWN)
- {
- SwapEndian(m_scanTag, eBigEndian);
- SwapEndian(m_levelTag, eBigEndian);
- };
+ CLevelInfo() = default;
// ILevelInfo
- virtual const char* GetName() const { return m_levelName.c_str(); };
- virtual const bool IsOfType(const char* sType) const;
- virtual const char* GetPath() const { return m_levelPath.c_str(); };
- virtual const char* GetPaks() const { return m_levelPaks.c_str(); };
- virtual bool GetIsModLevel() const { return m_isModLevel; }
- virtual const uint32 GetScanTag() const { return m_scanTag; }
- virtual const uint32 GetLevelTag() const { return m_levelTag; }
- virtual const char* GetDisplayName() const;
- virtual const char* GetPreviewImagePath() const { return m_previewImagePath.c_str(); }
- virtual const char* GetBackgroundImagePath() const { return m_backgroundImagePath.c_str(); }
- virtual const char* GetMinimapImagePath() const {return m_minimapImagePath.c_str(); }
- //virtual const ILevelInfo::TStringVec& GetMusicLibs() const { return m_musicLibs; }; // Gets reintroduced when level specific music data loading is implemented.
- virtual const bool MetadataLoaded() const { return m_bMetaDataRead; }
-
- virtual int GetGameTypeCount() const { return m_gameTypes.size(); };
- virtual const ILevelInfo::TGameTypeInfo* GetGameType(int gameType) const { return &m_gameTypes[gameType]; };
- virtual bool SupportsGameType(const char* gameTypeName) const;
- virtual const ILevelInfo::TGameTypeInfo* GetDefaultGameType() const;
- virtual bool HasGameRules() const{ return !m_gamerules.empty(); }
-
- virtual const ILevelInfo::SMinimapInfo& GetMinimapInfo() const { return m_minimapInfo; }
-
- virtual const char* GetDefaultGameRules() const{ return m_gamerules.empty() ? NULL : m_gamerules[0].c_str(); }
- virtual ILevelInfo::TStringVec GetGameRules() const{ return m_gamerules; }
+ virtual const char* GetName() const { return m_levelName.c_str(); }
+ virtual const char* GetPath() const { return m_levelPath.c_str(); }
+ virtual const char* GetAssetName() const { return m_levelAssetName.c_str(); }
// ~ILevelInfo
void GetMemoryUsage(ICrySizer*) const;
private:
- void ReadMetaData();
bool ReadInfo();
bool OpenLevelPak();
void CloseLevelPak();
- string m_levelName;
- string m_levelPath;
- string m_levelPaks;
- string m_levelDisplayName;
- string m_previewImagePath;
- string m_backgroundImagePath;
- string m_minimapImagePath;
+ AZStd::string m_defaultGameTypeName;
+ AZStd::string m_levelName;
+ AZStd::string m_levelPath;
+ AZStd::string m_levelAssetName;
- string m_levelPakFullPath;
+ AZStd::string m_levelPakFullPath;
- TStringVec m_gamerules;
- int m_heightmapSize;
- uint32 m_scanTag;
- uint32 m_levelTag;
- bool m_bMetaDataRead;
- std::vector m_gameTypes;
- bool m_isModLevel;
- SMinimapInfo m_minimapInfo;
+ bool m_isPak = false;
+};
- DynArray m_levelTypeList;
- bool m_isPak = false;
+struct ILevel
+{
+ virtual ~ILevel() = default;
+ virtual void Release() = 0;
+ virtual ILevelInfo* GetLevelInfo() = 0;
};
class CLevel
@@ -121,10 +86,7 @@ public:
void Release() { delete this; };
// ILevelSystem
- virtual DynArray* GetLevelTypeList();
- virtual void Rescan(const char* levelsFolder, const uint32 tag);
- void ScanFolder(const char* subfolder, bool modFolder, const uint32 tag) override;
- void PopulateLevels(string searchPattern, string& folder, AZ::IO::IArchive* pPak, bool& modFolder, const uint32& tag, bool fromFileSystemOnly) override;
+ virtual void Rescan(const char* levelsFolder);
virtual int GetLevelCount();
virtual ILevelInfo* GetLevelInfo(int level);
virtual ILevelInfo* GetLevelInfo(const char* levelName);
@@ -132,74 +94,81 @@ public:
virtual void AddListener(ILevelSystemListener* pListener);
virtual void RemoveListener(ILevelSystemListener* pListener);
- virtual ILevel* GetCurrentLevel() const { return m_pCurrentLevel; }
- virtual ILevel* LoadLevel(const char* levelName);
- virtual void UnLoadLevel();
- virtual ILevel* SetEditorLoadedLevel(const char* levelName, bool bReadLevelInfoMetaData = false);
- virtual void PrepareNextLevel(const char* levelName);
- virtual float GetLastLevelLoadTime() { return m_fLastLevelLoadTime; };
+ virtual bool LoadLevel(const char* levelName);
+ virtual void UnloadLevel();
virtual bool IsLevelLoaded() { return m_bLevelLoaded; }
+ const char* GetCurrentLevelName() const override
+ {
+ if (m_pCurrentLevel && m_pCurrentLevel->GetLevelInfo())
+ {
+ return m_pCurrentLevel->GetLevelInfo()->GetName();
+ }
+ else
+ {
+ return "";
+ }
+ }
// If the level load failed then we need to have a different shutdown procedure vs when a level is naturally unloaded
virtual void SetLevelLoadFailed(bool loadFailed) { m_levelLoadFailed = loadFailed; }
virtual bool GetLevelLoadFailed() { return m_levelLoadFailed; }
+ // Unsupported by legacy level system.
+ virtual AZ::Data::AssetType GetLevelAssetType() const { return {}; }
+
// ~ILevelSystem
void GetMemoryUsage(ICrySizer* s) const;
- void SaveOpenedFilesList();
-
private:
+ float GetLastLevelLoadTime() { return m_fLastLevelLoadTime; }
+
+ void ScanFolder(const char* subfolder, bool modFolder);
+ void PopulateLevels(
+ AZStd::string searchPattern, AZStd::string& folder, AZ::IO::IArchive* pPak, bool& modFolder, bool fromFileSystemOnly);
+ void PrepareNextLevel(const char* levelName);
ILevel* LoadLevelInternal(const char* _levelName);
- // ILevelSystemListener events notification
+ // Methods to notify ILevelSystemListener
void OnLevelNotFound(const char* levelName);
- void OnLoadingStart(ILevelInfo* pLevel);
- void OnLoadingComplete(ILevel* pLevel);
- void OnLoadingError(ILevelInfo* pLevel, const char* error);
- void OnLoadingProgress(ILevelInfo* pLevel, int progressAmount);
- void OnUnloadComplete(ILevel* pLevel);
+ void OnLoadingStart(const char* levelName);
+ void OnLoadingComplete(const char* levelName);
+ void OnLoadingError(const char* levelName, const char* error);
+ void OnLoadingProgress(const char* levelName, int progressAmount);
+ void OnUnloadComplete(const char* levelName);
- // lowercase string and replace backslashes with forward slashes
- // TODO: move this to a more general place in CryEngine
- string& UnifyName(string& name);
void LogLoadingTime();
bool LoadLevelInfo(CLevelInfo& levelInfo);
// internal get functions for the level infos ... they preserve the type and don't
// directly cast to the interface
CLevelInfo* GetLevelInfoInternal(int level);
- CLevelInfo* GetLevelInfoInternal(const char* levelName);
+ CLevelInfo* GetLevelInfoInternal(const AZStd::string& levelName);
ISystem* m_pSystem;
- std::vector m_levelInfos;
- string m_levelsFolder;
+ AZStd::vector m_levelInfos;
+ AZStd::string m_levelsFolder;
ILevel* m_pCurrentLevel;
ILevelInfo* m_pLoadingLevelInfo;
- string m_lastLevelName;
+ AZStd::string m_lastLevelName;
float m_fLastLevelLoadTime;
- float m_fFilteredProgress;
float m_fLastTime;
bool m_bLevelLoaded;
- bool m_bRecordingFileOpens;
bool m_levelLoadFailed = false;
int m_nLoadedLevelsCount;
CTimeValue m_levelLoadStartTime;
- static int s_loadCount;
-
- std::vector