diff --git a/Assets/Editor/Presets/GeomCache/game.cbc b/Assets/Editor/Presets/GeomCache/game.cbc
deleted file mode 100644
index 9b98f3460f..0000000000
--- a/Assets/Editor/Presets/GeomCache/game.cbc
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/Assets/Editor/Presets/GeomCache/game_lz4hc.cbc b/Assets/Editor/Presets/GeomCache/game_lz4hc.cbc
deleted file mode 100644
index dbd0499175..0000000000
--- a/Assets/Editor/Presets/GeomCache/game_lz4hc.cbc
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/Assets/Editor/Presets/GeomCache/game_z_up.cbc b/Assets/Editor/Presets/GeomCache/game_z_up.cbc
deleted file mode 100644
index ec2555a3e3..0000000000
--- a/Assets/Editor/Presets/GeomCache/game_z_up.cbc
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/Assets/Editor/Presets/GeomCache/game_z_up_lz4hc.cbc b/Assets/Editor/Presets/GeomCache/game_z_up_lz4hc.cbc
deleted file mode 100644
index c2e30a6386..0000000000
--- a/Assets/Editor/Presets/GeomCache/game_z_up_lz4hc.cbc
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/Assets/Editor/Presets/GeomCache/prerendered.cbc b/Assets/Editor/Presets/GeomCache/prerendered.cbc
deleted file mode 100644
index c09785111d..0000000000
--- a/Assets/Editor/Presets/GeomCache/prerendered.cbc
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/Assets/Editor/Presets/GeomCache/prerendered_z_up.cbc b/Assets/Editor/Presets/GeomCache/prerendered_z_up.cbc
deleted file mode 100644
index e42a915e58..0000000000
--- a/Assets/Editor/Presets/GeomCache/prerendered_z_up.cbc
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/Assets/Editor/Presets/GeomCache/rigids_only.cbc b/Assets/Editor/Presets/GeomCache/rigids_only.cbc
deleted file mode 100644
index e8620bc11e..0000000000
--- a/Assets/Editor/Presets/GeomCache/rigids_only.cbc
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/Assets/Editor/Presets/GeomCache/rigids_only_z_up.cbc b/Assets/Editor/Presets/GeomCache/rigids_only_z_up.cbc
deleted file mode 100644
index d1f8bc2db3..0000000000
--- a/Assets/Editor/Presets/GeomCache/rigids_only_z_up.cbc
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/Assets/Editor/Presets/GeomCache/uncompressed.cbc b/Assets/Editor/Presets/GeomCache/uncompressed.cbc
deleted file mode 100644
index e21d52d9d1..0000000000
--- a/Assets/Editor/Presets/GeomCache/uncompressed.cbc
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/Assets/Editor/Presets/GeomCache/uncompressed_z_up.cbc b/Assets/Editor/Presets/GeomCache/uncompressed_z_up.cbc
deleted file mode 100644
index 273ce1fbb1..0000000000
--- a/Assets/Editor/Presets/GeomCache/uncompressed_z_up.cbc
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/Assets/Engine/EngineAssets/GeomCaches/defaultGeomCache.abc b/Assets/Engine/EngineAssets/GeomCaches/defaultGeomCache.abc
deleted file mode 100644
index 8ca759d342..0000000000
--- a/Assets/Engine/EngineAssets/GeomCaches/defaultGeomCache.abc
+++ /dev/null
@@ -1,3 +0,0 @@
-version https://git-lfs.github.com/spec/v1
-oid sha256:9c36d7bc993ddf616f478115a123efabda5b4b833a4e6524312f43c228ae0902
-size 487003
diff --git a/Assets/Engine/EngineAssets/GeomCaches/defaultGeomCache.cbc b/Assets/Engine/EngineAssets/GeomCaches/defaultGeomCache.cbc
deleted file mode 100644
index 3c99ab1627..0000000000
--- a/Assets/Engine/EngineAssets/GeomCaches/defaultGeomCache.cbc
+++ /dev/null
@@ -1 +0,0 @@
-
diff --git a/Assets/Engine/EngineAssets/GeomCaches/defaultGeomCache.ma b/Assets/Engine/EngineAssets/GeomCaches/defaultGeomCache.ma
deleted file mode 100644
index 65aade11a0..0000000000
--- a/Assets/Engine/EngineAssets/GeomCaches/defaultGeomCache.ma
+++ /dev/null
@@ -1,3 +0,0 @@
-version https://git-lfs.github.com/spec/v1
-oid sha256:96a21446422b834ea90a5d38eaaca309fdee31dc3cc03c0e9c094b39ec3a459d
-size 4715164
diff --git a/Assets/Engine/EngineAssets/GeomCaches/defaultGeomCache.mtl b/Assets/Engine/EngineAssets/GeomCaches/defaultGeomCache.mtl
deleted file mode 100644
index 05dfe70b09..0000000000
--- a/Assets/Engine/EngineAssets/GeomCaches/defaultGeomCache.mtl
+++ /dev/null
@@ -1,17 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/AutomatedTesting/Gem/Code/Platform/Mac/runtime_dependencies.cmake b/AutomatedTesting/Gem/Code/Platform/Mac/runtime_dependencies.cmake
index 4d5680a30d..f9d1e60dda 100644
--- a/AutomatedTesting/Gem/Code/Platform/Mac/runtime_dependencies.cmake
+++ b/AutomatedTesting/Gem/Code/Platform/Mac/runtime_dependencies.cmake
@@ -8,3 +8,8 @@
# remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
#
+
+set(GEM_DEPENDENCIES
+ Gem::Atom_RHI_Metal.Private
+ Gem::Atom_RHI_Null.Private
+)
\ No newline at end of file
diff --git a/AutomatedTesting/Gem/Code/Platform/Mac/tool_dependencies.cmake b/AutomatedTesting/Gem/Code/Platform/Mac/tool_dependencies.cmake
index 4d5680a30d..2e9d450ab8 100644
--- a/AutomatedTesting/Gem/Code/Platform/Mac/tool_dependencies.cmake
+++ b/AutomatedTesting/Gem/Code/Platform/Mac/tool_dependencies.cmake
@@ -8,3 +8,12 @@
# remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
#
+
+set(GEM_DEPENDENCIES
+ Gem::Atom_RHI_Null.Private
+ Gem::Atom_RHI_Null.Builders
+ Gem::Atom_RHI_Metal.Private
+ Gem::Atom_RHI_Metal.Builders
+ Gem::Atom_RHI_Vulkan.Builders
+ Gem::Atom_RHI_DX12.Builders
+)
\ No newline at end of file
diff --git a/AutomatedTesting/Gem/PythonTests/CMakeLists.txt b/AutomatedTesting/Gem/PythonTests/CMakeLists.txt
index 6d3727195e..31afab87ed 100644
--- a/AutomatedTesting/Gem/PythonTests/CMakeLists.txt
+++ b/AutomatedTesting/Gem/PythonTests/CMakeLists.txt
@@ -51,7 +51,7 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS)
TEST_SUITE sandbox
TEST_SERIAL
PATH ${CMAKE_CURRENT_LIST_DIR}/physics/TestSuite_Sandbox.py
- TIMEOUT 3600
+ TIMEOUT 1500
RUNTIME_DEPENDENCIES
Legacy::Editor
AZ::AssetProcessor
@@ -68,7 +68,7 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS)
TEST_SUITE periodic
TEST_SERIAL
PATH ${CMAKE_CURRENT_LIST_DIR}/scripting/TestSuite_Active.py
- TIMEOUT 1500
+ TIMEOUT 3000
RUNTIME_DEPENDENCIES
Legacy::Editor
AZ::AssetProcessor
@@ -181,12 +181,30 @@ include(${pal_dir}/PAL_traits_${PAL_PLATFORM_NAME_LOWERCASE}.cmake)
if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS AND PAL_TRAIT_LARGE_WORLDS_TEST_SUPPORTED)
## DynVeg ##
+ # Temporarily moving all tests to periodic suite - SPEC-6553
+ #ly_add_pytest(
+ # NAME AutomatedTesting::DynamicVegetationTests_Main
+ # TEST_SERIAL
+ # TEST_SUITE main
+ # PATH ${CMAKE_CURRENT_LIST_DIR}/largeworlds/dyn_veg
+ # PYTEST_MARKS "not SUITE_sandbox and not SUITE_periodic and not SUITE_benchmark"
+ # TIMEOUT 1500
+ # RUNTIME_DEPENDENCIES
+ # AZ::AssetProcessor
+ # Legacy::Editor
+ # AutomatedTesting.GameLauncher
+ # AutomatedTesting.Assets
+ # COMPONENT
+ # LargeWorlds
+ #)
+
+
ly_add_pytest(
- NAME AutomatedTesting::DynamicVegetationTests_Main
+ NAME AutomatedTesting::DynamicVegetationTests_Sandbox
TEST_SERIAL
- TEST_SUITE main
+ TEST_SUITE sandbox
PATH ${CMAKE_CURRENT_LIST_DIR}/largeworlds/dyn_veg
- PYTEST_MARKS "not SUITE_sandbox and not SUITE_periodic and not SUITE_benchmark"
+ PYTEST_MARKS "SUITE_sandbox"
TIMEOUT 1500
RUNTIME_DEPENDENCIES
AZ::AssetProcessor
@@ -198,27 +216,26 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS AND PAL_TRAIT_
)
ly_add_pytest(
- NAME AutomatedTesting::DynamicVegetationTests_Sandbox
+ NAME AutomatedTesting::DynamicVegetationFilterTests_Periodic
TEST_SERIAL
- TEST_SUITE sandbox
+ TEST_SUITE periodic
PATH ${CMAKE_CURRENT_LIST_DIR}/largeworlds/dyn_veg
- PYTEST_MARKS "SUITE_sandbox"
+ PYTEST_MARKS "SUITE_periodic and dynveg_filter"
TIMEOUT 1500
RUNTIME_DEPENDENCIES
AZ::AssetProcessor
Legacy::Editor
- AutomatedTesting.GameLauncher
AutomatedTesting.Assets
COMPONENT
LargeWorlds
)
ly_add_pytest(
- NAME AutomatedTesting::DynamicVegetationTests_Periodic
+ NAME AutomatedTesting::DynamicVegetationModifierTests_Periodic
TEST_SERIAL
TEST_SUITE periodic
PATH ${CMAKE_CURRENT_LIST_DIR}/largeworlds/dyn_veg
- PYTEST_MARKS "SUITE_periodic"
+ PYTEST_MARKS "SUITE_periodic and dynveg_modifier"
TIMEOUT 1500
RUNTIME_DEPENDENCIES
AZ::AssetProcessor
@@ -228,22 +245,82 @@ if(PAL_TRAIT_BUILD_TESTS_SUPPORTED AND PAL_TRAIT_BUILD_HOST_TOOLS AND PAL_TRAIT_
LargeWorlds
)
-## LandscapeCanvas ##
ly_add_pytest(
- NAME AutomatedTesting::LandscapeCanvasTests_Main
+ NAME AutomatedTesting::DynamicVegetationRegressionTests_Periodic
TEST_SERIAL
- TEST_SUITE main
- PATH ${CMAKE_CURRENT_LIST_DIR}/largeworlds/landscape_canvas
- PYTEST_MARKS "not SUITE_sandbox and not SUITE_periodic and not SUITE_benchmark"
+ TEST_SUITE periodic
+ PATH ${CMAKE_CURRENT_LIST_DIR}/largeworlds/dyn_veg
+ PYTEST_MARKS "SUITE_periodic and dynveg_regression"
TIMEOUT 1500
RUNTIME_DEPENDENCIES
- AZ::AssetProcessor
- Legacy::Editor
- AutomatedTesting.Assets
+ AZ::AssetProcessor
+ Legacy::Editor
+ AutomatedTesting.Assets
COMPONENT
LargeWorlds
)
+ ly_add_pytest(
+ NAME AutomatedTesting::DynamicVegetationAreaTests_Periodic
+ TEST_SERIAL
+ TEST_SUITE periodic
+ PATH ${CMAKE_CURRENT_LIST_DIR}/largeworlds/dyn_veg
+ PYTEST_MARKS "SUITE_periodic and dynveg_area"
+ TIMEOUT 1500
+ RUNTIME_DEPENDENCIES
+ AZ::AssetProcessor
+ Legacy::Editor
+ AutomatedTesting.Assets
+ COMPONENT
+ LargeWorlds
+ )
+
+ ly_add_pytest(
+ NAME AutomatedTesting::DynamicVegetationMiscTests_Periodic
+ TEST_SERIAL
+ TEST_SUITE periodic
+ PATH ${CMAKE_CURRENT_LIST_DIR}/largeworlds/dyn_veg
+ PYTEST_MARKS "SUITE_periodic and dynveg_misc"
+ TIMEOUT 1500
+ RUNTIME_DEPENDENCIES
+ AZ::AssetProcessor
+ Legacy::Editor
+ AutomatedTesting.Assets
+ COMPONENT
+ LargeWorlds
+ )
+
+ ly_add_pytest(
+ NAME AutomatedTesting::DynamicVegetationSurfaceTagTests_Periodic
+ TEST_SERIAL
+ TEST_SUITE periodic
+ PATH ${CMAKE_CURRENT_LIST_DIR}/largeworlds/dyn_veg
+ PYTEST_MARKS "SUITE_periodic and dynveg_surfacetagemitter"
+ TIMEOUT 1500
+ RUNTIME_DEPENDENCIES
+ AZ::AssetProcessor
+ Legacy::Editor
+ AutomatedTesting.Assets
+ COMPONENT
+ LargeWorlds
+ )
+## LandscapeCanvas ##
+ # Temporarily moving all tests to periodic suite - SPEC-6553
+ #ly_add_pytest(
+ # NAME AutomatedTesting::LandscapeCanvasTests_Main
+ # TEST_SERIAL
+ # TEST_SUITE main
+ # PATH ${CMAKE_CURRENT_LIST_DIR}/largeworlds/landscape_canvas
+ # PYTEST_MARKS "not SUITE_sandbox and not SUITE_periodic and not SUITE_benchmark"
+ # TIMEOUT 1500
+ # RUNTIME_DEPENDENCIES
+ # AZ::AssetProcessor
+ # Legacy::Editor
+ # AutomatedTesting.Assets
+ # COMPONENT
+ # LargeWorlds
+ #)
+
ly_add_pytest(
NAME AutomatedTesting::LandscapeCanvasTests_Periodic
TEST_SERIAL
diff --git a/AutomatedTesting/Gem/PythonTests/EditorPythonBindings/CryMaterialsCommands_test.py b/AutomatedTesting/Gem/PythonTests/EditorPythonBindings/CryMaterialsCommands_test.py
deleted file mode 100755
index 41ae0608a4..0000000000
--- a/AutomatedTesting/Gem/PythonTests/EditorPythonBindings/CryMaterialsCommands_test.py
+++ /dev/null
@@ -1,75 +0,0 @@
-"""
-All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
-its licensors.
-
-For complete copyright and license terms please see the LICENSE at the root of this
-distribution (the "License"). All use of this software is governed by the License,
-or, if provided, by the license below or the license accompanying this file. Do not
-remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-"""
-
-#
-# This is a pytest module to test the in-Editor Python API from ViewPane.h
-#
-import pytest
-pytest.importorskip('ly_test_tools')
-
-import sys
-import os
-sys.path.append(os.path.dirname(__file__))
-from hydra_utils import launch_test_case
-
-
-@pytest.mark.SUITE_sandbox
-@pytest.mark.parametrize('launcher_platform', ['windows_editor'])
-@pytest.mark.parametrize('project', ['AutomatedTesting'])
-@pytest.mark.parametrize('level', ['auto_test'])
-class TestLegacyCryMaterialsCommandsAutomation(object):
-
- def test_Legacy_CryMaterials(self, request, editor, level, launcher_platform):
-
- unexpected_lines=[]
- expected_lines = [
- # "Material Settings/Shader updated correctly", # Disabled, SPEC-3590
- # "Material Settings/Surface Type updated correctly", # Disabled, SPEC-3590
- "Texture Maps/Diffuse/Tiling/IsTileU updated correctly",
- "Texture Maps/Diffuse/Tiling/TileU updated correctly",
- "Texture Maps/Diffuse/Rotator/Type updated correctly",
- "Texture Maps/Diffuse/Rotator/Amplitude updated correctly",
- "Texture Maps/Diffuse/Oscillator/AmplitudeU updated correctly",
- "Opacity Settings/Opacity updated correctly",
- "Opacity Settings/AlphaTest updated correctly",
- "Opacity Settings/Additive updated correctly",
- "Lighting Settings/Diffuse Color updated correctly",
- "Lighting Settings/Specular Color updated correctly",
- "Lighting Settings/Emissive Intensity updated correctly",
- "Lighting Settings/Emissive Color updated correctly",
- "Advanced/Allow layer activation updated correctly",
- "Advanced/2 Sided updated correctly",
- "Advanced/No Shadow updated correctly",
- "Advanced/Use Scattering updated correctly",
- "Advanced/Hide After Breaking updated correctly",
- "Advanced/Fog Volume Shading Quality High updated correctly",
- "Advanced/Blend Terrain Color updated correctly",
- "Advanced/Voxel Coverage updated correctly",
- "Advanced/Propagate Opacity Settings updated correctly",
- "Advanced/Propagate Lighting Settings updated correctly",
- "Advanced/Propagate Advanced Settings updated correctly",
- "Advanced/Propagate Texture Maps updated correctly",
- "Advanced/Propagate Shader Params updated correctly",
- "Advanced/Propagate Shader Generation updated correctly",
- "Advanced/Propagate Vertex Deformation updated correctly",
- # "Shader Params/Blend Factor updated correctly", # Disabled, SPEC-3590
- # "Shader Params/Indirect bounce color updated correctly", # Disabled, SPEC-3590
- "Vertex Deformation/Type updated correctly",
- "Vertex Deformation/Wave Length X updated correctly",
- "Vertex Deformation/Wave X/Level updated correctly",
- "Vertex Deformation/Wave X/Amplitude updated correctly",
- "Vertex Deformation/Wave X/Phase updated correctly",
- "Vertex Deformation/Wave X/Frequency updated correctly"
- ]
-
- test_case_file = os.path.join(os.path.dirname(__file__), 'CryMaterialsCommands_test_case.py')
- launch_test_case(editor, test_case_file, expected_lines, unexpected_lines)
-
diff --git a/AutomatedTesting/Gem/PythonTests/EditorPythonBindings/CryMaterialsCommands_test_case.py b/AutomatedTesting/Gem/PythonTests/EditorPythonBindings/CryMaterialsCommands_test_case.py
deleted file mode 100755
index 913b1ace24..0000000000
--- a/AutomatedTesting/Gem/PythonTests/EditorPythonBindings/CryMaterialsCommands_test_case.py
+++ /dev/null
@@ -1,116 +0,0 @@
-"""
-All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
-its licensors.
-
-For complete copyright and license terms please see the LICENSE at the root of this
-distribution (the "License"). All use of this software is governed by the License,
-or, if provided, by the license below or the license accompanying this file. Do not
-remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-"""
-
-# Tests the legacy Python API for CryMaterials while the Editor is running
-
-import azlmbr.bus as bus
-import azlmbr.editor as editor
-import azlmbr.legacy.material as material
-import azlmbr.math as math
-
-materialName = 'materials/ter_layer_green'
-print(f'Starting CryMaterial test case using material {materialName}')
-
-
-def MaterialPropertyTest(property, value, doReset=True):
- try:
- # get old value and attempt to set new value
- oldValue = material.get_property(materialName, property)
- if oldValue == value:
- print(f'>>> `{property}` already set to {oldValue}')
- return
- material.set_property(materialName, property, value)
-
- # test that the set new value worked
- newValue = material.get_property(materialName, property)
- if oldValue != newValue:
- print(f"{property} updated correctly")
-
- # reset back to old value
- if doReset:
- material.set_property(materialName, property, oldValue)
- except:
- print(f'!!! hit an exception when setting `{property}` to {value}')
-
-
-color = math.Color()
-color.r = 255.0
-color.g = 128.0
-color.b = 64.0
-color.a = 0.0
-
-# Material Settings
-# MaterialPropertyTest("Material Settings/Shader", "Geometrybeam") # Disabled, SPEC-3590
-# MaterialPropertyTest("Material Settings/Surface Type", "grass") # Disabled, SPEC-3590
-
-# Texture Maps
-MaterialPropertyTest("Texture Maps/Diffuse/Tiling/IsTileU", False)
-MaterialPropertyTest("Texture Maps/Diffuse/Tiling/IsTileV", False)
-MaterialPropertyTest("Texture Maps/Diffuse/Tiling/TileU", 0.42)
-MaterialPropertyTest("Texture Maps/Diffuse/Rotator/Type", 'Oscillated Rotation')
-MaterialPropertyTest("Texture Maps/Diffuse/Rotator/Amplitude", 42.0)
-MaterialPropertyTest("Texture Maps/Diffuse/Oscillator/TypeU", 'Fixed Moving')
-MaterialPropertyTest("Texture Maps/Diffuse/Oscillator/AmplitudeU", 42.0)
-
-# Vertex Deformation
-MaterialPropertyTest("Vertex Deformation/Type", 'Sin Wave')
-MaterialPropertyTest("Vertex Deformation/Wave Length X", 42.0)
-MaterialPropertyTest("Vertex Deformation/Type", 'Perlin 3D')
-MaterialPropertyTest("Vertex Deformation/Noise Scale", math.Vector3(1.1, 2.2, 3.3))
-
-# Opacity Settings
-MaterialPropertyTest("Opacity Settings/Opacity", 42)
-MaterialPropertyTest("Opacity Settings/AlphaTest", 2)
-MaterialPropertyTest("Opacity Settings/Additive", True)
-
-# Lighting Settings
-MaterialPropertyTest("Lighting Settings/Diffuse Color", color)
-MaterialPropertyTest("Lighting Settings/Specular Color", color)
-MaterialPropertyTest("Lighting Settings/Emissive Intensity", 42.0)
-MaterialPropertyTest("Lighting Settings/Emissive Color", color)
-MaterialPropertyTest("Lighting Settings/Specular Level", 2.0)
-
-# Advanced
-MaterialPropertyTest("Advanced/Allow layer activation", False)
-MaterialPropertyTest("Advanced/2 Sided", True)
-MaterialPropertyTest("Advanced/No Shadow", True)
-MaterialPropertyTest("Advanced/Use Scattering", True)
-MaterialPropertyTest("Advanced/Hide After Breaking", True)
-MaterialPropertyTest("Advanced/Fog Volume Shading Quality High", True)
-MaterialPropertyTest("Advanced/Blend Terrain Color", True)
-MaterialPropertyTest("Advanced/Voxel Coverage", 0.42)
-# --- MaterialPropertyTest("Advanced/Link to Material", "materials/ter_layer_blue") # Works, but clears on UI refresh
-MaterialPropertyTest("Advanced/Propagate Opacity Settings", True)
-MaterialPropertyTest("Advanced/Propagate Lighting Settings", True)
-MaterialPropertyTest("Advanced/Propagate Advanced Settings", True)
-MaterialPropertyTest("Advanced/Propagate Texture Maps", True)
-MaterialPropertyTest("Advanced/Propagate Shader Params", True)
-MaterialPropertyTest("Advanced/Propagate Shader Generation", True)
-MaterialPropertyTest("Advanced/Propagate Vertex Deformation", True)
-
-# Shader parameters vary with each Shader, just testing a couple of them...
-# MaterialPropertyTest("Shader Params/Blend Factor", 7.0, False) # Disabled, SPEC-3590
-# MaterialPropertyTest("Shader Params/Indirect bounce color", color, False) # Disabled, SPEC-3590
-
-### These values are reset to False when set. Left them here commented for reference.
-# MaterialPropertyTest("Shader Generation Params/Dust & Turbulence", True)
-# MaterialPropertyTest("Shader Generation Params/Receive Shadows", True)
-# MaterialPropertyTest("Shader Generation Params/UV Vignetting", True)
-
-# Vertex Deformation
-MaterialPropertyTest("Vertex Deformation/Type", "Sin Wave")
-MaterialPropertyTest("Vertex Deformation/Wave Length X", 42.0)
-MaterialPropertyTest("Vertex Deformation/Wave X/Level", 42.0)
-MaterialPropertyTest("Vertex Deformation/Wave X/Amplitude", 42.0)
-MaterialPropertyTest("Vertex Deformation/Wave X/Phase", 42.0)
-MaterialPropertyTest("Vertex Deformation/Wave X/Frequency", 42.0)
-
-editor.EditorToolsApplicationRequestBus(bus.Broadcast, 'ExitNoPrompt')
diff --git a/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/utils.py b/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/utils.py
index a9f6d0aa02..c7f1aba031 100644
--- a/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/utils.py
+++ b/AutomatedTesting/Gem/PythonTests/EditorPythonTestTools/editor_python_test_tools/utils.py
@@ -265,6 +265,7 @@ class Tracer:
self.warnings = []
self.errors = []
self.asserts = []
+ self.prints = []
self.has_warnings = False
self.has_errors = False
self.has_asserts = False
@@ -310,6 +311,11 @@ class Tracer:
def __repr__(self):
return f"[Assert: {self.message}]"
+
+ class PrintInfo:
+ def __init__(self, args):
+ self.window = args[0]
+ self.message = args[1]
def _on_warning(self, args):
warningInfo = Tracer.WarningInfo(args)
@@ -331,13 +337,19 @@ class Tracer:
Report.info("Tracer caught Assert: %s:%i[%s] \"%s\"" % (assertInfo.filename, assertInfo.line, assertInfo.function, assertInfo.message))
self.has_asserts = True
return False
-
+
+ def _on_printf(self, args):
+ printInfo = Tracer.PrintInfo(args)
+ self.prints.append(printInfo)
+ return False
+
def __enter__(self):
self.handler = azlmbr.debug.TraceMessageBusHandler()
self.handler.connect(None)
self.handler.add_callback("OnPreAssert", self._on_assert)
self.handler.add_callback("OnPreWarning", self._on_warning)
self.handler.add_callback("OnPreError", self._on_error)
+ self.handler.add_callback("OnPrintf", self._on_printf)
return self
def __exit__(self, type, value, traceback):
diff --git a/AutomatedTesting/Gem/PythonTests/atom_renderer/atom_hydra_scripts/hydra_AtomEditorComponents_AddedToEntity.py b/AutomatedTesting/Gem/PythonTests/atom_renderer/atom_hydra_scripts/hydra_AtomEditorComponents_AddedToEntity.py
index 062c449ab7..e701ff8d16 100644
--- a/AutomatedTesting/Gem/PythonTests/atom_renderer/atom_hydra_scripts/hydra_AtomEditorComponents_AddedToEntity.py
+++ b/AutomatedTesting/Gem/PythonTests/atom_renderer/atom_hydra_scripts/hydra_AtomEditorComponents_AddedToEntity.py
@@ -161,20 +161,6 @@ def run():
# Deletion/Undo/Redo test
verify_deletion_undo_redo(self.component_name, entity_obj)
- # Area Light Component
- area_light = "Area Light"
- ComponentTests(
- area_light, lambda entity_obj: verify_required_component_addition(
- entity_obj, ["Capsule Shape"], area_light))
-
- # Decal Component
- material_asset_path = os.path.join("AutomatedTesting", "Materials", "basic_grey.material")
- material_asset = asset.AssetCatalogRequestBus(
- bus.Broadcast, "GetAssetIdByPath", material_asset_path, math.Uuid(), False)
- ComponentTests(
- "Decal (Atom)", lambda entity_obj: verify_set_property(
- entity_obj, "Controller|Configuration|Material", material_asset))
-
# DepthOfField Component
camera_entity = hydra.Entity("camera_entity")
camera_entity.create_entity(math.Vector3(512.0, 512.0, 34.0), ["Camera"])
@@ -185,6 +171,14 @@ def run():
lambda entity_obj: verify_set_property(
entity_obj, "Controller|Configuration|Camera Entity", camera_entity.id))
+ # Decal Component
+ material_asset_path = os.path.join("AutomatedTesting", "Materials", "basic_grey.material")
+ material_asset = asset.AssetCatalogRequestBus(
+ bus.Broadcast, "GetAssetIdByPath", material_asset_path, math.Uuid(), False)
+ ComponentTests(
+ "Decal (Atom)", lambda entity_obj: verify_set_property(
+ entity_obj, "Controller|Configuration|Material", material_asset))
+
# Directional Light Component
ComponentTests(
"Directional Light",
@@ -213,9 +207,6 @@ def run():
# Physical Sky Component
ComponentTests("Physical Sky")
- # Point Light Component
- ComponentTests("Point Light")
-
# PostFX Layer Component
ComponentTests("PostFX Layer")
diff --git a/AutomatedTesting/Gem/PythonTests/atom_renderer/test_Atom_MainSuite.py b/AutomatedTesting/Gem/PythonTests/atom_renderer/test_Atom_MainSuite.py
index 16139e3f66..aafa2ff9b7 100644
--- a/AutomatedTesting/Gem/PythonTests/atom_renderer/test_Atom_MainSuite.py
+++ b/AutomatedTesting/Gem/PythonTests/atom_renderer/test_Atom_MainSuite.py
@@ -27,194 +27,6 @@ TEST_DIRECTORY = os.path.join(os.path.dirname(__file__), "atom_hydra_scripts")
@pytest.mark.parametrize("level", ["auto_test"])
class TestAtomEditorComponentsMain(object):
- @pytest.mark.test_case_id(
- "C32078117", # Area Light
- "C32078130", # Display Mapper
- "C32078129", # Light
- "C32078131", # Radius Weight Modifier
- "C32078127", # PostFX Layer
- "C32078126", # Point Light
- "C32078125", # Physical Sky
- "C32078115", # Global Skylight (IBL)
- "C32078121", # Exposure Control
- "C32078120", # Directional Light
- "C32078119", # DepthOfField
- "C32078118") # Decal
- def test_AtomEditorComponents_AddedToEntity(self, request, editor, level, workspace, project, launcher_platform):
- cfg_args = [level]
-
- expected_lines = [
- # Area Light Component
- "Area Light Entity successfully created",
- "Area Light_test: Component added to the entity: True",
- "Area Light_test: Component removed after UNDO: True",
- "Area Light_test: Component added after REDO: True",
- "Area Light_test: Entered game mode: True",
- "Area Light_test: Entity enabled after adding required components: True",
- "Area Light_test: Entity is hidden: True",
- "Area Light_test: Entity is shown: True",
- "Area Light_test: Entity deleted: True",
- "Area Light_test: UNDO entity deletion works: True",
- "Area Light_test: REDO entity deletion works: True",
- # Decal Component
- "Decal (Atom) Entity successfully created",
- "Decal (Atom)_test: Component added to the entity: True",
- "Decal (Atom)_test: Component removed after UNDO: True",
- "Decal (Atom)_test: Component added after REDO: True",
- "Decal (Atom)_test: Entered game mode: True",
- "Decal (Atom)_test: Exit game mode: True",
- "Decal (Atom) Controller|Configuration|Material: SUCCESS",
- "Decal (Atom)_test: Entity is hidden: True",
- "Decal (Atom)_test: Entity is shown: True",
- "Decal (Atom)_test: Entity deleted: True",
- "Decal (Atom)_test: UNDO entity deletion works: True",
- "Decal (Atom)_test: REDO entity deletion works: True",
- # DepthOfField Component
- "DepthOfField Entity successfully created",
- "DepthOfField_test: Component added to the entity: True",
- "DepthOfField_test: Component removed after UNDO: True",
- "DepthOfField_test: Component added after REDO: True",
- "DepthOfField_test: Entered game mode: True",
- "DepthOfField_test: Exit game mode: True",
- "DepthOfField_test: Entity disabled initially: True",
- "DepthOfField_test: Entity enabled after adding required components: True",
- "DepthOfField Controller|Configuration|Camera Entity: SUCCESS",
- "DepthOfField_test: Entity is hidden: True",
- "DepthOfField_test: Entity is shown: True",
- "DepthOfField_test: Entity deleted: True",
- "DepthOfField_test: UNDO entity deletion works: True",
- "DepthOfField_test: REDO entity deletion works: True",
- # Directional Light Component
- "Directional Light Entity successfully created",
- "Directional Light_test: Component added to the entity: True",
- "Directional Light_test: Component removed after UNDO: True",
- "Directional Light_test: Component added after REDO: True",
- "Directional Light_test: Entered game mode: True",
- "Directional Light_test: Exit game mode: True",
- "Directional Light Controller|Configuration|Shadow|Camera: SUCCESS",
- "Directional Light_test: Entity is hidden: True",
- "Directional Light_test: Entity is shown: True",
- "Directional Light_test: Entity deleted: True",
- "Directional Light_test: UNDO entity deletion works: True",
- "Directional Light_test: REDO entity deletion works: True",
- # Exposure Control Component
- "Exposure Control Entity successfully created",
- "Exposure Control_test: Component added to the entity: True",
- "Exposure Control_test: Component removed after UNDO: True",
- "Exposure Control_test: Component added after REDO: True",
- "Exposure Control_test: Entered game mode: True",
- "Exposure Control_test: Exit game mode: True",
- "Exposure Control_test: Entity disabled initially: True",
- "Exposure Control_test: Entity enabled after adding required components: True",
- "Exposure Control_test: Entity is hidden: True",
- "Exposure Control_test: Entity is shown: True",
- "Exposure Control_test: Entity deleted: True",
- "Exposure Control_test: UNDO entity deletion works: True",
- "Exposure Control_test: REDO entity deletion works: True",
- # Global Skylight (IBL) Component
- "Global Skylight (IBL) Entity successfully created",
- "Global Skylight (IBL)_test: Component added to the entity: True",
- "Global Skylight (IBL)_test: Component removed after UNDO: True",
- "Global Skylight (IBL)_test: Component added after REDO: True",
- "Global Skylight (IBL)_test: Entered game mode: True",
- "Global Skylight (IBL)_test: Exit game mode: True",
- "Global Skylight (IBL) Controller|Configuration|Diffuse Image: SUCCESS",
- "Global Skylight (IBL) Controller|Configuration|Specular Image: SUCCESS",
- "Global Skylight (IBL)_test: Entity is hidden: True",
- "Global Skylight (IBL)_test: Entity is shown: True",
- "Global Skylight (IBL)_test: Entity deleted: True",
- "Global Skylight (IBL)_test: UNDO entity deletion works: True",
- "Global Skylight (IBL)_test: REDO entity deletion works: True",
- # Physical Sky Component
- "Physical Sky Entity successfully created",
- "Physical Sky component was added to entity",
- "Entity has a Physical Sky component",
- "Physical Sky_test: Component added to the entity: True",
- "Physical Sky_test: Component removed after UNDO: True",
- "Physical Sky_test: Component added after REDO: True",
- "Physical Sky_test: Entered game mode: True",
- "Physical Sky_test: Exit game mode: True",
- "Physical Sky_test: Entity is hidden: True",
- "Physical Sky_test: Entity is shown: True",
- "Physical Sky_test: Entity deleted: True",
- "Physical Sky_test: UNDO entity deletion works: True",
- "Physical Sky_test: REDO entity deletion works: True",
- # Point Light Component
- "Point Light Entity successfully created",
- "Point Light_test: Component added to the entity: True",
- "Point Light_test: Component removed after UNDO: True",
- "Point Light_test: Component added after REDO: True",
- "Point Light_test: Entered game mode: True",
- "Point Light_test: Exit game mode: True",
- "Point Light_test: Entity is hidden: True",
- "Point Light_test: Entity is shown: True",
- "Point Light_test: Entity deleted: True",
- "Point Light_test: UNDO entity deletion works: True",
- "Point Light_test: REDO entity deletion works: True",
- # PostFX Layer Component
- "PostFX Layer Entity successfully created",
- "PostFX Layer_test: Component added to the entity: True",
- "PostFX Layer_test: Component removed after UNDO: True",
- "PostFX Layer_test: Component added after REDO: True",
- "PostFX Layer_test: Entered game mode: True",
- "PostFX Layer_test: Exit game mode: True",
- "PostFX Layer_test: Entity is hidden: True",
- "PostFX Layer_test: Entity is shown: True",
- "PostFX Layer_test: Entity deleted: True",
- "PostFX Layer_test: UNDO entity deletion works: True",
- "PostFX Layer_test: REDO entity deletion works: True",
- # Radius Weight Modifier Component
- "Radius Weight Modifier Entity successfully created",
- "Radius Weight Modifier_test: Component added to the entity: True",
- "Radius Weight Modifier_test: Component removed after UNDO: True",
- "Radius Weight Modifier_test: Component added after REDO: True",
- "Radius Weight Modifier_test: Entered game mode: True",
- "Radius Weight Modifier_test: Exit game mode: True",
- "Radius Weight Modifier_test: Entity is hidden: True",
- "Radius Weight Modifier_test: Entity is shown: True",
- "Radius Weight Modifier_test: Entity deleted: True",
- "Radius Weight Modifier_test: UNDO entity deletion works: True",
- "Radius Weight Modifier_test: REDO entity deletion works: True",
- # Light Component
- "Light Entity successfully created",
- "Light_test: Component added to the entity: True",
- "Light_test: Component removed after UNDO: True",
- "Light_test: Component added after REDO: True",
- "Light_test: Entered game mode: True",
- "Light_test: Exit game mode: True",
- "Light_test: Entity is hidden: True",
- "Light_test: Entity is shown: True",
- "Light_test: Entity deleted: True",
- "Light_test: UNDO entity deletion works: True",
- "Light_test: REDO entity deletion works: True",
- # Display Mapper Component
- "Display Mapper Entity successfully created",
- "Display Mapper_test: Component added to the entity: True",
- "Display Mapper_test: Component removed after UNDO: True",
- "Display Mapper_test: Component added after REDO: True",
- "Display Mapper_test: Entered game mode: True",
- "Display Mapper_test: Exit game mode: True",
- "Display Mapper_test: Entity is hidden: True",
- "Display Mapper_test: Entity is shown: True",
- "Display Mapper_test: Entity deleted: True",
- "Display Mapper_test: UNDO entity deletion works: True",
- "Display Mapper_test: REDO entity deletion works: True",
- ]
-
- unexpected_lines = [
- "failed to open",
- "Traceback (most recent call last):",
- ]
-
- hydra.launch_and_validate_results(
- request,
- TEST_DIRECTORY,
- editor,
- "hydra_AtomEditorComponents_AddedToEntity.py",
- timeout=EDITOR_TIMEOUT,
- expected_lines=expected_lines,
- unexpected_lines=unexpected_lines,
- halt_on_unexpected=True,
- null_renderer=True,
- cfg_args=cfg_args,
- )
+ # It requires at least one test
+ def test_Dummy(self, request, editor, level, workspace, project, launcher_platform):
+ pass
diff --git a/AutomatedTesting/Gem/PythonTests/atom_renderer/test_Atom_SandboxSuite.py b/AutomatedTesting/Gem/PythonTests/atom_renderer/test_Atom_SandboxSuite.py
index 0fb873e677..8ca5b5aa31 100644
--- a/AutomatedTesting/Gem/PythonTests/atom_renderer/test_Atom_SandboxSuite.py
+++ b/AutomatedTesting/Gem/PythonTests/atom_renderer/test_Atom_SandboxSuite.py
@@ -19,6 +19,170 @@ import pytest
@pytest.mark.parametrize("level", ["auto_test"])
class TestAtomEditorComponentsSandbox(object):
- # It requires at least one test
- def test_Dummy(self, request, editor, level, workspace, project, launcher_platform):
- pass
+ @pytest.mark.test_case_id(
+ "C32078117", # Area Light
+ "C32078130", # Display Mapper
+ "C32078129", # Light
+ "C32078131", # Radius Weight Modifier
+ "C32078127", # PostFX Layer
+ "C32078126", # Point Light
+ "C32078125", # Physical Sky
+ "C32078115", # Global Skylight (IBL)
+ "C32078121", # Exposure Control
+ "C32078120", # Directional Light
+ "C32078119", # DepthOfField
+ "C32078118") # Decal
+ def test_AtomEditorComponents_AddedToEntity(self, request, editor, level, workspace, project, launcher_platform):
+ cfg_args = [level]
+
+ expected_lines = [
+ # Decal Component
+ "Decal (Atom) Entity successfully created",
+ "Decal (Atom)_test: Component added to the entity: True",
+ "Decal (Atom)_test: Component removed after UNDO: True",
+ "Decal (Atom)_test: Component added after REDO: True",
+ "Decal (Atom)_test: Entered game mode: True",
+ "Decal (Atom)_test: Exit game mode: True",
+ "Decal (Atom) Controller|Configuration|Material: SUCCESS",
+ "Decal (Atom)_test: Entity is hidden: True",
+ "Decal (Atom)_test: Entity is shown: True",
+ "Decal (Atom)_test: Entity deleted: True",
+ "Decal (Atom)_test: UNDO entity deletion works: True",
+ "Decal (Atom)_test: REDO entity deletion works: True",
+ # DepthOfField Component
+ "DepthOfField Entity successfully created",
+ "DepthOfField_test: Component added to the entity: True",
+ "DepthOfField_test: Component removed after UNDO: True",
+ "DepthOfField_test: Component added after REDO: True",
+ "DepthOfField_test: Entered game mode: True",
+ "DepthOfField_test: Exit game mode: True",
+ "DepthOfField_test: Entity disabled initially: True",
+ "DepthOfField_test: Entity enabled after adding required components: True",
+ "DepthOfField Controller|Configuration|Camera Entity: SUCCESS",
+ "DepthOfField_test: Entity is hidden: True",
+ "DepthOfField_test: Entity is shown: True",
+ "DepthOfField_test: Entity deleted: True",
+ "DepthOfField_test: UNDO entity deletion works: True",
+ "DepthOfField_test: REDO entity deletion works: True",
+ # Directional Light Component
+ "Directional Light Entity successfully created",
+ "Directional Light_test: Component added to the entity: True",
+ "Directional Light_test: Component removed after UNDO: True",
+ "Directional Light_test: Component added after REDO: True",
+ "Directional Light_test: Entered game mode: True",
+ "Directional Light_test: Exit game mode: True",
+ "Directional Light Controller|Configuration|Shadow|Camera: SUCCESS",
+ "Directional Light_test: Entity is hidden: True",
+ "Directional Light_test: Entity is shown: True",
+ "Directional Light_test: Entity deleted: True",
+ "Directional Light_test: UNDO entity deletion works: True",
+ "Directional Light_test: REDO entity deletion works: True",
+ # Exposure Control Component
+ "Exposure Control Entity successfully created",
+ "Exposure Control_test: Component added to the entity: True",
+ "Exposure Control_test: Component removed after UNDO: True",
+ "Exposure Control_test: Component added after REDO: True",
+ "Exposure Control_test: Entered game mode: True",
+ "Exposure Control_test: Exit game mode: True",
+ "Exposure Control_test: Entity disabled initially: True",
+ "Exposure Control_test: Entity enabled after adding required components: True",
+ "Exposure Control_test: Entity is hidden: True",
+ "Exposure Control_test: Entity is shown: True",
+ "Exposure Control_test: Entity deleted: True",
+ "Exposure Control_test: UNDO entity deletion works: True",
+ "Exposure Control_test: REDO entity deletion works: True",
+ # Global Skylight (IBL) Component
+ "Global Skylight (IBL) Entity successfully created",
+ "Global Skylight (IBL)_test: Component added to the entity: True",
+ "Global Skylight (IBL)_test: Component removed after UNDO: True",
+ "Global Skylight (IBL)_test: Component added after REDO: True",
+ "Global Skylight (IBL)_test: Entered game mode: True",
+ "Global Skylight (IBL)_test: Exit game mode: True",
+ "Global Skylight (IBL) Controller|Configuration|Diffuse Image: SUCCESS",
+ "Global Skylight (IBL) Controller|Configuration|Specular Image: SUCCESS",
+ "Global Skylight (IBL)_test: Entity is hidden: True",
+ "Global Skylight (IBL)_test: Entity is shown: True",
+ "Global Skylight (IBL)_test: Entity deleted: True",
+ "Global Skylight (IBL)_test: UNDO entity deletion works: True",
+ "Global Skylight (IBL)_test: REDO entity deletion works: True",
+ # Physical Sky Component
+ "Physical Sky Entity successfully created",
+ "Physical Sky component was added to entity",
+ "Entity has a Physical Sky component",
+ "Physical Sky_test: Component added to the entity: True",
+ "Physical Sky_test: Component removed after UNDO: True",
+ "Physical Sky_test: Component added after REDO: True",
+ "Physical Sky_test: Entered game mode: True",
+ "Physical Sky_test: Exit game mode: True",
+ "Physical Sky_test: Entity is hidden: True",
+ "Physical Sky_test: Entity is shown: True",
+ "Physical Sky_test: Entity deleted: True",
+ "Physical Sky_test: UNDO entity deletion works: True",
+ "Physical Sky_test: REDO entity deletion works: True",
+ # PostFX Layer Component
+ "PostFX Layer Entity successfully created",
+ "PostFX Layer_test: Component added to the entity: True",
+ "PostFX Layer_test: Component removed after UNDO: True",
+ "PostFX Layer_test: Component added after REDO: True",
+ "PostFX Layer_test: Entered game mode: True",
+ "PostFX Layer_test: Exit game mode: True",
+ "PostFX Layer_test: Entity is hidden: True",
+ "PostFX Layer_test: Entity is shown: True",
+ "PostFX Layer_test: Entity deleted: True",
+ "PostFX Layer_test: UNDO entity deletion works: True",
+ "PostFX Layer_test: REDO entity deletion works: True",
+ # Radius Weight Modifier Component
+ "Radius Weight Modifier Entity successfully created",
+ "Radius Weight Modifier_test: Component added to the entity: True",
+ "Radius Weight Modifier_test: Component removed after UNDO: True",
+ "Radius Weight Modifier_test: Component added after REDO: True",
+ "Radius Weight Modifier_test: Entered game mode: True",
+ "Radius Weight Modifier_test: Exit game mode: True",
+ "Radius Weight Modifier_test: Entity is hidden: True",
+ "Radius Weight Modifier_test: Entity is shown: True",
+ "Radius Weight Modifier_test: Entity deleted: True",
+ "Radius Weight Modifier_test: UNDO entity deletion works: True",
+ "Radius Weight Modifier_test: REDO entity deletion works: True",
+ # Light Component
+ "Light Entity successfully created",
+ "Light_test: Component added to the entity: True",
+ "Light_test: Component removed after UNDO: True",
+ "Light_test: Component added after REDO: True",
+ "Light_test: Entered game mode: True",
+ "Light_test: Exit game mode: True",
+ "Light_test: Entity is hidden: True",
+ "Light_test: Entity is shown: True",
+ "Light_test: Entity deleted: True",
+ "Light_test: UNDO entity deletion works: True",
+ "Light_test: REDO entity deletion works: True",
+ # Display Mapper Component
+ "Display Mapper Entity successfully created",
+ "Display Mapper_test: Component added to the entity: True",
+ "Display Mapper_test: Component removed after UNDO: True",
+ "Display Mapper_test: Component added after REDO: True",
+ "Display Mapper_test: Entered game mode: True",
+ "Display Mapper_test: Exit game mode: True",
+ "Display Mapper_test: Entity is hidden: True",
+ "Display Mapper_test: Entity is shown: True",
+ "Display Mapper_test: Entity deleted: True",
+ "Display Mapper_test: UNDO entity deletion works: True",
+ "Display Mapper_test: REDO entity deletion works: True",
+ ]
+
+ unexpected_lines = [
+ "failed to open",
+ "Traceback (most recent call last):",
+ ]
+
+ hydra.launch_and_validate_results(
+ request,
+ TEST_DIRECTORY,
+ editor,
+ "hydra_AtomEditorComponents_AddedToEntity.py",
+ timeout=EDITOR_TIMEOUT,
+ expected_lines=expected_lines,
+ unexpected_lines=unexpected_lines,
+ halt_on_unexpected=True,
+ null_renderer=True,
+ cfg_args=cfg_args,
+ )
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/DynamicSliceInstanceSpawner_DynamicSliceSpawnerWorks.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/DynamicSliceInstanceSpawner_DynamicSliceSpawnerWorks.py
index 0be220cad0..466cd610e4 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/DynamicSliceInstanceSpawner_DynamicSliceSpawnerWorks.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/DynamicSliceInstanceSpawner_DynamicSliceSpawnerWorks.py
@@ -114,11 +114,8 @@ class TestDynamicSliceInstanceSpawner(EditorTestHelper):
# This should result in 400 instances, since our box is 16 m x 16 m and by default the veg system plants
# 20 instances per 16 meters
spawner_entity.get_set_test(0, 'Configuration|Allow Empty Assets', True)
- general.idle_wait(1.0)
num_expected_instances = 20 * 20
- box = azlmbr.shape.ShapeComponentRequestsBus(bus.Event, 'GetEncompassingAabb', spawner_entity.id)
- num_found = azlmbr.areasystem.AreaSystemRequestBus(bus.Broadcast, 'GetInstanceCountInAabb', box)
- property_tree_success = property_tree_success and (num_found == num_expected_instances)
+ property_tree_success = property_tree_success and self.wait_for_condition(lambda: dynveg.validate_instance_count_in_entity_shape(spawner_entity.id, num_expected_instances), 5.0)
self.test_success = self.test_success and property_tree_success
self.log(f'Property Tree spawner type test: {property_tree_success}')
@@ -127,10 +124,8 @@ class TestDynamicSliceInstanceSpawner(EditorTestHelper):
# Since we have an empty slice path, we should have 0 instances once we disable 'Allow Empty Assets'
num_expected_instances = 0
allow_empty_assets_success = allow_empty_assets_success and spawner_entity.get_set_test(0, 'Configuration|Allow Empty Assets', False)
- general.idle_wait(1.0)
- num_found = azlmbr.areasystem.AreaSystemRequestBus(bus.Broadcast, 'GetInstanceCountInAabb', box)
- self.log(f'Allow Empty Assets test: Found {num_found} instances -- Expected {num_expected_instances} instances')
- allow_empty_assets_success = allow_empty_assets_success and (num_found == num_expected_instances)
+ self.log('Allow Empty Assets test:')
+ allow_empty_assets_success = allow_empty_assets_success and self.wait_for_condition(lambda: dynveg.validate_instance_count_in_entity_shape(spawner_entity.id, num_expected_instances), 5.0)
self.test_success = self.test_success and allow_empty_assets_success
self.log(f'Allow Empty Assets test: {allow_empty_assets_success}')
@@ -143,10 +138,8 @@ class TestDynamicSliceInstanceSpawner(EditorTestHelper):
descriptor = hydra.get_component_property_value(spawner_entity.components[2], 'Configuration|Embedded Assets|[0]')
descriptor.spawner = dynamic_slice_spawner
spawns_slices_success = spawns_slices_success and spawner_entity.get_set_test(2, "Configuration|Embedded Assets|[0]", descriptor)
- general.idle_wait(1.0)
- num_found = azlmbr.areasystem.AreaSystemRequestBus(bus.Broadcast, 'GetInstanceCountInAabb', box)
- self.log(f'Spawn dynamic slices test: Found {num_found} instances -- Expected {num_expected_instances} instances')
- spawns_slices_success = spawns_slices_success and (num_found == num_expected_instances)
+ self.log('Spawn dynamic slices test:')
+ spawns_slices_success = spawns_slices_success and self.wait_for_condition(lambda: dynveg.validate_instance_count_in_entity_shape(spawner_entity.id, num_expected_instances), 5.0)
self.test_success = self.test_success and spawns_slices_success
self.log(f'Spawn dynamic slices test: {spawns_slices_success}')
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/EmptyInstanceSpawner_EmptySpawnerWorks.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/EmptyInstanceSpawner_EmptySpawnerWorks.py
index 161ad038a5..dc353aca1a 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/EmptyInstanceSpawner_EmptySpawnerWorks.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/EditorScripts/EmptyInstanceSpawner_EmptySpawnerWorks.py
@@ -100,21 +100,15 @@ class TestEmptyInstanceSpawner(EditorTestHelper):
# This should result in 400 instances, since our box is 16 m x 16 m and by default the veg system plants
# 20 instances per 16 meters
- general.idle_wait(2.0)
num_expected_instances = 20 * 20
- box = azlmbr.shape.ShapeComponentRequestsBus(bus.Event, 'GetEncompassingAabb', spawner_entity.id)
- num_found = azlmbr.areasystem.AreaSystemRequestBus(bus.Broadcast, 'GetInstanceCountInAabb', box)
- property_tree_success = property_tree_success and (num_found == num_expected_instances)
+ property_tree_success = property_tree_success and self.wait_for_condition(lambda: dynveg.validate_instance_count_in_entity_shape(spawner_entity.id, num_expected_instances), 5.0)
self.test_success = self.test_success and property_tree_success
- self.log(f'Found {num_found} instances -- Expected {num_expected_instances} instances')
self.log(f'Property Tree spawner type test: {property_tree_success}')
# 6) Validate that the "Allow Empty Assets" setting doesn't affect the EmptyInstanceSpawner
allow_empty_assets_success = True
spawner_entity.get_set_test(0, 'Configuration|Allow Empty Assets', False)
- general.idle_wait(2.0)
- num_found = azlmbr.areasystem.AreaSystemRequestBus(bus.Broadcast, 'GetInstanceCountInAabb', box)
- allow_empty_assets_success = allow_empty_assets_success and (num_found == num_expected_instances)
+ allow_empty_assets_success = allow_empty_assets_success and self.wait_for_condition(lambda: dynveg.validate_instance_count_in_entity_shape(spawner_entity.id, num_expected_instances), 5.0)
self.test_success = self.test_success and allow_empty_assets_success
self.log(f'Allow Empty Assets test: {allow_empty_assets_success}')
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AltitudeFilter.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AltitudeFilter.py
index 2db8534696..17a5f72863 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AltitudeFilter.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AltitudeFilter.py
@@ -37,6 +37,7 @@ class TestAltitudeFilter(object):
@pytest.mark.test_case_id('C4814463', 'C4847477')
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_filter
def test_AltitudeFilter_ComponentAndOverrides_InstancesPlantAtSpecifiedAltitude(self, request, editor, level,
launcher_platform):
@@ -61,6 +62,7 @@ class TestAltitudeFilter(object):
@pytest.mark.test_case_id("C4847476")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_filter
def test_AltitudeFilter_ShapeSample_InstancesPlantAtSpecifiedAltitude(self, request, editor, level,
launcher_platform):
@@ -85,6 +87,7 @@ class TestAltitudeFilter(object):
@pytest.mark.test_case_id("C4847478")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_filter
@pytest.mark.xfail # LYN-3275
def test_AltitudeFilter_FilterStageToggle(self, request, editor, level, workspace, launcher_platform):
cfg_args = [level]
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AreaComponentSlices.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AreaComponentSlices.py
index 1353efbf2e..5f42fc6de0 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AreaComponentSlices.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AreaComponentSlices.py
@@ -52,6 +52,7 @@ class TestAreaComponents(object):
@pytest.mark.test_case_id("C2627900", "C2627905", "C2627904")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_misc
def test_AreaComponents_SliceCreationVisibilityToggleWorks(self, request, editor, level, workspace,
launcher_platform):
cfg_args = [level]
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AssetListCombiner.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AssetListCombiner.py
index ad0917ca22..b40d99b100 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AssetListCombiner.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AssetListCombiner.py
@@ -38,6 +38,7 @@ class TestAssetListCombiner(object):
@pytest.mark.test_case_id("C4762374", "C4762373")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_misc
def test_AssetListCombiner_CombinedDescriptorsExpressInConfiguredArea(self, request, editor, level,
launcher_platform):
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AssetWeightSelector.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AssetWeightSelector.py
index 65472df3bc..7b34a10d66 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AssetWeightSelector.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_AssetWeightSelector.py
@@ -42,6 +42,7 @@ class TestAssetWeightSelector(object):
@pytest.mark.test_case_id("C6269654", "C4762368")
@pytest.mark.SUITE_sandbox
+ @pytest.mark.dynveg_filter
def test_AssetWeightSelector_InstancesExpressBasedOnWeight(self, request, editor, level, launcher_platform):
expected_lines = [
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_Debugger.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_Debugger.py
index 45518b71fc..7466089173 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_Debugger.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_Debugger.py
@@ -40,6 +40,7 @@ class TestDebugger(object):
@pytest.mark.test_case_id("C2789148")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_misc
def test_Debugger_DebugCVarsWork(self, request, editor, level, workspace, launcher_platform):
cfg_args = [level]
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_DistanceBetweenFilter.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_DistanceBetweenFilter.py
index 3171cc032f..191f27fca0 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_DistanceBetweenFilter.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_DistanceBetweenFilter.py
@@ -38,6 +38,7 @@ class TestDistanceBetweenFilter(object):
@pytest.mark.test_case_id("C4851066")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_filter
def test_DistanceBetweenFilter_InstancesPlantAtSpecifiedRadius(self, request, editor, level, launcher_platform):
expected_lines = [
@@ -58,6 +59,7 @@ class TestDistanceBetweenFilter(object):
@pytest.mark.test_case_id("C4814458")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_filter
def test_DistanceBetweenFilterOverrides_InstancesPlantAtSpecifiedRadius(self, request, editor, level,
launcher_platform):
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_DynVeg_Regressions.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_DynVeg_Regressions.py
index b3cf344b2b..5c6e034a12 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_DynVeg_Regressions.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_DynVeg_Regressions.py
@@ -40,6 +40,7 @@ class Test_DynVeg_Regressions(object):
@pytest.mark.test_case_id("C29470845")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_regression
def test_SurfaceDataRefreshes_RemainsStable(self, request, editor, level, launcher_platform):
expected_lines = [
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_DynamicSliceInstanceSpawner.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_DynamicSliceInstanceSpawner.py
index f0673a9438..9898570692 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_DynamicSliceInstanceSpawner.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_DynamicSliceInstanceSpawner.py
@@ -41,7 +41,8 @@ class TestDynamicSliceInstanceSpawner(object):
return console
@pytest.mark.test_case_id("C28851763")
- @pytest.mark.SUITE_sandbox
+ @pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_area
@pytest.mark.parametrize("launcher_platform", ['windows_editor'])
def test_DynamicSliceInstanceSpawner_DynamicSliceSpawnerWorks(self, request, editor, level, workspace, project,
launcher_platform):
@@ -66,6 +67,7 @@ class TestDynamicSliceInstanceSpawner(object):
@pytest.mark.test_case_id('C2574330')
@pytest.mark.BAT
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_area
@pytest.mark.parametrize("launcher_platform", ['windows_editor'])
def test_DynamicSliceInstanceSpawner_Embedded_E2E_Editor(self, workspace, request, editor, level, project,
launcher_platform):
@@ -85,6 +87,7 @@ class TestDynamicSliceInstanceSpawner(object):
@pytest.mark.test_case_id('C2574330')
@pytest.mark.BAT
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_area
@pytest.mark.parametrize("launcher_platform", ['windows'])
@pytest.mark.skip # ATOM-14703
def test_DynamicSliceInstanceSpawner_Embedded_E2E_Launcher(self, workspace, launcher, level,
@@ -101,6 +104,7 @@ class TestDynamicSliceInstanceSpawner(object):
@pytest.mark.test_case_id('C4762367')
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_area
@pytest.mark.parametrize("launcher_platform", ['windows_editor'])
def test_DynamicSliceInstanceSpawner_External_E2E_Editor(self, workspace, request, editor, level, project,
launcher_platform):
@@ -119,6 +123,7 @@ class TestDynamicSliceInstanceSpawner(object):
@pytest.mark.test_case_id('C4762367')
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_area
@pytest.mark.parametrize("launcher_platform", ['windows'])
@pytest.mark.skip # ATOM-14703
def test_DynamicSliceInstanceSpawner_External_E2E_Launcher(self, workspace, launcher, level,
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_EmptyInstanceSpawner.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_EmptyInstanceSpawner.py
index fc8c31fc7b..7bd8484cf4 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_EmptyInstanceSpawner.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_EmptyInstanceSpawner.py
@@ -36,13 +36,9 @@ class TestEmptyInstanceSpawner(object):
file_system.delete([os.path.join(workspace.paths.engine_root(), project, "Levels", level)], True, True)
- # Main suite needs at least one test
- @pytest.mark.SUITE_main
- def test_EmptyInstanceSpawner_Dummy(self, request, editor, level, workspace, project, launcher_platform):
- pass
-
@pytest.mark.test_case_id("C28851762")
- @pytest.mark.SUITE_sandbox
+ @pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_area
def test_EmptyInstanceSpawner_EmptySpawnerWorks(self, request, editor, level, launcher_platform):
cfg_args = [level]
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_InstanceSpawnerPriority.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_InstanceSpawnerPriority.py
index d04b827985..53b5c3b760 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_InstanceSpawnerPriority.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_InstanceSpawnerPriority.py
@@ -43,6 +43,7 @@ class TestInstanceSpawnerPriority(object):
@pytest.mark.test_case_id("C5747383", "C4762382")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_misc
def test_InstanceSpawnerPriority_LayerAndSubPriority_HigherValuesPlantOverLower(self, request, editor, level,
launcher_platform):
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_LayerBlender.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_LayerBlender.py
index 2286238364..76b8b3cd3a 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_LayerBlender.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_LayerBlender.py
@@ -20,17 +20,10 @@ import pytest
pytest.importorskip("ly_test_tools")
-import time as time
-
-import editor_python_test_tools.hydra_test_utils as hydra
-import ly_test_tools.launchers.launcher_helper as launcher_helper
+import ly_remote_console.remote_console_commands as remote_console_commands
import ly_test_tools.environment.waiter as waiter
import ly_test_tools.environment.file_system as file_system
-import ly_remote_console.remote_console_commands as remote_console_commands
-from ly_remote_console.remote_console_commands import send_command_and_expect_response as send_command_and_expect_response
-
-import automatedtesting_shared.screenshot_utils as screenshot_utils
-from automatedtesting_shared.network_utils import check_for_listening_port
+import editor_python_test_tools.hydra_test_utils as hydra
test_directory = os.path.join(os.path.dirname(__file__), "EditorScripts")
@@ -58,6 +51,7 @@ class TestLayerBlender(object):
@pytest.mark.test_case_id("C2627906")
@pytest.mark.BAT
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_area
@pytest.mark.parametrize("launcher_platform", ['windows_editor'])
def test_LayerBlender_E2E_Editor(self, workspace, request, editor, project, level, launcher_platform):
# Make sure temp level doesn't already exist
@@ -95,6 +89,7 @@ class TestLayerBlender(object):
@pytest.mark.test_case_id("C2627906")
@pytest.mark.BAT
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_area
@pytest.mark.xfail
@pytest.mark.parametrize("launcher_platform", ['windows'])
def test_LayerBlender_E2E_Launcher(self, workspace, project, launcher, level, remote_console_instance,
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_LayerBlocker.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_LayerBlocker.py
index 6da0cdd6db..308f4480c5 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_LayerBlocker.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_LayerBlocker.py
@@ -38,6 +38,7 @@ class TestLayerBlocker(object):
@pytest.mark.test_case_id("C2793772")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_area
def test_LayerBlocker_InstancesBlockedInConfiguredArea(self, request, editor, level, launcher_platform):
expected_lines = [
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_LayerSpawner.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_LayerSpawner.py
index 93149c9490..d206a962da 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_LayerSpawner.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_LayerSpawner.py
@@ -40,6 +40,7 @@ class TestLayerSpawner(object):
@pytest.mark.test_case_id("C4762381")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_misc
def test_LayerSpawner_InheritBehaviorFlag(self, request, editor, level, workspace, launcher_platform):
expected_lines = [
@@ -60,6 +61,7 @@ class TestLayerSpawner(object):
@pytest.mark.test_case_id("C2802020")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_misc
def test_LayerSpawner_InstancesPlantInAllSupportedShapes(self, request, editor, level, launcher_platform):
expected_lines = [
@@ -101,6 +103,7 @@ class TestLayerSpawner(object):
@pytest.mark.test_case_id("C4765973")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_misc
@pytest.mark.xfail # LYN-3275
def test_LayerSpawner_FilterStageToggle(self, request, editor, level, workspace, launcher_platform):
@@ -122,6 +125,7 @@ class TestLayerSpawner(object):
@pytest.mark.test_case_id("C30000751")
@pytest.mark.SUITE_sandbox
+ @pytest.mark.dynveg_misc
@pytest.mark.skip # ATOM-14828
def test_LayerSpawner_InstancesRefreshUsingCorrectViewportCamera(self, request, editor, level, launcher_platform):
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_MeshBlocker.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_MeshBlocker.py
index c04390e647..7e1b416556 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_MeshBlocker.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_MeshBlocker.py
@@ -46,6 +46,7 @@ class TestMeshBlocker(object):
"""
@pytest.mark.test_case_id("C3980834")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_area
@pytest.mark.xfail # LYN-3273
def test_MeshBlocker_InstancesBlockedByMesh(self, request, editor, level, launcher_platform):
expected_lines = [
@@ -70,6 +71,7 @@ class TestMeshBlocker(object):
"""
@pytest.mark.test_case_id("C4766030")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_area
@pytest.mark.xfail # LYN-3273
def test_MeshBlocker_InstancesBlockedByMeshHeightTuning(self, request, editor, level, launcher_platform):
expected_lines = [
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_MeshSurfaceTagEmitter.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_MeshSurfaceTagEmitter.py
index 77638cb576..dcbffdf3b7 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_MeshSurfaceTagEmitter.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_MeshSurfaceTagEmitter.py
@@ -38,6 +38,7 @@ class TestMeshSurfaceTagEmitter(object):
@pytest.mark.test_case_id("C2908172")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_surfacetagemitter
def test_MeshSurfaceTagEmitter_DependentOnMeshComponent(self, request, editor, level, launcher_platform):
expected_lines = [
@@ -66,6 +67,7 @@ class TestMeshSurfaceTagEmitter(object):
@pytest.mark.test_case_id("C2908174")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_surfacetagemitter
def test_MeshSurfaceTagEmitter_SurfaceTagsAddRemoveSuccessfully(self, request, editor, level, launcher_platform):
expected_lines = [
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_PhysXColliderSurfaceTagEmitter.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_PhysXColliderSurfaceTagEmitter.py
index ca4e30a719..0f84e2caa2 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_PhysXColliderSurfaceTagEmitter.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_PhysXColliderSurfaceTagEmitter.py
@@ -38,6 +38,7 @@ class TestPhysXColliderSurfaceTagEmitter(object):
@pytest.mark.test_case_id("C29053640")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_surfacetagemitter
def test_PhysXColliderSurfaceTagEmitter_E2E_Editor(self, request, editor, level, launcher_platform):
expected_lines = [
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_PositionModifier.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_PositionModifier.py
index ac3e0abb4f..2cf8db3b96 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_PositionModifier.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_PositionModifier.py
@@ -38,6 +38,7 @@ class TestPositionModifier(object):
@pytest.mark.test_case_id("C4874099", "C4814461")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_modifier
def test_PositionModifier_ComponentAndOverrides_InstancesPlantAtSpecifiedOffsets(self, request, editor, level,
launcher_platform):
@@ -60,6 +61,7 @@ class TestPositionModifier(object):
@pytest.mark.test_case_id("C4874100")
@pytest.mark.SUITE_sandbox
+ @pytest.mark.dynveg_modifier
@pytest.mark.xfail # LYN-3275
def test_PositionModifier_AutoSnapToSurfaceWorks(self, request, editor, level, launcher_platform):
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_RotationModifier.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_RotationModifier.py
index 518949c0c0..3b0c9b3947 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_RotationModifier.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_RotationModifier.py
@@ -42,6 +42,7 @@ class TestRotationModifier(object):
@pytest.mark.test_case_id("C4896922")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_modifier
def test_RotationModifier_InstancesRotateWithinRange(self, request, editor, level, launcher_platform) -> None:
"""
Launches editor and run test script to test that rotation modifier works for all axis.
@@ -71,6 +72,7 @@ class TestRotationModifier(object):
@pytest.mark.test_case_id("C4814460")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_modifier
def test_RotationModifierOverrides_InstancesRotateWithinRange(self, request, editor, level, launcher_platform) -> None:
expected_lines = [
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_ScaleModifier.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_ScaleModifier.py
index 6acd95e4f6..7fe7a4ece2 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_ScaleModifier.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_ScaleModifier.py
@@ -41,6 +41,7 @@ class TestScaleOverrideWorksSuccessfully(object):
@pytest.mark.test_case_id("C4814462")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_modifier
def test_ScaleModifierOverrides_InstancesProperlyScale(self, request, editor, level, launcher_platform):
expected_lines = [
@@ -70,6 +71,7 @@ class TestScaleOverrideWorksSuccessfully(object):
@pytest.mark.test_case_id("C4896937")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_modifier
def test_ScaleModifier_InstancesProperlyScale(self, request, editor, level, launcher_platform):
expected_lines = [
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_ShapeIntersectionFilter.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_ShapeIntersectionFilter.py
index ea90b67a7f..8acdb1b644 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_ShapeIntersectionFilter.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_ShapeIntersectionFilter.py
@@ -38,6 +38,7 @@ class TestShapeIntersectionFilter(object):
@pytest.mark.test_case_id("C4874094")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_filter
def test_ShapeIntersectionFilter_InstancesPlantInAssignedShape(self, request, editor, level, launcher_platform):
expected_lines = [
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SlopeAlignmentModifier.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SlopeAlignmentModifier.py
index 563ac1dcc5..6825686509 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SlopeAlignmentModifier.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SlopeAlignmentModifier.py
@@ -41,6 +41,7 @@ class TestSlopeAlignmentModifier(object):
@pytest.mark.test_case_id("C4896941")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_modifier
@pytest.mark.skip # ATOM-14299
def test_SlopeAlignmentModifier_InstanceSurfaceAlignment(self, request, editor, level, launcher_platform):
@@ -63,6 +64,7 @@ class TestSlopeAlignmentModifier(object):
@pytest.mark.test_case_id("C4814459")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_modifier
@pytest.mark.skip # ATOM-14299
def test_SlopeAlignmentModifierOverrides_InstanceSurfaceAlignment(self, request, editor, level, launcher_platform):
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SlopeFilter.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SlopeFilter.py
index dc0f0e6514..48e532adcd 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SlopeFilter.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SlopeFilter.py
@@ -39,6 +39,7 @@ class TestSlopeFilter(object):
@pytest.mark.test_case_id("C4874097")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_filter
def test_SlopeFilter_FilterStageToggle(self, request, editor, level, workspace, launcher_platform):
cfg_args = [level]
@@ -70,6 +71,7 @@ class TestSlopeFilter(object):
@pytest.mark.test_case_id("C4814464", "C4874096")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_filter
@pytest.mark.skip # LYN-2211
def test_SlopeFilter_ComponentAndOverrides_InstancesPlantOnValidSlopes(self, request, editor, level,
launcher_platform):
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SurfaceMaskFilter.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SurfaceMaskFilter.py
index 20cab85293..952c000232 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SurfaceMaskFilter.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SurfaceMaskFilter.py
@@ -40,6 +40,7 @@ class TestSurfaceMaskFilter(object):
# Simple validation test to ensure that SurfaceTag can be created, set to a value, and compared to another SurfaceTag.
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_filter
def test_SurfaceMaskFilter_BasicSurfaceTagCreation(self, request, level, editor, launcher_platform):
expected_lines = [
@@ -61,6 +62,7 @@ class TestSurfaceMaskFilter(object):
@pytest.mark.test_case_id("C2561342")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_filter
def test_SurfaceMaskFilter_ExclusiveSurfaceTags_Function(self, request, editor, level, launcher_platform):
expected_lines = [
@@ -93,6 +95,7 @@ class TestSurfaceMaskFilter(object):
@pytest.mark.test_case_id("C2561341")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_filter
def test_SurfaceMaskFilter_InclusiveSurfaceTags_Function(self, request, editor, level, launcher_platform):
expected_lines = [
@@ -125,6 +128,7 @@ class TestSurfaceMaskFilter(object):
@pytest.mark.test_case_id("C3711666")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_filter
def test_SurfaceMaskFilterOverrides_MultipleDescriptorOverridesPlantAsExpected(self, request, editor, level,
launcher_platform):
diff --git a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SystemSettings.py b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SystemSettings.py
index adf9a90587..0b55d06ae4 100755
--- a/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SystemSettings.py
+++ b/AutomatedTesting/Gem/PythonTests/largeworlds/dyn_veg/test_SystemSettings.py
@@ -38,6 +38,7 @@ class TestSystemSettings(object):
@pytest.mark.test_case_id("C2646869")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_misc
def test_SystemSettings_SectorPointDensity(self, request, editor, level, launcher_platform):
expected_lines = [
@@ -64,6 +65,7 @@ class TestSystemSettings(object):
@pytest.mark.test_case_id("C2646870")
@pytest.mark.SUITE_periodic
+ @pytest.mark.dynveg_misc
def test_SystemSettings_SectorSize(self, request, editor, level, launcher_platform):
expected_lines = [
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C100000_RigidBody_EnablingGravityWorksPoC.py b/AutomatedTesting/Gem/PythonTests/physics/C100000_RigidBody_EnablingGravityWorksPoC.py
index e0277180ae..1284c234bd 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C100000_RigidBody_EnablingGravityWorksPoC.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C100000_RigidBody_EnablingGravityWorksPoC.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C100000
# Test Case Title : Check that Gravity works
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/100000
+
# fmt:off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C111111_RigidBody_EnablingGravityWorksUsingNotificationsPoC.py b/AutomatedTesting/Gem/PythonTests/physics/C111111_RigidBody_EnablingGravityWorksUsingNotificationsPoC.py
index c7dd8debb9..725da5fb24 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C111111_RigidBody_EnablingGravityWorksUsingNotificationsPoC.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C111111_RigidBody_EnablingGravityWorksUsingNotificationsPoC.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C111111
# Test Case Title : Check that Gravity works
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/111111
+
# fmt:off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C12712452_ScriptCanvas_CollisionEvents.py b/AutomatedTesting/Gem/PythonTests/physics/C12712452_ScriptCanvas_CollisionEvents.py
index 216a75233f..380bb8a3c8 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C12712452_ScriptCanvas_CollisionEvents.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C12712452_ScriptCanvas_CollisionEvents.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test Case ID : C12712452
# Test Case Title : Verify ScriptCanvas Collision Events
-# Test Case URL : https://testrail.agscollab.com/index.php?/cases/view/12712452
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C12712453_ScriptCanvas_MultipleRaycastNode.py b/AutomatedTesting/Gem/PythonTests/physics/C12712453_ScriptCanvas_MultipleRaycastNode.py
index 2adf30e65e..b415688de7 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C12712453_ScriptCanvas_MultipleRaycastNode.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C12712453_ScriptCanvas_MultipleRaycastNode.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C12712453
# Test Case Title : Verify Raycast Multiple Node
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/12712453
+
# fmt:off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C12712454_ScriptCanvas_OverlapNodeVerification.py b/AutomatedTesting/Gem/PythonTests/physics/C12712454_ScriptCanvas_OverlapNodeVerification.py
index 94eed900ff..bcf980a710 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C12712454_ScriptCanvas_OverlapNodeVerification.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C12712454_ScriptCanvas_OverlapNodeVerification.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : 12712454
# Test Case Title : Verify overlap nodes in script canvas
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/12712454
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C12712455_ScriptCanvas_ShapeCastVerification.py b/AutomatedTesting/Gem/PythonTests/physics/C12712455_ScriptCanvas_ShapeCastVerification.py
index 61f26ebecb..668e8083c3 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C12712455_ScriptCanvas_ShapeCastVerification.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C12712455_ScriptCanvas_ShapeCastVerification.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C12712455
# Test Case Title : Verify shape cast nodes in SC
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/12712455
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C12868578_ForceRegion_DirectionHasNoAffectOnMagnitude.py b/AutomatedTesting/Gem/PythonTests/physics/C12868578_ForceRegion_DirectionHasNoAffectOnMagnitude.py
index 4745927e89..d2438110fe 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C12868578_ForceRegion_DirectionHasNoAffectOnMagnitude.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C12868578_ForceRegion_DirectionHasNoAffectOnMagnitude.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C12868578
# Test Case Title : Check that World space and local space force direction doesn't affect magnitude of force exerted
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/12868578
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C12868580_ForceRegion_SplineModifiedTransform.py b/AutomatedTesting/Gem/PythonTests/physics/C12868580_ForceRegion_SplineModifiedTransform.py
index 937fdd85a6..6372104fcf 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C12868580_ForceRegion_SplineModifiedTransform.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C12868580_ForceRegion_SplineModifiedTransform.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C12868580
# Test Case Title : Check that spline follow force works if transform components of entity are altered
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/12868580
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C12905527_ForceRegion_MagnitudeDeviation.py b/AutomatedTesting/Gem/PythonTests/physics/C12905527_ForceRegion_MagnitudeDeviation.py
index 0cb0a2f841..76578460d5 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C12905527_ForceRegion_MagnitudeDeviation.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C12905527_ForceRegion_MagnitudeDeviation.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C12905527
# Test Case Title : Check that deviation occurring in Force Magnitude due to Values in Force direction is not large
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/12905527
+
# fmt: off
class Tests():
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C12905528_ForceRegion_WithNonTriggerCollider.py b/AutomatedTesting/Gem/PythonTests/physics/C12905528_ForceRegion_WithNonTriggerCollider.py
index 42565333f7..38dc5488d2 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C12905528_ForceRegion_WithNonTriggerCollider.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C12905528_ForceRegion_WithNonTriggerCollider.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C12905528
Test Case Title : Check that user is warned if non-trigger collider component is used with force region
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/12905528
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C13351703_COM_NotIncludeTriggerShapes.py b/AutomatedTesting/Gem/PythonTests/physics/C13351703_COM_NotIncludeTriggerShapes.py
index 828022ccf2..d5bd946d34 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C13351703_COM_NotIncludeTriggerShapes.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C13351703_COM_NotIncludeTriggerShapes.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C13351703
# Test Case Title : Check that Center of Mass calculations should not include trigger shapes
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/13351703
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C13352089_RigidBodies_MaxAngularVelocity.py b/AutomatedTesting/Gem/PythonTests/physics/C13352089_RigidBodies_MaxAngularVelocity.py
index 77d93d9752..09b6956b06 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C13352089_RigidBodies_MaxAngularVelocity.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C13352089_RigidBodies_MaxAngularVelocity.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C13352089
# Test Case Title : Verify that maximum angular velocity interacts correctly with initial angular velocity
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/13352089
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C13508019_Terrain_TerrainTexturePainterWorks.py b/AutomatedTesting/Gem/PythonTests/physics/C13508019_Terrain_TerrainTexturePainterWorks.py
index 1c580bfbfe..9c7a6e75e9 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C13508019_Terrain_TerrainTexturePainterWorks.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C13508019_Terrain_TerrainTexturePainterWorks.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C13508019
# Test Case Title : Verify terrain materials are updated after using terrain texture layer painter.
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/13508019
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C13895144_Ragdoll_ChangeLevel.py b/AutomatedTesting/Gem/PythonTests/physics/C13895144_Ragdoll_ChangeLevel.py
index 61efe20dbd..66050565a4 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C13895144_Ragdoll_ChangeLevel.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C13895144_Ragdoll_ChangeLevel.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C13895144
# Test Case Title : Run a level with multiple ragdolls and then switch levels
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/13895144
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C14195074_ScriptCanvas_PostUpdateEvent.py b/AutomatedTesting/Gem/PythonTests/physics/C14195074_ScriptCanvas_PostUpdateEvent.py
index 5668082f78..1d0e1d5ac8 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C14195074_ScriptCanvas_PostUpdateEvent.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C14195074_ScriptCanvas_PostUpdateEvent.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C14195074
# Test Case Title : Verify Postsimulate Events
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/14195074
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C14654881_CharacterController_SwitchLevels.py b/AutomatedTesting/Gem/PythonTests/physics/C14654881_CharacterController_SwitchLevels.py
index fd5653b801..8fc58b4765 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C14654881_CharacterController_SwitchLevels.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C14654881_CharacterController_SwitchLevels.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C14654881
# Test Case Title : Switching levels from a level containing a character controller component
# should not lead to a crash
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/14654881
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C14654882_Ragdoll_ragdollAPTest.py b/AutomatedTesting/Gem/PythonTests/physics/C14654882_Ragdoll_ragdollAPTest.py
index 03c18a5f1a..33077f2607 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C14654882_Ragdoll_ragdollAPTest.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C14654882_Ragdoll_ragdollAPTest.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
"""
Test case ID : C14654882
Test Case Title : Loading level with old PhysX Ragdoll component serialization should not produce asset processor errors
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/14654882
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C14861498_ConfirmError_NoPxMesh.py b/AutomatedTesting/Gem/PythonTests/physics/C14861498_ConfirmError_NoPxMesh.py
index e52bdb7574..dca831456d 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C14861498_ConfirmError_NoPxMesh.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C14861498_ConfirmError_NoPxMesh.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C14861498
# Test Case Title : Confirm that when a PhysXCollider has no physics asset, the physics asset collider \
# shape throw an error
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/14861498
+
# fmt:off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C14861500_DefaultSetting_ColliderShape.py b/AutomatedTesting/Gem/PythonTests/physics/C14861500_DefaultSetting_ColliderShape.py
index 7a65448dcd..c6a275d04d 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C14861500_DefaultSetting_ColliderShape.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C14861500_DefaultSetting_ColliderShape.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C14861500
Test Case Title : Verify Default shape is Physics Asset
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/14861500
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C14861501_PhysXCollider_RenderMeshAutoAssigned.py b/AutomatedTesting/Gem/PythonTests/physics/C14861501_PhysXCollider_RenderMeshAutoAssigned.py
index 904b5b0189..e415687001 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C14861501_PhysXCollider_RenderMeshAutoAssigned.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C14861501_PhysXCollider_RenderMeshAutoAssigned.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C14861501
Test Case Title : Verify PxMesh is auto-assigned when Collider component is added after Rendering Mesh component
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/14861501
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C14861502_PhysXCollider_AssetAutoAssigned.py b/AutomatedTesting/Gem/PythonTests/physics/C14861502_PhysXCollider_AssetAutoAssigned.py
index 075c3f5b61..64820f7daf 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C14861502_PhysXCollider_AssetAutoAssigned.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C14861502_PhysXCollider_AssetAutoAssigned.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C14861502
Test Case Title : Verify PxMesh is auto-assigned in collider when Mesh is assigned in Rendering Mesh component
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/14861502
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C14861504_RenderMeshAsset_WithNoPxAsset.py b/AutomatedTesting/Gem/PythonTests/physics/C14861504_RenderMeshAsset_WithNoPxAsset.py
index bbaabf67f6..766a359397 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C14861504_RenderMeshAsset_WithNoPxAsset.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C14861504_RenderMeshAsset_WithNoPxAsset.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C14861504
Test Case Title : Verify if Rendering Mesh does not have a PhysX Collision Mesh fbx, then PxMesh is not auto-assigned
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/14861504
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C14902097_ScriptCanvas_PreUpdateEvent.py b/AutomatedTesting/Gem/PythonTests/physics/C14902097_ScriptCanvas_PreUpdateEvent.py
index 45557098f7..327f40ec38 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C14902097_ScriptCanvas_PreUpdateEvent.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C14902097_ScriptCanvas_PreUpdateEvent.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C14902097
# Test Case Title : Verify Presimulate Events
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/14902097
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C14902098_ScriptCanvas_PostPhysicsUpdate.py b/AutomatedTesting/Gem/PythonTests/physics/C14902098_ScriptCanvas_PostPhysicsUpdate.py
index 19caaab4fe..f7c8be8804 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C14902098_ScriptCanvas_PostPhysicsUpdate.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C14902098_ScriptCanvas_PostPhysicsUpdate.py
@@ -12,7 +12,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 Postsimulate works independently from rendering tick
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/14902098
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C14976307_Gravity_SetGravityWorks.py b/AutomatedTesting/Gem/PythonTests/physics/C14976307_Gravity_SetGravityWorks.py
index 342ac6bdbd..73137ac497 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C14976307_Gravity_SetGravityWorks.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C14976307_Gravity_SetGravityWorks.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C14976307
# Test Case Title : Check that Set Gravity Enabled works on an entity with gravity that starts as disabled
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/14976307
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C14976308_ScriptCanvas_SetKinematicTargetTransform.py b/AutomatedTesting/Gem/PythonTests/physics/C14976308_ScriptCanvas_SetKinematicTargetTransform.py
index 815e922a76..c76c5cab80 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C14976308_ScriptCanvas_SetKinematicTargetTransform.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C14976308_ScriptCanvas_SetKinematicTargetTransform.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test Case
# ID : C14976308
# Title : Verify that SetKinematicTarget on PhysX rigid body updates transform for kinematic entities and vice versa
-# URL : https://testrail.agscollab.com/index.php?/cases/view/14976308
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C15096732_Material_DefaultLibraryUpdatedAcrossLevels_after.py b/AutomatedTesting/Gem/PythonTests/physics/C15096732_Material_DefaultLibraryUpdatedAcrossLevels_after.py
index 76ea9475ff..bdfc9d19be 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C15096732_Material_DefaultLibraryUpdatedAcrossLevels_after.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C15096732_Material_DefaultLibraryUpdatedAcrossLevels_after.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C15096732
# Test Case Title : Verify Default material library works across different levels
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/15096732
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C15096732_Material_DefaultLibraryUpdatedAcrossLevels_before.py b/AutomatedTesting/Gem/PythonTests/physics/C15096732_Material_DefaultLibraryUpdatedAcrossLevels_before.py
index 748052db56..d45423fe94 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C15096732_Material_DefaultLibraryUpdatedAcrossLevels_before.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C15096732_Material_DefaultLibraryUpdatedAcrossLevels_before.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C15096732
# Test Case Title : Verify Default material library works across different levels
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/15096732
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C15096735_Materials_DefaultLibraryConsistency.py b/AutomatedTesting/Gem/PythonTests/physics/C15096735_Materials_DefaultLibraryConsistency.py
index 4c7949cc91..3dd49d4fe4 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C15096735_Materials_DefaultLibraryConsistency.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C15096735_Materials_DefaultLibraryConsistency.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C15096735
# Test Case Title : Verify that default material library works consistently across all systems that use it
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/15096735
+
# fmt:off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C15096737_Materials_DefaultMaterialLibraryChanges.py b/AutomatedTesting/Gem/PythonTests/physics/C15096737_Materials_DefaultMaterialLibraryChanges.py
index cc7dc3c5e2..c806cbb7d4 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C15096737_Materials_DefaultMaterialLibraryChanges.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C15096737_Materials_DefaultMaterialLibraryChanges.py
@@ -14,7 +14,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test Case Title : Verify that a change in the default material library material information
# affects all the materials that reference it, even non-defaulted
# exactly like if the library was selected
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/15096737
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C15096740_Material_LibraryUpdatedCorrectly.py b/AutomatedTesting/Gem/PythonTests/physics/C15096740_Material_LibraryUpdatedCorrectly.py
index 0f33f0858b..bef98f6830 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C15096740_Material_LibraryUpdatedCorrectly.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C15096740_Material_LibraryUpdatedCorrectly.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C15096740
Test Case Title : Verify that clearing a material library on all systems that use it,
assigns the default material library
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/15096740
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C15308217_NoCrash_LevelSwitch.py b/AutomatedTesting/Gem/PythonTests/physics/C15308217_NoCrash_LevelSwitch.py
index 625a8bfb4a..dadfbd7a7e 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C15308217_NoCrash_LevelSwitch.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C15308217_NoCrash_LevelSwitch.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C15308217
# Test Case Title : Verify that the Terrain texture layer doesn't crash when changing
# from on a level with a terrain component to another level without a terrain component
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/15308217
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C15308221_Material_ComponentsInSyncWithLibrary.py b/AutomatedTesting/Gem/PythonTests/physics/C15308221_Material_ComponentsInSyncWithLibrary.py
index 3f6457f15c..ebc7d3fadd 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C15308221_Material_ComponentsInSyncWithLibrary.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C15308221_Material_ComponentsInSyncWithLibrary.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test Case ID : C15308221
# Test Case Title : Verify that material library and slots are always in sync and work consistently through the different places of usage
-# Test Case URL : https://testrail.agscollab.com/index.php?/cases/view/15308221
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C15425929_Undo_Redo.py b/AutomatedTesting/Gem/PythonTests/physics/C15425929_Undo_Redo.py
index 57a0e6a75e..dba14552c8 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C15425929_Undo_Redo.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C15425929_Undo_Redo.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C15425929
# Test Case Title : Verify that undo - redo operations do not create any error
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/15425929
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C15425935_Material_LibraryUpdatedAcrossLevels.py b/AutomatedTesting/Gem/PythonTests/physics/C15425935_Material_LibraryUpdatedAcrossLevels.py
index f61886ccd0..8ff90fddaf 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C15425935_Material_LibraryUpdatedAcrossLevels.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C15425935_Material_LibraryUpdatedAcrossLevels.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C15425935
# Test Case Title : Verify that the change in Material Library gets updated across levels
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/15425935
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C15556261_PhysXMaterials_CharacterControllerMaterialAssignment.py b/AutomatedTesting/Gem/PythonTests/physics/C15556261_PhysXMaterials_CharacterControllerMaterialAssignment.py
index 99e0dcc669..21f5952678 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C15556261_PhysXMaterials_CharacterControllerMaterialAssignment.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C15556261_PhysXMaterials_CharacterControllerMaterialAssignment.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C15556261
# Test Case Title : Check that the material assignment works with Character Controller
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/15556261
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C15563573_Material_AddModifyDeleteOnCharacterController.py b/AutomatedTesting/Gem/PythonTests/physics/C15563573_Material_AddModifyDeleteOnCharacterController.py
index 4572dd322a..1e9b15fc90 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C15563573_Material_AddModifyDeleteOnCharacterController.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C15563573_Material_AddModifyDeleteOnCharacterController.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test Case ID : C15563573
# Test Case Title : Check that any change (Add/Delete/Modify) made to the material surface in the material library reflects immediately in the PhysX Character Controller
-# Test Case URL : https://testrail.agscollab.com/index.php?/cases/view/15563573
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C15845879_ForceRegion_HighLinearDampingForce.py b/AutomatedTesting/Gem/PythonTests/physics/C15845879_ForceRegion_HighLinearDampingForce.py
index 52af7d8be5..6b31ffb13b 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C15845879_ForceRegion_HighLinearDampingForce.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C15845879_ForceRegion_HighLinearDampingForce.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C15845879
# Test Case Title : Check that linear damping with high values do not make the object to quiver
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/15845879
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C17411467_AddPhysxRagdollComponent.py b/AutomatedTesting/Gem/PythonTests/physics/C17411467_AddPhysxRagdollComponent.py
index 68efd452b2..32bd02ae26 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C17411467_AddPhysxRagdollComponent.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C17411467_AddPhysxRagdollComponent.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C17411467
Test Case Title : Check that Physx Ragdoll component can be added without errors/warnings
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/17411467
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18243580_Joints_Fixed2BodiesConstrained.py b/AutomatedTesting/Gem/PythonTests/physics/C18243580_Joints_Fixed2BodiesConstrained.py
index b13869ce12..c3a351ebea 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18243580_Joints_Fixed2BodiesConstrained.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18243580_Joints_Fixed2BodiesConstrained.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C18243580
# Test Case Title : Check that fixed joint constrains 2 bodies
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/18243580
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18243581_Joints_FixedBreakable.py b/AutomatedTesting/Gem/PythonTests/physics/C18243581_Joints_FixedBreakable.py
index 19feee575b..00e9a5625f 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18243581_Joints_FixedBreakable.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18243581_Joints_FixedBreakable.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C18243581
# Test Case Title : Check that fixed joint is breakable
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/18243581
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18243582_Joints_FixedLeadFollowerCollide.py b/AutomatedTesting/Gem/PythonTests/physics/C18243582_Joints_FixedLeadFollowerCollide.py
index c9c90d35a7..d34e3f67d3 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18243582_Joints_FixedLeadFollowerCollide.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18243582_Joints_FixedLeadFollowerCollide.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C18243582
# Test Case Title : Check that fixed joint allows lead-follower collision
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/18243582
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18243583_Joints_Hinge2BodiesConstrained.py b/AutomatedTesting/Gem/PythonTests/physics/C18243583_Joints_Hinge2BodiesConstrained.py
index 66343534a7..eafce6ceaf 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18243583_Joints_Hinge2BodiesConstrained.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18243583_Joints_Hinge2BodiesConstrained.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C18243583
# Test Case Title : Check that hinge joint constrains 2 bodies about X-axis
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/18243583
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18243584_Joints_HingeSoftLimitsConstrained.py b/AutomatedTesting/Gem/PythonTests/physics/C18243584_Joints_HingeSoftLimitsConstrained.py
index 3b335cc5c6..90027be2d7 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18243584_Joints_HingeSoftLimitsConstrained.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18243584_Joints_HingeSoftLimitsConstrained.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C18243584
# Test Case Title : Check that hinge joint allows soft limit constraints on 2 bodies
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/18243584
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18243585_Joints_HingeNoLimitsConstrained.py b/AutomatedTesting/Gem/PythonTests/physics/C18243585_Joints_HingeNoLimitsConstrained.py
index 289522fcac..0f677d94ae 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18243585_Joints_HingeNoLimitsConstrained.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18243585_Joints_HingeNoLimitsConstrained.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C18243585
# Test Case Title : Check that hinge joint allows no limit constraints on 2 bodies
-# URL of the test case :https://testrail.agscollab.com/index.php?/cases/view/18243585
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18243586_Joints_HingeLeadFollowerCollide.py b/AutomatedTesting/Gem/PythonTests/physics/C18243586_Joints_HingeLeadFollowerCollide.py
index 60b9189c83..7c973729d1 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18243586_Joints_HingeLeadFollowerCollide.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18243586_Joints_HingeLeadFollowerCollide.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C18243586
# Test Case Title : Check that hinge joint allows lead-follower collision
-# URL of the test case :https://testrail.agscollab.com/index.php?/cases/view/18243586
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18243587_Joints_HingeBreakable.py b/AutomatedTesting/Gem/PythonTests/physics/C18243587_Joints_HingeBreakable.py
index af6fa8cbac..4734328d70 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18243587_Joints_HingeBreakable.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18243587_Joints_HingeBreakable.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C18243587
# Test Case Title : Check that hinge joint is breakable
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/18243587
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18243588_Joints_Ball2BodiesConstrained.py b/AutomatedTesting/Gem/PythonTests/physics/C18243588_Joints_Ball2BodiesConstrained.py
index 074ca03000..b6acfd6dd8 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18243588_Joints_Ball2BodiesConstrained.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18243588_Joints_Ball2BodiesConstrained.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C18243588
# Test Case Title : Check that ball joint constrains 2 bodies within cone limits
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/18243588
+
# fmt: off
class Tests:
enter_game_mode = ("Entered game mode", "Failed to enter game mode")
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18243589_Joints_BallSoftLimitsConstrained.py b/AutomatedTesting/Gem/PythonTests/physics/C18243589_Joints_BallSoftLimitsConstrained.py
index e038b33043..1ca49035b5 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18243589_Joints_BallSoftLimitsConstrained.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18243589_Joints_BallSoftLimitsConstrained.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : 18243589
# Test Case Title : Check that ball joint allows soft limit constraints
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/18243589
+
# fmt: off
class Tests:
@@ -57,6 +57,7 @@ def C18243589_Joints_BallSoftLimitsConstrained():
"""
import os
import sys
+ import math
import ImportPathHelper as imports
@@ -95,13 +96,33 @@ def C18243589_Joints_BallSoftLimitsConstrained():
Report.info_vector3(follower.position, "follower initial position:")
leadInitialPosition = lead.position
followerInitialPosition = follower.position
-
- # 4) Wait for several seconds
- general.idle_wait(1.0) # wait for lead and follower to move
+
+ followerMovedAboveJoint = False
+ #calculate the start vector from follower and lead positions
+ normalizedStartPos = JointsHelper.getRelativeVector(lead.position, follower.position)
+ normalizedStartPos = normalizedStartPos.GetNormalizedSafe()
+ #the targeted angle to reach between the initial vector and the current follower-lead vector
+ TARGET_ANGLE_DEG = 45
+ targetAngle = math.radians(TARGET_ANGLE_DEG)
+ angleAchieved = 0.0
+
+ def checkAngleMet():
+ #calculate the current follower-lead vector
+ normalVec = JointsHelper.getRelativeVector(lead.position, follower.position)
+ normalVec = normalVec.GetNormalizedSafe()
+ #dot product + acos to get the angle
+ angleAchieved = math.acos(normalizedStartPos.Dot(normalVec))
+ #is it above target?
+ return angleAchieved > targetAngle
+
+ MAX_WAIT_TIME = 2.0 #seconds
+ followerMovedAboveJoint = helper.wait_for_condition(checkAngleMet, MAX_WAIT_TIME)
# 5) Check to see if lead and follower behaved as expected
- Report.info_vector3(lead.position, "lead position after 1 second:")
- Report.info_vector3(follower.position, "follower position after 1 second:")
+ Report.info_vector3(lead.position, "lead position:")
+ Report.info_vector3(follower.position, "follower position:")
+ angleAchievedDeg = math.degrees(angleAchieved)
+ Report.info(f"Angle achieved {angleAchievedDeg:.2f} Target {TARGET_ANGLE_DEG:.2f}")
leadPositionDelta = lead.position.Subtract(leadInitialPosition)
leadRemainedStill = JointsHelper.vector3SmallerThanScalar(leadPositionDelta, FLOAT_EPSILON)
@@ -111,7 +132,6 @@ def C18243589_Joints_BallSoftLimitsConstrained():
followerMovedinXYZ = JointsHelper.vector3LargerThanScalar(followerPositionDelta, FLOAT_EPSILON)
Report.critical_result(Tests.check_follower_position, followerMovedinXYZ)
- followerMovedAboveJoint = follower.position.z > (followerInitialPosition.z + 2.5) # (followerInitialPosition.z + 2.5) is the z position past the 45 degree limit. This is to show that the follower swinged past the 45 degree cone limit, above the joint position.
Report.critical_result(Tests.check_follower_above_joint, followerMovedAboveJoint)
# 6) Exit Game Mode
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18243590_Joints_BallNoLimitsConstrained.py b/AutomatedTesting/Gem/PythonTests/physics/C18243590_Joints_BallNoLimitsConstrained.py
index ede46fd5c5..1d5a213cd8 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18243590_Joints_BallNoLimitsConstrained.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18243590_Joints_BallNoLimitsConstrained.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C18243590
# Test Case Title : Check that ball joint allows no limit constraints
-# URL of the test case :https://testrail.agscollab.com/index.php?/cases/view/18243590
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18243591_Joints_BallLeadFollowerCollide.py b/AutomatedTesting/Gem/PythonTests/physics/C18243591_Joints_BallLeadFollowerCollide.py
index c3e527956f..8f7b2d7823 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18243591_Joints_BallLeadFollowerCollide.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18243591_Joints_BallLeadFollowerCollide.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C18243591
# Test Case Title : Check that ball joint allows lead-follower collision
-# URL of the test case :https://testrail.agscollab.com/index.php?/cases/view/18243591
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18243592_Joints_BallBreakable.py b/AutomatedTesting/Gem/PythonTests/physics/C18243592_Joints_BallBreakable.py
index 350fccd125..0fa43cf9c8 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18243592_Joints_BallBreakable.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18243592_Joints_BallBreakable.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C18243592
# Test Case Title : Check that ball joint is breakable
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/18243592
+
# fmt: off
class Tests:
enter_game_mode = ("Entered game mode", "Failed to enter game mode")
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18243593_Joints_GlobalFrameConstrained.py b/AutomatedTesting/Gem/PythonTests/physics/C18243593_Joints_GlobalFrameConstrained.py
index 4580a229ea..37d659f181 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18243593_Joints_GlobalFrameConstrained.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18243593_Joints_GlobalFrameConstrained.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C18243593
# Test Case Title : Check that fixed/hinge/ball joints allow constraints to global frame
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/18243593
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18977601_Material_FrictionCombinePriority.py b/AutomatedTesting/Gem/PythonTests/physics/C18977601_Material_FrictionCombinePriority.py
index 57dfc0f349..b17b97a816 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18977601_Material_FrictionCombinePriority.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18977601_Material_FrictionCombinePriority.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C18977601
# Test Case Title : Verify that when two objects with different materials collide, the friction combine priority works
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/18977601
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C18981526_Material_RestitutionCombinePriority.py b/AutomatedTesting/Gem/PythonTests/physics/C18981526_Material_RestitutionCombinePriority.py
index 9b7fea1ab9..690d3d4d3f 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C18981526_Material_RestitutionCombinePriority.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C18981526_Material_RestitutionCombinePriority.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C18981526
# Test Case Title : Verify when two objects with different materials collide, the restitution combine priority works
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/18981526
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C19536274_GetCollisionName_PrintsName.py b/AutomatedTesting/Gem/PythonTests/physics/C19536274_GetCollisionName_PrintsName.py
index 48c947aa1f..611b502019 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C19536274_GetCollisionName_PrintsName.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C19536274_GetCollisionName_PrintsName.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C19536274
Test Case Title : Verify that the Get Collision Layer Name node prints the name of the collision layer
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/19536274
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C19536277_GetCollisionName_PrintsNothing.py b/AutomatedTesting/Gem/PythonTests/physics/C19536277_GetCollisionName_PrintsNothing.py
index 66e1302b5b..04d973cbb2 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C19536277_GetCollisionName_PrintsNothing.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C19536277_GetCollisionName_PrintsNothing.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C19536277
Test Case Title : Verify that when a group is modified using ToggleCollisionLayer node such that the new group is not in the pre-existing groups, GetCollisionGroupName node prints no value
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/19536277
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C19578018_ShapeColliderWithNoShapeComponent.py b/AutomatedTesting/Gem/PythonTests/physics/C19578018_ShapeColliderWithNoShapeComponent.py
index 32ece8541c..23996934bc 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C19578018_ShapeColliderWithNoShapeComponent.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C19578018_ShapeColliderWithNoShapeComponent.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C19578018
Test Case Title : Verify that a shape collider component with no shape component indicates a missing service
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/19578018
+
"""
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C19578021_ShapeCollider_CanBeAdded.py b/AutomatedTesting/Gem/PythonTests/physics/C19578021_ShapeCollider_CanBeAdded.py
index 0c42f5457d..1eb36e16f4 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C19578021_ShapeCollider_CanBeAdded.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C19578021_ShapeCollider_CanBeAdded.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C19578021
Test Case Title : Verify that a shape collider component may be added to an entity along with one or more PhysX collider components
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/19578021
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C19723164_ShapeColliders_WontCrashEditor.py b/AutomatedTesting/Gem/PythonTests/physics/C19723164_ShapeColliders_WontCrashEditor.py
index 769f08e3c4..f6584624c3 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C19723164_ShapeColliders_WontCrashEditor.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C19723164_ShapeColliders_WontCrashEditor.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C19723164
Test Case Title : Verify that if we had 512 shape colliders in the level, the level does not crash
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/19723164
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain.py b/AutomatedTesting/Gem/PythonTests/physics/C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain.py
index d8e0a6769c..101b96b99b 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C24308873
# Test Case Title : Check that cylinder shape collider collides with terrain
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/24308873
+
# A cylinder is suspended slightly over PhysX Terrain to check that it collides when dropped
@@ -20,7 +20,10 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
class Tests():
enter_game_mode = ("Entered game mode", "Failed to enter game mode")
find_cylinder = ("Cylinder entity found", "Cylinder entity not found")
- find_terrain = ("Terrain found", "Terrain not found")
+ create_terrain = ("Terrain entity created successfully", "Failed to create Terrain Entity")
+ find_terrain = ("Terrain entity found", "Terrain entity not found")
+ add_physx_shape_collider = ("Added PhysX Shape Collider", "Failed to add PhysX Shape Collider")
+ add_box_shape = ("Added Box Shape", "Failed to add Box Shape")
cylinder_above_terrain = ("Cylinder position above ground", "Cylinder is not above the ground")
time_out = ("No time out occurred", "A time out occurred, please validate level setup")
touched_ground = ("Touched ground before time out", "Did not touch ground before time out")
@@ -40,11 +43,12 @@ def C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain():
Once game mode is entered, the cylinder should fall toward and collide with the terrain.
Steps:
- 1) Open level and enter game mode
- 2) Retrieve entities and positions
- 3) Wait for cylinder to collide with terrain OR time out
- 4) Exit game mode
- 5) Close the editor
+ 1) Open level and create terrain Entity.
+ 2) Enter Game Mode.
+ 3) Retrieve entities and positions
+ 4) Wait for cylinder to collide with terrain OR time out
+ 5) Exit game mode
+ 6) Close the editor
:return:
"""
@@ -54,29 +58,48 @@ def C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain():
import ImportPathHelper as imports
imports.init()
-
+ from editor_python_test_tools.editor_entity_utils import EditorEntity
import azlmbr.legacy.general as general
import azlmbr.bus
+ import azlmbr.math as math
from editor_python_test_tools.utils import Report
from editor_python_test_tools.utils import TestHelper as helper
# Global time out
TIME_OUT = 1.0
- # 1) Open level / Enter game mode
+ # 1) Open level
helper.init_idle()
helper.open_level("Physics", "C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain")
+
+ # Create terrain entity
+ terrain = EditorEntity.create_editor_entity_at([30.0, 30.0, 33.96], "Terrain")
+ Report.result(Tests.create_terrain, terrain.id.IsValid())
+
+ terrain.add_component("PhysX Shape Collider")
+ Report.result(Tests.add_physx_shape_collider, terrain.has_component("PhysX Shape Collider"))
+
+ box_shape_component = terrain.add_component("Box Shape")
+ Report.result(Tests.add_box_shape, terrain.has_component("Box Shape"))
+
+ box_shape_component.set_component_property_value("Box Shape|Box Configuration|Dimensions",
+ math.Vector3(1024.0, 1024.0, 0.01))
+
+ # 2)Enter game mode
helper.enter_game_mode(Tests.enter_game_mode)
- # 2) Retrieve entities and positions
+ # 3) Retrieve entities and positions
cylinder_id = general.find_game_entity("PhysX_Cylinder")
Report.critical_result(Tests.find_cylinder, cylinder_id.IsValid())
+
+
+ terrain_id = general.find_game_entity("Terrain")
+ Report.critical_result(Tests.find_terrain, terrain_id.IsValid())
- terrain_id = general.find_game_entity("PhysX_Terrain")
- Report.critical_result(Tests.find_terrain, terrain_id.IsValid())
- cylinder_pos = azlmbr.components.TransformBus(azlmbr.bus.Event, "GetWorldTM", cylinder_id).GetPosition()
- terrain_pos = azlmbr.components.TransformBus(azlmbr.bus.Event, "GetWorldTM", terrain_id).GetPosition()
+ cylinder_pos = azlmbr.components.TransformBus(azlmbr.bus.Event, "GetWorldTranslation", cylinder_id)
+ #Cylinder position is 64,84,35
+ terrain_pos = azlmbr.components.TransformBus(azlmbr.bus.Event, "GetWorldTranslation", terrain_id)
Report.info_vector3(cylinder_pos, "Cylinder:")
Report.info_vector3(terrain_pos, "Terrain:")
Report.critical_result(
@@ -104,13 +127,13 @@ def C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain():
handler.connect(cylinder_id)
handler.add_callback("OnCollisionBegin", on_collision_begin)
- # 3) Wait for the cylinder to hit the ground OR time out
+ # 4) Wait for the cylinder to hit the ground OR time out
test_completed = helper.wait_for_condition((lambda: TouchGround.value), TIME_OUT)
Report.critical_result(Tests.time_out, test_completed)
Report.result(Tests.touched_ground, TouchGround.value)
- # 4) Exit game mode
+ # 5) Exit game mode
helper.exit_game_mode(Tests.exit_game_mode)
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C28978033_Ragdoll_WorldBodyBusTests.py b/AutomatedTesting/Gem/PythonTests/physics/C28978033_Ragdoll_WorldBodyBusTests.py
index 8980e68250..052795318a 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C28978033_Ragdoll_WorldBodyBusTests.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C28978033_Ragdoll_WorldBodyBusTests.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C28978033
# Test Case Title : Check that WorldRequestBus works with PhysX ragdoll
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/28978033
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C29032500_EditorComponents_WorldBodyBusWorks.py b/AutomatedTesting/Gem/PythonTests/physics/C29032500_EditorComponents_WorldBodyBusWorks.py
index be541e4bf9..4915d362f7 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C29032500_EditorComponents_WorldBodyBusWorks.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C29032500_EditorComponents_WorldBodyBusWorks.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C29032500
# Test Case Title : Check that WorldRequestBus works with editor components
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/29032500
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C3510642_Terrain_NotCollideWithTerrain.py b/AutomatedTesting/Gem/PythonTests/physics/C3510642_Terrain_NotCollideWithTerrain.py
index 3e3770adb9..b671cd3754 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C3510642_Terrain_NotCollideWithTerrain.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C3510642_Terrain_NotCollideWithTerrain.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C3510642
# Test Case Title : Check that when no physX terrain component is added, collision of a PhysX object
# with terrain does not work. Consequently, PhysX material assignment to terrain cannot be tested.
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/3510642
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4044455_Material_libraryChangesInstantly.py b/AutomatedTesting/Gem/PythonTests/physics/C4044455_Material_libraryChangesInstantly.py
index 5f2c40f11e..a7916129e8 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4044455_Material_libraryChangesInstantly.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4044455_Material_libraryChangesInstantly.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : 4044455
# Test Case Title : Verify that any change in any of the values including the name of the material,
# once saved, is immediately reflected in the component and functionality
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4044455
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4044456_Material_FrictionCombine.py b/AutomatedTesting/Gem/PythonTests/physics/C4044456_Material_FrictionCombine.py
index b71c1e8ede..eced55fc76 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4044456_Material_FrictionCombine.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4044456_Material_FrictionCombine.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4044456
# Test Case Title : Verify that when two objects with different materials collide, the friction combine works
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4044456
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4044457_Material_RestitutionCombine.py b/AutomatedTesting/Gem/PythonTests/physics/C4044457_Material_RestitutionCombine.py
index 1ed2e8086c..5969541a86 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4044457_Material_RestitutionCombine.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4044457_Material_RestitutionCombine.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4044457
# Test Case Title : Verify that when two objects with different materials collide, the restitution combine works
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4044457
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4044459_Material_DynamicFriction.py b/AutomatedTesting/Gem/PythonTests/physics/C4044459_Material_DynamicFriction.py
index c420250dfa..d414bc4813 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4044459_Material_DynamicFriction.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4044459_Material_DynamicFriction.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4044459
# Test Case Title : Verify the functionality of dynamic friction
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4044459
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4044460_Material_StaticFriction.py b/AutomatedTesting/Gem/PythonTests/physics/C4044460_Material_StaticFriction.py
index 4e330002ff..6e864c554b 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4044460_Material_StaticFriction.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4044460_Material_StaticFriction.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4044460
# Test Case Title : Verify the functionality of static friction
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4044460
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4044461_Material_Restitution.py b/AutomatedTesting/Gem/PythonTests/physics/C4044461_Material_Restitution.py
index af8990d87f..a5219ed2c7 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4044461_Material_Restitution.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4044461_Material_Restitution.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4044461
# Test Case Title : Verify the functionality of restitution
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4044461
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4044694_Material_EmptyLibraryUsesDefault.py b/AutomatedTesting/Gem/PythonTests/physics/C4044694_Material_EmptyLibraryUsesDefault.py
index a8375114d5..e9106d89eb 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4044694_Material_EmptyLibraryUsesDefault.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4044694_Material_EmptyLibraryUsesDefault.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test Case ID : C4044694
# Test Case Title : Verify that if we add an empty Material library in Collider Component, the object continues to use Default material values
-# Test Case URL : https://testrail.agscollab.com/index.php?/cases/view/4044694
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4044695_PhysXCollider_AddMultipleSurfaceFbx.py b/AutomatedTesting/Gem/PythonTests/physics/C4044695_PhysXCollider_AddMultipleSurfaceFbx.py
index 858e778f07..d65e9050bd 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4044695_PhysXCollider_AddMultipleSurfaceFbx.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4044695_PhysXCollider_AddMultipleSurfaceFbx.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C4044695
Test Case Title : Verify that when you add a multiple surface fbx in PxMesh in PhysxCollider,
multiple number of Material Slots populate in the Materials Section
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4044695
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4044697_Material_PerfaceMaterialValidation.py b/AutomatedTesting/Gem/PythonTests/physics/C4044697_Material_PerfaceMaterialValidation.py
index dba759015f..435e8242d5 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4044697_Material_PerfaceMaterialValidation.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4044697_Material_PerfaceMaterialValidation.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4044697
# Test Case Title : Verify that each surface picks up the material assigned to it and behaves accordingly.
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4044697
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4888315_Material_AddModifyDeleteOnCollider.py b/AutomatedTesting/Gem/PythonTests/physics/C4888315_Material_AddModifyDeleteOnCollider.py
index 145a5e1b60..b7b3ed855f 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4888315_Material_AddModifyDeleteOnCollider.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4888315_Material_AddModifyDeleteOnCollider.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test Case ID : C4888315
# Test Case Title : Check that any change (Add/Delete/Modify) made to the material surface in the material library reflects immediately in the PhysX Collider component
-# Test Case URL : https://testrail.agscollab.com/index.php?/cases/view/4888315
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4925577_Materials_MaterialAssignedToTerrain.py b/AutomatedTesting/Gem/PythonTests/physics/C4925577_Materials_MaterialAssignedToTerrain.py
index 59b6a3fdfc..7ebb62eaf3 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4925577_Materials_MaterialAssignedToTerrain.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4925577_Materials_MaterialAssignedToTerrain.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4925577
# Test Case Title : Verify that material can be assigned to PhysX terrain in Terrain Texture Layers
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4925577
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4925579_Material_AddModifyDeleteOnTerrain.py b/AutomatedTesting/Gem/PythonTests/physics/C4925579_Material_AddModifyDeleteOnTerrain.py
index e0425c35be..315cf9c3bd 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4925579_Material_AddModifyDeleteOnTerrain.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4925579_Material_AddModifyDeleteOnTerrain.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test Case ID : C4925579
# Test Case Title : Check that any change (Add/Delete/Modify) made to the material surface in the material library reflects immediately in the PhysX Terrain layers
-# Test Case URL : https://testrail.agscollab.com/index.php?/cases/view/4925579
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4925580_Material_RagdollBonesMaterial.py b/AutomatedTesting/Gem/PythonTests/physics/C4925580_Material_RagdollBonesMaterial.py
index 9944a033e3..5fae373f47 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4925580_Material_RagdollBonesMaterial.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4925580_Material_RagdollBonesMaterial.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test Case ID : C4925580
# Test Case Title : Verify that Material can be assigned to Ragdoll Bones and they behave as per their material
-# Test Case URL : https://testrail.agscollab.com/index.php?/cases/view/4925580
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4925582_Material_AddModifyDeleteOnRagdollBones.py b/AutomatedTesting/Gem/PythonTests/physics/C4925582_Material_AddModifyDeleteOnRagdollBones.py
index ed872ae99e..ca37be6ff0 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4925582_Material_AddModifyDeleteOnRagdollBones.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4925582_Material_AddModifyDeleteOnRagdollBones.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test Case ID : C4925582
# Test Case Title : Check that any change (Add/Delete/Modify) made to the material surface in the material library reflects immediately in the ragdoll bones
-# Test Case URL : https://testrail.agscollab.com/index.php?/cases/view/4925582
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976194_RigidBody_PhysXComponentIsValid.py b/AutomatedTesting/Gem/PythonTests/physics/C4976194_RigidBody_PhysXComponentIsValid.py
index aa059eb224..8bb005711e 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976194_RigidBody_PhysXComponentIsValid.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976194_RigidBody_PhysXComponentIsValid.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976194
# Test Case Title : Verify that you can add PhysX Rigid Bodies Physics component to an Entity without any warning or Error.
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976194
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976195_RigidBodies_InitialLinearVelocity.py b/AutomatedTesting/Gem/PythonTests/physics/C4976195_RigidBodies_InitialLinearVelocity.py
index c5740b2798..3dbf26a0ac 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976195_RigidBodies_InitialLinearVelocity.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976195_RigidBodies_InitialLinearVelocity.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976195
# Test Case Title : Verify that when you assign an Initial Linear Velocity to an object,
# ... it moves with that linear velocity when we switch to game mode.
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976195
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976197_RigidBodies_InitialAngularVelocity.py b/AutomatedTesting/Gem/PythonTests/physics/C4976197_RigidBodies_InitialAngularVelocity.py
index 08e171269e..7a17eb5941 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976197_RigidBodies_InitialAngularVelocity.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976197_RigidBodies_InitialAngularVelocity.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976197
# Test Case Title : Verify that when you assign an Initial Angular Velocity to an object,
# it moves with that Angular velocity when we switch to game mode
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976197
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976199_RigidBodies_LinearDampingObjectMotion.py b/AutomatedTesting/Gem/PythonTests/physics/C4976199_RigidBodies_LinearDampingObjectMotion.py
index 2e19b633c4..457cb18640 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976199_RigidBodies_LinearDampingObjectMotion.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976199_RigidBodies_LinearDampingObjectMotion.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976199
# Test Case Title : Verify that with higher linear damping, the object in motion comes to rest faster
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976199
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976200_RigidBody_AngularDampingObjectRotation.py b/AutomatedTesting/Gem/PythonTests/physics/C4976200_RigidBody_AngularDampingObjectRotation.py
index b90b34be53..f423821757 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976200_RigidBody_AngularDampingObjectRotation.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976200_RigidBody_AngularDampingObjectRotation.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976200
# Test Case Title : Verify that with higher angular damping, the object in rotation comes to rest faster
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976200
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976201_RigidBody_MassIsAssigned.py b/AutomatedTesting/Gem/PythonTests/physics/C4976201_RigidBody_MassIsAssigned.py
index 7fb0ff84ce..fd15cbbb0f 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976201_RigidBody_MassIsAssigned.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976201_RigidBody_MassIsAssigned.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976201
# Test Case Title : Verify that the value assigned to the Mass of the object, gets actually assigned to the object
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976201
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976202_RigidBody_StopsWhenBelowKineticThreshold.py b/AutomatedTesting/Gem/PythonTests/physics/C4976202_RigidBody_StopsWhenBelowKineticThreshold.py
index 7d4cf1066e..c66f5cf7b6 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976202_RigidBody_StopsWhenBelowKineticThreshold.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976202_RigidBody_StopsWhenBelowKineticThreshold.py
@@ -14,7 +14,7 @@ Test case ID : C4976202
Test Case Title : Verify that if the object is moving with Kinetic energy less than
the sleep threshold value, then physX will put it to stop after 0.4 secs (once the
wake counter goes to zero) if the KE is still below the threshold
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976202
+
"""
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976204_Verify_Start_Asleep_Condition.py b/AutomatedTesting/Gem/PythonTests/physics/C4976204_Verify_Start_Asleep_Condition.py
index 29fc2ec2a3..6b29062adf 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976204_Verify_Start_Asleep_Condition.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976204_Verify_Start_Asleep_Condition.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976204
# Test Case Title : Verify that when Start Asleep is checked, the object in air does not fall down due to
# gravity or does not start moving with initial linear velocity assigned to it when switched to game mode
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976204
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976206_RigidBodies_GravityEnabledActive.py b/AutomatedTesting/Gem/PythonTests/physics/C4976206_RigidBodies_GravityEnabledActive.py
index b97c590a93..934e546d65 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976206_RigidBodies_GravityEnabledActive.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976206_RigidBodies_GravityEnabledActive.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976206
# Test Case Title : VErify that when Gravity enables is checked, the object falls down due to gravity [sic]
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976206
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976207_PhysXRigidBodies_KinematicBehavior.py b/AutomatedTesting/Gem/PythonTests/physics/C4976207_PhysXRigidBodies_KinematicBehavior.py
index 4481c00fc5..58193a1e9b 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976207_PhysXRigidBodies_KinematicBehavior.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976207_PhysXRigidBodies_KinematicBehavior.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976207
# Test Case Title : Verify that when Kinematic is checked, the object behaves as a Kinematic object
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976207
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976209_RigidBody_ComputesCOM.py b/AutomatedTesting/Gem/PythonTests/physics/C4976209_RigidBody_ComputesCOM.py
index 79ea6e5dc7..600b20d98d 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976209_RigidBody_ComputesCOM.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976209_RigidBody_ComputesCOM.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976209
# Test Case Title : Verify that when Compute COM is enabled, the PhysX system computes the COM of the object on its own
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976209
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976210_COM_ManualSetting.py b/AutomatedTesting/Gem/PythonTests/physics/C4976210_COM_ManualSetting.py
index 451081ba23..c53fb3508d 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976210_COM_ManualSetting.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976210_COM_ManualSetting.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976210
# Test Case Title : Verify that when Compute COM is disabled, the user gets an option to add the co-ordinates of
# the COM and the COM gets implemented at those co-ordinates.
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976210
+
import os
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976218_RigidBodies_InertiaObjectsNotComputed.py b/AutomatedTesting/Gem/PythonTests/physics/C4976218_RigidBodies_InertiaObjectsNotComputed.py
index 63f0d382c3..dada67548b 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976218_RigidBodies_InertiaObjectsNotComputed.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976218_RigidBodies_InertiaObjectsNotComputed.py
@@ -9,7 +9,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
"""
# Test case ID : C4976218
# Test Case Title: Verify that when compute inertia is checked, the physX engine does compute the inertia of the objects
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976218
+
# fmt: off
class Tests():
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976227_Collider_NewGroup.py b/AutomatedTesting/Gem/PythonTests/physics/C4976227_Collider_NewGroup.py
index 8d9dc01396..78c031870d 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976227_Collider_NewGroup.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976227_Collider_NewGroup.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976227
# Test Case Title : Validate that a Collision Group can be added
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976227
+
# Level has entity with custom collision group added.
# If level enters game mode, collision group addition is validated.
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976236_AddPhysxColliderComponent.py b/AutomatedTesting/Gem/PythonTests/physics/C4976236_AddPhysxColliderComponent.py
index 72442601e4..fdb862005f 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976236_AddPhysxColliderComponent.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976236_AddPhysxColliderComponent.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C4976236
Test Case Title : Verify that you can add the physX collider component to an entity
without it throwing an error or warning
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976236
+
"""
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976242_Collision_SameCollisionlayerSameCollisiongroup.py b/AutomatedTesting/Gem/PythonTests/physics/C4976242_Collision_SameCollisionlayerSameCollisiongroup.py
index bb6234b69e..ac14164f45 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976242_Collision_SameCollisionlayerSameCollisiongroup.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976242_Collision_SameCollisionlayerSameCollisiongroup.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976242
# Test Case Title : Assign same collision layer and same collision group to two entities and
# verify that they collide or not
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976242
+
# fmt: off
class Tests():
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976243_Collision_SameCollisionGroupDiffCollisionLayers.py b/AutomatedTesting/Gem/PythonTests/physics/C4976243_Collision_SameCollisionGroupDiffCollisionLayers.py
index 949ebb2b2a..44a8b15169 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976243_Collision_SameCollisionGroupDiffCollisionLayers.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976243_Collision_SameCollisionGroupDiffCollisionLayers.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976243
# Test Case Title : Assign different collision layers and same collision group
# (such that this group has both these collision layers enabled) to two entities and verify that they collide
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976243
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976244_Collider_SameGroupSameLayerCollision.py b/AutomatedTesting/Gem/PythonTests/physics/C4976244_Collider_SameGroupSameLayerCollision.py
index c35b9fab81..ca1e7f57f5 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976244_Collider_SameGroupSameLayerCollision.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976244_Collider_SameGroupSameLayerCollision.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976244
# Test Case Title : Checks that two entities of similar custom layer collide
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976244
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4976245_PhysXCollider_CollisionLayerTest.py b/AutomatedTesting/Gem/PythonTests/physics/C4976245_PhysXCollider_CollisionLayerTest.py
index dafb8d9014..5f8c0a8d67 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4976245_PhysXCollider_CollisionLayerTest.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4976245_PhysXCollider_CollisionLayerTest.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4976245
# Test Case Title : Check that two entities of collision group "None" do not collide,
# even though they have the same collision layer
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4976245
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4982593_PhysXCollider_CollisionLayerTest.py b/AutomatedTesting/Gem/PythonTests/physics/C4982593_PhysXCollider_CollisionLayerTest.py
index 8d985de402..126ebf48dc 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4982593_PhysXCollider_CollisionLayerTest.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4982593_PhysXCollider_CollisionLayerTest.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4982593
# Test Case Title : Check that two entities with different collision groups and layers do not collide.
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4982593
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4982595_Collider_TriggerDisablesCollision.py b/AutomatedTesting/Gem/PythonTests/physics/C4982595_Collider_TriggerDisablesCollision.py
index 8746996ca8..c50c517086 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4982595_Collider_TriggerDisablesCollision.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4982595_Collider_TriggerDisablesCollision.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test Case ID : C4982595
# Test Case Title : Verify that when the Trigger Checkbox is ticked, the object no longer collides with another object
# but simply passes through it
-# Test Case URL : https://testrail.agscollab.com/index.php?/cases/view/4982595
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4982797_Collider_ColliderOffset.py b/AutomatedTesting/Gem/PythonTests/physics/C4982797_Collider_ColliderOffset.py
index 2bd4fc5adc..29a3b7f89d 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4982797_Collider_ColliderOffset.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4982797_Collider_ColliderOffset.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4982797
# Test Case Title : Check that collision offsets trigger collision events,
# not entity transform locations
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4982797
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4982798_Collider_ColliderRotationOffset.py b/AutomatedTesting/Gem/PythonTests/physics/C4982798_Collider_ColliderRotationOffset.py
index f86890d8bf..6276c81871 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4982798_Collider_ColliderRotationOffset.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4982798_Collider_ColliderRotationOffset.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C4982798
# Test Case Title : Verify that when the x,y,z values are defined in the offset, the collider frame
# rotates from its original orientation in the direction defined by the x,y,z units
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4982798
+
import os
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4982800_PhysXColliderShape_CanBeSelected.py b/AutomatedTesting/Gem/PythonTests/physics/C4982800_PhysXColliderShape_CanBeSelected.py
index c37ad2b2d2..1822a1efa7 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4982800_PhysXColliderShape_CanBeSelected.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4982800_PhysXColliderShape_CanBeSelected.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C4982800
Test Case Title : Verify that the shape Sphere can be selected from the drop downlist and the value for its radius can be set
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4982800
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4982801_PhysXColliderShape_CanBeSelected.py b/AutomatedTesting/Gem/PythonTests/physics/C4982801_PhysXColliderShape_CanBeSelected.py
index 19a835da18..ef9b8171c4 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4982801_PhysXColliderShape_CanBeSelected.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4982801_PhysXColliderShape_CanBeSelected.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C4982801
Test Case Title : Verify that the shape Box can be selected from drop downlist and the value for its dimensions in x,y,z can be set after that
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4982801
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4982802_PhysXColliderShape_CanBeSelected.py b/AutomatedTesting/Gem/PythonTests/physics/C4982802_PhysXColliderShape_CanBeSelected.py
index e1365d0887..642dea48de 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4982802_PhysXColliderShape_CanBeSelected.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4982802_PhysXColliderShape_CanBeSelected.py
@@ -10,7 +10,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C4982802
Test Case Title : Verify that the shape capsule can be selected from drop downlist and the value for its height and radius can be set after that
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4982802
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C4982803_Enable_PxMesh_Option.py b/AutomatedTesting/Gem/PythonTests/physics/C4982803_Enable_PxMesh_Option.py
index 4ae177934a..99e93c26c9 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C4982803_Enable_PxMesh_Option.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C4982803_Enable_PxMesh_Option.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Test case ID : C4982803
Test Case Title : Verify that when the shape Physics Asset is selected,
PxMesh option gets enabled and a Px Mesh can be selected and assigned to the object
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/4982803
+
"""
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5296614_PhysXMaterial_ColliderShape.py b/AutomatedTesting/Gem/PythonTests/physics/C5296614_PhysXMaterial_ColliderShape.py
index 9d2a49ac70..b4af6ab506 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5296614_PhysXMaterial_ColliderShape.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5296614_PhysXMaterial_ColliderShape.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5296614
# Test Case Title : Check that unless you assign a shape to a physX collider component,
# the material assigned to it does not take affect
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5296614
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5340400_RigidBody_ManualMomentOfInertia.py b/AutomatedTesting/Gem/PythonTests/physics/C5340400_RigidBody_ManualMomentOfInertia.py
index 7617e41cad..838007436c 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5340400_RigidBody_ManualMomentOfInertia.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5340400_RigidBody_ManualMomentOfInertia.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5340400
# Test Case Title : Verify that when Compute inertia is disabled, the user gets to set the moment of inertia
# and physX engine work accordingly
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5340400
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5689518_PhysXTerrain_CollidesWithPhysXTerrain.py b/AutomatedTesting/Gem/PythonTests/physics/C5689518_PhysXTerrain_CollidesWithPhysXTerrain.py
index 0686adf15d..f17bf2492f 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5689518_PhysXTerrain_CollidesWithPhysXTerrain.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5689518_PhysXTerrain_CollidesWithPhysXTerrain.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5689518
# Test Case Title : PhysX entities collide with PhysX Terrain
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5689518
+
# A ball is suspended slightly over PhysX Terrain to check that it collides when dropped
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5689522_Physxterrain_AddPhysxterrainNoEditorCrash.py b/AutomatedTesting/Gem/PythonTests/physics/C5689522_Physxterrain_AddPhysxterrainNoEditorCrash.py
index ffafeaab34..61ef63c4ae 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5689522_Physxterrain_AddPhysxterrainNoEditorCrash.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5689522_Physxterrain_AddPhysxterrainNoEditorCrash.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5689522
# Test Case Title : Create an entity with PhysX terrain. Add another PhysX terrain and verify that
# you are able to add it without any crash or error.
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5689522
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5689524_MultipleTerrains_CheckWarningInConsole.py b/AutomatedTesting/Gem/PythonTests/physics/C5689524_MultipleTerrains_CheckWarningInConsole.py
index 2b1a73f1f3..c395507ea0 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5689524_MultipleTerrains_CheckWarningInConsole.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5689524_MultipleTerrains_CheckWarningInConsole.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5689524
# Test Case Title : Create multiple entities each with one or more terrain components and verify that you are
# able to successfully add the PhysX Terrain components to them.
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5689524
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5689528_Terrain_MultipleTerrainComponents.py b/AutomatedTesting/Gem/PythonTests/physics/C5689528_Terrain_MultipleTerrainComponents.py
index 265836489d..12f3955bf6 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5689528_Terrain_MultipleTerrainComponents.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5689528_Terrain_MultipleTerrainComponents.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5689528
# Test Case Title : Create multiple entities each with one PhysX terrain component and verify that a warning
# is thrown to the user
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5689528
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5689529_Verify_Terrain_RigidBody_Collider_Mesh.py b/AutomatedTesting/Gem/PythonTests/physics/C5689529_Verify_Terrain_RigidBody_Collider_Mesh.py
index 138ae68408..c5342d7421 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5689529_Verify_Terrain_RigidBody_Collider_Mesh.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5689529_Verify_Terrain_RigidBody_Collider_Mesh.py
@@ -14,7 +14,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test Case Title : Create an entity with PhysX Terrain component and add
# PhysX Rigid Body PhysX, PhysX Collider and Rendering Mesh to it and
# verify that it works in game mode
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5689529
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5689531_Warning_TerrainSliceTerrainComponent.py b/AutomatedTesting/Gem/PythonTests/physics/C5689531_Warning_TerrainSliceTerrainComponent.py
index 7d60a61ec1..85a9037a36 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5689531_Warning_TerrainSliceTerrainComponent.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5689531_Warning_TerrainSliceTerrainComponent.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5689531
# Test Case Title : Check that when you add a spawner component to a level to spawn a
# terrain and also add a terrain component explicitly, no crash happens
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5689531
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5932040_ForceRegion_CubeExertsWorldForce.py b/AutomatedTesting/Gem/PythonTests/physics/C5932040_ForceRegion_CubeExertsWorldForce.py
index f01dd4582f..b1f9f8f934 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5932040_ForceRegion_CubeExertsWorldForce.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5932040_ForceRegion_CubeExertsWorldForce.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5932040
# Test Case Title : Check that force region exerts world space force on rigid bodies
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5932040
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5932041_PhysXForceRegion_LocalSpaceForceOnRigidBodies.py b/AutomatedTesting/Gem/PythonTests/physics/C5932041_PhysXForceRegion_LocalSpaceForceOnRigidBodies.py
index 095a669541..5fc07fdc67 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5932041_PhysXForceRegion_LocalSpaceForceOnRigidBodies.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5932041_PhysXForceRegion_LocalSpaceForceOnRigidBodies.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5932041
# Test Case Title : Check that force region exerts local space force on rigid bodies
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5932041
+
# Sphere drops and is acted upon in an upward and positive x-ward direction by a force
# with a magnitude close to the assigned force region magnitude when it reaches the force region.
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5932042_PhysXForceRegion_LinearDamping.py b/AutomatedTesting/Gem/PythonTests/physics/C5932042_PhysXForceRegion_LinearDamping.py
index 04cecd45b2..b55ce59d7a 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5932042_PhysXForceRegion_LinearDamping.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5932042_PhysXForceRegion_LinearDamping.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5932042
# Test Case Title : Check that force region exerts linear damping force on rigid bodies
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5932042
+
# fmt: off
@@ -135,7 +135,7 @@ def C5932042_PhysXForceRegion_LinearDamping():
# Constants
CLOSE_ENOUGH = 0.001
- TIME_OUT = 2.0
+ TIME_OUT = 3.0
INITIAL_VELOCITY = azmath.Vector3(0.0, 0.0, -10.0)
# 1) Open level / Enter game mode
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5932043_ForceRegion_SimpleDragOnRigidBodies.py b/AutomatedTesting/Gem/PythonTests/physics/C5932043_ForceRegion_SimpleDragOnRigidBodies.py
index 512698ce4b..b4d29f8065 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5932043_ForceRegion_SimpleDragOnRigidBodies.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5932043_ForceRegion_SimpleDragOnRigidBodies.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5932043
# Test Case Title : Check that force region exerts simple drag force on rigid bodies
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5932043
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5932044_ForceRegion_PointForceOnRigidBody.py b/AutomatedTesting/Gem/PythonTests/physics/C5932044_ForceRegion_PointForceOnRigidBody.py
index b7257b488b..6cfaf857a4 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5932044_ForceRegion_PointForceOnRigidBody.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5932044_ForceRegion_PointForceOnRigidBody.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5932044
# Test Case Title : Check that force region exerts point force on rigid bodies
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5932044
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5932045_ForceRegion_Spline.py b/AutomatedTesting/Gem/PythonTests/physics/C5932045_ForceRegion_Spline.py
index eca0679921..298265966c 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5932045_ForceRegion_Spline.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5932045_ForceRegion_Spline.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5932045
# Test Case Title : Check that force region exerts spline follow force on rigid bodies
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5932045
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5959759_RigidBody_ForceRegionSpherePointForce.py b/AutomatedTesting/Gem/PythonTests/physics/C5959759_RigidBody_ForceRegionSpherePointForce.py
index 6aff0a7145..a8ef614f75 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5959759_RigidBody_ForceRegionSpherePointForce.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5959759_RigidBody_ForceRegionSpherePointForce.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5959759
# Test Case Title : Check that force region (sphere) exerts point force
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5959759
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5959760_PhysXForceRegion_PointForceExertion.py b/AutomatedTesting/Gem/PythonTests/physics/C5959760_PhysXForceRegion_PointForceExertion.py
index 89eb1842be..4cb1cffd16 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5959760_PhysXForceRegion_PointForceExertion.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5959760_PhysXForceRegion_PointForceExertion.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5959760
# Test Case Title : Check that force region (capsule) exerts point force
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5959760
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5959761_ForceRegion_PhysAssetExertsPointForce.py b/AutomatedTesting/Gem/PythonTests/physics/C5959761_ForceRegion_PhysAssetExertsPointForce.py
index ba0475266b..27f9e41a7d 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5959761_ForceRegion_PhysAssetExertsPointForce.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5959761_ForceRegion_PhysAssetExertsPointForce.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5959761
# Test Case Title : Check that force region (physics asset) exerts point force
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5959761
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5959763_ForceRegion_ForceRegionImpulsesCube.py b/AutomatedTesting/Gem/PythonTests/physics/C5959763_ForceRegion_ForceRegionImpulsesCube.py
index 76130d25eb..4b62f9a029 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5959763_ForceRegion_ForceRegionImpulsesCube.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5959763_ForceRegion_ForceRegionImpulsesCube.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5959764
# Test Case Title : Check that rigid body (Cube) gets impulse from force region
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5959764
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5959764_ForceRegion_ForceRegionImpulsesCapsule.py b/AutomatedTesting/Gem/PythonTests/physics/C5959764_ForceRegion_ForceRegionImpulsesCapsule.py
index f314dae5b7..aadc07b09b 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5959764_ForceRegion_ForceRegionImpulsesCapsule.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5959764_ForceRegion_ForceRegionImpulsesCapsule.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5959764
# Test Case Title : Check that rigid body (Capsule) gets impulse from force region
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5959764
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5959765_ForceRegion_AssetGetsImpulsed.py b/AutomatedTesting/Gem/PythonTests/physics/C5959765_ForceRegion_AssetGetsImpulsed.py
index ddcba5996b..ed007594c2 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5959765_ForceRegion_AssetGetsImpulsed.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5959765_ForceRegion_AssetGetsImpulsed.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5959765
# Test Case Title : Check that rigid body (asset) gets impulse from force region
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5959765
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5959808_ForceRegion_PositionOffset.py b/AutomatedTesting/Gem/PythonTests/physics/C5959808_ForceRegion_PositionOffset.py
index 175f73a420..7c3f8a43aa 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5959808_ForceRegion_PositionOffset.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5959808_ForceRegion_PositionOffset.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5959808
# Test Case Title : Verify Force Region Position Offset
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5959808
+
# fmt:off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5959809_ForceRegion_RotationalOffset.py b/AutomatedTesting/Gem/PythonTests/physics/C5959809_ForceRegion_RotationalOffset.py
index 1ad53194d3..dc84be8798 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5959809_ForceRegion_RotationalOffset.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5959809_ForceRegion_RotationalOffset.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5959809
# Test Case Title : Verify Force Region Rotational Offset
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5959809
+
# fmt:off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5959810_ForceRegion_ForceRegionCombinesForces.py b/AutomatedTesting/Gem/PythonTests/physics/C5959810_ForceRegion_ForceRegionCombinesForces.py
index 212f7cc86b..8efc3dc635 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5959810_ForceRegion_ForceRegionCombinesForces.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5959810_ForceRegion_ForceRegionCombinesForces.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5959810
# Test Case Title : Check that multiple forces in single force region create correct net force
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5959810
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5968759_ForceRegion_ExertsSeveralForcesOnRigidBody.py b/AutomatedTesting/Gem/PythonTests/physics/C5968759_ForceRegion_ExertsSeveralForcesOnRigidBody.py
index 4aa0fef642..948e172962 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5968759_ForceRegion_ExertsSeveralForcesOnRigidBody.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5968759_ForceRegion_ExertsSeveralForcesOnRigidBody.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5968759
# Test Case Title : Check nested force regions exert forces simultaneously on rigid body
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5968759
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C5968760_ForceRegion_CheckNetForceChange.py b/AutomatedTesting/Gem/PythonTests/physics/C5968760_ForceRegion_CheckNetForceChange.py
index ba491c96a7..0897fcb0d7 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C5968760_ForceRegion_CheckNetForceChange.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C5968760_ForceRegion_CheckNetForceChange.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C5968760
# Test Case Title : Check moving force region changes net force
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/5968760
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C6032082_Terrain_MultipleResolutionsValid.py b/AutomatedTesting/Gem/PythonTests/physics/C6032082_Terrain_MultipleResolutionsValid.py
index 4543b0b8f6..00d53a2d6c 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C6032082_Terrain_MultipleResolutionsValid.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C6032082_Terrain_MultipleResolutionsValid.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C6032082
# Test Case Title : Verify multiple terrain resolutions are supported
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/6032082
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C6090546_ForceRegion_SliceFileInstantiates.py b/AutomatedTesting/Gem/PythonTests/physics/C6090546_ForceRegion_SliceFileInstantiates.py
index 557b7e7ec5..2b427468b7 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C6090546_ForceRegion_SliceFileInstantiates.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C6090546_ForceRegion_SliceFileInstantiates.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C6090546
# Test Case Title : Check that a force region slice can be saved and instantiated
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/6090546
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C6090547_ForceRegion_ParentChildForceRegions.py b/AutomatedTesting/Gem/PythonTests/physics/C6090547_ForceRegion_ParentChildForceRegions.py
index a07fd1861b..84474f0226 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C6090547_ForceRegion_ParentChildForceRegions.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C6090547_ForceRegion_ParentChildForceRegions.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C6090547
# Test Case Title : Check that force regions in parent and child entities work together.
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/6090547
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C6090550_ForceRegion_WorldSpaceForceNegative.py b/AutomatedTesting/Gem/PythonTests/physics/C6090550_ForceRegion_WorldSpaceForceNegative.py
index f8da62ebac..e2c55a024d 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C6090550_ForceRegion_WorldSpaceForceNegative.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C6090550_ForceRegion_WorldSpaceForceNegative.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
"""
Test case ID : C6090550
Test Case Title : Check that force region exerts world space force on rigid bodies (negative test)
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/6090550
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C6090551_ForceRegion_LocalSpaceForceNegative.py b/AutomatedTesting/Gem/PythonTests/physics/C6090551_ForceRegion_LocalSpaceForceNegative.py
index 0788b1da66..2e201e20bd 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C6090551_ForceRegion_LocalSpaceForceNegative.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C6090551_ForceRegion_LocalSpaceForceNegative.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
"""
Test case ID : C6090551
Test Case Title : Check that force region exerts local space force on rigid bodies (negative test)
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/6090551
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C6090552_ForceRegion_LinearDampingNegative.py b/AutomatedTesting/Gem/PythonTests/physics/C6090552_ForceRegion_LinearDampingNegative.py
index a878819045..585a337389 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C6090552_ForceRegion_LinearDampingNegative.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C6090552_ForceRegion_LinearDampingNegative.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
"""
Test case ID : C6090552
Test Case Title : Check that force region exerts linear damping force on rigid bodies (negative test)
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/6090552
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C6090553_ForceRegion_SimpleDragForceOnRigidBodies.py b/AutomatedTesting/Gem/PythonTests/physics/C6090553_ForceRegion_SimpleDragForceOnRigidBodies.py
index 43c4335918..6abee0ad64 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C6090553_ForceRegion_SimpleDragForceOnRigidBodies.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C6090553_ForceRegion_SimpleDragForceOnRigidBodies.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C6090553
# Test Case Title : Check that force region exerts simple drag force on rigid bodies (negative test)
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/6090553
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C6090554_ForceRegion_PointForceNegative.py b/AutomatedTesting/Gem/PythonTests/physics/C6090554_ForceRegion_PointForceNegative.py
index d7781b6040..0969cebd8d 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C6090554_ForceRegion_PointForceNegative.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C6090554_ForceRegion_PointForceNegative.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
"""
Test case ID : C6090554
Test Case Title : Check that force region exerts point force on rigid bodies (negative test)
-URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/6090554
+
"""
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C6090555_ForceRegion_SplineFollowOnRigidBodies.py b/AutomatedTesting/Gem/PythonTests/physics/C6090555_ForceRegion_SplineFollowOnRigidBodies.py
index b1b76d896d..90f67391ad 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C6090555_ForceRegion_SplineFollowOnRigidBodies.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C6090555_ForceRegion_SplineFollowOnRigidBodies.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C6090555
# Test Case Title : Check that force region exerts spline follow force on rigid bodies(negative test)
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/6090555
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C6131473_StaticSlice_OnDynamicSliceSpawn.py b/AutomatedTesting/Gem/PythonTests/physics/C6131473_StaticSlice_OnDynamicSliceSpawn.py
index 11281df4eb..ee68ef6049 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C6131473_StaticSlice_OnDynamicSliceSpawn.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C6131473_StaticSlice_OnDynamicSliceSpawn.py
@@ -13,7 +13,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C6131473
# Test Case Title : Verify a static slice is not spawned automatically everytime a dynamic slice with
# PhysX Components is spawned
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/6131473
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C6224408_ScriptCanvas_EntitySpawn.py b/AutomatedTesting/Gem/PythonTests/physics/C6224408_ScriptCanvas_EntitySpawn.py
index 6501e11e68..6693c17dff 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C6224408_ScriptCanvas_EntitySpawn.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C6224408_ScriptCanvas_EntitySpawn.py
@@ -11,7 +11,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C6224408
# Test Case Title : Entity using PhysX nodes in Script Canvas can be spawned.
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/6224408
+
# fmt: off
class Tests:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C6274125_ScriptCanvas_TriggerEvents.py b/AutomatedTesting/Gem/PythonTests/physics/C6274125_ScriptCanvas_TriggerEvents.py
index 44c8be9e1e..c360473b7f 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C6274125_ScriptCanvas_TriggerEvents.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C6274125_ScriptCanvas_TriggerEvents.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C6274125
# Test Case Title : Verify ScriptCanvas Trigger Events.
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/6274125
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/C6321601_Force_HighValuesDirectionAxes.py b/AutomatedTesting/Gem/PythonTests/physics/C6321601_Force_HighValuesDirectionAxes.py
index c1a51f2887..4b0b036970 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/C6321601_Force_HighValuesDirectionAxes.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/C6321601_Force_HighValuesDirectionAxes.py
@@ -12,7 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# Test case ID : C6321601
# Test Case Title : Check that very high values of direction axes of forces do not throw error
-# URL of the test case : https://testrail.agscollab.com/index.php?/cases/view/6321601
+
# fmt: off
diff --git a/AutomatedTesting/Gem/PythonTests/physics/JointsHelper.py b/AutomatedTesting/Gem/PythonTests/physics/JointsHelper.py
index e61118ef5b..476c1df237 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/JointsHelper.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/JointsHelper.py
@@ -27,6 +27,13 @@ def vector3LargerThanScalar(vec3Value, scalarValue):
vec3Value.y > scalarValue and
vec3Value.z > scalarValue)
+def getRelativeVector(vecA, vecB):
+ relativeVec = vecA
+ relativeVec.x = relativeVec.x - vecB.x
+ relativeVec.y = relativeVec.y - vecB.y
+ relativeVec.z = relativeVec.z - vecB.z
+ return relativeVec
+
# Entity class for joints tests
class JointEntity:
diff --git a/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Main.py b/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Main.py
index 67e855a00e..8f1f2f7481 100644
--- a/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Main.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Main.py
@@ -34,4 +34,61 @@ class TestAutomation(TestAutomationBase):
def test_C111111_RigidBody_EnablingGravityWorksUsingNotificationsPoC(self, request, workspace, editor, launcher_platform):
from . import C111111_RigidBody_EnablingGravityWorksUsingNotificationsPoC as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ def test_C5932041_PhysXForceRegion_LocalSpaceForceOnRigidBodies(self, request, workspace, editor, launcher_platform):
+ from . import C5932041_PhysXForceRegion_LocalSpaceForceOnRigidBodies as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ def test_C4044459_Material_DynamicFriction(self, request, workspace, editor, launcher_platform):
+ from . import C4044459_Material_DynamicFriction as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ def test_C15425929_Undo_Redo(self, request, workspace, editor, launcher_platform):
+ from . import C15425929_Undo_Redo as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ def test_C4976243_Collision_SameCollisionGroupDiffCollisionLayers(self, request, workspace, editor,
+ launcher_platform):
+ from . import C4976243_Collision_SameCollisionGroupDiffCollisionLayers as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ def test_C14654881_CharacterController_SwitchLevels(self, request, workspace, editor, launcher_platform):
+ from . import C14654881_CharacterController_SwitchLevels as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ def test_C17411467_AddPhysxRagdollComponent(self, request, workspace, editor, launcher_platform):
+ from . import C17411467_AddPhysxRagdollComponent as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ def test_C12712453_ScriptCanvas_MultipleRaycastNode(self, request, workspace, editor, launcher_platform):
+ from . import C12712453_ScriptCanvas_MultipleRaycastNode as test_module
+ # Fixme: unexpected_lines = ["Assert"] + test_module.Lines.unexpected
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ @fm.file_override('physxsystemconfiguration.setreg','C4982593_PhysXCollider_CollisionLayer.setreg_override', 'AutomatedTesting/Registry')
+ def test_C4982593_PhysXCollider_CollisionLayerTest(self, request, workspace, editor, launcher_platform):
+ from . import C4982593_PhysXCollider_CollisionLayerTest as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ def test_C18243586_Joints_HingeLeadFollowerCollide(self, request, workspace, editor, launcher_platform):
+ from . import C18243586_Joints_HingeLeadFollowerCollide as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ def test_C4982803_Enable_PxMesh_Option(self, request, workspace, editor, launcher_platform):
+ from . import C4982803_Enable_PxMesh_Option as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ def test_C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain(self, request, workspace, editor, launcher_platform):
+ from . import C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain as test_module
self._run_test(request, workspace, editor, test_module)
\ No newline at end of file
diff --git a/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Periodic.py b/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Periodic.py
index 39ed85a65a..3bbfe64e38 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Periodic.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Periodic.py
@@ -52,11 +52,6 @@ class TestAutomation(TestAutomationBase):
from . import C4976207_PhysXRigidBodies_KinematicBehavior as test_module
self._run_test(request, workspace, editor, test_module)
- @revert_physics_config
- def test_C5932041_PhysXForceRegion_LocalSpaceForceOnRigidBodies(self, request, workspace, editor, launcher_platform):
- from . import C5932041_PhysXForceRegion_LocalSpaceForceOnRigidBodies as test_module
- self._run_test(request, workspace, editor, test_module)
-
@revert_physics_config
def test_C5932042_PhysXForceRegion_LinearDamping(self, request, workspace, editor, launcher_platform):
from . import C5932042_PhysXForceRegion_LinearDamping as test_module
@@ -92,11 +87,6 @@ class TestAutomation(TestAutomationBase):
from . import C4976194_RigidBody_PhysXComponentIsValid as test_module
self._run_test(request, workspace, editor, test_module)
- @revert_physics_config
- def test_C4044459_Material_DynamicFriction(self, request, workspace, editor, launcher_platform):
- from . import C4044459_Material_DynamicFriction as test_module
- self._run_test(request, workspace, editor, test_module)
-
@revert_physics_config
def test_C5932045_ForceRegion_Spline(self, request, workspace, editor, launcher_platform):
from . import C5932045_ForceRegion_Spline as test_module
@@ -208,26 +198,11 @@ class TestAutomation(TestAutomationBase):
from . import C18981526_Material_RestitutionCombinePriority as test_module
self._run_test(request, workspace, editor, test_module)
- @revert_physics_config
- def test_C15425929_Undo_Redo(self, request, workspace, editor, launcher_platform):
- from . import C15425929_Undo_Redo as test_module
- self._run_test(request, workspace, editor, test_module)
-
- @revert_physics_config
- def test_C15308217_NoCrash_LevelSwitch(self, request, workspace, editor, launcher_platform):
- from . import C15308217_NoCrash_LevelSwitch as test_module
- self._run_test(request, workspace, editor, test_module)
-
@revert_physics_config
def test_C12868580_ForceRegion_SplineModifiedTransform(self, request, workspace, editor, launcher_platform):
from . import C12868580_ForceRegion_SplineModifiedTransform as test_module
self._run_test(request, workspace, editor, test_module)
- @revert_physics_config
- def test_C4976243_Collision_SameCollisionGroupDiffCollisionLayers(self, request, workspace, editor, launcher_platform):
- from . import C4976243_Collision_SameCollisionGroupDiffCollisionLayers 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
@@ -248,17 +223,6 @@ class TestAutomation(TestAutomationBase):
from . import C6131473_StaticSlice_OnDynamicSliceSpawn as test_module
self._run_test(request, workspace, editor, test_module)
- @revert_physics_config
- def test_C4982798_Collider_ColliderRotationOffset(self, request, workspace, editor, launcher_platform):
- from . import C4982798_Collider_ColliderRotationOffset as test_module
- self._run_test(request, workspace, editor, test_module)
-
- @revert_physics_config
- def test_C12712453_ScriptCanvas_MultipleRaycastNode(self, request, workspace, editor, launcher_platform):
- from . import C12712453_ScriptCanvas_MultipleRaycastNode as test_module
- # Fixme: unexpected_lines = ["Assert"] + test_module.Lines.unexpected
- self._run_test(request, workspace, editor, test_module)
-
@revert_physics_config
def test_C5959808_ForceRegion_PositionOffset(self, request, workspace, editor, launcher_platform):
from . import C5959808_ForceRegion_PositionOffset as test_module
@@ -275,7 +239,7 @@ class TestAutomation(TestAutomationBase):
def test_C13895144_Ragdoll_ChangeLevel(self, request, workspace, editor, launcher_platform):
from . import C13895144_Ragdoll_ChangeLevel as test_module
self._run_test(request, workspace, editor, test_module)
-
+
@revert_physics_config
def test_C5968759_ForceRegion_ExertsSeveralForcesOnRigidBody(self, request, workspace, editor, launcher_platform):
from . import C5968759_ForceRegion_ExertsSeveralForcesOnRigidBody as test_module
@@ -290,6 +254,8 @@ class TestAutomation(TestAutomationBase):
from . import C4044697_Material_PerfaceMaterialValidation as test_module
self._run_test(request, workspace, editor, test_module)
+ @pytest.mark.xfail(
+ reason="This test will sometimes fail as the ball will continue to roll before the timeout is reached.")
@revert_physics_config
def test_C4976202_RigidBody_StopsWhenBelowKineticThreshold(self, request, workspace, editor, launcher_platform):
from . import C4976202_RigidBody_StopsWhenBelowKineticThreshold as test_module
@@ -305,11 +271,6 @@ class TestAutomation(TestAutomationBase):
from . import C5296614_PhysXMaterial_ColliderShape as test_module
self._run_test(request, workspace, editor, test_module)
- @revert_physics_config
- def test_C6090547_ForceRegion_ParentChildForceRegions(self, request, workspace, editor, launcher_platform):
- from . import C6090547_ForceRegion_ParentChildForceRegions as test_module
- self._run_test(request, workspace, editor, test_module)
-
@revert_physics_config
def test_C4982595_Collider_TriggerDisablesCollision(self, request, workspace, editor, launcher_platform):
from . import C4982595_Collider_TriggerDisablesCollision as test_module
@@ -320,11 +281,6 @@ class TestAutomation(TestAutomationBase):
from . import C14976307_Gravity_SetGravityWorks as test_module
self._run_test(request, workspace, editor, test_module)
- @revert_physics_config
- def test_C14654881_CharacterController_SwitchLevels(self, request, workspace, editor, launcher_platform):
- from . import C14654881_CharacterController_SwitchLevels as test_module
- self._run_test(request, workspace, editor, test_module)
-
@revert_physics_config
def test_C15556261_PhysXMaterials_CharacterControllerMaterialAssignment(self, request, workspace, editor, launcher_platform):
from . import C15556261_PhysXMaterials_CharacterControllerMaterialAssignment as test_module
@@ -352,19 +308,19 @@ class TestAutomation(TestAutomationBase):
self._run_test(request, workspace, editor, test_module)
@revert_physics_config
- @fm.file_override('physxsystemconfiguration.setreg','C4976245_PhysXCollider_CollisionLayerTest.setreg', 'AutomatedTesting/Registry')
+ @fm.file_override('physxsystemconfiguration.setreg','C4976245_PhysXCollider_CollisionLayerTest.setreg_override', 'AutomatedTesting/Registry')
def test_C4976245_PhysXCollider_CollisionLayerTest(self, request, workspace, editor, launcher_platform):
from . import C4976245_PhysXCollider_CollisionLayerTest as test_module
self._run_test(request, workspace, editor, test_module)
@revert_physics_config
- @fm.file_override('physxsystemconfiguration.setreg','C4976244_Collider_SameGroupSameLayerCollision.setreg', 'AutomatedTesting/Registry')
+ @fm.file_override('physxsystemconfiguration.setreg','C4976244_Collider_SameGroupSameLayerCollision.setreg_override', 'AutomatedTesting/Registry')
def test_C4976244_Collider_SameGroupSameLayerCollision(self, request, workspace, editor, launcher_platform):
from . import C4976244_Collider_SameGroupSameLayerCollision as test_module
self._run_test(request, workspace, editor, test_module)
@revert_physics_config
- @fm.file_override('physxdefaultsceneconfiguration.setreg','C14195074_ScriptCanvas_PostUpdateEvent.setreg', 'AutomatedTesting/Registry')
+ @fm.file_override('physxdefaultsceneconfiguration.setreg','C14195074_ScriptCanvas_PostUpdateEvent.setreg_override', 'AutomatedTesting/Registry')
def test_C14195074_ScriptCanvas_PostUpdateEvent(self, request, workspace, editor, launcher_platform):
from . import C14195074_ScriptCanvas_PostUpdateEvent as test_module
self._run_test(request, workspace, editor, test_module)
@@ -375,19 +331,7 @@ class TestAutomation(TestAutomationBase):
self._run_test(request, workspace, editor, test_module)
@revert_physics_config
- @fm.file_override('physxsystemconfiguration.setreg','C4982593_PhysXCollider_CollisionLayer.setreg', 'AutomatedTesting/Registry')
- def test_C4982593_PhysXCollider_CollisionLayerTest(self, request, workspace, editor, launcher_platform):
- from . import C4982593_PhysXCollider_CollisionLayerTest as test_module
- self._run_test(request, workspace, editor, test_module)
-
- @revert_physics_config
- @fm.file_override('physxsystemconfiguration.setreg','C3510644_Collider_CollisionGroups.setreg', 'AutomatedTesting/Registry')
- def test_C3510644_Collider_CollisionGroups(self, request, workspace, editor, launcher_platform):
- from . import C3510644_Collider_CollisionGroups as test_module
- self._run_test(request, workspace, editor, test_module)
-
- @revert_physics_config
- @fm.file_override('physxdefaultsceneconfiguration.setreg','C14902097_ScriptCanvas_PreUpdateEvent.setreg', 'AutomatedTesting/Registry')
+ @fm.file_override('physxdefaultsceneconfiguration.setreg','C14902097_ScriptCanvas_PreUpdateEvent.setreg_override', 'AutomatedTesting/Registry')
def test_C14902097_ScriptCanvas_PreUpdateEvent(self, request, workspace, editor, launcher_platform):
from . import C14902097_ScriptCanvas_PreUpdateEvent as test_module
self._run_test(request, workspace, editor, test_module)
@@ -415,18 +359,13 @@ class TestAutomation(TestAutomationBase):
from . import C18243589_Joints_BallSoftLimitsConstrained as test_module
self._run_test(request, workspace, editor, test_module)
- @revert_physics_config
- def test_C18243586_Joints_HingeLeadFollowerCollide(self, request, workspace, editor, launcher_platform):
- from . import C18243586_Joints_HingeLeadFollowerCollide as test_module
- self._run_test(request, workspace, editor, test_module)
-
@revert_physics_config
def test_C18243591_Joints_BallLeadFollowerCollide(self, request, workspace, editor, launcher_platform):
from . import C18243591_Joints_BallLeadFollowerCollide as test_module
self._run_test(request, workspace, editor, test_module)
@revert_physics_config
- @fm.file_override('physxsystemconfiguration.setreg','C4976227_Collider_NewGroup.setreg', 'AutomatedTesting/Registry')
+ @fm.file_override('physxsystemconfiguration.setreg','C4976227_Collider_NewGroup.setreg_override', 'AutomatedTesting/Registry')
def test_C4976227_Collider_NewGroup(self, request, workspace, editor, launcher_platform):
from . import C4976227_Collider_NewGroup as test_module
self._run_test(request, workspace, editor, test_module)
@@ -441,21 +380,11 @@ class TestAutomation(TestAutomationBase):
from . import C14861500_DefaultSetting_ColliderShape as test_module
self._run_test(request, workspace, editor, test_module)
- @revert_physics_config
- def test_C19578021_ShapeCollider_CanBeAdded(self, request, workspace, editor, launcher_platform):
- from . import C19578021_ShapeCollider_CanBeAdded as test_module
- self._run_test(request, workspace, editor, test_module)
-
@revert_physics_config
def test_C19723164_ShapeCollider_WontCrashEditor(self, request, workspace, editor, launcher_platform):
from . import C19723164_ShapeColliders_WontCrashEditor as test_module
self._run_test(request, workspace, editor, test_module)
- @revert_physics_config
- def test_C4982803_Enable_PxMesh_Option(self, request, workspace, editor, launcher_platform):
- from . import C4982803_Enable_PxMesh_Option as test_module
- self._run_test(request, workspace, editor, test_module)
-
@revert_physics_config
def test_C4982800_PhysXColliderShape_CanBeSelected(self, request, workspace, editor, launcher_platform):
from . import C4982800_PhysXColliderShape_CanBeSelected as test_module
@@ -471,10 +400,6 @@ class TestAutomation(TestAutomationBase):
from . import C4982802_PhysXColliderShape_CanBeSelected as test_module
self._run_test(request, workspace, editor, test_module)
- def test_C17411467_AddPhysxRagdollComponent(self, request, workspace, editor, launcher_platform):
- from . import C17411467_AddPhysxRagdollComponent as test_module
- self._run_test(request, workspace, editor, test_module)
-
def test_C12905528_ForceRegion_WithNonTriggerCollider(self, request, workspace, editor, launcher_platform):
from . import C12905528_ForceRegion_WithNonTriggerCollider as test_module
# Fixme: expected_lines = ["[Warning] (PhysX Force Region) - Please ensure collider component marked as trigger exists in entity"]
@@ -522,4 +447,35 @@ class TestAutomation(TestAutomationBase):
def test_C100000_RigidBody_EnablingGravityWorksPoC(self, request, workspace, editor, launcher_platform):
from . import C100000_RigidBody_EnablingGravityWorksPoC as test_module
- self._run_test(request, workspace, editor, test_module)
\ No newline at end of file
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ @fm.file_override('physxsystemconfiguration.setreg','C3510644_Collider_CollisionGroups.setreg_override', 'AutomatedTesting/Registry')
+ def test_C3510644_Collider_CollisionGroups(self, request, workspace, editor, launcher_platform):
+ from . import C3510644_Collider_CollisionGroups as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ def test_C4982798_Collider_ColliderRotationOffset(self, request, workspace, editor, launcher_platform):
+ from . import C4982798_Collider_ColliderRotationOffset as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ def test_C15308217_NoCrash_LevelSwitch(self, request, workspace, editor, launcher_platform):
+ from . import C15308217_NoCrash_LevelSwitch as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ def test_C6090547_ForceRegion_ParentChildForceRegions(self, request, workspace, editor, launcher_platform):
+ from . import C6090547_ForceRegion_ParentChildForceRegions as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ def test_C19578021_ShapeCollider_CanBeAdded(self, request, workspace, editor, launcher_platform):
+ from . import C19578021_ShapeCollider_CanBeAdded as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @revert_physics_config
+ def test_C15425929_Undo_Redo(self, request, workspace, editor, launcher_platform):
+ from . import C15425929_Undo_Redo as test_module
+ self._run_test(request, workspace, editor, test_module)
diff --git a/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Sandbox.py b/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Sandbox.py
index 39bc4c8188..e829726ba9 100755
--- a/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Sandbox.py
+++ b/AutomatedTesting/Gem/PythonTests/physics/TestSuite_Sandbox.py
@@ -1,49 +1,49 @@
-"""
-All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
-its licensors.
-
-For complete copyright and license terms please see the LICENSE at the root of this
-distribution (the "License"). All use of this software is governed by the License,
-or, if provided, by the license below or the license accompanying this file. Do not
-remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-
-"""
-
-# This suite consists of all test cases that are passing and have been verified.
-
-import pytest
-import os
-import sys
-
-from .FileManagement import FileManagement as fm
-from ly_test_tools import LAUNCHERS
-
-sys.path.append(os.path.dirname(os.path.abspath(__file__)) + '/../automatedtesting_shared')
-
-from base import TestAutomationBase
-
-
-revert_physics_config = fm.file_revert_list(['physxdebugconfiguration.setreg', 'physxdefaultsceneconfiguration.setreg', 'physxsystemconfiguration.setreg'], 'AutomatedTesting/Registry')
-
-
-@pytest.mark.SUITE_sandbox
-@pytest.mark.parametrize("launcher_platform", ['windows_editor'])
-@pytest.mark.parametrize("project", ["AutomatedTesting"])
-class TestAutomation(TestAutomationBase):
-
- ## Seems to be flaky, need to investigate
- def test_C19536274_GetCollisionName_PrintsName(self, request, workspace, editor, launcher_platform):
- from . import C19536274_GetCollisionName_PrintsName as test_module
- # Fixme: expected_lines=["Layer Name: Right"]
- self._run_test(request, workspace, editor, test_module)
-
- ## Seems to be flaky, need to investigate
- def test_C19536277_GetCollisionName_PrintsNothing(self, request, workspace, editor, launcher_platform):
- from . import C19536277_GetCollisionName_PrintsNothing as test_module
- # All groups present in the PhysX Collider that could show up in test
- # Fixme: collision_groups = ["All", "None", "All_NoTouchBend", "All_3", "None_1", "All_NoTouchBend_1", "All_2", "None_1_1", "All_NoTouchBend_1_1", "All_1", "None_1_1_1", "All_NoTouchBend_1_1_1", "All_4", "None_1_1_1_1", "All_NoTouchBend_1_1_1_1", "GroupLeft", "GroupRight"]
- # Fixme: for group in collision_groups:
- # Fixme: unexpected_lines.append(f"GroupName: {group}")
- # Fixme: expected_lines=["GroupName: "]
- self._run_test(request, workspace, editor, test_module)
\ No newline at end of file
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+"""
+
+# This suite consists of all test cases that are passing and have been verified.
+
+import pytest
+import os
+import sys
+
+from .FileManagement import FileManagement as fm
+from ly_test_tools import LAUNCHERS
+
+sys.path.append(os.path.dirname(os.path.abspath(__file__)) + '/../automatedtesting_shared')
+
+from base import TestAutomationBase
+
+
+revert_physics_config = fm.file_revert_list(['physxdebugconfiguration.setreg', 'physxdefaultsceneconfiguration.setreg', 'physxsystemconfiguration.setreg'], 'AutomatedTesting/Registry')
+
+
+@pytest.mark.SUITE_sandbox
+@pytest.mark.parametrize("launcher_platform", ['windows_editor'])
+@pytest.mark.parametrize("project", ["AutomatedTesting"])
+class TestAutomation(TestAutomationBase):
+
+ ## Seems to be flaky, need to investigate
+ def test_C19536274_GetCollisionName_PrintsName(self, request, workspace, editor, launcher_platform):
+ from . import C19536274_GetCollisionName_PrintsName as test_module
+ # Fixme: expected_lines=["Layer Name: Right"]
+ self._run_test(request, workspace, editor, test_module)
+
+ ## Seems to be flaky, need to investigate
+ def test_C19536277_GetCollisionName_PrintsNothing(self, request, workspace, editor, launcher_platform):
+ from . import C19536277_GetCollisionName_PrintsNothing as test_module
+ # All groups present in the PhysX Collider that could show up in test
+ # Fixme: collision_groups = ["All", "None", "All_NoTouchBend", "All_3", "None_1", "All_NoTouchBend_1", "All_2", "None_1_1", "All_NoTouchBend_1_1", "All_1", "None_1_1_1", "All_NoTouchBend_1_1_1", "All_4", "None_1_1_1_1", "All_NoTouchBend_1_1_1_1", "GroupLeft", "GroupRight"]
+ # Fixme: for group in collision_groups:
+ # Fixme: unexpected_lines.append(f"GroupName: {group}")
+ # Fixme: expected_lines=["GroupName: "]
+ self._run_test(request, workspace, editor, test_module)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/AssetEditor_CreateScriptEventFile.py b/AutomatedTesting/Gem/PythonTests/scripting/AssetEditor_CreateScriptEventFile.py
new file mode 100644
index 0000000000..dcbbf47f0c
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/AssetEditor_CreateScriptEventFile.py
@@ -0,0 +1,124 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+Test case ID: T92569013
+Test Case Title: Script Event file can be created
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92569013
+"""
+
+
+# fmt: off
+class Tests():
+ new_event_created = ("New Script Event created", "New Script Event not created")
+ child_event_created = ("Child Event created", "Child not created")
+ file_saved = ("Script event file saved", "Script event file did not save")
+ console_error = ("No unexpected error in console", "Error found in console")
+ console_warning = ("No unexpected warning in console", "Warning found in console")
+# fmt: on
+
+
+def CreateScriptEventFile():
+ """
+ Summary:
+ Script Event file can be created
+
+ Expected Behavior:
+ File is created without any errors and warnings in Console
+
+ Test Steps:
+ 1) Open Asset Editor
+ 2) Get Asset Editor Qt object
+ 3) Create new Script Event Asset
+ 4) Add new child event
+ 5) Save the Script Event file
+ 6) Verify if file is created
+ 7) Verify console for errors/warnings
+ 8) Close Asset Editor
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+ import os
+ from utils import Report
+ from utils import TestHelper as helper
+ from utils import Tracer
+ import pyside_utils
+
+ # Open 3D Engine imports
+ import azlmbr.legacy.general as general
+ import azlmbr.editor as editor
+ import azlmbr.bus as bus
+
+ # Pyside imports
+ from PySide2 import QtWidgets
+
+ GENERAL_WAIT = 1.0 # seconds
+
+ FILE_PATH = os.path.join("AutomatedTesting", "ScriptCanvas", "test_file.scriptevent")
+
+ # 1) Open Asset Editor
+ general.idle_enable(True)
+ # Initially close the Asset Editor and then reopen to ensure we don't have any existing assets open
+ general.close_pane("Asset Editor")
+ general.open_pane("Asset Editor")
+ helper.wait_for_condition(lambda: general.is_pane_visible("Asset Editor"), 5.0)
+
+ # 2) Get Asset Editor Qt object
+ editor_window = pyside_utils.get_editor_main_window()
+ asset_editor_widget = editor_window.findChild(QtWidgets.QDockWidget, "Asset Editor").findChild(
+ QtWidgets.QWidget, "AssetEditorWindowClass"
+ )
+ container = asset_editor_widget.findChild(QtWidgets.QWidget, "ContainerForRows")
+ menu_bar = asset_editor_widget.findChild(QtWidgets.QMenuBar)
+
+ # 3) Create new Script Event Asset
+ action = pyside_utils.find_child_by_pattern(menu_bar, {"type": QtWidgets.QAction, "text": "Script Events"})
+ action.trigger()
+ result = helper.wait_for_condition(
+ lambda: container.findChild(QtWidgets.QFrame, "Events") is not None, 3 * GENERAL_WAIT
+ )
+ Report.result(Tests.new_event_created, result)
+
+ # 4) Add new child event
+ add_event = container.findChild(QtWidgets.QFrame, "Events").findChild(QtWidgets.QToolButton, "")
+ add_event.click()
+ result = helper.wait_for_condition(
+ lambda: asset_editor_widget.findChild(QtWidgets.QFrame, "EventName") is not None, GENERAL_WAIT
+ )
+ Report.result(Tests.child_event_created, result)
+
+ with Tracer() as section_tracer:
+ # 5) Save the Script Event file
+ editor.AssetEditorWidgetRequestsBus(bus.Broadcast, "SaveAssetAs", FILE_PATH)
+
+ # 6) Verify if file is created
+ result = helper.wait_for_condition(lambda: os.path.exists(FILE_PATH), 3 * GENERAL_WAIT)
+ Report.result(Tests.file_saved, result)
+
+ # 7) Verify console for errors/warnings
+ Report.result(Tests.console_error, not section_tracer.has_errors)
+ Report.result(Tests.console_warning, not section_tracer.has_warnings)
+
+ # 8) Close Asset Editor
+ general.close_pane("Asset Editor")
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+
+ from utils import Report
+
+ Report.start_test(CreateScriptEventFile)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/AssetEditor_NewScriptEvent.py b/AutomatedTesting/Gem/PythonTests/scripting/AssetEditor_NewScriptEvent.py
new file mode 100644
index 0000000000..1f801d4eeb
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/AssetEditor_NewScriptEvent.py
@@ -0,0 +1,129 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+
+Test case ID: T92568942
+Test Case Title: Clicking the "+" button and selecting "New Script Event" opens the
+Asset Editor with a new Script Event asset
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92568942
+"""
+
+from PySide2 import QtWidgets
+import azlmbr.legacy.general as general
+
+import editor_python_test_tools.pyside_utils as pyside_utils
+from editor_python_test_tools.utils import TestHelper as helper
+from editor_python_test_tools.utils import Report
+
+
+class Tests:
+ action_found = "New Script event action found"
+ asset_editor_opened = "Asset Editor opened"
+ new_asset = "Asset Editor created with new asset"
+ script_event = "New Script event created in Asset Editor"
+
+
+GENERAL_WAIT = 0.5 # seconds
+
+
+class TestAssetEditor_NewScriptEvent:
+ """
+ Summary:
+ Clicking the "+" button in Node Palette and creating New Script Event opens Asset Editor
+
+ Expected Behavior:
+ Clicking the "+" button and selecting "New Script Event" opens the Asset Editor with a
+ new Script Event asset
+
+ Test Steps:
+ 1) Open Script Canvas window (Tools > Script Canvas)
+ 2) Close any existing AssetEditor window
+ 3) Get the SC window object
+ 4) Click on New Script Event on Node palette
+ 5) Verify if Asset Editor opened
+ 6) Verify if a new asset with Script Canvas category is opened
+ 7) Close Script Canvas and Asset Editor
+
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ @pyside_utils.wrap_async
+ async def run_test(self):
+ # 1) Open Script Canvas window (Tools > Script Canvas)
+ general.idle_enable(True)
+ general.open_pane("Script Canvas")
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
+
+ # 2) Close any existing AssetEditor window
+ general.close_pane("Asset Editor")
+ helper.wait_for_condition(lambda: not general.is_pane_visible("Asset Editor"), 5.0)
+
+ # 3) Get the SC window object
+ editor_window = pyside_utils.get_editor_main_window()
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+ node_palette = sc.findChild(QtWidgets.QDockWidget, "NodePalette")
+ frame = node_palette.findChild(QtWidgets.QFrame, "searchCustomization")
+ button = frame.findChild(QtWidgets.QToolButton)
+ pyside_utils.click_button_async(button)
+
+ # 4) Click on New Script Event on Node palette
+ menu = None
+
+ def menu_has_focus():
+ nonlocal menu
+ for fw in [
+ QtWidgets.QApplication.activePopupWidget(),
+ QtWidgets.QApplication.activeModalWidget(),
+ QtWidgets.QApplication.focusWidget(),
+ QtWidgets.QApplication.activeWindow(),
+ ]:
+ print(fw)
+ if fw and isinstance(fw, QtWidgets.QMenu) and fw.isVisible():
+ menu = fw
+ return True
+ return False
+
+ await pyside_utils.wait_for_condition(menu_has_focus, GENERAL_WAIT)
+ action = await pyside_utils.wait_for_action_in_menu(menu, {"text": "New Script Event"})
+ Report.info(f"{Tests.action_found}: {action is not None}")
+ action.trigger()
+ pyside_utils.queue_hide_event(menu)
+
+ # 5) Verify if Asset Editor opened
+ result = helper.wait_for_condition(lambda: general.is_pane_visible("Asset Editor"), GENERAL_WAIT)
+ Report.info(f"{Tests.asset_editor_opened}: {result}")
+
+ # 6) Verify if a new asset with Script Canvas category is opened
+ asset_editor = editor_window.findChild(QtWidgets.QDockWidget, "Asset Editor")
+ row_container = asset_editor.findChild(QtWidgets.QWidget, "ContainerForRows")
+ # NOTE: QWidget ContainerForRows will have frames of Name, Category, ToolTip etc.
+ # To validate if a new script event file is generated, we check for
+ # QFrame Category and its value
+ categories = row_container.findChildren(QtWidgets.QFrame, "Category")
+ Report.info(f"{Tests.new_asset}: {len(categories)>0}")
+ result = False
+ for frame in categories:
+ line_edit = frame.findChild(QtWidgets.QLineEdit)
+ result = True if (line_edit and line_edit.text() == "Script Events") else False
+ Report.info(f"{Tests.script_event}: {result}")
+
+ # 7) Close Script Canvas and Asset Editor
+ general.close_pane("Script Canvas")
+ general.close_pane("Asset Editor")
+
+
+test = TestAssetEditor_NewScriptEvent()
+test.run_test()
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/Debugging_TargetMultipleEntities.py b/AutomatedTesting/Gem/PythonTests/scripting/Debugging_TargetMultipleEntities.py
new file mode 100644
index 0000000000..a26cb4f923
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/Debugging_TargetMultipleEntities.py
@@ -0,0 +1,144 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+
+Test case ID: T92568856
+Test Case Title: Multiple Entities can be targeted in the Debugger tool
+URLs of the test case: https://testrail.agscollab.com/index.php?/tests/view/92568856
+"""
+
+
+# fmt: off
+class Tests():
+ level_created = ("New level created", "New level not created")
+ entities_found = ("Entities are found in Logging window", "Entities are not found in Logging window")
+ select_multiple_targets = ("Multiple targets are selected", "Multiple targets are not selected")
+# fmt: on
+
+
+GENERAL_WAIT = 0.5 # seconds
+
+
+def Debugging_TargetMultipleEntities():
+ """
+ Summary:
+ Multiple Entities can be targeted in the Debugger tool
+
+ Expected Behavior:
+ Selected files can be checked for logging.
+ Upon checking, checkboxes of the parent folders change to either full or partial check.
+
+ Test Steps:
+ 1) Create temp level
+ 2) Create two entities with scriptcanvas components
+ 3) Set values for scriptcanvas
+ 4) Open Script Canvas window and get sc opbject
+ 5) Open Debugging(Logging) window
+ 6) Click on Entities tab in logging window
+ 7) Verify if the scriptcanvas exist under entities
+ 8) Verify if the entities can be selected
+ 9) Close Debugging window and Script Canvas window
+
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ from PySide2 import QtWidgets
+ from PySide2.QtCore import Qt
+ import azlmbr.legacy.general as general
+ import azlmbr.math as math
+ import azlmbr.asset as asset
+ import azlmbr.bus as bus
+
+ import os
+ import pyside_utils
+ import hydra_editor_utils as hydra
+ from utils import TestHelper as helper
+ from utils import Report
+
+ LEVEL_NAME = "tmp_level"
+ ASSET_NAME_1 = "ScriptCanvas_TwoComponents0.scriptcanvas"
+ ASSET_NAME_2 = "ScriptCanvas_TwoComponents1.scriptcanvas"
+ ASSET_1 = os.path.join("scriptcanvas", ASSET_NAME_1)
+ ASSET_2 = os.path.join("scriptcanvas", ASSET_NAME_2)
+ WAIT_TIME = 3.0
+
+ def get_asset(asset_path):
+ return asset.AssetCatalogRequestBus(bus.Broadcast, "GetAssetIdByPath", asset_path, math.Uuid(), False)
+
+ # 1) Create temp level
+ general.idle_enable(True)
+ result = general.create_level_no_prompt(LEVEL_NAME, 128, 1, 512, True)
+ Report.critical_result(Tests.level_created, result == 0)
+ helper.wait_for_condition(lambda: general.get_current_level_name() == LEVEL_NAME, WAIT_TIME)
+ general.close_pane("Error Report")
+
+ # 2) Create two entities with scriptcanvas components
+ position = math.Vector3(512.0, 512.0, 32.0)
+ test_entity_1 = hydra.Entity("test_entity_1")
+ test_entity_1.create_entity(position, ["Script Canvas"])
+ test_entity_2 = hydra.Entity("test_entity_2")
+ test_entity_2.create_entity(position, ["Script Canvas"])
+
+ # 3) Set values for scriptcanvas
+ test_entity_1.get_set_test(0, "Script Canvas Asset|Script Canvas Asset", get_asset(ASSET_1))
+ test_entity_2.get_set_test(0, "Script Canvas Asset|Script Canvas Asset", get_asset(ASSET_2))
+
+ # 4) Open Script Canvas window and get sc opbject
+ general.open_pane("Script Canvas")
+ editor_window = pyside_utils.get_editor_main_window()
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+
+ # 5) Open Debugging(Logging) window
+ if (
+ sc.findChild(QtWidgets.QDockWidget, "LoggingWindow") is None
+ or not sc.findChild(QtWidgets.QDockWidget, "LoggingWindow").isVisible()
+ ):
+ action = pyside_utils.find_child_by_pattern(sc, {"text": "Debugging", "type": QtWidgets.QAction})
+ action.trigger()
+ logging_window = sc.findChild(QtWidgets.QDockWidget, "LoggingWindow")
+
+ # 6) Click on Entities tab in logging window
+ button = pyside_utils.find_child_by_pattern(logging_window, {"type": QtWidgets.QPushButton, "text": "Entities"})
+ button.click()
+
+ # 7) Verify if the scriptcanvas exist under entities
+ entities = logging_window.findChild(QtWidgets.QWidget, "entitiesPage")
+ tree = entities.findChild(QtWidgets.QTreeView, "pivotTreeView")
+ asset_1_mi = pyside_utils.find_child_by_pattern(tree, ASSET_NAME_1.lower())
+ asset_2_mi = pyside_utils.find_child_by_pattern(tree, ASSET_NAME_2.lower())
+ result = asset_1_mi is not None and asset_2_mi is not None
+ Report.critical_result(Tests.entities_found, result)
+
+ # 8) Verify if the entities can be selected
+ tree.expandAll()
+ tree.model().setData(asset_1_mi, 2, Qt.CheckStateRole)
+ tree.model().setData(asset_2_mi, 2, Qt.CheckStateRole)
+ checklist = [asset_1_mi, asset_1_mi.parent(), asset_2_mi, asset_2_mi.parent()]
+ result = all([index.data(Qt.CheckStateRole) == 2 for index in checklist])
+ Report.critical_result(Tests.select_multiple_targets, result)
+
+ # 9) Close Debugging window and Script Canvas window
+ logging_window.close()
+ general.close_pane("Script Canvas")
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+ from utils import Report
+
+ Report.start_test(Debugging_TargetMultipleEntities)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/Debugging_TargetMultipleGraphs.py b/AutomatedTesting/Gem/PythonTests/scripting/Debugging_TargetMultipleGraphs.py
new file mode 100644
index 0000000000..4aa5c822a7
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/Debugging_TargetMultipleGraphs.py
@@ -0,0 +1,113 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+
+Test case ID: T92569137
+Test Case Title: Multiple Graphs can be targeted in the Debugger tool
+URLs of the test case: https://testrail.agscollab.com/index.php?/tests/view/92569137
+"""
+
+
+# fmt: off
+class Tests():
+ select_multiple_targets = ("Multiple targets are selected", "Multiple targets are not selected")
+# fmt: on
+
+
+GENERAL_WAIT = 0.5 # seconds
+
+
+def Debugging_TargetMultipleGraphs():
+ """
+ Summary:
+ Multiple Graphs can be targeted in the Debugger tool
+
+ Expected Behavior:
+ Selected files can be checked for logging.
+ Upon checking, checkboxes of the parent folders change to either full or partial check.
+
+ Test Steps:
+ 1) Open Script Canvas window (Tools > Script Canvas)
+ 2) Get the SC window object
+ 3) Open Debugging Tool if not opened already
+ 4) Select Graphs tab under logging window
+ 5) Select multiple targets from levels and scriptcanvas
+ 6) Verify if multiple targets are selected
+ 7) Close Debugging window and Script Canvas window
+
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ from PySide2 import QtWidgets
+ from PySide2.QtCore import Qt
+ import azlmbr.legacy.general as general
+
+ import pyside_utils
+ from utils import TestHelper as helper
+ from utils import Report
+
+ # 1) Open Script Canvas window (Tools > Script Canvas)
+ general.idle_enable(True)
+ general.open_pane("Script Canvas")
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 6.0)
+
+ # 2) Get the SC window object
+ editor_window = pyside_utils.get_editor_main_window()
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+
+ # 3) Open Debugging Tool if not opened already
+ if (
+ sc.findChild(QtWidgets.QDockWidget, "LoggingWindow") is None
+ or not sc.findChild(QtWidgets.QDockWidget, "LoggingWindow").isVisible()
+ ):
+ action = pyside_utils.find_child_by_pattern(sc, {"text": "Debugging", "type": QtWidgets.QAction})
+ action.trigger()
+ logging_window = sc.findChild(QtWidgets.QDockWidget, "LoggingWindow")
+
+ # 4) Select Graphs tab under logging window
+ button = pyside_utils.find_child_by_pattern(logging_window, {"type": QtWidgets.QPushButton, "text": "Graphs"})
+ button.click()
+
+ # 5) Select multiple targets from levels and scriptcanvas
+ graphs = logging_window.findChild(QtWidgets.QWidget, "graphsPage")
+ tree = graphs.findChild(QtWidgets.QTreeView, "pivotTreeView")
+ # Select the first child under levels
+ level_model_index = pyside_utils.find_child_by_pattern(tree, "levels")
+ level_child_index = pyside_utils.get_item_view_index(tree, 0, 0, level_model_index)
+ tree.model().setData(level_child_index, 2, Qt.CheckStateRole)
+ # Select the first child under scriptcanvas
+ sc_model_index = pyside_utils.find_child_by_pattern(tree, "scriptcanvas")
+ sc_child_index = pyside_utils.get_item_view_index(tree, 0, 0, sc_model_index)
+ tree.model().setData(sc_child_index, 2, Qt.CheckStateRole)
+
+ # 6) Verify if multiple targets are selected
+ result = all([index.data(Qt.CheckStateRole) != 0 for index in (level_model_index, sc_model_index)])
+ result = result and all([index.data(Qt.CheckStateRole) == 2 for index in (level_child_index, sc_child_index)])
+ Report.result(Tests.select_multiple_targets, result)
+
+ # 7) Close Debugging window and Script Canvas window
+ logging_window.close()
+ general.close_pane("Script Canvas")
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+
+ from utils import Report
+
+ Report.start_test(Debugging_TargetMultipleGraphs)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/Docking_Pane.py b/AutomatedTesting/Gem/PythonTests/scripting/Docking_Pane.py
index 25dd83e5e2..4fa1e1257f 100755
--- a/AutomatedTesting/Gem/PythonTests/scripting/Docking_Pane.py
+++ b/AutomatedTesting/Gem/PythonTests/scripting/Docking_Pane.py
@@ -16,7 +16,6 @@ URLs of the test case: https://testrail.agscollab.com/index.php?/cases/view/1702
# fmt: off
class Tests():
- open_sc_window = ("Script Canvas window is opened", "Failed to open Script Canvas window")
pane_opened = ("Pane is opened successfully", "Failed to open pane")
dock_pane = ("Pane is docked successfully", "Failed to dock Pane into one or more allowed area")
# fmt: on
@@ -78,8 +77,7 @@ def Docking_Pane():
# 1) Open Script Canvas window (Tools > Script Canvas)
general.open_pane("Script Canvas")
- is_sc_visible = helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
- Report.result(Tests.open_sc_window, is_sc_visible)
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
# 2) Make sure Node Palette pane is opened
editor_window = pyside_utils.get_editor_main_window()
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/EditMenu_UndoRedo.py b/AutomatedTesting/Gem/PythonTests/scripting/EditMenu_UndoRedo.py
new file mode 100644
index 0000000000..a87d9e9be9
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/EditMenu_UndoRedo.py
@@ -0,0 +1,123 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+
+Test case ID: T92569049
+Test Case Title: Edit > Undo undoes the last action
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92569049
+Test case ID: T92569051
+Test Case Title: Edit > Redo redoes the last undone action
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92569051
+"""
+
+
+# fmt: off
+class Tests():
+ variable_created = ("New variable created", "New variable not created")
+ undo_worked = ("Undo action working", "Undo action did not work")
+ redo_worked = ("Redo action working", "Redo action did not work")
+# fmt: on
+
+
+def EditMenu_UndoRedo():
+ """
+ Summary:
+ Edit > Undo undoes the last action
+ Edit > Redo redoes the last undone action
+ We create a new variable in variable manager, undo and verify if variable is removed,
+ redo it and verify if the variable is created again.
+
+ Expected Behavior:
+ The last action is undone.
+ The last undone action is redone.
+
+ Test Steps:
+ 1) Open Script Canvas window (Tools > Script Canvas)
+ 2) Get the SC window object
+ 3) Open Variable Manager if not opened already
+ 4) Create Graph
+ 5) Create new variable
+ 6) Verify if the variable is created initially
+ 7) Trigger Undo action and verify if variable is removed in Variable Manager
+ 8) Trigger Redo action and verify if variable is readded in Variable Manager
+ 9) Close SC window
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ from PySide2 import QtWidgets, QtCore
+
+ import azlmbr.legacy.general as general
+
+ import pyside_utils
+
+ # 1) Open Script Canvas window
+ general.idle_enable(True)
+ general.open_pane("Script Canvas")
+
+ # 2) Get the SC window object
+ editor_window = pyside_utils.get_editor_main_window()
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+
+ # 3) Open Variable Manager if not opened already
+ if sc.findChild(QtWidgets.QDockWidget, "VariableManager") is None:
+ action = pyside_utils.find_child_by_pattern(sc, {"text": "Variable Manager", "type": QtWidgets.QAction})
+ action.trigger()
+ variable_manager = sc.findChild(QtWidgets.QDockWidget, "VariableManager")
+
+ # 4) Create Graph
+ action = pyside_utils.find_child_by_pattern(sc, {"objectName": "action_New_Script", "type": QtWidgets.QAction})
+ action.trigger()
+
+ # 5) Create new variable
+ add_button = variable_manager.findChild(QtWidgets.QPushButton, "addButton")
+ add_button.click() # Click on Create Variable button
+ # Select variable type
+ table_view = variable_manager.findChild(QtWidgets.QTableView, "variablePalette")
+ model_index = pyside_utils.find_child_by_pattern(table_view, "Boolean")
+ # Click on it to create variable
+ pyside_utils.item_view_index_mouse_click(table_view, model_index)
+
+ # 6) Verify if the variable is created initially
+ graph_vars = variable_manager.findChild(QtWidgets.QTableView, "graphVariables")
+ result = graph_vars.model().rowCount(QtCore.QModelIndex()) == 1 # since we added 1 variable, rowcount=1
+ Report.result(Tests.variable_created, result)
+
+ # 7) Trigger Undo action and verify if variable is removed in Variable Manager
+ action = sc.findChild(QtWidgets.QAction, "action_Undo")
+ action.trigger()
+ result = graph_vars.model().rowCount(QtCore.QModelIndex()) == 0 # since we triggered undo, rowcount=0
+ Report.result(Tests.undo_worked, result)
+
+ # 8) Trigger Redo action and verify if variable is readded in Variable Manager
+ action = sc.findChild(QtWidgets.QAction, "action_Redo")
+ action.trigger()
+ result = (
+ graph_vars.model().rowCount(QtCore.QModelIndex()) == 1
+ ) # since action is redone 1 variable is readded, rowcount=1
+ Report.result(Tests.redo_worked, result)
+
+ # 9) Close SC window
+ general.close_pane("Script Canvas")
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+
+ from utils import Report
+
+ Report.start_test(EditMenu_UndoRedo)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/Entity_AddScriptCanvasComponent.py b/AutomatedTesting/Gem/PythonTests/scripting/Entity_AddScriptCanvasComponent.py
new file mode 100644
index 0000000000..fd8e9b1173
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/Entity_AddScriptCanvasComponent.py
@@ -0,0 +1,88 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+Test case ID: T92562978
+Test Case Title: Script Canvas Component can be added to an entity
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92562978
+"""
+
+
+# fmt: off
+class Tests():
+ level_created = ("New level created", "Failed to create new level")
+ entity_created = ("Test Entity created", "Failed to create test entity")
+ add_sc_component = ("Script Canvas component added to entity", "Failed to add SC component to entity")
+ no_errors_found = ("Tracer found no errors", "One or more errors found by Tracer")
+ no_warnings_found = ("Tracer found no warnings", "One or more warnings found by Tracer")
+# fmt: on
+
+
+def Entity_AddScriptCanvasComponent():
+ """
+ Summary:
+ verify if Script Canvas component can be added to Entity without any issue
+
+ Expected Behavior:
+ Script Canvas Component is added to the entity successfully without issue.
+
+ Test Steps:
+ 1) Create temp level
+ 2) Create test entity
+ 3) Start Tracer
+ 4) Add Script Canvas component to test entity
+ 5) Search for errors and warnings
+
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ from utils import TestHelper as helper
+ from utils import Tracer
+ from editor_entity_utils import EditorEntity
+ import azlmbr.legacy.general as general
+
+ LEVEL_NAME = "tmp_level"
+ WAIT_TIME = 3.0 # SECONDS
+
+ # 1) Create temp level
+ general.idle_enable(True)
+ result = general.create_level_no_prompt(LEVEL_NAME, 128, 1, 512, True)
+ Report.critical_result(Tests.level_created, result == 0)
+ helper.wait_for_condition(lambda: general.get_current_level_name() == LEVEL_NAME, WAIT_TIME)
+ general.close_pane("Error Report")
+
+ # 2) Create new entity
+ test_entity = EditorEntity.create_editor_entity("test_entity")
+ Report.result(Tests.entity_created, test_entity.id.IsValid())
+
+ # 3) Start Tracer
+ with Tracer() as section_tracer:
+
+ # 4) Add Script Canvas component to test entity
+ test_entity.add_component("Script Canvas")
+ Report.result(Tests.add_sc_component, test_entity.has_component("Script Canvas"))
+
+ # 5) Search for errors and warnings
+ Report.result(Tests.no_errors_found, not section_tracer.has_errors)
+ Report.result(Tests.no_warnings_found, not section_tracer.has_warnings)
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+ from utils import Report
+
+ Report.start_test(Entity_AddScriptCanvasComponent)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/FileMenu_New_Open.py b/AutomatedTesting/Gem/PythonTests/scripting/FileMenu_New_Open.py
new file mode 100644
index 0000000000..f72ac8ea01
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/FileMenu_New_Open.py
@@ -0,0 +1,98 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+
+Test case ID: T92569037
+Test Case Title: File > New Script creates a new script
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92569037
+Test case ID: T92569039
+Test Case Title: File > Open opens the Open... dialog
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92569039
+"""
+
+import os
+import sys
+from PySide2 import QtWidgets
+import azlmbr.legacy.general as general
+
+import editor_python_test_tools.pyside_utils as pyside_utils
+from editor_python_test_tools.utils import Report
+
+# fmt: off
+class Tests():
+ new_action = "File->New action working as expected"
+ open_action = "File->Open action working as expected"
+# fmt: on
+
+
+GENERAL_WAIT = 0.5 # seconds
+
+
+class TestFileMenuNewOpen:
+ """
+ Summary:
+ When clicked on File->New, new script opens and File->Open should open the FileBrowser
+
+ Expected Behavior:
+ New and Open actions should work as expected.
+
+ Test Steps:
+ 1) Open Script Canvas window (Tools > Script Canvas)
+ 2) Get the SC window object
+ 3) Trigger File->New action
+ 4) Verify if New tab is opened
+ 5) Trigger File->Open action
+ 6) Close Script Canvas window
+
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ @pyside_utils.wrap_async
+ async def run_test(self):
+ # 1) Open Script Canvas window (Tools > Script Canvas)
+ general.open_pane("Script Canvas")
+
+ # 2) Get the SC window object
+ editor_window = pyside_utils.get_editor_main_window()
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+ sc_main = sc.findChild(QtWidgets.QMainWindow)
+ sc_tabs = sc_main.findChild(QtWidgets.QTabWidget, "ScriptCanvasTabs")
+
+ # 3) Trigger File->New action
+ initial_tabs_count = sc_tabs.count()
+ action = pyside_utils.find_child_by_pattern(
+ sc_main, {"objectName": "action_New_Script", "type": QtWidgets.QAction}
+ )
+ action.trigger()
+
+ # 4) Verify if New tab is opened
+ general.idle_wait(GENERAL_WAIT)
+ Report.info(f"{Tests.new_action}: {sc_tabs.count() == initial_tabs_count + 1}")
+
+ # 5) Trigger File->Open action
+ action = pyside_utils.find_child_by_pattern(sc_main, {"objectName": "action_Open", "type": QtWidgets.QAction})
+ pyside_utils.trigger_action_async(action)
+ general.idle_wait(GENERAL_WAIT)
+ popup = await pyside_utils.wait_for_modal_widget()
+ Report.info(f"{Tests.open_action}: {popup and 'Open' in popup.windowTitle()}")
+ popup.close()
+
+ # 6) Close Script Canvas window
+ general.close_pane("Script Canvas")
+
+
+test = TestFileMenuNewOpen()
+test.run_test()
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/GraphClose_SavePrompt.py b/AutomatedTesting/Gem/PythonTests/scripting/GraphClose_SavePrompt.py
new file mode 100644
index 0000000000..ce610b159b
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/GraphClose_SavePrompt.py
@@ -0,0 +1,110 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+
+Test case ID: T92563070
+Test Case Title: Graphs can be closed by clicking X on the Graph name tab
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92563070
+Test case ID: T92563068
+Test Case Title: Save Prompt: User is prompted to save a graph on close after
+creating a new graph
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92563068
+"""
+
+import os
+import sys
+from PySide2 import QtWidgets
+import azlmbr.legacy.general as general
+
+import editor_python_test_tools.pyside_utils as pyside_utils
+from editor_python_test_tools.utils import TestHelper as helper
+from editor_python_test_tools.utils import Report
+
+# fmt: off
+class Tests():
+ new_graph = "New graph created"
+ save_prompt = "Save prompt opened as expected"
+ close_graph = "Close button worked as expected"
+# fmt: on
+
+
+GENERAL_WAIT = 0.5 # seconds
+
+
+class TestGraphCloseSavePrompt:
+ """
+ Summary:
+ The graph is closed when x button is clicked.
+ Save Prompt is opened before closing.
+
+ Expected Behavior:
+ New and Open actions should work as expected.
+
+ Test Steps:
+ 1) Open Script Canvas window (Tools > Script Canvas)
+ 2) Get the SC window object
+ 3) Trigger File->New action
+ 4) Verify if New tab is opened
+ 5) Close new tab using X on top of graph and check for save dialog
+ 6) Check if tab is closed
+ 7) Close Script Canvas window
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ @pyside_utils.wrap_async
+ async def run_test(self):
+ # 1) Open Script Canvas window (Tools > Script Canvas)
+ general.idle_enable(True)
+ general.open_pane("Script Canvas")
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
+
+ # 2) Get the SC window object
+ editor_window = pyside_utils.get_editor_main_window()
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+ sc_main = sc.findChild(QtWidgets.QMainWindow)
+ sc_tabs = sc_main.findChild(QtWidgets.QTabWidget, "ScriptCanvasTabs")
+ tab_bar = sc_tabs.findChild(QtWidgets.QTabBar)
+
+ # 3) Trigger File->New action
+ initial_tabs_count = sc_tabs.count()
+ action = pyside_utils.find_child_by_pattern(
+ sc_main, {"objectName": "action_New_Script", "type": QtWidgets.QAction}
+ )
+ action.trigger()
+
+ # 4) Verify if New tab is opened
+ result = helper.wait_for_condition(lambda: sc_tabs.count() == initial_tabs_count + 1, GENERAL_WAIT)
+ Report.info(f"{Tests.new_graph}: {result}")
+
+ # 5) Close new tab using X on top of graph and check for save dialog
+ close_button = tab_bar.findChildren(QtWidgets.QAbstractButton)[0]
+ pyside_utils.click_button_async(close_button)
+ popup = await pyside_utils.wait_for_modal_widget()
+ if popup:
+ Report.info(f"{Tests.save_prompt}: {popup.findChild(QtWidgets.QDialog, 'SaveChangesDialog') is not None}")
+ dont_save = popup.findChild(QtWidgets.QPushButton, "m_continueButton")
+ dont_save.click()
+
+ # 6) Check if tab is closed
+ await pyside_utils.wait_for_condition(lambda: sc_tabs.count() == initial_tabs_count, 5.0)
+ Report.info(f"{Tests.close_graph}: {sc_tabs.count()==initial_tabs_count}")
+
+ # 7) Close Script Canvas window
+ general.close_pane("Script Canvas")
+
+
+test = TestGraphCloseSavePrompt()
+test.run_test()
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/Graph_ZoomInZoomOut.py b/AutomatedTesting/Gem/PythonTests/scripting/Graph_ZoomInZoomOut.py
new file mode 100644
index 0000000000..a93b6e61d1
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/Graph_ZoomInZoomOut.py
@@ -0,0 +1,120 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+
+Test case ID: T92569079
+Test Case Title: View > Zoom In zooms the graph in
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92569079
+Test case ID: T92569081
+Test Case Title: View > Zoom In zooms the graph out
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92569081
+"""
+
+
+# fmt: off
+class Tests():
+ zoom_in = ("Zoom In action working as expected", "Zoom In action not working as expected")
+ zoom_out = ("Zoom Out action working as expected", "Zoom Out action not working as expected")
+# fmt: on
+
+
+GENERAL_WAIT = 0.5 # seconds
+
+
+def Graph_ZoomInZoomOut():
+ """
+ Summary:
+ The graph can be zoomed in and zoomed out.
+
+ Expected Behavior:
+ The graph is zoomed in when when we click View->ZoomIn
+ The graph is zoomed out when when we click View->ZoomOut
+
+ Test Steps:
+ 1) Open Script Canvas window (Tools > Script Canvas)
+ 2) Get the SC window object
+ 3) Create new graph
+ 4) Get initial graph transform values
+ 5) Trigger Zoom In and verify if the graph transform scale is increased
+ 6) Trigger Zoom Out and verify if the graph transform scale is decreased
+ 7) Close Script Canvas window
+
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ # Helper imports
+ import ImportPathHelper as imports
+
+ imports.init()
+
+ from PySide2 import QtWidgets
+ import azlmbr.legacy.general as general
+
+ import pyside_utils
+ from utils import TestHelper as helper
+ from utils import Report
+
+ # 1) Open Script Canvas window (Tools > Script Canvas)
+ general.idle_enable(True)
+ general.open_pane("Script Canvas")
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
+
+ # 2) Get the SC window object
+ editor_window = pyside_utils.get_editor_main_window()
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+ sc_main = sc.findChild(QtWidgets.QMainWindow)
+
+ # 3) Create new graph
+ create_new_graph = pyside_utils.find_child_by_pattern(
+ sc_main, {"objectName": "action_New_Script", "type": QtWidgets.QAction}
+ )
+ create_new_graph.trigger()
+
+ # 4) Get initial graph transform values
+ graphics_view = sc_main.findChild(QtWidgets.QGraphicsView)
+ # NOTE: transform m11 and m22 are horizontal and vertical scales of graph
+ # they increase when zoomed in and decreased when zoomed out
+ curr_m11, curr_m22 = graphics_view.transform().m11(), graphics_view.transform().m22()
+
+ # 5) Trigger Zoom In and verify if the graph transform scale is increased
+ zin = pyside_utils.find_child_by_pattern(sc_main, {"objectName": "action_ZoomIn", "type": QtWidgets.QAction})
+ zin.trigger()
+ result = helper.wait_for_condition(
+ lambda: curr_m11 < graphics_view.transform().m11() and curr_m22 < graphics_view.transform().m22(), GENERAL_WAIT,
+ )
+ Report.result(Tests.zoom_in, result)
+
+ # 6) Trigger Zoom Out and verify if the graph transform scale is decreased
+ curr_m11, curr_m22 = graphics_view.transform().m11(), graphics_view.transform().m22()
+ zout = pyside_utils.find_child_by_pattern(sc_main, {"objectName": "action_ZoomOut", "type": QtWidgets.QAction})
+ zout.trigger()
+ result = helper.wait_for_condition(
+ lambda: curr_m11 > graphics_view.transform().m11() and curr_m22 > graphics_view.transform().m22(), GENERAL_WAIT,
+ )
+ Report.result(Tests.zoom_out, result)
+
+ # 7) Close Script Canvas window
+ general.close_pane("Script Canvas")
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+
+ from utils import Report
+
+ Report.start_test(Graph_ZoomInZoomOut)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/ImportPathHelper.py b/AutomatedTesting/Gem/PythonTests/scripting/ImportPathHelper.py
index 8aede24d0e..a45024cebf 100755
--- a/AutomatedTesting/Gem/PythonTests/scripting/ImportPathHelper.py
+++ b/AutomatedTesting/Gem/PythonTests/scripting/ImportPathHelper.py
@@ -13,4 +13,5 @@ def init():
import os
import sys
sys.path.append(os.path.dirname(os.path.abspath(__file__)) + '/../automatedtesting_shared')
+ sys.path.append(os.path.dirname(os.path.abspath(__file__)) + '/../EditorPythonTestTools/editor_python_test_tools')
\ No newline at end of file
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/NodeInspector_RenameVariable.py b/AutomatedTesting/Gem/PythonTests/scripting/NodeInspector_RenameVariable.py
new file mode 100644
index 0000000000..33d3f4137a
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/NodeInspector_RenameVariable.py
@@ -0,0 +1,132 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+Test case ID: T92568982
+Test Case Title: Renaming variables in the Node Inspector
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92568982
+"""
+
+
+# fmt: off
+class Tests():
+ variable_created = ("New variable created", "New variable is not created")
+ node_inspector_rename = ("Variable is renamed in Node Inspector", "Variable is not renamed in Node Inspector")
+ variable_manager_rename = ("Variable is renamed in Variable Manager", "Variable is not renamed in Variable Manager")
+# fmt: on
+
+
+GENERAL_WAIT = 0.5 # seconds
+
+
+def NodeInspector_RenameVariable():
+ """
+ Summary:
+ Renaming variables in the Node Inspector, renames the actual variable.
+
+ Expected Behavior:
+ The Variable's name is changed in both Node Inspector and Variable Manager.
+
+ Test Steps:
+ 1) Open Script Canvas window (Tools > Script Canvas)
+ 2) Get the SC window object
+ 3) Open Variable Manager if not opened already
+ 4) Open Node Inspector if not opened already
+ 5) Create new graph and a new variable in Variable manager
+ 6) Click on the variable
+ 7) Update name in Node Inspector and click on ENTER
+ 8) Verify if the name is updated in Node inspector and Variable manager
+ 9) Close Script Canvas window
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ TEST_NAME = "test name"
+
+ from PySide2 import QtWidgets, QtCore, QtTest
+ from PySide2.QtCore import Qt
+ import azlmbr.legacy.general as general
+
+ import pyside_utils
+ from utils import TestHelper as helper
+
+ def open_tool(sc, dock_widget_name, pane_name):
+ if sc.findChild(QtWidgets.QDockWidget, dock_widget_name) is None:
+ action = pyside_utils.find_child_by_pattern(sc, {"text": pane_name, "type": QtWidgets.QAction})
+ action.trigger()
+ tool = sc.findChild(QtWidgets.QDockWidget, dock_widget_name)
+ return tool
+
+ # 1) Open Script Canvas window
+ general.idle_enable(True)
+ general.open_pane("Script Canvas")
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
+
+ # 2) Get the SC window object
+ editor_window = pyside_utils.get_editor_main_window()
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+
+ # 3) Open Variable Manager if not opened already
+ variable_manager = open_tool(sc, "VariableManager", "Variable Manager")
+
+ # 4) Open Node Inspector if not opened already
+ node_inspector = open_tool(sc, "NodeInspector", "Node Inspector")
+
+ # 5) Create new graph and a new variable in Variable manager
+ action = pyside_utils.find_child_by_pattern(sc, {"objectName": "action_New_Script", "type": QtWidgets.QAction})
+ action.trigger()
+ graph_vars = variable_manager.findChild(QtWidgets.QTableView, "graphVariables")
+ add_button = variable_manager.findChild(QtWidgets.QPushButton, "addButton")
+ add_button.click()
+ # Select variable type
+ table_view = variable_manager.findChild(QtWidgets.QTableView, "variablePalette")
+ model_index = pyside_utils.find_child_by_pattern(table_view, "Boolean")
+ # Click on it to create variable
+ pyside_utils.item_view_index_mouse_click(table_view, model_index)
+ result = graph_vars.model().rowCount(QtCore.QModelIndex()) == 1
+ var_mi = pyside_utils.find_child_by_pattern(graph_vars, "Variable 1")
+ result = result and (var_mi is not None)
+ Report.critical_result(Tests.variable_created, result)
+
+ # 6) Click on the variable
+ pyside_utils.item_view_index_mouse_click(graph_vars, var_mi)
+
+ # 7) Update name in Node Inspector and click on ENTER
+ helper.wait_for_condition(
+ lambda: node_inspector.findChild(QtWidgets.QWidget, "ContainerForRows") is not None, GENERAL_WAIT
+ )
+ row_container = node_inspector.findChild(QtWidgets.QWidget, "ContainerForRows")
+ name_frame = row_container.findChild(QtWidgets.QWidget, "Name")
+ name_line_edit = name_frame.findChild(QtWidgets.QLineEdit)
+ name_line_edit.setText(TEST_NAME)
+ QtTest.QTest.keyClick(name_line_edit, Qt.Key_Return, Qt.NoModifier)
+
+ # 8) Verify if the name is updated in Node inspector and Variable manager
+ helper.wait_for_condition(lambda: var_mi.data(Qt.DisplayRole) == TEST_NAME, GENERAL_WAIT)
+ Report.critical_result(Tests.node_inspector_rename, name_line_edit.text() == TEST_NAME)
+ Report.critical_result(Tests.variable_manager_rename, var_mi.data(Qt.DisplayRole) == TEST_NAME)
+
+ # 9) Close Script Canvas window
+ general.close_pane("Script Canvas")
+
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+
+ from utils import Report
+
+ Report.start_test(NodeInspector_RenameVariable)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/NodePalette_ClearSelection.py b/AutomatedTesting/Gem/PythonTests/scripting/NodePalette_ClearSelection.py
new file mode 100644
index 0000000000..de30e46767
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/NodePalette_ClearSelection.py
@@ -0,0 +1,94 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+Test case ID: T92562993
+Test Case Title: Clicking the X button on the Search Box clears the currently entered string
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92562993
+"""
+
+
+# fmt: off
+class Tests():
+ set_search_string = ("Search string is set", "Search string is not set")
+ search_string_cleared = ("Search string cleared as expected", "Search string not cleared")
+# fmt: on
+
+
+def NodePalette_ClearSelection():
+ """
+ Summary:
+ We enter some string in the Node Palette Search box, and click on the X button to verify if the
+ search string got cleared.
+
+ Expected Behavior:
+ Clicking the X button on the Search Box clears the currently entered string
+
+ Test Steps:
+ 1) Open Script Canvas window (Tools > Script Canvas)
+ 2) Get the SC window object
+ 3) Open Node Manager if not opened already
+ 4) Set some string in the Search box
+ 5) Verify if the test string is set
+ 6) Clear search string and verify if it is cleared
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ from PySide2 import QtWidgets
+
+ from utils import TestHelper as helper
+
+ import azlmbr.legacy.general as general
+
+ import pyside_utils
+
+ TEST_STRING = "Test String"
+
+ # 1) Open Script Canvas window (Tools > Script Canvas)
+ general.idle_enable(True)
+ general.open_pane("Script Canvas")
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 3.0)
+
+ # 2) Get the SC window object
+ editor_window = pyside_utils.get_editor_main_window()
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+
+ # 3) Open Node Manager if not opened already
+ if sc.findChild(QtWidgets.QDockWidget, "NodePalette") is None:
+ action = pyside_utils.find_child_by_pattern(sc, {"text": "Node Palette", "type": QtWidgets.QAction})
+ action.trigger()
+ node_palette = sc.findChild(QtWidgets.QDockWidget, "NodePalette")
+ search_frame = node_palette.findChild(QtWidgets.QFrame, "searchFrame")
+
+ # 4) Set some string in the Search box
+ search_box = search_frame.findChild(QtWidgets.QLineEdit, "searchFilter")
+ search_box.setText(TEST_STRING)
+
+ # 5) Verify if the test string is set
+ Report.result(Tests.set_search_string, search_box.text() == TEST_STRING)
+
+ # 6) Clear search string and verify if it is cleared
+ clear_text_button = search_frame.findChild(QtWidgets.QToolButton, "ClearToolButton")
+ clear_text_button.click()
+ Report.result(Tests.search_string_cleared, search_box.text() == "")
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+ from utils import Report
+
+ Report.start_test(NodePalette_ClearSelection)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/NodePalette_SelectNode.py b/AutomatedTesting/Gem/PythonTests/scripting/NodePalette_SelectNode.py
new file mode 100644
index 0000000000..2ab76071a6
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/NodePalette_SelectNode.py
@@ -0,0 +1,104 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+
+Test case ID: T92568940
+Test Case Title: Categories and Nodes can be selected
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92568940
+"""
+
+
+# fmt: off
+class Tests():
+ category_selected = ("Category can be selected", "Category cannot be selected")
+ node_selected = ("Node can be selected", "Node cannot be selected")
+# fmt: on
+
+
+GENERAL_WAIT = 0.5 # seconds
+
+
+def NodePalette_SelectNode():
+ """
+ Summary:
+ Categories and Nodes can be selected
+
+ Expected Behavior:
+ When clicked on Node Palette, nodes and categories can be selected.
+
+ Test Steps:
+ 1) Open Script Canvas window (Tools > Script Canvas)
+ 2) Get the SC window object
+ 3) Expand QTreeView
+ 4) Click on category and check if it is selected
+ 5) Click on node and check if it is selected
+ 6) Close Script Canvas window
+
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ CATEGORY = "AI"
+ NODE = "Find Path To Entity"
+
+ from PySide2 import QtWidgets
+ import azlmbr.legacy.general as general
+
+ import pyside_utils
+ from utils import TestHelper as helper
+
+ # 1) Open Script Canvas window (Tools > Script Canvas)
+ general.idle_enable(True)
+ general.open_pane("Script Canvas")
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
+
+ # 2) Get the SC window object
+ editor_window = pyside_utils.get_editor_main_window()
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+ if sc.findChild(QtWidgets.QDockWidget, "NodePalette") is None:
+ action = pyside_utils.find_child_by_pattern(sc, {"text": "Node Palette", "type": QtWidgets.QAction})
+ action.trigger()
+ node_palette = sc.findChild(QtWidgets.QDockWidget, "NodePalette")
+ tree = node_palette.findChild(QtWidgets.QTreeView, "treeView")
+
+ # 3) Expand QTreeView
+ tree.expandAll()
+
+ # 4) Click on category and check if it is selected
+ category_index = pyside_utils.find_child_by_hierarchy(tree, CATEGORY)
+ tree.scrollTo(category_index)
+ pyside_utils.item_view_index_mouse_click(tree, category_index)
+ pyside_utils.wait_for_condition(tree.selectedIndexes() and tree.selectedIndexes()[0] == category_index)
+ Report.result(Tests.category_selected, tree.selectedIndexes()[0] == category_index)
+
+ # 5) Click on node and check if it is selected
+ node_index = pyside_utils.find_child_by_pattern(tree, NODE)
+ helper.wait_for_condition(lambda: tree.isExpanded(node_index), GENERAL_WAIT)
+ pyside_utils.item_view_index_mouse_click(tree, node_index)
+ pyside_utils.wait_for_condition(tree.selectedIndexes()[0] == node_index)
+ Report.result(Tests.node_selected, tree.selectedIndexes()[0] == node_index)
+
+ # 6) Close Script Canvas window
+ general.close_pane("Script Canvas")
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+
+ from utils import Report
+
+ Report.start_test(NodePalette_SelectNode)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/OnEntityActivatedDeactivated_PrintMessage.py b/AutomatedTesting/Gem/PythonTests/scripting/OnEntityActivatedDeactivated_PrintMessage.py
new file mode 100644
index 0000000000..51b63c4268
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/OnEntityActivatedDeactivated_PrintMessage.py
@@ -0,0 +1,184 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+Test case ID: T92569253 // T92569254
+Test Case Title: On Entity Activated // On Entity Deactivated
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92569253 // https://testrail.agscollab.com/index.php?/tests/view/92569254
+"""
+
+
+# fmt: off
+class Tests():
+ level_created = ("Successfully created temp level", "Failed to create temp level")
+ controller_exists = ("Successfully found controller entity", "Failed to find controller entity")
+ activated_exists = ("Successfully found activated entity", "Failed to find activated entity")
+ deactivated_exists = ("Successfully found deactivated entity","Failed to find deactivated entity")
+ start_states_correct = ("Start states set up successfully", "Start states set up incorrectly")
+ game_mode_entered = ("Successfully entered game mode" "Failed to enter game mode")
+ lines_found = ("Successfully found expected prints", "Failed to find expected prints")
+ game_mode_exited = ("Successfully exited game mode" "Failed to exit game mode")
+# fmt: on
+
+
+def OnEntityActivatedDeactivated_PrintMessage():
+ """
+ Summary:
+ Verify that the On Entity Activation node is working as expected
+
+ Expected Behavior:
+ Upon entering game mode, the Controller entity will wait 1 second and then activate the ActivationTest
+ entity. The script attached to ActivationTest will print out a message on activation. The Controller
+ will also deactivate the DeactivationTest entity, which should print a message.
+
+ Test Steps:
+ 1) Create temp level
+ 2) Setup the level
+ 3) Validate the entities
+ 4) Start the Tracer
+ 5) Enter Game Mode
+ 6) Validate Print message
+ 7) Exit game mode
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+ import os
+
+ from utils import TestHelper as helper
+ from editor_entity_utils import EditorEntity as Entity
+ from utils import Report
+ from utils import Tracer
+
+ import azlmbr.legacy.general as general
+
+ EditorEntity = str
+ LEVEL_NAME = "tmp_level"
+ WAIT_TIME = 3.0 # SECONDS
+ EXPECTED_LINES = ["Activator Script: Activated", "Deactivator Script: Deactivated"]
+ controller_dict = {
+ "name": "Controller",
+ "status": "active",
+ "path": os.path.join("ScriptCanvas", "OnEntityActivatedScripts", "controller.scriptcanvas")
+ }
+ activated_dict = {
+ "name": "ActivationTest",
+ "status": "inactive",
+ "path": os.path.join("ScriptCanvas", "OnEntityActivatedScripts", "activator.scriptcanvas")
+ }
+ deactivated_dict = {
+ "name": "DeactivationTest",
+ "status": "active",
+ "path": os.path.join("ScriptCanvas", "OnEntityActivatedScripts", "deactivator.scriptcanvas")
+ }
+
+ def get_asset(asset_path):
+ return azlmbr.asset.AssetCatalogRequestBus(azlmbr.bus.Broadcast, "GetAssetIdByPath", asset_path, azlmbr.math.Uuid(), False)
+
+ def setup_level():
+ def create_editor_entity(entity_dict:dict, entity_to_activate:EditorEntity=None, entity_to_deactivate:EditorEntity=None) -> EditorEntity:
+ entity = Entity.create_editor_entity(entity_dict["name"])
+ entity.set_start_status(entity_dict["status"])
+ sc_component = entity.add_component("Script Canvas")
+ sc_component.set_component_property_value("Script Canvas Asset|Script Canvas Asset", get_asset(entity_dict["path"]))
+
+ if entity_dict["name"] == "Controller":
+ sc_component.get_property_tree()
+ sc_component.set_component_property_value("Properties|Variable Fields|Variables|[0]|Name,Value|Datum|Datum|EntityToActivate", entity_to_activate.id)
+ sc_component.set_component_property_value("Properties|Variable Fields|Variables|[1]|Name,Value|Datum|Datum|EntityToDeactivate", entity_to_deactivate.id)
+ return entity
+
+ activated = create_editor_entity(activated_dict)
+ deactivated = create_editor_entity(deactivated_dict)
+ create_editor_entity(controller_dict, activated, deactivated)
+
+ def validate_entity_exist(entity_name: str, test_tuple: tuple):
+ """
+ Validate the entity with the given name exists in the level
+ :return: entity: editor entity object
+ """
+ entity = Entity.find_editor_entity(entity_name)
+ Report.critical_result(test_tuple, entity.id.IsValid())
+ return entity
+
+ def validate_start_state(entity:EditorEntity, expected_state:str):
+ """
+ Validate that the starting state of the entity is correct, if it isn't then attempt to rectify and recheck.
+ :return: bool: Whether state is set as expected
+ """
+ state_options = {
+ "active": azlmbr.globals.property.EditorEntityStartStatus_StartActive,
+ "inactive": azlmbr.globals.property.EditorEntityStartStatus_StartInactive,
+ "editor": azlmbr.globals.property.EditorEntityStartStatus_EditorOnly,
+ }
+ if expected_state.lower() not in state_options.keys():
+ raise ValueError(f"{expected_state} is an invalid option; valid options: active, inactive, or editor.")
+
+ state = entity.get_start_status()
+ if state != state_options[expected_state]:
+ # If state fails to set, set_start_status will assert
+ entity.set_start_status(expected_state)
+ return True
+
+ def validate_entities_in_level():
+ controller = validate_entity_exist(controller_dict["name"], Tests.controller_exists)
+ state1_correct = validate_start_state(controller, controller_dict["status"])
+
+ act_tester = validate_entity_exist(activated_dict["name"], Tests.activated_exists)
+ state2_correct = validate_start_state(act_tester, activated_dict["status"])
+
+ deac_tester = validate_entity_exist(deactivated_dict["name"], Tests.deactivated_exists)
+ state3_correct = validate_start_state(deac_tester, deactivated_dict["status"])
+
+ all_states_correct = state1_correct and state2_correct and state3_correct
+ Report.critical_result(Tests.start_states_correct, all_states_correct)
+
+ def locate_expected_lines(line_list: list):
+ found_lines = [printInfo.message.strip() for printInfo in section_tracer.prints]
+ return all(line in found_lines for line in line_list)
+
+ # 1) Create temp level
+ general.idle_enable(True)
+ result = general.create_level_no_prompt(LEVEL_NAME, 128, 1, 512, True)
+ Report.critical_result(Tests.level_created, result == 0)
+ helper.wait_for_condition(lambda: general.get_current_level_name() == LEVEL_NAME, WAIT_TIME)
+ general.close_pane("Error Report")
+
+ # 2) Setup the level
+ setup_level()
+
+ # 3) Validate the entities
+ validate_entities_in_level()
+
+ # 4) Start the Tracer
+ with Tracer() as section_tracer:
+
+ # 5) Enter Game Mode
+ helper.enter_game_mode(Tests.game_mode_entered)
+
+ # 6) Validate Print message
+ helper.wait_for_condition(lambda: locate_expected_lines(EXPECTED_LINES), WAIT_TIME)
+
+ Report.result(Tests.lines_found, locate_expected_lines(EXPECTED_LINES))
+
+ # 7) Exit game mode
+ helper.exit_game_mode(Tests.game_mode_exited)
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+ imports.init()
+
+ from utils import Report
+
+ Report.start_test(OnEntityActivatedDeactivated_PrintMessage)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/Opening_Closing_Pane.py b/AutomatedTesting/Gem/PythonTests/scripting/Opening_Closing_Pane.py
index 6100285092..666f052240 100755
--- a/AutomatedTesting/Gem/PythonTests/scripting/Opening_Closing_Pane.py
+++ b/AutomatedTesting/Gem/PythonTests/scripting/Opening_Closing_Pane.py
@@ -17,7 +17,6 @@ URLs of the test case: https://testrail.agscollab.com/index.php?/cases/view/1702
# fmt: off
class Tests():
- open_sc_window = ("Script Canvas window is opened", "Failed to open Script Canvas window")
default_visible = ("All the panes visible by default", "One or more panes do not visible by default")
open_panes = ("All the Panes opened successfully", "Failed to open one or more panes")
close_pane = ("All the Panes closed successfully", "Failed to close one or more panes")
@@ -49,11 +48,6 @@ def Opening_Closing_Pane():
:return: None
"""
- # Helper imports
- import ImportPathHelper as imports
-
- imports.init()
-
from editor_python_test_tools.utils import Report
from editor_python_test_tools.utils import TestHelper as helper
import editor_python_test_tools.pyside_utils as pyside_utils
@@ -82,8 +76,7 @@ def Opening_Closing_Pane():
# 1) Open Script Canvas window (Tools > Script Canvas)
general.open_pane("Script Canvas")
- is_sc_visible = helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
- Report.result(Tests.open_sc_window, is_sc_visible)
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
# 2) Restore default layout
editor_window = pyside_utils.get_editor_main_window()
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/Pane_RetainOnSCRestart.py b/AutomatedTesting/Gem/PythonTests/scripting/Pane_RetainOnSCRestart.py
new file mode 100644
index 0000000000..fa5e9e6068
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/Pane_RetainOnSCRestart.py
@@ -0,0 +1,164 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+Test case ID: C1702821 // C1702832
+Test Case Title: Retain visibility, size and location upon Script Canvas restart
+URLs of the test case: https://testrail.agscollab.com/index.php?/cases/view/1702821 and
+ https://testrail.agscollab.com/index.php?/cases/view/1702832
+"""
+
+
+# fmt: off
+class Tests():
+ relaunch_sc = ("Script Canvas window is relaunched", "Failed to relaunch Script Canvas window")
+ test_panes_visible = ("All the test panes are opened", "Failed to open one or more test panes")
+ close_pane_1 = ("Test pane 1 is closed", "Failed to close test pane 1")
+ visiblity_retained = ("Test pane retained its visiblity on SC restart", "Failed to retain visiblity of test pane on SC restart")
+ resize_pane_3 = ("Test pane 3 resized successfully", "Failed to resize Test pane 3")
+ size_retained = ("Test pane retained its size on SC restart", "Failed to retain size of test pane on SC restart")
+ location_changed = ("Location of test pane 2 changed successfully", "Failed to change locatio of test pane 2")
+ location_retained = ("Test pane retained its location on SC restart", "Failed to retain location of test pane on SC restart")
+# fmt: on
+
+
+def Pane_RetainOnSCRestart():
+ """
+ Summary:
+ The Script Canvas window is opened to verify if Script canvas panes can retain its visibility, size and location
+ upon ScriptCanvas restart.
+
+ Expected Behavior:
+ The ScriptCanvas pane retain it's visiblity, size and location upon ScriptCanvas restart.
+
+ Test Steps:
+ 1) Open Script Canvas window (Tools > Script Canvas)
+ 2) Make sure test panes are open and visible
+ 3) Close test pane 1
+ 4) Change dock location of test pane 2
+ 5) Resize test pane 3
+ 6) Relaunch Script Canvas
+ 7) Verify if test pane 1 retain its visiblity
+ 8) Verify if location of test pane 2 is retained
+ 9) Verify if size of test pane 3 is retained
+ 10) Restore default layout and close SC window
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ # Helper imports
+ from utils import Report
+ from utils import TestHelper as helper
+ import pyside_utils
+
+ # Open 3D Engine Imports
+ import azlmbr.legacy.general as general
+
+ # Pyside imports
+ from PySide2 import QtCore, QtWidgets
+ from PySide2.QtCore import Qt
+
+ # Constants
+ TEST_PANE_1 = "NodePalette" # test visibility
+ TEST_PANE_2 = "VariableManager" # test location
+ TEST_PANE_3 = "NodeInspector" # test size
+ SCALE_INT = 10 # Random resize scale integer
+ DOCKAREA = Qt.TopDockWidgetArea # Preferred top area since no widget is docked on top
+
+ def click_menu_option(window, option_text):
+ action = pyside_utils.find_child_by_pattern(window, {"text": option_text, "type": QtWidgets.QAction})
+ action.trigger()
+
+ def find_pane(window, pane_name):
+ return window.findChild(QtWidgets.QDockWidget, pane_name)
+
+ # Test starts here
+ general.idle_enable(True)
+
+ # 1) Open Script Canvas window (Tools > Script Canvas)
+ general.open_pane("Script Canvas")
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 3.0)
+
+ # 2) Make sure test panes are open and visible
+ editor_window = pyside_utils.get_editor_main_window()
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+ click_menu_option(sc, "Restore Default Layout")
+ test_pane_1 = sc.findChild(QtWidgets.QDockWidget, TEST_PANE_1)
+ test_pane_2 = sc.findChild(QtWidgets.QDockWidget, TEST_PANE_2)
+ test_pane_3 = sc.findChild(QtWidgets.QDockWidget, TEST_PANE_3)
+
+ Report.result(
+ Tests.test_panes_visible, test_pane_1.isVisible() and test_pane_2.isVisible() and test_pane_3.isVisible()
+ )
+
+ # Initiate try block here to restore default in finally block
+ try:
+ # 3) Close test pane
+ test_pane_1.close()
+ Report.result(Tests.close_pane_1, not test_pane_1.isVisible())
+
+ # 4) Change dock location of test pane 2
+ sc_main = sc.findChild(QtWidgets.QMainWindow)
+ sc_main.addDockWidget(DOCKAREA, find_pane(sc_main, TEST_PANE_2), QtCore.Qt.Vertical)
+ Report.result(Tests.location_changed, sc_main.dockWidgetArea(find_pane(sc_main, TEST_PANE_2)) == DOCKAREA)
+
+ # 5) Resize test pane 3
+ initial_size = test_pane_3.frameSize()
+ test_pane_3.resize(initial_size.width() + SCALE_INT, initial_size.height() + SCALE_INT)
+ new_size = test_pane_3.frameSize()
+ resize_success = (
+ abs(initial_size.width() - new_size.width()) == abs(initial_size.height() - new_size.height()) == SCALE_INT
+ )
+ Report.result(Tests.resize_pane_3, resize_success)
+
+ # 6) Relaunch Script Canvas
+ general.close_pane("Script Canvas")
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 2.0)
+
+ general.open_pane("Script Canvas")
+ sc_visible = helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
+ Report.result(Tests.relaunch_sc, sc_visible)
+
+ # 7) Verify if test pane 1 retain its visiblity
+ editor_window = pyside_utils.get_editor_main_window()
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+ Report.result(Tests.visiblity_retained, not find_pane(sc, TEST_PANE_1).isVisible())
+
+ # 8) Verify if location of test pane 2 is retained
+ sc_main = sc.findChild(QtWidgets.QMainWindow)
+ Report.result(Tests.location_retained, sc_main.dockWidgetArea(find_pane(sc_main, TEST_PANE_2)) == DOCKAREA)
+
+ # 9) Verify if size of test pane 3 is retained
+ test_pane_3 = sc.findChild(QtWidgets.QDockWidget, TEST_PANE_3)
+ retained_size = test_pane_3.frameSize()
+ retain_success = retained_size != initial_size
+ Report.result(Tests.size_retained, retain_success)
+
+ finally:
+ # 10) Restore default layout and close SC window
+ general.open_pane("Script Canvas")
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+ click_menu_option(sc, "Restore Default Layout")
+ sc.close()
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+
+ from utils import Report
+
+ Report.start_test(Pane_RetainOnSCRestart)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/Resizing_Pane.py b/AutomatedTesting/Gem/PythonTests/scripting/Resizing_Pane.py
index 9262e76cb0..180f577953 100755
--- a/AutomatedTesting/Gem/PythonTests/scripting/Resizing_Pane.py
+++ b/AutomatedTesting/Gem/PythonTests/scripting/Resizing_Pane.py
@@ -16,7 +16,6 @@ URLs of the test case: https://testrail.agscollab.com/index.php?/cases/view/1702
# fmt: off
class Tests():
- open_sc_window = ("Script Canvas window is opened", "Failed to open Script Canvas window")
open_pane = ("Pane opened successfully", "Failed to open pane")
resize_pane = ("Pane window resized successfully", "Failed to resize pane window")
# fmt: on
@@ -46,11 +45,6 @@ def Resizing_Pane():
:return: None
"""
- # Helper imports
- import ImportPathHelper as imports
-
- imports.init()
-
from editor_python_test_tools.utils import Report
from editor_python_test_tools.utils import TestHelper as helper
import editor_python_test_tools.pyside_utils as pyside_utils
@@ -76,8 +70,7 @@ def Resizing_Pane():
# 1) Open Script Canvas window (Tools > Script Canvas)
general.open_pane("Script Canvas")
- is_sc_visible = helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
- Report.result(Tests.open_sc_window, is_sc_visible)
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
# 2) Restore default layout
editor_window = pyside_utils.get_editor_main_window()
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/ScriptCanvas_ChangingAssets.py b/AutomatedTesting/Gem/PythonTests/scripting/ScriptCanvas_ChangingAssets.py
new file mode 100644
index 0000000000..38d60ad871
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/ScriptCanvas_ChangingAssets.py
@@ -0,0 +1,116 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+Test case ID: T92562986
+Test Case Title: Changing the assigned Script Canvas Asset on an entity properly updates
+level functionality
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92562986
+"""
+
+
+# fmt: off
+class Tests():
+ level_created = ("New level created", "New level not created")
+ entity_created = ("Test Entity created", "Test Entity not created")
+ game_mode_entered = ("Game Mode successfully entered", "Game mode failed to enter")
+ game_mode_exited = ("Game Mode successfully exited", "Game mode failed to exited")
+ found_lines = ("Expected log lines were found", "Expected log lines were not found")
+# fmt: on
+
+
+def ScriptCanvas_ChangingAssets():
+ """
+ Summary:
+ Changing the assigned Script Canvas Asset on an entity properly updates level functionality
+
+ Expected Behavior:
+ When game mode is entered, respective strings of assigned assets should be printed
+
+ Test Steps:
+ 1) Create temp level
+ 2) Create new entity
+ 3) Start Tracer
+ 4) Set first script and evaluate
+ 5) Set second script and evaluate
+
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ import os
+
+ from utils import TestHelper as helper
+ from utils import Tracer
+ import hydra_editor_utils as hydra
+ import azlmbr.legacy.general as general
+ import azlmbr.math as math
+ import azlmbr.asset as asset
+ import azlmbr.bus as bus
+ import azlmbr.paths as paths
+
+ LEVEL_NAME = "tmp_level"
+ ASSET_1 = os.path.join("scriptcanvas", "ScriptCanvas_TwoComponents0.scriptcanvas")
+ ASSET_2 = os.path.join("scriptcanvas", "ScriptCanvas_TwoComponents1.scriptcanvas")
+ EXP_LINE_1 = "Greetings from the first script"
+ EXP_LINE_2 = "Greetings from the second script"
+ WAIT_TIME = 3.0 # SECONDS
+
+ def get_asset(asset_path):
+ return asset.AssetCatalogRequestBus(bus.Broadcast, "GetAssetIdByPath", asset_path, math.Uuid(), False)
+
+ def find_expected_line(expected_line):
+ found_lines = [printInfo.message.strip() for printInfo in section_tracer.prints]
+ return expected_line in found_lines
+
+ def set_asset_evaluate(test_entity, ASSET_PATH, EXP_LINE):
+ # Set Script Canvas entity
+ test_entity.get_set_test(0, "Script Canvas Asset|Script Canvas Asset", get_asset(ASSET_PATH))
+
+ # Enter/exit game mode
+ helper.enter_game_mode(Tests.game_mode_entered)
+ helper.wait_for_condition(lambda: find_expected_line(EXP_LINE), WAIT_TIME)
+ Report.result(Tests.found_lines, find_expected_line(EXP_LINE))
+ helper.exit_game_mode(Tests.game_mode_exited)
+
+
+ # 1) Create temp level
+ general.idle_enable(True)
+ result = general.create_level_no_prompt(LEVEL_NAME, 128, 1, 512, True)
+ Report.critical_result(Tests.level_created, result == 0)
+ helper.wait_for_condition(lambda: general.get_current_level_name() == LEVEL_NAME, WAIT_TIME)
+ general.close_pane("Error Report")
+
+ # 2) Create new entity
+ position = math.Vector3(512.0, 512.0, 32.0)
+ test_entity = hydra.Entity("test_entity")
+ test_entity.create_entity(position, ["Script Canvas"])
+
+ # 3) Start Tracer
+ with Tracer() as section_tracer:
+
+ # 4) Set first script and evaluate
+ set_asset_evaluate(test_entity, ASSET_1, EXP_LINE_1)
+
+ # 5) Set second script and evaluate
+ set_asset_evaluate(test_entity, ASSET_2, EXP_LINE_2)
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+ from utils import Report
+
+ Report.start_test(ScriptCanvas_ChangingAssets)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/ScriptCanvas_TwoComponents.py b/AutomatedTesting/Gem/PythonTests/scripting/ScriptCanvas_TwoComponents.py
new file mode 100644
index 0000000000..896bee96e5
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/ScriptCanvas_TwoComponents.py
@@ -0,0 +1,118 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+Test case ID: T92563190
+Test Case Title: A single Entity with two Script Canvas components works properly
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92563190
+"""
+
+
+# fmt: off
+class Tests():
+ level_created = ("New level created", "New level not created")
+ game_mode_entered = ("Game Mode successfully entered", "Game mode failed to enter")
+ game_mode_exited = ("Game Mode successfully exited", "Game mode failed to exited")
+ found_lines = ("Expected log lines were found", "Expected log lines were not found")
+# fmt: on
+
+
+class LogLines:
+ expected_lines = ["Greetings from the first script", "Greetings from the second script"]
+
+
+def ScriptCanvas_TwoComponents():
+ """
+ Summary:
+ A test entity contains two Script Canvas components with different unique script canvas files.
+ Each of these files will have a print node set to activate on graph start.
+
+ Expected Behavior:
+ When game mode is entered, two unique strings should be printed out to the console
+
+ Test Steps:
+ 1) Create level
+ 2) Create entity with SC components
+ 3) Start Tracer
+ 4) Enter game mode
+ 5) Wait for expected lines to be found
+ 6) Report if expected lines were found
+ 7) Exit game mode
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+ import os
+
+ from utils import TestHelper as helper
+ import hydra_editor_utils as hydra
+ from utils import Report
+ from utils import Tracer
+ import azlmbr.legacy.general as general
+ import azlmbr.math as math
+ import azlmbr.asset as asset
+ import azlmbr.bus as bus
+
+ LEVEL_NAME = "tmp_level"
+ ASSET_1 = os.path.join("scriptcanvas", "ScriptCanvas_TwoComponents0.scriptcanvas")
+ ASSET_2 = os.path.join("scriptcanvas", "ScriptCanvas_TwoComponents1.scriptcanvas")
+ WAIT_TIME = 3.0 # SECONDS
+
+ def get_asset(asset_path):
+ return asset.AssetCatalogRequestBus(bus.Broadcast, "GetAssetIdByPath", asset_path, math.Uuid(), False)
+
+ def locate_expected_lines():
+ found_lines = []
+ for printInfo in section_tracer.prints:
+ found_lines.append(printInfo.message.strip())
+
+ return all(line in found_lines for line in LogLines.expected_lines)
+
+ # 1) Create level
+ general.idle_enable(True)
+ result = general.create_level_no_prompt(LEVEL_NAME, 128, 1, 512, True)
+ Report.critical_result(Tests.level_created, result == 0)
+ helper.wait_for_condition(lambda: general.get_current_level_name() == LEVEL_NAME, WAIT_TIME)
+ general.close_pane("Error Report")
+
+ # 2) Create entity with SC components
+ position = math.Vector3(512.0, 512.0, 32.0)
+ test_entity = hydra.Entity("test_entity")
+ test_entity.create_entity(position, ["Script Canvas", "Script Canvas"])
+ test_entity.get_set_test(0, "Script Canvas Asset|Script Canvas Asset", get_asset(ASSET_1))
+ test_entity.get_set_test(1, "Script Canvas Asset|Script Canvas Asset", get_asset(ASSET_2))
+
+ # 3) Start Tracer
+ with Tracer() as section_tracer:
+
+ # 4) Enter game mode
+ helper.enter_game_mode(Tests.game_mode_entered)
+
+ # 5) Wait for expected lines to be found
+ helper.wait_for_condition(locate_expected_lines, WAIT_TIME)
+
+ # 6) Report if expected lines were found
+ Report.result(Tests.found_lines, locate_expected_lines())
+
+ # 7) Exit game mode
+ helper.exit_game_mode(Tests.game_mode_exited)
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+
+ from utils import Report
+
+ Report.start_test(ScriptCanvas_TwoComponents)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/ScriptCanvas_TwoEntities.py b/AutomatedTesting/Gem/PythonTests/scripting/ScriptCanvas_TwoEntities.py
new file mode 100644
index 0000000000..401e6c0271
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/ScriptCanvas_TwoEntities.py
@@ -0,0 +1,107 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+Test case ID: T92563191
+Test Case Title: Two Entities can use the same Graph asset successfully at RunTime
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92563191
+"""
+
+
+# fmt: off
+class Tests():
+ level_created = ("New level created", "New level not created")
+ game_mode_entered = ("Game Mode successfully entered", "Game mode failed to enter")
+ game_mode_exited = ("Game Mode successfully exited", "Game mode failed to exited")
+ found_lines = ("Expected log lines were found", "Expected log lines were not found")
+# fmt: on
+
+
+def ScriptCanvas_TwoEntities():
+ """
+ Summary:
+ Two Entities can use the same Graph asset successfully at RunTime. The script canvas asset
+ attached to the enties will print the respective entity names.
+
+ Expected Behavior:
+ When game mode is entered, respective strings of different entities should be printed.
+
+ Test Steps:
+ 1) Create temp level
+ 2) Create two new entities with different names
+ 3) Set ScriptCanvas asset to both the entities
+ 4) Enter/Exit game mode and verify log lines
+
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ import os
+
+ from utils import TestHelper as helper
+ from utils import Tracer
+ import hydra_editor_utils as hydra
+ import azlmbr.legacy.general as general
+ import azlmbr.math as math
+ import azlmbr.asset as asset
+ import azlmbr.bus as bus
+
+ LEVEL_NAME = "tmp_level"
+ ASSET_PATH = os.path.join("scriptcanvas", "T92563191_test.scriptcanvas")
+ EXPECTED_LINES = ["Entity Name: test_entity_1", "Entity Name: test_entity_2"]
+ WAIT_TIME = 0.5 # SECONDS
+
+ def get_asset(asset_path):
+ return asset.AssetCatalogRequestBus(bus.Broadcast, "GetAssetIdByPath", asset_path, math.Uuid(), False)
+
+ # 1) Create temp level
+ general.idle_enable(True)
+ result = general.create_level_no_prompt(LEVEL_NAME, 128, 1, 512, True)
+ Report.critical_result(Tests.level_created, result == 0)
+ helper.wait_for_condition(lambda: general.get_current_level_name() == LEVEL_NAME, WAIT_TIME)
+ general.close_pane("Error Report")
+
+ # 2) Create two new entities with different names
+ position = math.Vector3(512.0, 512.0, 32.0)
+ test_entity_1 = hydra.Entity("test_entity_1")
+ test_entity_1.create_entity(position, ["Script Canvas"])
+
+ test_entity_2 = hydra.Entity("test_entity_2")
+ test_entity_2.create_entity(position, ["Script Canvas"])
+
+ # 3) Set ScriptCanvas asset to both the entities
+ test_entity_1.get_set_test(0, "Script Canvas Asset|Script Canvas Asset", get_asset(ASSET_PATH))
+ test_entity_2.get_set_test(0, "Script Canvas Asset|Script Canvas Asset", get_asset(ASSET_PATH))
+
+ # 4) Enter/Exit game mode and verify log lines
+ with Tracer() as section_tracer:
+
+ helper.enter_game_mode(Tests.game_mode_entered)
+ # wait for WAIT_TIME to let the script print strings
+ general.idle_wait(WAIT_TIME)
+ helper.exit_game_mode(Tests.game_mode_exited)
+
+ found_lines = [printInfo.message.strip() for printInfo in section_tracer.prints]
+ result = all(line in found_lines for line in EXPECTED_LINES)
+
+ Report.result(Tests.found_lines, result)
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+ from utils import Report
+
+ Report.start_test(ScriptCanvas_TwoEntities)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/ScriptEvents_SendReceiveAcrossMultiple.py b/AutomatedTesting/Gem/PythonTests/scripting/ScriptEvents_SendReceiveAcrossMultiple.py
new file mode 100644
index 0000000000..d671229cdf
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/ScriptEvents_SendReceiveAcrossMultiple.py
@@ -0,0 +1,120 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+Test case ID: T92567321
+Test Case Title: Script Events: Can send and receive a script event across multiple entities successfully
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92567321
+"""
+
+
+# fmt: off
+class Tests():
+ level_created = ("Successfully created temporary level", "Failed to create temporary level")
+ entitya_created = ("Successfully created EntityA", "Failed to create EntityA")
+ entityb_created = ("Successfully created EntityB", "Failed to create EntityB")
+ enter_game_mode = ("Successfully entered game mode", "Failed to enter game mode")
+ lines_found = ("Successfully found expected message", "Failed to find expected message")
+ exit_game_mode = ("Successfully exited game mode", "Failed to exit game mode")
+# fmt: on
+
+
+def ScriptEvents_SendReceiveAcrossMultiple():
+ """
+ Summary:
+ EntityA and EntityB will be created in a level. Attached to both will be a Script Canvas component. The Script Event created for the test will be sent from EntityA to EntityB.
+
+ Expected Behavior:
+ The output of the Script Event should be printed to the console
+
+ Test Steps:
+ 1) Create test level
+ 2) Create EntityA/EntityB (add scriptcanvas files part of entity setup)
+ 3) Start Tracer
+ 4) Enter Game Mode
+ 5) Read for line
+ 6) Exit Game Mode
+
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+ import os
+
+ from editor_entity_utils import EditorEntity as Entity
+ from utils import Report
+ from utils import TestHelper as helper
+ from utils import Tracer
+
+ import azlmbr.legacy.general as general
+
+ LEVEL_NAME = "tmp_level"
+ WAIT_TIME = 3.0
+ ASSET_PREFIX = "T92567321"
+ asset_paths = {
+ "event": os.path.join("TestAssets", f"{ASSET_PREFIX}.scriptevents"),
+ "assetA": os.path.join("ScriptCanvas", f"{ASSET_PREFIX}A.scriptcanvas"),
+ "assetB": os.path.join("ScriptCanvas", f"{ASSET_PREFIX}B.scriptcanvas"),
+ }
+ sc_for_entities = {
+ "EntityA": asset_paths["assetA"],
+ "EntityB": asset_paths["assetB"]
+ }
+ EXPECTED_LINES = ["Incoming Message Received"]
+
+ def get_asset(asset_path):
+ return azlmbr.asset.AssetCatalogRequestBus(azlmbr.bus.Broadcast, "GetAssetIdByPath", asset_path, azlmbr.math.Uuid(), False)
+
+ def create_editor_entity(name, sc_asset):
+ entity = Entity.create_editor_entity(name)
+ sc_comp = entity.add_component("Script Canvas")
+ sc_comp.set_component_property_value("Script Canvas Asset|Script Canvas Asset", get_asset(sc_asset))
+ Report.critical_result(Tests.__dict__[name.lower()+"_created"], entity.id.isValid())
+
+ def locate_expected_lines(line_list: list):
+ found_lines = [printInfo.message.strip() for printInfo in section_tracer.prints]
+
+ return all(line in found_lines for line in line_list)
+
+ # 1) Create temp level
+ general.idle_enable(True)
+ result = general.create_level_no_prompt(LEVEL_NAME, 128, 1, 512, True)
+ Report.critical_result(Tests.level_created, result == 0)
+ helper.wait_for_condition(lambda: general.get_current_level_name() == LEVEL_NAME, WAIT_TIME)
+ general.close_pane("Error Report")
+
+ # 2) Create EntityA/EntityB
+ for key in sc_for_entities.keys():
+ create_editor_entity(key, sc_for_entities[key])
+
+ # 3) Start Tracer
+ with Tracer() as section_tracer:
+
+ # 4) Enter Game Mode
+ helper.enter_game_mode(Tests.enter_game_mode)
+
+ # 5) Read for line
+ lines_located = helper.wait_for_condition(lambda: locate_expected_lines(EXPECTED_LINES), WAIT_TIME)
+ Report.result(Tests.lines_found, lines_located)
+
+ # 6) Exit Game Mode
+ helper.exit_game_mode(Tests.exit_game_mode)
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+ imports.init()
+
+ from utils import Report
+
+ Report.start_test(ScriptEvents_SendReceiveAcrossMultiple)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/ScriptEvents_SendReceiveSuccessfully.py b/AutomatedTesting/Gem/PythonTests/scripting/ScriptEvents_SendReceiveSuccessfully.py
new file mode 100644
index 0000000000..b5e26d14ae
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/ScriptEvents_SendReceiveSuccessfully.py
@@ -0,0 +1,110 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+Test case ID: T92567320
+Test Case Title: Script Events: Can send and receive a script event successfully
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92567320
+"""
+
+
+# fmt: off
+class Tests():
+ level_created = ("Successfully created temporary level", "Failed to create temporary level")
+ entity_created = ("Successfully created test entity", "Failed to create test entity")
+ enter_game_mode = ("Successfully entered game mode", "Failed to enter game mode")
+ lines_found = ("Successfully found expected message", "Failed to find expected message")
+ exit_game_mode = ("Successfully exited game mode", "Failed to exit game mode")
+# fmt: on
+
+
+def ScriptEvents_SendReceiveSuccessfully():
+ """
+ Summary:
+ An entity exists in the level that contains a Script Canvas component. In the graph is both a Send Event
+ and a Receive Event.
+
+ Expected Behavior:
+ After entering game mode the graph on the entity should print an expected message to the console
+
+ Test Steps:
+ 1) Create test level
+ 2) Create test entity
+ 3) Start Tracer
+ 4) Enter Game Mode
+ 5) Read for line
+ 6) Exit Game Mode
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+ import os
+ from editor_entity_utils import EditorEntity as Entity
+ from utils import Report
+ from utils import TestHelper as helper
+ from utils import Tracer
+
+ import azlmbr.legacy.general as general
+ import azlmbr.asset as asset
+ import azlmbr.math as math
+ import azlmbr.bus as bus
+
+ LEVEL_NAME = "tmp_level"
+ WAIT_TIME = 3.0 # SECONDS
+ EXPECTED_LINES = ["T92567320: Message Received"]
+ SC_ASSET_PATH = os.path.join("ScriptCanvas", "T92567320.scriptcanvas")
+
+ def create_editor_entity(name, sc_asset):
+ entity = Entity.create_editor_entity(name)
+ sc_comp = entity.add_component("Script Canvas")
+ asset_id = asset.AssetCatalogRequestBus(bus.Broadcast, "GetAssetIdByPath", sc_asset, math.Uuid(), False)
+ sc_comp.set_component_property_value("Script Canvas Asset|Script Canvas Asset", asset_id)
+ Report.critical_result(Tests.entity_created, entity.id.isValid())
+
+ def locate_expected_lines(line_list: list):
+ found_lines = [printInfo.message.strip() for printInfo in section_tracer.prints]
+
+ return all(line in found_lines for line in line_list)
+
+ # 1) Create temp level
+ general.idle_enable(True)
+ result = general.create_level_no_prompt(LEVEL_NAME, 128, 1, 512, True)
+ Report.critical_result(Tests.level_created, result == 0)
+ helper.wait_for_condition(lambda: general.get_current_level_name() == LEVEL_NAME, WAIT_TIME)
+ general.close_pane("Error Report")
+
+ # 2) Create test entity
+ create_editor_entity("TestEntity", SC_ASSET_PATH)
+
+ # 3) Start Tracer
+ with Tracer() as section_tracer:
+
+ # 4) Enter Game Mode
+ helper.enter_game_mode(Tests.enter_game_mode)
+
+ # 5) Read for line
+ lines_located = helper.wait_for_condition(lambda: locate_expected_lines(EXPECTED_LINES), WAIT_TIME)
+ Report.result(Tests.lines_found, lines_located)
+
+ # 6) Exit Game Mode
+ helper.exit_game_mode(Tests.exit_game_mode)
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+
+ from utils import Report
+
+ Report.start_test(ScriptEvents_SendReceiveSuccessfully)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/TestSuite_Active.py b/AutomatedTesting/Gem/PythonTests/scripting/TestSuite_Active.py
index 8c34f29ebf..d87f2986bf 100755
--- a/AutomatedTesting/Gem/PythonTests/scripting/TestSuite_Active.py
+++ b/AutomatedTesting/Gem/PythonTests/scripting/TestSuite_Active.py
@@ -12,22 +12,243 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
import pytest
import os
import sys
+sys.path.append(os.path.dirname(__file__))
+import ImportPathHelper as imports
+imports.init()
+
+import hydra_test_utils as hydra
+import ly_test_tools.environment.file_system as file_system
from ly_test_tools import LAUNCHERS
+from base import TestAutomationBase
-sys.path.append(os.path.dirname(os.path.abspath(__file__)) + '/../automatedtesting_shared')
+TEST_DIRECTORY = os.path.dirname(__file__)
-from base import TestAutomationBase
@pytest.mark.SUITE_periodic
@pytest.mark.parametrize("launcher_platform", ['windows_editor'])
@pytest.mark.parametrize("project", ["AutomatedTesting"])
class TestAutomation(TestAutomationBase):
-
+ @pytest.mark.test_case_id("C1702834", "C1702823")
+ def test_Opening_Closing_Pane(self, request, workspace, editor, launcher_platform):
+ from . import Opening_Closing_Pane as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("C1702824")
def test_Docking_Pane(self, request, workspace, editor, launcher_platform):
from . import Docking_Pane as test_module
self._run_test(request, workspace, editor, test_module)
+ @pytest.mark.test_case_id("C1702829")
def test_Resizing_Pane(self, request, workspace, editor, launcher_platform):
from . import Resizing_Pane as test_module
self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92563190")
+ @pytest.mark.parametrize("level", ["tmp_level"])
+ def test_ScriptCanvas_TwoComponents(self, request, workspace, editor, launcher_platform, level):
+ def teardown():
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ request.addfinalizer(teardown)
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ from . import ScriptCanvas_TwoComponents as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92562986")
+ @pytest.mark.parametrize("level", ["tmp_level"])
+ def test_ScriptCanvas_ChangingAssets(self, request, workspace, editor, launcher_platform, project, level):
+ def teardown():
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ request.addfinalizer(teardown)
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ from . import ScriptCanvas_ChangingAssets as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92569079", "T92569081")
+ def test_Graph_ZoomInZoomOut(self, request, workspace, editor, launcher_platform):
+ from . import Graph_ZoomInZoomOut as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92568940")
+ def test_NodePalette_SelectNode(self, request, workspace, editor, launcher_platform):
+ from . import NodePalette_SelectNode as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92569253")
+ @pytest.mark.test_case_id("T92569254")
+ @pytest.mark.parametrize("level", ["tmp_level"])
+ def test_OnEntityActivatedDeactivated_PrintMessage(self, request, workspace, editor, launcher_platform, project, level):
+ def teardown():
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ request.addfinalizer(teardown)
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ from . import OnEntityActivatedDeactivated_PrintMessage as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92562993")
+ def test_NodePalette_ClearSelection(self, request, workspace, editor, launcher_platform, project):
+ from . import NodePalette_ClearSelection as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92563191")
+ @pytest.mark.parametrize("level", ["tmp_level"])
+ def test_ScriptCanvas_TwoEntities(self, request, workspace, editor, launcher_platform, project, level):
+ def teardown():
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ request.addfinalizer(teardown)
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ from . import ScriptCanvas_TwoEntities as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92569013")
+ def test_AssetEditor_CreateScriptEventFile(self, request, workspace, editor, launcher_platform, project):
+ def teardown():
+ file_system.delete(
+ [os.path.join(workspace.paths.project(), "ScriptCanvas", "test_file.scriptevent")], True, True
+ )
+ request.addfinalizer(teardown)
+ file_system.delete(
+ [os.path.join(workspace.paths.project(), "ScriptCanvas", "test_file.scriptevent")], True, True
+ )
+ from . import AssetEditor_CreateScriptEventFile as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92569165", "T92569167", "T92569168", "T92569170")
+ def test_Toggle_ScriptCanvasTools(self, request, workspace, editor, launcher_platform):
+ from . import Toggle_ScriptCanvasTools as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92568982")
+ def test_NodeInspector_RenameVariable(self, request, workspace, editor, launcher_platform, project):
+ from . import NodeInspector_RenameVariable as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92569137")
+ def test_Debugging_TargetMultipleGraphs(self, request, workspace, editor, launcher_platform, project):
+ from . import Debugging_TargetMultipleGraphs as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92568856")
+ @pytest.mark.parametrize("level", ["tmp_level"])
+ def test_Debugging_TargetMultipleEntities(self, request, workspace, editor, launcher_platform, project, level):
+ def teardown():
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ request.addfinalizer(teardown)
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ from . import Debugging_TargetMultipleEntities as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92569049", "T92569051")
+ def test_EditMenu_UndoRedo(self, request, workspace, editor, launcher_platform, project):
+ from . import EditMenu_UndoRedo as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("C1702825", "C1702831")
+ def test_UnDockedPane_CloseSCWindow(self, request, workspace, editor, launcher_platform):
+ from . import UnDockedPane_CloseSCWindow as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92562978")
+ @pytest.mark.parametrize("level", ["tmp_level"])
+ def test_Entity_AddScriptCanvasComponent(self, request, workspace, editor, launcher_platform, project, level):
+ def teardown():
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ request.addfinalizer(teardown)
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ from . import Entity_AddScriptCanvasComponent as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("C1702821", "C1702832")
+ def test_Pane_RetainOnSCRestart(self, request, workspace, editor, launcher_platform):
+ from . import Pane_RetainOnSCRestart as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92567321")
+ @pytest.mark.parametrize("level", ["tmp_level"])
+ def test_ScriptEvents_SendReceiveAcrossMultiple(self, request, workspace, editor, launcher_platform, project, level):
+ def teardown():
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ request.addfinalizer(teardown)
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ from . import ScriptEvents_SendReceiveAcrossMultiple as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+ @pytest.mark.test_case_id("T92567320")
+ @pytest.mark.parametrize("level", ["tmp_level"])
+ def test_ScriptEvents_SendReceiveSuccessfully(self, request, workspace, editor, launcher_platform, project, level):
+ def teardown():
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ request.addfinalizer(teardown)
+ file_system.delete([os.path.join(workspace.paths.project(), "Levels", level)], True, True)
+ from . import ScriptEvents_SendReceiveSuccessfully as test_module
+ self._run_test(request, workspace, editor, test_module)
+
+# NOTE: We had to use hydra_test_utils.py, as TestAutomationBase run_test method
+# fails because of pyside_utils import
+@pytest.mark.SUITE_periodic
+@pytest.mark.parametrize("launcher_platform", ["windows_editor"])
+@pytest.mark.parametrize("project", ["AutomatedTesting"])
+class TestScriptCanvasTests(object):
+ """
+ The following tests use hydra_test_utils.py to launch the editor and validate the results.
+ """
+
+ @pytest.mark.test_case_id("T92569037", "T92569039")
+ def test_FileMenu_New_Open(self, request, editor, launcher_platform):
+ expected_lines = [
+ "File->New action working as expected: True",
+ "File->Open action working as expected: True",
+ ]
+ hydra.launch_and_validate_results(
+ request, TEST_DIRECTORY, editor, "FileMenu_New_Open.py", expected_lines, auto_test_mode=False, timeout=60,
+ )
+
+ @pytest.mark.test_case_id("T92568942")
+ def test_AssetEditor_NewScriptEvent(self, request, editor, launcher_platform):
+ expected_lines = [
+ "New Script event action found: True",
+ "Asset Editor opened: True",
+ "Asset Editor created with new asset: True",
+ "New Script event created in Asset Editor: True",
+ ]
+ hydra.launch_and_validate_results(
+ request,
+ TEST_DIRECTORY,
+ editor,
+ "AssetEditor_NewScriptEvent.py",
+ expected_lines,
+ auto_test_mode=False,
+ timeout=60,
+ )
+
+ @pytest.mark.test_case_id("T92563068", "T92563070")
+ def test_GraphClose_SavePrompt(self, request, editor, launcher_platform):
+ expected_lines = [
+ "New graph created: True",
+ "Save prompt opened as expected: True",
+ "Close button worked as expected: True",
+ ]
+ hydra.launch_and_validate_results(
+ request,
+ TEST_DIRECTORY,
+ editor,
+ "GraphClose_SavePrompt.py",
+ expected_lines,
+ auto_test_mode=False,
+ timeout=60,
+ )
+
+ @pytest.mark.test_case_id("T92564789", "T92568873")
+ def test_VariableManager_CreateDeleteVars(self, request, editor, launcher_platform):
+ var_types = ["Boolean", "Color", "EntityID", "Number", "String", "Transform", "Vector2", "Vector3", "Vector4"]
+ expected_lines = [f"Success: {var_type} variable is created" for var_type in var_types]
+ expected_lines.extend([f"Success: {var_type} variable is deleted" for var_type in var_types])
+ hydra.launch_and_validate_results(
+ request,
+ TEST_DIRECTORY,
+ editor,
+ "VariableManager_CreateDeleteVars.py",
+ expected_lines,
+ auto_test_mode=False,
+ timeout=60,
+ )
\ No newline at end of file
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/Toggle_ScriptCanvasTools.py b/AutomatedTesting/Gem/PythonTests/scripting/Toggle_ScriptCanvasTools.py
new file mode 100644
index 0000000000..4024e28277
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/Toggle_ScriptCanvasTools.py
@@ -0,0 +1,137 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+Test case ID: C92569165, C92569167, C92569168, C92569170
+Test Case Title: Tools > Node Palette toggles the Node Palette
+ Tools > Node Inspector toggles the Node Inspector
+ Tools > Bookmarks toggles the Bookmarks
+ Tools > Variable Manager toggles the Variable Manager
+
+URLs of the test case: https://testrail.agscollab.com/index.php?/cases/view/92569165
+ https://testrail.agscollab.com/index.php?/cases/view/92569167
+ https://testrail.agscollab.com/index.php?/cases/view/92569168
+ https://testrail.agscollab.com/index.php?/cases/view/92569170
+"""
+
+
+# fmt: off
+class Tests():
+ node_palette_opened = ("NodePalette is opened successfully", "Failed to open NodePalette")
+ node_inspector_opened = ("NodeInspector is opened successfully", "Failed to open NodeInspector")
+ bookmark_opened = ("Bookmarks is opened successfully", "Failed to open Bookmarks")
+ variable_manager_opened = ("VariableManager is opened successfully", "Failed to open VariableManager")
+ node_palette_closed_by_start = ("NodePalette is closed successfully", "Failed to close NodePalette")
+ node_inspector_closed_by_start = ("NodeInspector is closed successfully", "Failed to close NodeInspector")
+ bookmark_closed_by_start = ("Bookmarks is closed successfully", "Failed to close Bookmarks")
+ variable_manager_closed_by_start = ("VariableManager is closed successfully", "Failed to close VariableManager")
+ node_palette_closed_by_end = ("NodePalette is closed successfully", "Failed to close NodePalette")
+ node_inspector_closed_by_end = ("NodeInspector is closed successfully", "Failed to close NodeInspector")
+ bookmark_closed_by_end = ("Bookmarks is closed successfully", "Failed to close Bookmarks")
+ variable_manager_closed_by_end = ("VariableManager is closed successfully", "Failed to close VariableManager")
+# fmt: on
+
+
+def Toggle_ScriptCanvasTools():
+ """
+ Summary:
+ Toggle Node Palette, Node Inspector, Bookmarks and Variable Manager in Script Canvas.
+ Make sure each pane opens and closes successfully.
+
+ Expected Behavior:
+ Each pane opens and closes successfully.
+
+ Test Steps:
+ 1) Open Script Canvas window (Tools > Script Canvas)
+ 2) Make sure Node Palette, Node Inspector, Bookmarks and Variable Manager panes are closed in Script Canvas window
+ 3) Open Node Palette, Node Inspector, Bookmarks and Variable Manager in Script Canvas window
+ 4) Close Node Palette, Node Inspector, Bookmarks and Variable Manager in Script Canvas window
+ 5) Restore default layout
+ 6) Close Script Canvas window
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ from utils import Report
+ from utils import TestHelper as helper
+ import pyside_utils
+
+ # Open 3D Engine imports
+ import azlmbr.legacy.general as general
+
+ # Pyside imports
+ from PySide2 import QtWidgets
+
+ def click_menu_option(window, option_text):
+ action = pyside_utils.find_child_by_pattern(window, {"text": option_text, "type": QtWidgets.QAction})
+ action.trigger()
+
+ def find_pane(window, pane_name):
+ return window.findChild(QtWidgets.QDockWidget, pane_name)
+
+ def close_tool(window, pane_widget, test_tuple):
+ pane = find_pane(window, pane_widget)
+ pane.close()
+ Report.result(test_tuple, not pane.isVisible())
+
+ def open_tool(window, pane_widget, tool, test_tuple):
+ pane = find_pane(window, pane_widget)
+ if not pane.isVisible():
+ click_menu_option(window, tool)
+ pane = find_pane(window, pane_widget)
+ Report.result(test_tuple, pane.isVisible())
+
+ # Test starts here
+ general.idle_enable(True)
+
+ # 1) Open Script Canvas window (Tools > Script Canvas)
+ general.open_pane("Script Canvas")
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
+
+ # 2) Make sure Node Palette, Node Inspector, Bookmarks and Variable Manager panes are closed in Script Canvas window
+ editor_window = pyside_utils.get_editor_main_window()
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+ close_tool(sc, "NodePalette", Tests.node_palette_closed_by_start)
+ close_tool(sc, "NodeInspector", Tests.node_inspector_closed_by_start)
+ close_tool(sc, "BookmarkDockWidget", Tests.bookmark_closed_by_start)
+ close_tool(sc, "VariableManager", Tests.variable_manager_closed_by_start)
+
+ # 3) Open Node Palette, Node Inspector, Bookmarks and Variable Manager in Script Canvas window
+ open_tool(sc, "NodePalette", "Node Palette", Tests.node_palette_opened)
+ open_tool(sc, "NodeInspector", "Node Inspector", Tests.node_inspector_opened)
+ open_tool(sc, "BookmarkDockWidget", "Bookmarks", Tests.bookmark_opened)
+ open_tool(sc, "VariableManager", "Variable Manager", Tests.variable_manager_opened)
+
+ # 4) Close Node Palette, Node Inspector, Bookmarks and Variable Manager in Script Canvas window
+ close_tool(sc, "NodePalette", Tests.node_palette_closed_by_end)
+ close_tool(sc, "NodeInspector", Tests.node_inspector_closed_by_end)
+ close_tool(sc, "BookmarkDockWidget", Tests.bookmark_closed_by_end)
+ close_tool(sc, "VariableManager", Tests.variable_manager_closed_by_end)
+
+ # 5) Restore default layout
+ # Need this step to restore to default in case of test failure
+ click_menu_option(sc, "Restore Default Layout")
+
+ # 6) Close Script Canvas window
+ sc.close()
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+
+ from utils import Report
+
+ Report.start_test(Toggle_ScriptCanvasTools)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/UnDockedPane_CloseSCWindow.py b/AutomatedTesting/Gem/PythonTests/scripting/UnDockedPane_CloseSCWindow.py
new file mode 100644
index 0000000000..875f28ec95
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/UnDockedPane_CloseSCWindow.py
@@ -0,0 +1,128 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+Test case ID: C1702825 // C1702831
+Test Case Title: Undocking // Closing script canvas with the pane floating
+URLs of the test case: https://testrail.agscollab.com/index.php?/cases/view/1702825 &
+ https://testrail.agscollab.com/index.php?/cases/view/1702831
+"""
+
+
+# fmt: off
+class Tests():
+ undock_pane = ("Pane is undocked successfully", "Failed to undock pane")
+ close_sc_window = ("Script Canvas window is closed", "Failed to close Script Canvas window")
+ pane_closed = ("Pane is closed successfully", "Failed to close the pane")
+# fmt: on
+
+
+def UnDockedPane_CloseSCWindow():
+ """
+ Summary:
+ The Script Canvas window is opened with one of the pane undocked.
+ Verify if undocked pane closes upon closing Script canvas window.
+
+ Expected Behavior:
+ The undocked pane closes when Script Canvas window closed.
+
+ Test Steps:
+ 1) Open Script Canvas window (Tools > Script Canvas)
+ 2) Undock Node Palette pane
+ 3) Connect to Pane visibility signal emitter to verify pane closed
+ 4) Close Script Canvas window
+ 5) Restore default layout
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ # Helper imports
+ from utils import Report
+ from utils import TestHelper as helper
+ import pyside_utils
+
+ # Open 3D Engine imports
+ import azlmbr.legacy.general as general
+
+ # Pyside imports
+ from PySide2 import QtWidgets
+
+ TEST_PANE = "NodePalette" # Chosen most commonly used pane
+
+ def click_menu_option(window, option_text):
+ action = pyside_utils.find_child_by_pattern(window, {"text": option_text, "type": QtWidgets.QAction})
+ action.trigger()
+
+ def find_pane(window, pane_name):
+ return window.findChild(QtWidgets.QDockWidget, pane_name)
+
+ def on_top_level_changed():
+ # This function has test condition always True since it gets emitted only when condition satisfied
+ Report.result(Tests.undock_pane, True)
+
+ def on_pane_closed():
+ # This function has test condition always True since it gets emitted only when condition satisfied
+ Report.result(Tests.pane_closed, True)
+
+ # Test starts here
+ general.idle_enable(True)
+
+ # 1) Open Script Canvas window (Tools > Script Canvas)
+ general.open_pane("Script Canvas")
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
+
+ # 2) Undock Node Palette pane
+ # Make sure Node Palette pane is opened
+ editor_window = pyside_utils.get_editor_main_window()
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+ pane = find_pane(sc, TEST_PANE)
+ if not pane.isVisible():
+ click_menu_option(sc, "Node Palette")
+ pane = find_pane(sc, TEST_PANE) # New reference
+
+ # We drag/drop pane over the graph since it doesn't allow docking, so this will undock it
+ try:
+ graph = find_pane(sc, "GraphCanvasEditorCentralWidget")
+ try:
+ pane.topLevelChanged.connect(on_top_level_changed)
+ pyside_utils.drag_and_drop(pane, graph)
+ finally:
+ pane.topLevelChanged.disconnect(on_top_level_changed)
+
+ # 3) Connect to Pane visibility signal emitter to verify pane closed
+ # No need to disconnect this since pane widget gets deleted when SC window closed
+ pane.visibilityChanged.connect(on_pane_closed)
+
+ # 4) Close Script Canvas window
+ sc.close()
+ is_sc_visible = helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 2.0)
+ Report.result(Tests.close_sc_window, not is_sc_visible)
+
+ finally:
+ # 5) Restore default layout
+ general.open_pane("Script Canvas")
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 5.0)
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+ click_menu_option(sc, "Restore Default Layout")
+ sc.close()
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+
+ from utils import Report
+
+ Report.start_test(UnDockedPane_CloseSCWindow)
diff --git a/AutomatedTesting/Gem/PythonTests/scripting/VariableManager_CreateDeleteVars.py b/AutomatedTesting/Gem/PythonTests/scripting/VariableManager_CreateDeleteVars.py
new file mode 100644
index 0000000000..6facc324d4
--- /dev/null
+++ b/AutomatedTesting/Gem/PythonTests/scripting/VariableManager_CreateDeleteVars.py
@@ -0,0 +1,123 @@
+"""
+All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
+its licensors.
+
+For complete copyright and license terms please see the LICENSE at the root of this
+distribution (the "License"). All use of this software is governed by the License,
+or, if provided, by the license below or the license accompanying this file. Do not
+remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+
+Test case ID: T92564789
+Test Case Title: Each Variable type can be created
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92564789
+Test case ID: T92568873
+Test Case Title: Each Variable type can be deleted
+URL of the test case: https://testrail.agscollab.com/index.php?/tests/view/92568873
+"""
+
+
+def VariableManager_CreateDeleteVars():
+ """
+ Summary:
+ Each variable type can be created and deleted in variable manager.
+
+ Expected Behavior:
+ Each variable type can be created and deleted in variable manager.
+
+ Test Steps:
+ 1) Open Script Canvas window (Tools > Script Canvas)
+ 2) Get the SC window object
+ 3) Open Variable Manager if not opened already
+ 4) Create Graph
+ 5) Create variable of each type and verify if it is created
+ 6) Delete each type of variable and verify if it is deleted
+ 7) Close SC window
+
+ Note:
+ - This test file must be called from the Open 3D Engine Editor command terminal
+ - Any passed and failed tests are written to the Editor.log file.
+ Parsing the file or running a log_monitor are required to observe the test results.
+
+ :return: None
+ """
+
+ from PySide2 import QtWidgets, QtCore, QtTest
+
+ from PySide2.QtCore import Qt
+
+ from utils import TestHelper as helper
+
+ import azlmbr.legacy.general as general
+
+ import pyside_utils
+
+ def generate_test_tuple(var_type, action):
+ return (f"{var_type} variable is {action}d", f"{var_type} variable is not {action}d")
+
+ # 1) Open Script Canvas window
+ general.idle_enable(True)
+ general.open_pane("Script Canvas")
+ helper.wait_for_condition(lambda: general.is_pane_visible("Script Canvas"), 10.0)
+
+ # 2) Get the SC window object
+ editor_window = pyside_utils.get_editor_main_window()
+ sc = editor_window.findChild(QtWidgets.QDockWidget, "Script Canvas")
+
+ # 3) Open Variable Manager if not opened already
+ if sc.findChild(QtWidgets.QDockWidget, "VariableManager") is None:
+ action = pyside_utils.find_child_by_pattern(sc, {"text": "Variable Manager", "type": QtWidgets.QAction})
+ action.trigger()
+ variable_manager = sc.findChild(QtWidgets.QDockWidget, "VariableManager")
+
+ # 4) Create Graph
+ action = pyside_utils.find_child_by_pattern(sc, {"objectName": "action_New_Script", "type": QtWidgets.QAction})
+ action.trigger()
+
+ graph_vars = variable_manager.findChild(QtWidgets.QTableView, "graphVariables")
+
+ var_types = ["Boolean", "Color", "EntityID", "Number", "String", "Transform", "Vector2", "Vector3", "Vector4"]
+
+ # 5) Create variable of each type and verify if it is created
+ for index, var_type in enumerate(var_types):
+ # Create new variable
+ add_button = variable_manager.findChild(QtWidgets.QPushButton, "addButton")
+ add_button.click() # Click on Create Variable button
+ # Select variable type
+ table_view = variable_manager.findChild(QtWidgets.QTableView, "variablePalette")
+ model_index = pyside_utils.find_child_by_pattern(table_view, var_type)
+ # Click on it to create variable
+ pyside_utils.item_view_index_mouse_click(table_view, model_index)
+ # Verify if the variable is created
+ # NOTE: To check if variable of a type is created, we are checking 1) rowcount
+ # 2) If we have row with variable "Variable "
+ # 3) Type of variable, which is next column of the variable name
+ result = graph_vars.model().rowCount(QtCore.QModelIndex()) == (
+ index + 1
+ ) # since we added 1 variable, rowcount will increase by 1
+ var_mi = pyside_utils.find_child_by_pattern(graph_vars, f"Variable {index+1}")
+ result = result and (var_mi is not None) and (var_mi.siblingAtColumn(1).data(Qt.DisplayRole) == var_type)
+ Report.result(generate_test_tuple(var_type, "create"), result)
+
+ # 6) Delete each type of variable and verify if it is deleted
+ for index, var_type in enumerate(var_types):
+ # Delete variable and verify if its deleted
+ # NOTE: To check if variable of a type is deleted, we are checking rowcount
+ var_mi = pyside_utils.find_child_by_pattern(graph_vars, f"Variable {index+1}")
+ pyside_utils.item_view_index_mouse_click(graph_vars, var_mi)
+ QtTest.QTest.keyClick(graph_vars, Qt.Key_Delete, Qt.NoModifier)
+ # since variable is deleted, rowcount will decrease by 1
+ result = graph_vars.model().rowCount(QtCore.QModelIndex()) == (len(var_types) - (index + 1))
+ Report.result(generate_test_tuple(var_type, "delete"), result)
+
+ # 7) Close SC window
+ general.close_pane("Script Canvas")
+
+
+if __name__ == "__main__":
+ import ImportPathHelper as imports
+
+ imports.init()
+ from utils import Report
+
+ Report.start_test(VariableManager_CreateDeleteVars)
diff --git a/AutomatedTesting/Levels/Physics/C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain/C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain.ly b/AutomatedTesting/Levels/Physics/C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain/C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain.ly
index ba141251d5..d618bf1873 100644
--- a/AutomatedTesting/Levels/Physics/C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain/C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain.ly
+++ b/AutomatedTesting/Levels/Physics/C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain/C24308873_CylinderShapeCollider_CollidesWithPhysXTerrain.ly
@@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
-oid sha256:231d5ac32c95334eeb1cbf77ea0bceae1d8010de3290dfdbd991abb46d18bae6
-size 6844
+oid sha256:83af66a6db4ff2b4df7212099b661a96668cfb326d8984e41b16506ec0062141
+size 5844
diff --git a/AutomatedTesting/Registry/C14195074_ScriptCanvas_PostUpdateEvent.setreg b/AutomatedTesting/Registry/C14195074_ScriptCanvas_PostUpdateEvent.setreg_override
similarity index 100%
rename from AutomatedTesting/Registry/C14195074_ScriptCanvas_PostUpdateEvent.setreg
rename to AutomatedTesting/Registry/C14195074_ScriptCanvas_PostUpdateEvent.setreg_override
diff --git a/AutomatedTesting/Registry/C14902097_ScriptCanvas_PreUpdateEvent.setreg b/AutomatedTesting/Registry/C14902097_ScriptCanvas_PreUpdateEvent.setreg_override
similarity index 100%
rename from AutomatedTesting/Registry/C14902097_ScriptCanvas_PreUpdateEvent.setreg
rename to AutomatedTesting/Registry/C14902097_ScriptCanvas_PreUpdateEvent.setreg_override
diff --git a/AutomatedTesting/Registry/C3510644_Collider_CollisionGroups.setreg b/AutomatedTesting/Registry/C3510644_Collider_CollisionGroups.setreg_override
similarity index 100%
rename from AutomatedTesting/Registry/C3510644_Collider_CollisionGroups.setreg
rename to AutomatedTesting/Registry/C3510644_Collider_CollisionGroups.setreg_override
diff --git a/AutomatedTesting/Registry/C4976227_Collider_NewGroup.setreg b/AutomatedTesting/Registry/C4976227_Collider_NewGroup.setreg_override
similarity index 100%
rename from AutomatedTesting/Registry/C4976227_Collider_NewGroup.setreg
rename to AutomatedTesting/Registry/C4976227_Collider_NewGroup.setreg_override
diff --git a/AutomatedTesting/Registry/C4976244_Collider_SameGroupSameLayerCollision.setreg b/AutomatedTesting/Registry/C4976244_Collider_SameGroupSameLayerCollision.setreg_override
similarity index 100%
rename from AutomatedTesting/Registry/C4976244_Collider_SameGroupSameLayerCollision.setreg
rename to AutomatedTesting/Registry/C4976244_Collider_SameGroupSameLayerCollision.setreg_override
diff --git a/AutomatedTesting/Registry/C4976245_PhysXCollider_CollisionLayerTest.setreg b/AutomatedTesting/Registry/C4976245_PhysXCollider_CollisionLayerTest.setreg_override
similarity index 100%
rename from AutomatedTesting/Registry/C4976245_PhysXCollider_CollisionLayerTest.setreg
rename to AutomatedTesting/Registry/C4976245_PhysXCollider_CollisionLayerTest.setreg_override
diff --git a/AutomatedTesting/Registry/C4982593_PhysXCollider_CollisionLayer.setreg b/AutomatedTesting/Registry/C4982593_PhysXCollider_CollisionLayer.setreg_override
similarity index 100%
rename from AutomatedTesting/Registry/C4982593_PhysXCollider_CollisionLayer.setreg
rename to AutomatedTesting/Registry/C4982593_PhysXCollider_CollisionLayer.setreg_override
diff --git a/AutomatedTesting/Registry/assets_scan_folders.setreg b/AutomatedTesting/Registry/assets_scan_folders.setreg
index 5394d381a3..91061f3337 100644
--- a/AutomatedTesting/Registry/assets_scan_folders.setreg
+++ b/AutomatedTesting/Registry/assets_scan_folders.setreg
@@ -38,6 +38,13 @@
"Gems/PrimitiveAssets"
]
},
+ "MaterialEditor":
+ {
+ "SourcePaths":
+ [
+ "Gems/Atom/Tools/MaterialEditor"
+ ]
+ },
"UiBasics":
{
"SourcePaths":
diff --git a/AutomatedTesting/ScriptCanvas/OnEntityActivatedScripts/activator.scriptcanvas b/AutomatedTesting/ScriptCanvas/OnEntityActivatedScripts/activator.scriptcanvas
new file mode 100644
index 0000000000..89d86f0d54
--- /dev/null
+++ b/AutomatedTesting/ScriptCanvas/OnEntityActivatedScripts/activator.scriptcanvas
@@ -0,0 +1,778 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/AutomatedTesting/ScriptCanvas/OnEntityActivatedScripts/controller.scriptcanvas b/AutomatedTesting/ScriptCanvas/OnEntityActivatedScripts/controller.scriptcanvas
new file mode 100644
index 0000000000..83a899798e
--- /dev/null
+++ b/AutomatedTesting/ScriptCanvas/OnEntityActivatedScripts/controller.scriptcanvas
@@ -0,0 +1,1865 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/AutomatedTesting/ScriptCanvas/OnEntityActivatedScripts/deactivator.scriptcanvas b/AutomatedTesting/ScriptCanvas/OnEntityActivatedScripts/deactivator.scriptcanvas
new file mode 100644
index 0000000000..ca98ee303a
--- /dev/null
+++ b/AutomatedTesting/ScriptCanvas/OnEntityActivatedScripts/deactivator.scriptcanvas
@@ -0,0 +1,766 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/AutomatedTesting/ScriptCanvas/ScriptCanvas_TwoComponents0.scriptcanvas b/AutomatedTesting/ScriptCanvas/ScriptCanvas_TwoComponents0.scriptcanvas
new file mode 100644
index 0000000000..af3afead19
--- /dev/null
+++ b/AutomatedTesting/ScriptCanvas/ScriptCanvas_TwoComponents0.scriptcanvas
@@ -0,0 +1,365 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/AutomatedTesting/ScriptCanvas/ScriptCanvas_TwoComponents1.scriptcanvas b/AutomatedTesting/ScriptCanvas/ScriptCanvas_TwoComponents1.scriptcanvas
new file mode 100644
index 0000000000..0a16717520
--- /dev/null
+++ b/AutomatedTesting/ScriptCanvas/ScriptCanvas_TwoComponents1.scriptcanvas
@@ -0,0 +1,365 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/AutomatedTesting/ScriptCanvas/T92563191_test.scriptcanvas b/AutomatedTesting/ScriptCanvas/T92563191_test.scriptcanvas
new file mode 100644
index 0000000000..f0797739a5
--- /dev/null
+++ b/AutomatedTesting/ScriptCanvas/T92563191_test.scriptcanvas
@@ -0,0 +1,750 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/AutomatedTesting/ScriptCanvas/T92567320.scriptcanvas b/AutomatedTesting/ScriptCanvas/T92567320.scriptcanvas
new file mode 100644
index 0000000000..d509442435
--- /dev/null
+++ b/AutomatedTesting/ScriptCanvas/T92567320.scriptcanvas
@@ -0,0 +1,1266 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/AutomatedTesting/ScriptCanvas/T92567321A.scriptcanvas b/AutomatedTesting/ScriptCanvas/T92567321A.scriptcanvas
new file mode 100644
index 0000000000..644a5daa17
--- /dev/null
+++ b/AutomatedTesting/ScriptCanvas/T92567321A.scriptcanvas
@@ -0,0 +1,778 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/AutomatedTesting/ScriptCanvas/T92567321B.scriptcanvas b/AutomatedTesting/ScriptCanvas/T92567321B.scriptcanvas
new file mode 100644
index 0000000000..54c83c2933
--- /dev/null
+++ b/AutomatedTesting/ScriptCanvas/T92567321B.scriptcanvas
@@ -0,0 +1,880 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/AutomatedTesting/ShaderLib/raytracingscenesrg.srgi b/AutomatedTesting/ShaderLib/raytracingscenesrg.srgi
deleted file mode 100644
index ac1d663bb8..0000000000
--- a/AutomatedTesting/ShaderLib/raytracingscenesrg.srgi
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
-* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
-* its licensors.
-*
-* For complete copyright and license terms please see the LICENSE at the root of this
-* distribution (the "License"). All use of this software is governed by the License,
-* or, if provided, by the license below or the license accompanying this file. Do not
-* remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-*
-*/
-
-#pragma once
-
-// Please read README.md for an explanation on why scenesrg.srgi and viewsrg.srgi are
-// located in this folder (And how you can optionally customize your own scenesrg.srgi
-// and viewsrg.srgi in your game project).
-
-#include
-
-partial ShaderResourceGroup RayTracingSceneSrg : SRG_RayTracingScene
-{
-/* Intentionally Empty. Helps define the SrgSemantic for RayTracingSceneSrg once.*/
-};
-
-#define AZ_COLLECTING_PARTIAL_SRGS
-#include
-#undef AZ_COLLECTING_PARTIAL_SRGS
diff --git a/AutomatedTesting/TestAssets/T92567320.scriptevents b/AutomatedTesting/TestAssets/T92567320.scriptevents
new file mode 100644
index 0000000000..63cf20f2d0
--- /dev/null
+++ b/AutomatedTesting/TestAssets/T92567320.scriptevents
@@ -0,0 +1,116 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/AutomatedTesting/TestAssets/T92567321.scriptevents b/AutomatedTesting/TestAssets/T92567321.scriptevents
new file mode 100644
index 0000000000..6f9308ad02
--- /dev/null
+++ b/AutomatedTesting/TestAssets/T92567321.scriptevents
@@ -0,0 +1,166 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/CMakeLists.txt b/CMakeLists.txt
index cefbcf2ef4..ae8a7a05f8 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -75,7 +75,9 @@ foreach(restricted_platform ${PAL_RESTRICTED_PLATFORMS})
endif()
endforeach()
-add_subdirectory(scripts)
+if(NOT INSTALLED_ENGINE)
+ add_subdirectory(scripts)
+endif()
# SPEC-1417 will investigate and fix this
if(NOT PAL_PLATFORM_NAME STREQUAL "Mac")
@@ -125,5 +127,5 @@ if(NOT INSTALLED_ENGINE)
ly_setup_o3de_install()
# IMPORTANT: must be included last
- include(cmake/CPack.cmake)
+ include(cmake/Packaging.cmake)
endif()
diff --git a/Code/CryEngine/CMakeLists.txt b/Code/CryEngine/CMakeLists.txt
index 38fcbf4a27..96f6427268 100644
--- a/Code/CryEngine/CMakeLists.txt
+++ b/Code/CryEngine/CMakeLists.txt
@@ -10,5 +10,4 @@
#
add_subdirectory(CryCommon)
-add_subdirectory(CryFont)
add_subdirectory(CrySystem)
diff --git a/Code/CryEngine/CryCommon/CREVolumeObject.h b/Code/CryEngine/CryCommon/CREVolumeObject.h
index d84c7b3e50..2137053a8e 100644
--- a/Code/CryEngine/CryCommon/CREVolumeObject.h
+++ b/Code/CryEngine/CryCommon/CREVolumeObject.h
@@ -55,7 +55,7 @@ public:
Matrix34 m_matInv;
Vec3 m_eyePosInWS;
Vec3 m_eyePosInOS;
- Plane m_volumeTraceStartPlane;
+ Plane_tpl m_volumeTraceStartPlane;
AABB m_renderBoundsOS;
bool m_viewerInsideVolume;
bool m_nearPlaneIntersectsVolume;
diff --git a/Code/CryEngine/CryCommon/CREWaterOcean.h b/Code/CryEngine/CryCommon/CREWaterOcean.h
index 784588309f..e8ca310d41 100644
--- a/Code/CryEngine/CryCommon/CREWaterOcean.h
+++ b/Code/CryEngine/CryCommon/CREWaterOcean.h
@@ -25,7 +25,7 @@ public:
virtual void mfPrepare(bool bCheckOverflow);
virtual bool mfDraw(CShader* ef, SShaderPass* sfm);
- virtual void mfGetPlane(Plane& pl);
+ virtual void mfGetPlane(Plane_tpl& pl);
virtual void Create(uint32 nVerticesCount, SVF_P3F_C4B_T2F* pVertices, uint32 nIndicesCount, const void* pIndices, uint32 nIndexSizeof);
void ReleaseOcean();
diff --git a/Code/CryEngine/CryCommon/CREWaterVolume.h b/Code/CryEngine/CryCommon/CREWaterVolume.h
index 3e7a0636e6..89102e3097 100644
--- a/Code/CryEngine/CryCommon/CREWaterVolume.h
+++ b/Code/CryEngine/CryCommon/CREWaterVolume.h
@@ -27,7 +27,7 @@ public:
virtual ~CREWaterVolume();
virtual void mfPrepare(bool bCheckOverflow);
virtual bool mfDraw(CShader* ef, SShaderPass* sfm);
- virtual void mfGetPlane(Plane& pl);
+ virtual void mfGetPlane(Plane_tpl& pl);
virtual void mfCenter(Vec3& vCenter, CRenderObject* pObj);
virtual void GetMemoryUsage(ICrySizer* pSizer) const
@@ -69,7 +69,7 @@ public:
Vec3 m_center;
AABB m_WSBBox;
- Plane m_fogPlane;
+ Plane_tpl m_fogPlane;
float m_fogDensity;
Vec3 m_fogColor;
bool m_fogColorAffectedBySun;
diff --git a/Code/CryEngine/CryCommon/CryEngineDecalInfo.h b/Code/CryEngine/CryCommon/CryEngineDecalInfo.h
deleted file mode 100644
index f38533e341..0000000000
--- a/Code/CryEngine/CryCommon/CryEngineDecalInfo.h
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
-* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
-* its licensors.
-*
-* For complete copyright and license terms please see the LICENSE at the root of this
-* distribution (the "License"). All use of this software is governed by the License,
-* or, if provided, by the license below or the license accompanying this file. Do not
-* remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-*
-*/
-// Original file Copyright Crytek GMBH or its affiliates, used under license.
-
-// Description : declaration of struct CryEngineDecalInfo.
-
-// Note:
-// 3D Engine and Character Animation subsystems (as well as perhaps
-// some others) transfer data about the decals that need to be spawned
-// via this structure. This is to avoid passing many parameters through
-// each function call, and to save on copying these parameters when just
-// simply passing the structure from one function to another.
-
-#ifndef CRYINCLUDE_CRYCOMMON_CRYENGINEDECALINFO_H
-#define CRYINCLUDE_CRYCOMMON_CRYENGINEDECALINFO_H
-#pragma once
-
-#include "Cry_Math.h"
-
-// Summary:
-// Structure containing common parameters that describe a decal
-
-struct SDecalOwnerInfo
-{
- SDecalOwnerInfo() { memset(this, 0, sizeof(*this)); nRenderNodeSlotId = nRenderNodeSlotSubObjectId = -1; }
- struct IStatObj* GetOwner(Matrix34A& objMat);
-
- struct IRenderNode* pRenderNode; // Owner (decal will be attached to or wrapped around of this object)
- PodArray* pDecalReceivers;
- int nRenderNodeSlotId; // is set internally by 3dengine
- int nRenderNodeSlotSubObjectId; // is set internally by 3dengine
- int nMatID;
-};
-
-struct CryEngineDecalInfo
-{
- SDecalOwnerInfo ownerInfo;
- Vec3 vPos; // Decal position (world coordinates)
- Vec3 vNormal; // Decal/face normal
- float fSize; // Decal size
- float fLifeTime; // Decal life time (in seconds)
- float fAngle; // Angle of rotation
- struct IStatObj* pIStatObj; // Decal geometry
- Vec3 vHitDirection; // Direction from weapon/player position to decal position (bullet direction)
- float fGrowTime, fGrowTimeAlpha;// Used for blood pools
- unsigned int nGroupId; // Used for multi-component decals
- bool bSkipOverlappingTest; // Always spawn decals even if there are a lot of other decals in same place
- bool bAssemble; // Assemble to bigger decals if more than 1 decal is on the same place
- bool bForceEdge; // force the decal to the nearest edge of the owner mesh and project it accordingly
- bool bForceSingleOwner; // Do not attempt to cast the decal into the environment even if it's large enough
- bool bDeferred;
- uint8 sortPrio;
- char szMaterialName[_MAX_PATH]; // name of material used for rendering the decal (in favor of szTextureName/nTid and the default decal shader)
- bool preventDecalOnGround; // mainly for decal placement support
- const Matrix33* pExplicitRightUpFront; // mainly for decal placement support
-
- void GetMemoryUsage([[maybe_unused]] ICrySizer* pSizer) const{}
-
- // the constructor fills in some non-obligatory fields; the other fields must be filled in by the client
- CryEngineDecalInfo ()
- {
- memset(this, 0, sizeof(*this));
- ownerInfo.nRenderNodeSlotId = ownerInfo.nRenderNodeSlotSubObjectId = -1;
- sortPrio = 255;
- }
-};
-
-#endif // CRYINCLUDE_CRYCOMMON_CRYENGINEDECALINFO_H
diff --git a/Code/CryEngine/CryCommon/CryFontBus.h b/Code/CryEngine/CryCommon/CryFontBus.h
deleted file mode 100644
index 9922193f42..0000000000
--- a/Code/CryEngine/CryCommon/CryFontBus.h
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
- * its licensors.
- *
- * For complete copyright and license terms please see the LICENSE at the root of this
- * distribution (the "License"). All use of this software is governed by the License,
- * or, if provided, by the license below or the license accompanying this file. Do not
- * remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- */
-
-#pragma once
-
-#include
-
-#include
-
-namespace AZ
-{
- /*!
- * Signal LY to create an ICryFont
- */
- class CryFontCreationRequests
- : public AZ::EBusTraits
- {
- public:
- using MutexType = AZStd::recursive_mutex;
- static const AZ::EBusHandlerPolicy HandlerPolicy = AZ::EBusHandlerPolicy::Single;
- static const AZ::EBusAddressPolicy AddressPolicy = AZ::EBusAddressPolicy::Single;
-
- virtual bool CreateCryFont([[maybe_unused]] SSystemGlobalEnvironment& env, [[maybe_unused]] const SSystemInitParams& initParams) {return false;} //! return false to fall back to default CryFont initialization
- };
- using CryFontCreationRequestBus = AZ::EBus;
-
-}
diff --git a/Code/CryEngine/CryCommon/Cry_Camera.h b/Code/CryEngine/CryCommon/Cry_Camera.h
index a744d7335f..56a764d897 100644
--- a/Code/CryEngine/CryCommon/Cry_Camera.h
+++ b/Code/CryEngine/CryCommon/Cry_Camera.h
@@ -594,7 +594,7 @@ public:
ILINE const Vec3& GetFPVertex(int nId) const; //get far-plane vertices
ILINE const Vec3& GetPPVertex(int nId) const; //get projection-plane vertices
- ILINE const Plane* GetFrustumPlane(int numplane) const { return &m_fp[numplane]; }
+ ILINE const Plane_tpl* GetFrustumPlane(int numplane) const { return &m_fp[numplane]; }
//////////////////////////////////////////////////////////////////////////
// Z-Buffer ranges.
@@ -720,7 +720,7 @@ private:
Vec3 m_cltn, m_crtn, m_clbn, m_crbn; //this are the 4 vertices of the near-plane in cam-space
Vec3 m_cltf, m_crtf, m_clbf, m_crbf; //this are the 4 vertices of the farclip-plane in cam-space
- Plane m_fp [FRUSTUM_PLANES]; //
+ Plane_tpl m_fp [FRUSTUM_PLANES]; //
uint32 m_idx1[FRUSTUM_PLANES], m_idy1[FRUSTUM_PLANES], m_idz1[FRUSTUM_PLANES]; //
uint32 m_idx2[FRUSTUM_PLANES], m_idy2[FRUSTUM_PLANES], m_idz2[FRUSTUM_PLANES]; //
@@ -742,7 +742,7 @@ public:
m_crtp = arrvVerts[2];
m_crbp = arrvVerts[3];
}
- inline void SetFrustumPlane(int i, const Plane& plane)
+ inline void SetFrustumPlane(int i, const Plane_tpl& plane)
{
m_fp[i] = plane;
//do not break strict aliasing rules, use union instead of reinterpret_casts
@@ -1180,12 +1180,12 @@ inline void CCamera::UpdateFrustum()
//-------------------------------------------------------------------------------
//--- calculate the six frustum-planes using the frustum edges in world-space ---
//-------------------------------------------------------------------------------
- m_fp[FR_PLANE_NEAR ] = Plane::CreatePlane(m_crtn + GetPosition(), m_cltn + GetPosition(), m_crbn + GetPosition());
- m_fp[FR_PLANE_RIGHT ] = Plane::CreatePlane(m_crbf + GetPosition(), m_crtf + GetPosition(), GetPosition());
- m_fp[FR_PLANE_LEFT ] = Plane::CreatePlane(m_cltf + GetPosition(), m_clbf + GetPosition(), GetPosition());
- m_fp[FR_PLANE_TOP ] = Plane::CreatePlane(m_crtf + GetPosition(), m_cltf + GetPosition(), GetPosition());
- m_fp[FR_PLANE_BOTTOM] = Plane::CreatePlane(m_clbf + GetPosition(), m_crbf + GetPosition(), GetPosition());
- m_fp[FR_PLANE_FAR ] = Plane::CreatePlane(m_crtf + GetPosition(), m_crbf + GetPosition(), m_cltf + GetPosition()); //clip-plane
+ m_fp[FR_PLANE_NEAR ] = Plane_tpl::CreatePlane(m_crtn + GetPosition(), m_cltn + GetPosition(), m_crbn + GetPosition());
+ m_fp[FR_PLANE_RIGHT ] = Plane_tpl::CreatePlane(m_crbf + GetPosition(), m_crtf + GetPosition(), GetPosition());
+ m_fp[FR_PLANE_LEFT ] = Plane_tpl::CreatePlane(m_cltf + GetPosition(), m_clbf + GetPosition(), GetPosition());
+ m_fp[FR_PLANE_TOP ] = Plane_tpl::CreatePlane(m_crtf + GetPosition(), m_cltf + GetPosition(), GetPosition());
+ m_fp[FR_PLANE_BOTTOM] = Plane_tpl::CreatePlane(m_clbf + GetPosition(), m_crbf + GetPosition(), GetPosition());
+ m_fp[FR_PLANE_FAR ] = Plane_tpl::CreatePlane(m_crtf + GetPosition(), m_crbf + GetPosition(), m_cltf + GetPosition()); //clip-plane
uint32 rh = m_Matrix.IsOrthonormalRH();
if (rh == 0)
diff --git a/Code/CryEngine/CryCommon/Cry_GeoDistance.h b/Code/CryEngine/CryCommon/Cry_GeoDistance.h
index 92c1f65d87..47794c7671 100644
--- a/Code/CryEngine/CryCommon/Cry_GeoDistance.h
+++ b/Code/CryEngine/CryCommon/Cry_GeoDistance.h
@@ -1168,17 +1168,6 @@ namespace Distance {
return fDist2;
}
- // Compute both the min and max distances of a box to a plane, in the sense of the plane normal.
- inline void AABB_Plane(float* pfDistMin, float* pfDistMax, const AABB& box, const Plane& pl)
- {
- float fDist0 = pl.DistFromPlane(box.min),
- fDistX = (box.max.x - box.min.x) * pl.n.x,
- fDistY = (box.max.y - box.min.y) * pl.n.y,
- fDistZ = (box.max.z - box.min.z) * pl.n.z;
- *pfDistMin = fDist0 + min(fDistX, 0.f) + min(fDistY, 0.f) + min(fDistZ, 0.f);
- *pfDistMax = fDist0 + max(fDistX, 0.f) + max(fDistY, 0.f) + max(fDistZ, 0.f);
- }
-
//----------------------------------------------------------------------------------
// Distance: Sphere_Triangle
//----------------------------------------------------------------------------------
diff --git a/Code/CryEngine/CryCommon/Cry_GeoIntersect.h b/Code/CryEngine/CryCommon/Cry_GeoIntersect.h
index c2f556c4b7..89f6d8ebaf 100644
--- a/Code/CryEngine/CryCommon/Cry_GeoIntersect.h
+++ b/Code/CryEngine/CryCommon/Cry_GeoIntersect.h
@@ -22,7 +22,7 @@
#include
namespace Intersect {
- inline bool Ray_Plane(const Ray& ray, const Plane& plane, Vec3& output, bool bSingleSidePlane = true)
+ inline bool Ray_Plane(const Ray& ray, const Plane_tpl& plane, Vec3& output, bool bSingleSidePlane = true)
{
float cosine = plane.n | ray.direction;
@@ -49,7 +49,7 @@ namespace Intersect {
return true; //intersection occurred
}
- inline bool Line_Plane(const Line& line, const Plane& plane, Vec3& output, bool bSingleSidePlane = true)
+ inline bool Line_Plane(const Line& line, const Plane_tpl& plane, Vec3& output, bool bSingleSidePlane = true)
{
float cosine = plane.n | line.direction;
diff --git a/Code/CryEngine/CryCommon/Cry_GeoOverlap.h b/Code/CryEngine/CryCommon/Cry_GeoOverlap.h
index 3f2c7081d7..ab560b7518 100644
--- a/Code/CryEngine/CryCommon/Cry_GeoOverlap.h
+++ b/Code/CryEngine/CryCommon/Cry_GeoOverlap.h
@@ -945,29 +945,6 @@ namespace Overlap {
}
}
-
- /*!
- *
- * we use the SEPARATING-AXIS-TEST for OBB/Plane overlap.
- *
- * Example:
- * bool result=Overlap::OBB_Plane( pos,obb, plane );
- *
- */
- inline bool OBB_Plane(const Vec3& pos, const OBB& obb, const Plane& plane)
- {
- //the new center-position in world-space
- Vec3 p = obb.m33 * obb.c + pos;
- //extract the orientation-vectors from the columns of the 3x3 matrix
- //and scale them by the half-lengths
- Vec3 ax = Vec3(obb.m33.m00, obb.m33.m10, obb.m33.m20) * obb.h.x;
- Vec3 ay = Vec3(obb.m33.m01, obb.m33.m11, obb.m33.m21) * obb.h.y;
- Vec3 az = Vec3(obb.m33.m02, obb.m33.m12, obb.m33.m22) * obb.h.z;
- //check OBB against Plane, using the plane-normal as separating axis
- return fabsf(plane | p) < (fabsf(plane.n | ax) + fabsf(plane.n | ay) + fabsf(plane.n | az));
- }
-
-
/*!
*
* we use the SEPARATING AXIS TEST to check if a triangle and AABB overlap.
@@ -1214,7 +1191,7 @@ namespace Overlap {
//test if the box intersects the plane of the triangle
//compute plane equation of triangle: normal*x+d=0
- Plane plane = Plane::CreatePlane((e0 % e1), v0);
+ Plane_tpl plane = Plane_tpl::CreatePlane((e0 % e1), v0);
Vec3 vmin, vmax;
if (plane.n.x > 0.0f)
@@ -1505,7 +1482,7 @@ namespace Overlap {
//test if the box overlaps the plane of the triangle
//compute plane equation of triangle: normal*x+d=0
- Plane plane = Plane::CreatePlane((e0 % e1), v0);
+ Plane_tpl plane = Plane_tpl::CreatePlane((e0 % e1), v0);
Vec3 vmin, vmax;
if (plane.n.x > 0.0f)
diff --git a/Code/CryEngine/CryCommon/Gem.h b/Code/CryEngine/CryCommon/Gem.h
deleted file mode 100644
index 3097fcf304..0000000000
--- a/Code/CryEngine/CryCommon/Gem.h
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
-* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
-* its licensors.
-*
-* For complete copyright and license terms please see the LICENSE at the root of this
-* distribution (the "License"). All use of this software is governed by the License,
-* or, if provided, by the license below or the license accompanying this file. Do not
-* remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-*
-*/
-#pragma once
-
-#include
-
-#if defined(AZ_RESTRICTED_PLATFORM)
- #include AZ_RESTRICTED_FILE(Gem_h)
-#endif
-
-#if defined(LINUX) || defined(APPLE) || defined(ANDROID)
- #define OPENGL 1
-#endif
-
-#include
-
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-
-#include
-#include
-#include
-#include
-#include
-#include <3dEngine.h>
-#include
-#include
-
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-
-#include
-#include
-#include
-
-#include
diff --git a/Code/CryEngine/CryCommon/I3DEngine.h b/Code/CryEngine/CryCommon/I3DEngine.h
deleted file mode 100644
index 8d3801ecb4..0000000000
--- a/Code/CryEngine/CryCommon/I3DEngine.h
+++ /dev/null
@@ -1,3021 +0,0 @@
-/*
-* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
-* its licensors.
-*
-* For complete copyright and license terms please see the LICENSE at the root of this
-* distribution (the "License"). All use of this software is governed by the License,
-* or, if provided, by the license below or the license accompanying this file. Do not
-* remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-*
-*/
-// Original file Copyright Crytek GMBH or its affiliates, used under license.
-
-// Description : 3dengine interface
-
-#ifndef CRYINCLUDE_CRYCOMMON_I3DENGINE_H
-#define CRYINCLUDE_CRYCOMMON_I3DENGINE_H
-#pragma once
-
-// The maximum number of unique surface types that can be used per node
-#define MMRM_MAX_SURFACE_TYPES 16
-#define COMPILED_OCTREE_FILE_NAME "terrain/terrain.dat"
-
-// !!! Do not add any headers here !!!
-#include "CryEngineDecalInfo.h"
-#include
-#include // <> required for Interfuscator
-#include "IRenderer.h"
-#include // <> required for Interfuscator
-#include // <> required for Interfuscator
-#include // <> required for Interfuscator
-#include // <> required for Interfuscator
-#include "CryArray.h"
-#include // <> required for Interfuscator
-#include
-// !!! Do not add any headers here !!!
-
-class IOpticsManager;
-class CContentCGF;
-class ICrySizer;
-class CRenderView;
-struct ISystem;
-struct CVars;
-struct pe_params_particle;
-struct IMaterial;
-struct SpawnParams;
-struct ForceObject;
-struct IRenderNode;
-struct IObjManager;
-struct IDeferredPhysicsEventManager;
-struct IBSPTree3D;
-struct ITextureLoadHandler;
-struct ITimeOfDay;
-struct MacroTextureConfiguration;
-
-namespace LegacyProceduralVegetation
-{
- class IVegetationPoolManager;
-}
-
-namespace LegacyTerrain
-{
- struct MacroTextureConfiguration;
-}
-
-namespace ChunkFile
-{
- struct IChunkFileWriter;
-}
-
-namespace AZ
-{
- class Aabb;
-}
-
-enum E3DEngineParameter
-{
- E3DPARAM_SUN_COLOR,
-
- E3DPARAM_SUN_SPECULAR_MULTIPLIER,
-
- E3DPARAM_AMBIENT_GROUND_COLOR,
- E3DPARAM_AMBIENT_MIN_HEIGHT,
- E3DPARAM_AMBIENT_MAX_HEIGHT,
-
- E3DPARAM_FOG_COLOR,
- E3DPARAM_FOG_COLOR2,
- E3DPARAM_FOG_RADIAL_COLOR,
-
- E3DPARAM_VOLFOG_HEIGHT_DENSITY,
- E3DPARAM_VOLFOG_HEIGHT_DENSITY2,
-
- E3DPARAM_VOLFOG_GRADIENT_CTRL,
-
- E3DPARAM_VOLFOG_GLOBAL_DENSITY,
- E3DPARAM_VOLFOG_RAMP,
-
- E3DPARAM_VOLFOG_SHADOW_RANGE,
- E3DPARAM_VOLFOG_SHADOW_DARKENING,
- E3DPARAM_VOLFOG_SHADOW_ENABLE,
-
- E3DPARAM_VOLFOG2_CTRL_PARAMS,
- E3DPARAM_VOLFOG2_SCATTERING_PARAMS,
- E3DPARAM_VOLFOG2_RAMP,
- E3DPARAM_VOLFOG2_COLOR,
- E3DPARAM_VOLFOG2_GLOBAL_DENSITY,
- E3DPARAM_VOLFOG2_HEIGHT_DENSITY,
- E3DPARAM_VOLFOG2_HEIGHT_DENSITY2,
- E3DPARAM_VOLFOG2_COLOR1,
- E3DPARAM_VOLFOG2_COLOR2,
-
- E3DPARAM_SKYLIGHT_SUN_INTENSITY,
-
- E3DPARAM_SKYLIGHT_KM,
- E3DPARAM_SKYLIGHT_KR,
- E3DPARAM_SKYLIGHT_G,
-
- E3DPARAM_SKYLIGHT_WAVELENGTH_R,
- E3DPARAM_SKYLIGHT_WAVELENGTH_G,
- E3DPARAM_SKYLIGHT_WAVELENGTH_B,
-
- E3DPARAM_NIGHSKY_HORIZON_COLOR,
- E3DPARAM_NIGHSKY_ZENITH_COLOR,
- E3DPARAM_NIGHSKY_ZENITH_SHIFT,
-
- E3DPARAM_NIGHSKY_STAR_INTENSITY,
-
- E3DPARAM_NIGHSKY_MOON_DIRECTION,
- E3DPARAM_NIGHSKY_MOON_COLOR,
- E3DPARAM_NIGHSKY_MOON_SIZE,
- E3DPARAM_NIGHSKY_MOON_INNERCORONA_COLOR,
- E3DPARAM_NIGHSKY_MOON_INNERCORONA_SCALE,
- E3DPARAM_NIGHSKY_MOON_OUTERCORONA_COLOR,
- E3DPARAM_NIGHSKY_MOON_OUTERCORONA_SCALE,
-
- E3DPARAM_CLOUDSHADING_MULTIPLIERS,
- E3DPARAM_CLOUDSHADING_SUNCOLOR,
- E3DPARAM_CLOUDSHADING_SKYCOLOR,
-
- E3DPARAM_CORONA_SIZE,
-
- E3DPARAM_OCEANFOG_COLOR,
- E3DPARAM_OCEANFOG_DENSITY,
-
- // Sky highlight (ex. From Lightning)
- E3DPARAM_SKY_HIGHLIGHT_COLOR,
- E3DPARAM_SKY_HIGHLIGHT_SIZE,
- E3DPARAM_SKY_HIGHLIGHT_POS,
-
- E3DPARAM_SKY_MOONROTATION,
-
- E3DPARAM_SKY_SKYBOX_ANGLE,
- E3DPARAM_SKY_SKYBOX_STRETCHING,
-
- EPARAM_SUN_SHAFTS_VISIBILITY,
-
- E3DPARAM_SKYBOX_MULTIPLIER,
-
- E3DPARAM_DAY_NIGHT_INDICATOR,
-
- // Tone mapping tweakables
- E3DPARAM_HDR_FILMCURVE_SHOULDER_SCALE,
- E3DPARAM_HDR_FILMCURVE_LINEAR_SCALE,
- E3DPARAM_HDR_FILMCURVE_TOE_SCALE,
- E3DPARAM_HDR_FILMCURVE_WHITEPOINT,
-
- E3DPARAM_HDR_EYEADAPTATION_PARAMS,
- E3DPARAM_HDR_EYEADAPTATION_PARAMS_LEGACY,
- E3DPARAM_HDR_BLOOM_AMOUNT,
-
- E3DPARAM_HDR_COLORGRADING_COLOR_SATURATION,
- E3DPARAM_HDR_COLORGRADING_COLOR_BALANCE,
-
- E3DPARAM_COLORGRADING_FILTERS_PHOTOFILTER_COLOR,
- E3DPARAM_COLORGRADING_FILTERS_PHOTOFILTER_DENSITY,
- E3DPARAM_COLORGRADING_FILTERS_GRAIN
-};
-
-enum EShadowMode
-{
- ESM_NORMAL = 0,
- ESM_HIGHQUALITY
-};
-
-struct IBSPTree3D
-{
- typedef DynArray CFace;
- typedef DynArray FaceList;
-
- virtual ~IBSPTree3D() {}
- virtual bool IsInside(const Vec3& vPos) const = 0;
- virtual void GetMemoryUsage(ICrySizer* pSizer) const = 0;
-
- virtual size_t WriteToBuffer(void* pBuffer) const = 0;
- virtual void ReadFromBuffer(const void* pBuffer) = 0;
-};
-
-//////////////////////////////////////////////////////////////////////////
-// Description:
-// This structure is filled and passed by the caller to the DebugDraw functions of the stat object or entity.
-struct SGeometryDebugDrawInfo
-{
- Matrix34 tm; // Transformation Matrix
- ColorB color; // Optional color of the lines.
- ColorB lineColor; // Optional color of the lines.
-
- // Optional flags controlling how to render debug draw information.
- uint32 bNoCull : 1;
- uint32 bNoLines : 1;
- uint32 bExtrude : 1; // Extrude debug draw geometry alittle bit so it is over real geometry.
-
- SGeometryDebugDrawInfo()
- : color(255, 0, 255, 255)
- , lineColor(255, 255, 0, 255)
- , bNoLines(0)
- , bNoCull(0) { tm.SetIdentity(); }
-};
-
-struct SFrameLodInfo
-{
- uint32 nID;
- float fLodRatio;
- float fTargetSize;
- uint nMinLod;
- uint nMaxLod;
-
- SFrameLodInfo()
- {
- nID = 0;
- fLodRatio = 0.f;
- fTargetSize = 0.f;
- nMinLod = 0;
- nMaxLod = 6;
- }
-};
-struct SMeshLodInfo
-{
- static const int s_nMaxLodCount = 5;
- float fGeometricMean;
- uint nFaceCount;
- uint32 nFrameLodID;
- SMeshLodInfo()
- {
- Clear();
- }
- void Clear()
- {
- fGeometricMean = 0.f;
- nFaceCount = 0;
- nFrameLodID = 0;
- }
- void Merge(const SMeshLodInfo& lodInfo)
- {
- uint nTotalCount = nFaceCount + lodInfo.nFaceCount;
- if (nTotalCount > 0)
- {
- float fGeometricMeanTotal = 0.f;
- if (fGeometricMean > 0.f)
- {
- fGeometricMeanTotal += logf(fGeometricMean) * nFaceCount;
- }
- if (lodInfo.fGeometricMean > 0.f)
- {
- fGeometricMeanTotal += logf(lodInfo.fGeometricMean) * lodInfo.nFaceCount;
- }
- fGeometricMean = expf(fGeometricMeanTotal / (float)nTotalCount);
- nFaceCount = nTotalCount;
- }
- }
-};
-// Summary:
-// Physics material enumerator, allows for 3dengine to get material id from game code.
-struct IPhysMaterialEnumerator
-{
- //
- virtual ~IPhysMaterialEnumerator(){}
- virtual int EnumPhysMaterial(const char* szPhysMatName) = 0;
- virtual bool IsCollidable(int nMatId) = 0;
- virtual int GetMaterialCount() = 0;
- virtual const char* GetMaterialNameByIndex(int index) = 0;
- //
-};
-
-
-// Summary:
-// Physics foreign data flags.
-enum EPhysForeignFlags
-{
- PFF_HIDABLE = 0x1,
- PFF_HIDABLE_SECONDARY = 0x2,
- PFF_EXCLUDE_FROM_STATIC = 0x4,
- PFF_UNIMPORTANT = 0x20,
- PFF_OUTDOOR_AREA = 0x40,
- PFF_MOVING_PLATFORM = 0x80,
-};
-
-// Summary:
-// Ocean data flags.
-enum EOceanRenderFlags
-{
- OCR_NO_DRAW = 1 << 0,
- OCR_OCEANVOLUME_VISIBLE = 1 << 1,
-};
-
-// Summary:
-// Structure to pass vegetation group properties.
-struct IStatInstGroup
-{
- enum EPlayerHideable
- {
- ePlayerHideable_None = 0,
- ePlayerHideable_High,
- ePlayerHideable_Mid,
- ePlayerHideable_Low,
-
- ePlayerHideable_COUNT,
- };
-
- IStatInstGroup()
- {
- pStatObj = 0;
- szFileName[0] = 0;
- bHideability = 0;
- bHideabilitySecondary = 0;
- fBending = 0;
- nCastShadowMinSpec = 0;
- bRecvShadow = 0;
- bDynamicDistanceShadows = false;
- bUseAlphaBlending = 0;
- fSpriteDistRatio = 1.f;
- fShadowDistRatio = 1.f;
- fMaxViewDistRatio = 1.f;
- fLodDistRatio = 1.f;
- fBrightness = 1.f;
- pMaterial = 0;
-
- fDensity = 1;
- fElevationMax = 4096;
- fElevationMin = 8;
- fSize = 1;
- fSizeVar = 0;
- fSlopeMax = 255;
- fSlopeMin = 0;
- fStiffness = 0.5f;
- fDamping = 2.5f;
- fVariance = 0.6f;
- fAirResistance = 1.f;
- bRandomRotation = false;
- nRotationRangeToTerrainNormal = 0;
- nMaterialLayers = 0;
- bAllowIndoor = false;
- fAlignToTerrainCoefficient = 0.f;
- bAutoMerged = false;
- minConfigSpec = (ESystemConfigSpec)0;
- nTexturesAreStreamedIn = 0;
- nPlayerHideable = ePlayerHideable_None;
- nID = -1;
- }
-
- IStatObj* GetStatObj()
- {
- IStatObj* p = pStatObj;
- return (IStatObj*)p;
- }
- const IStatObj* GetStatObj() const
- {
- const IStatObj* p = pStatObj;
- return (const IStatObj*)p;
- }
-
- _smart_ptr pStatObj;
- char szFileName[256];
- bool bHideability;
- bool bHideabilitySecondary;
- float fBending;
- uint8 nCastShadowMinSpec;
- bool bRecvShadow;
- bool bDynamicDistanceShadows;
- bool bUseAlphaBlending;
- float fSpriteDistRatio;
- float fLodDistRatio;
- float fShadowDistRatio;
- float fMaxViewDistRatio;
- float fBrightness;
- bool bRandomRotation;
- int32 nRotationRangeToTerrainNormal;
- float fAlignToTerrainCoefficient;
- bool bAllowIndoor;
- bool bAutoMerged;
-
- float fDensity;
- float fElevationMax;
- float fElevationMin;
- float fSize;
- float fSizeVar;
- float fSlopeMax;
- float fSlopeMin;
- float fStiffness;
- float fDamping;
- float fVariance;
- float fAirResistance;
-
- float fVegRadius;
- float fVegRadiusVert;
- float fVegRadiusHor;
-
- int nPlayerHideable;
- int nID;
-
- // Minimal configuration spec for this vegetation group.
- ESystemConfigSpec minConfigSpec;
-
- // Override material for this instance group.
- _smart_ptr pMaterial;
-
- // Material layers bitmask -> which layers are active.
- uint8 nMaterialLayers;
-
- // Textures Are Streamed In.
- uint8 nTexturesAreStreamedIn;
-
- // Flags similar to entity render flags.
- int m_dwRndFlags;
-};
-
-// Description:
-// Water volumes should usually be created by I3DEngine::CreateWaterVolume.
-// Summary:
-// Interface to water volumes.
-struct IWaterVolume
-{
- //
- //DOC-IGNORE-BEGIN
- virtual ~IWaterVolume(){}
- virtual void UpdatePoints(const Vec3* pPoints, int nCount, float fHeight) = 0;
- virtual void SetFlowSpeed(float fSpeed) = 0;
- virtual void SetAffectToVolFog(bool bAffectToVolFog) = 0;
- virtual void SetTriSizeLimits(float fTriMinSize, float fTriMaxSize) = 0;
- // virtual void SetMaterial(const char * szShaderName) = 0;
- virtual void SetMaterial(_smart_ptr pMaterial) = 0;
- virtual _smart_ptr GetMaterial() = 0;
- virtual const char* GetName() const = 0;
- virtual void SetName(const char* szName) = 0;
- //DOC-IGNORE-END
-
- // Description:
- // Used to change the water level. Will assign a new Z value to all
- // vertices of the water geometry.
- // Arguments:
- // vNewOffset - Position of the new water level
- // Summary:
- // Sets a new water level.
- virtual void SetPositionOffset(const Vec3& vNewOffset) = 0;
- //
-};
-
-struct SClipVolumeBlendInfo
-{
- static const int BlendPlaneCount = 2;
-
- Plane blendPlanes[BlendPlaneCount];
- struct IClipVolume* blendVolumes[BlendPlaneCount];
-};
-
-struct IClipVolume
-{
- enum EClipVolumeFlags
- {
- eClipVolumeConnectedToOutdoor = BIT(0),
- eClipVolumeIgnoreGI = BIT(1),
- eClipVolumeAffectedBySun = BIT(2),
- eClipVolumeBlend = BIT(3),
- eClipVolumeIsVisArea = BIT(4),
- eClipVolumeIgnoreOutdoorAO = BIT(5),
- };
-
- virtual ~IClipVolume() {};
- virtual void GetClipVolumeMesh(_smart_ptr& renderMesh, Matrix34& worldTM) const = 0;
- virtual AABB GetClipVolumeBBox() const = 0;
- virtual bool IsPointInsideClipVolume(const Vec3& point) const = 0;
-
- virtual uint8 GetStencilRef() const = 0;
- virtual uint GetClipVolumeFlags() const = 0;
-};
-
-// Summary:
-// Provides information about the different VisArea volumes.
-struct IVisArea
- : public IClipVolume
-{
- //
- virtual ~IVisArea(){}
- // Summary:
- // Gets the last rendered frame id.
- // Return Value:
- // An int which contains the frame id.
- virtual int GetVisFrameId() = 0;
-
- // Description:
- // Gets a list of all the VisAreas which are connected to the current one.
- // Arguments:
- // pAreas - Pointer to an array of IVisArea*
- // nMaxConnNum - The maximum of IVisArea to write in pAreas
- // bSkipDisabledPortals - Ignore portals which are disabled
- // Return Value:
- // An integer which hold the amount of VisArea found to be connected. If
- // the return is equal to nMaxConnNum, it's possible that not all
- // connected VisAreas were returned due to the restriction imposed by the
- // argument.
- // Summary:
- // Gets all the areas which are connected to the current one.
- virtual int GetVisAreaConnections(IVisArea** pAreas, int nMaxConnNum, bool bSkipDisabledPortals = false) = 0;
-
- // Summary:
- // Determines if it's connected to an outdoor area.
- // Return Value:
- // True if the VisArea is connected to an outdoor area.
- virtual bool IsConnectedToOutdoor() const = 0;
-
- // Summary:
- // Determines if the visarea ignores Global Illumination inside.
- // Return Value:
- // True if the VisArea ignores Global Illumination inside.
- virtual bool IsIgnoringGI() const = 0;
-
- // Summary:
- // Determines if the visarea ignores Outdoor Ambient occlusion inside.
- // Return Value:
- // True if the VisArea ignores Outdoor Ambient Occlusion inside.
- virtual bool IsIgnoringOutdoorAO() const = 0;
-
- // Summary:
- // Gets the name.
- // Notes:
- // The name is always returned in lower case.
- // Return Value:
- // A null terminated char array containing the name of the VisArea.
- virtual const char* GetName() = 0;
-
- // Summary:
- // Determines if this VisArea is a portal.
- // Return Value:
- // True if the VisArea is a portal, or false in the opposite case.
- virtual bool IsPortal() const = 0;
-
- // Description:
- // Searches for a specified VisArea to see if it's connected to the current
- // VisArea.
- // Arguments:
- // pAnotherArea - A specified VisArea to find
- // nMaxRecursion - The maximum number of recursion to do while searching
- // bSkipDisabledPortals - Will avoid searching disabled VisAreas
- // pVisitedAreas - if not NULL - will get list of all visited areas
- // Return Value:
- // True if the VisArea was found.
- // Summary:
- // Searches for a specified VisArea.
- virtual bool FindVisArea(IVisArea* pAnotherArea, int nMaxRecursion, bool bSkipDisabledPortals) = 0;
-
- // Description:
- // Searches for the surrounding VisAreas which connected to the current
- // VisArea.
- // Arguments:
- // nMaxRecursion - The maximum number of recursion to do while searching
- // bSkipDisabledPortals - Will avoid searching disabled VisAreas
- // pVisitedAreas - if not NULL - will get list of all visited areas
- // Return Value:
- // None.
- // Summary:
- // Searches for the surrounding VisAreas.
- virtual void FindSurroundingVisArea(int nMaxRecursion, bool bSkipDisabledPortals, PodArray* pVisitedAreas = NULL, int nMaxVisitedAreas = 0, int nDeepness = 0) = 0;
-
- // Summary:
- // Determines if it's affected by outdoor lighting.
- // Return Value:
- // Returns true if the VisArea if it's affected by outdoor lighting, else
- // false will be returned.
- virtual bool IsAffectedByOutLights() const = 0;
-
- // Summary:
- // Determines if the spere can be affect the VisArea.
- // Return Value:
- // Returns true if the VisArea can be affected by the sphere, else
- // false will be returned.
- virtual bool IsSphereInsideVisArea(const Vec3& vPos, const f32 fRadius) = 0;
-
- // Summary:
- // Clips geometry inside or outside a vis area.
- // Return Value:
- // Whether geom was clipped.
- virtual bool ClipToVisArea(bool bInside, Sphere& sphere, Vec3 const& vNormal) = 0;
-
- // Summary:
- // Gives back the axis aligned bounding box of VisArea.
- // Return Value:
- // Returns the pointer of a AABB.
- virtual const AABB* GetAABBox() const = 0;
-
- // Summary:
- // Gives back the axis aligned bounding box of all static objects in the VisArea.
- // This AABB can be huger than the ViaArea AABB as some objects might not be completely inside the VisArea.
- // Return Value:
- // Returns the pointer to the AABB.
- virtual const AABB* GetStaticObjectAABBox() const = 0;
-
- // Summary:
- // Determines if the point can be affect the VisArea.
- // Return Value:
- // Returns true if the VisArea can be affected by the point, else
- // false will be returned.
- virtual bool IsPointInsideVisArea(const Vec3& vPos) const = 0;
-
- virtual void GetShapePoints(const Vec3*& pPoints, size_t& nPoints) = 0;
- virtual float GetHeight() = 0;
- //
-};
-
-#include "OceanConstants.h"
-
-// float m_SortId : offseted by +WATER_LEVEL_SORTID_OFFSET if the camera object line is crossing the water surface
-// : otherwise offseted by -WATER_LEVEL_SORTID_OFFSET
-#define WATER_LEVEL_SORTID_OFFSET 10000000
-
-#define DEFAULT_SID 0
-
-// Summary:
-// indirect lighting quadtree definition.
-namespace NQT
-{
- // Forward declaration
- template
- class CQuadTree;
-}
-
-#define FILEVERSION_TERRAIN_SHLIGHTING_FILE 5
-
-enum EVoxelBrushShape
-{
- evbsSphere = 1,
- evbsBox,
-};
-
-enum EVoxelEditTarget
-{
- evetVoxelObjects = 1,
-};
-
-enum EVoxelEditOperation
-{
- eveoNone = 0,
- eveoPaintHeightPos,
- eveoPaintHeightNeg,
- eveoCreate,
- eveoSubstract,
- eveoMaterial,
- eveoBaseColor,
- eveoBlurPos,
- eveoBlurNeg,
- eveoCopyTerrainPos,
- eveoCopyTerrainNeg,
- eveoPickHeight,
- eveoIntegrateMeshPos,
- eveoIntegrateMeshNeg,
- eveoForceDepth,
- eveoLimitLod,
- eveoLast,
-};
-
-#define COMPILED_VISAREA_MAP_FILE_NAME "terrain\\indoor.dat"
-#define COMPILED_MERGED_MESHES_BASE_NAME "terrain\\merged_meshes_sectors\\"
-#define COMPILED_MERGED_MESHES_LIST "mmrm_used_meshes.lst"
-#define LEVEL_INFO_FILE_NAME "levelinfo.xml"
-
-//////////////////////////////////////////////////////////////////////////
-
-#pragma pack(push,4)
-
-#define VISAREAMANAGER_CHUNK_VERSION 6
-
-#define SERIALIZATION_FLAG_BIG_ENDIAN 1
-#define SERIALIZATION_FLAG_SECTOR_PALETTES 2
-
-#define TCH_FLAG2_AREA_ACTIVATION_IN_USE 1
-
-struct SVisAreaManChunkHeader
-{
- int8 nVersion;
- int8 nDummy;
- int8 nFlags;
- int8 nFlags2;
- int nChunkSize;
- int nVisAreasNum;
- int nPortalsNum;
- int nOcclAreasNum;
-
- AUTO_STRUCT_INFO
-};
-
-struct SOcTreeNodeChunk
-{
- int16 nChunkVersion;
- int16 ucChildsMask;
- AABB nodeBox;
- int32 nObjectsBlockSize;
-
- AUTO_STRUCT_INFO
-};
-
-struct SHotUpdateInfo
-{
- SHotUpdateInfo()
- {
- nHeigtmap = 1;
- nObjTypeMask = ~0;
- pVisibleLayerMask = NULL;
- pLayerIdTranslation = NULL;
- areaBox.Reset();
- }
-
- uint32 nHeigtmap;
- uint32 nObjTypeMask;
- const uint8* pVisibleLayerMask;
- const uint16* pLayerIdTranslation;
- AABB areaBox;
-
- AUTO_STRUCT_INFO
-};
-
-#define OCTREE_CHUNK_VERSION 29
-
-//==============================================================================================
-
-// Summary:
-// Common header for binary files used by 3dengine
-struct SCommonFileHeader
-{
- char signature[4]; // File signature, should be "CRY "
- uint8 file_type; // File type
- uint8 flags; // File common flags
- uint16 version; // File version
-
- AUTO_STRUCT_INFO
-};
-
-struct IVisAreaCallback
-{
- //
- virtual ~IVisAreaCallback(){}
- virtual void OnVisAreaDeleted(IVisArea* pVisArea) = 0;
- //
-};
-
-struct IVisAreaManager
-{
- //
- virtual ~IVisAreaManager(){}
- // Summary:
- // Loads data into VisAreaManager engine from memory block.
- virtual bool SetCompiledData(uint8* pData, int nDataSize, std::vector** ppStatObjTable, std::vector<_smart_ptr >** ppMatTable, bool bHotUpdate, SHotUpdateInfo* pExportInfo) = 0;
-
- // Summary:
- // Saves data from VisAreaManager engine into memory block.
- virtual bool GetCompiledData(uint8* pData, int nDataSize, std::vector** ppStatObjTable, std::vector<_smart_ptr >** ppMatTable, std::vector** ppStatInstGroupTable, EEndian eEndian, SHotUpdateInfo* pExportInfo = NULL) = 0;
-
- // Summary:
- // Returns VisAreaManager data memory block size.
- virtual int GetCompiledDataSize(SHotUpdateInfo* pExportInfo = NULL) = 0;
-
- // Summary:
- // Returns the accumulated number of visareas and portals.
- virtual int GetNumberOfVisArea() const = 0;
-
- // Summary:
- // Returns the visarea interface based on the id (0..GetNumberOfVisArea()) it can be a visarea or a portal.
- virtual IVisArea* GetVisAreaById(int nID) const = 0;
-
- virtual void AddListener(IVisAreaCallback* pListener) = 0;
- virtual void RemoveListener(IVisAreaCallback* pListener) = 0;
-
- virtual void PrepareSegmentData(const AABB& box) = 0;
- virtual void ReleaseInactiveSegments() = 0;
- virtual bool CreateSegment(int nSID) = 0;
- virtual bool DeleteSegment(int nSID, bool bDeleteNow) = 0;
- virtual bool StreamCompiledData(uint8* pData, int nDataSize, int nSID, std::vector* pStatObjTable, std::vector<_smart_ptr >* pMatTable, std::vector* pStatInstGroupTable, const Vec2& vIndexOffset) = 0;
- virtual void OffsetPosition(const Vec3& delta) = 0;
- virtual void UpdateConnections() = 0;
- // Summary:
- // Clones all vis areas in a region of the level, offsetting and rotating them based
- // on the values passed in.
- // Arguments:
- // offset - Offset amount, relative to the center of the region passed in.
- // zRotation - Rotation around the z axis, in radians.
- virtual void CloneRegion(const AABB& region, const Vec3& offset, float zRotation) = 0;
-
- // Summary:
- // Removes all vis areas in a region of the level.
- virtual void ClearRegion(const AABB& region) = 0;
-
- virtual void GetObjectsByType(PodArray& lstObjects, EERType objType, const AABB* pBBox, ObjectTreeQueryFilterCallback filterCallback = nullptr) = 0;
- virtual void GetObjectsByFlags(uint dwFlags, PodArray& lstObjects) = 0;
-
- virtual void GetObjects(PodArray& lstObjects, const AABB* pBBox) = 0;
-
- virtual bool IsOutdoorAreasVisible() = 0;
-};
-
-struct SSkyLightRenderParams
-{
- static const int skyDomeTextureWidth = 64;
- static const int skyDomeTextureHeight = 32;
- static const int skyDomeTextureSize = 64 * 32;
-
- static const int skyDomeTextureWidthBy8 = 8;
- static const int skyDomeTextureWidthBy4Log = 4; // = log2(64/4)
- static const int skyDomeTextureHeightBy2Log = 4; // = log2(32/2)
-
- SSkyLightRenderParams()
- : m_pSkyDomeMesh(0)
- , m_pSkyDomeTextureDataMie(0)
- , m_pSkyDomeTextureDataRayleigh(0)
- , m_skyDomeTexturePitch(0)
- , m_skyDomeTextureTimeStamp(-1)
- , m_partialMieInScatteringConst(0.0f, 0.0f, 0.0f, 0.0f)
- , m_partialRayleighInScatteringConst(0.0f, 0.0f, 0.0f, 0.0f)
- , m_sunDirection(0.0f, 0.0f, 0.0f, 0.0f)
- , m_phaseFunctionConsts(0.0f, 0.0f, 0.0f, 0.0f)
- , m_hazeColor(0.0f, 0.0f, 0.0f, 0.0f)
- , m_hazeColorMieNoPremul(0.0f, 0.0f, 0.0f, 0.0f)
- , m_hazeColorRayleighNoPremul(0.0f, 0.0f, 0.0f, 0.0f)
- , m_skyColorTop(0.0f, 0.0f, 0.0f)
- , m_skyColorNorth(0.0f, 0.0f, 0.0f)
- , m_skyColorEast(0.0f, 0.0f, 0.0f)
- , m_skyColorSouth(0.0f, 0.0f, 0.0f)
- , m_skyColorWest(0.0f, 0.0f, 0.0f)
- {
- }
-
- // Sky dome mesh
- _smart_ptr m_pSkyDomeMesh;
-
- // temporarily add padding bytes to prevent fetching Vec4 constants below from wrong offset
- uint32 dummy0;
- uint32 dummy1;
-
- // Sky dome texture data
- const void* m_pSkyDomeTextureDataMie;
- const void* m_pSkyDomeTextureDataRayleigh;
- size_t m_skyDomeTexturePitch;
- int m_skyDomeTextureTimeStamp;
-
- int pad;//Enable 16 byte alignment for Vec4s
-
- // Sky dome shader constants
- Vec4 m_partialMieInScatteringConst;
- Vec4 m_partialRayleighInScatteringConst;
- Vec4 m_sunDirection;
- Vec4 m_phaseFunctionConsts;
- Vec4 m_hazeColor;
- Vec4 m_hazeColorMieNoPremul;
- Vec4 m_hazeColorRayleighNoPremul;
-
- // Sky hemisphere colors
- Vec3 m_skyColorTop;
- Vec3 m_skyColorNorth;
- Vec3 m_skyColorEast;
- Vec3 m_skyColorSouth;
- Vec3 m_skyColorWest;
-};
-
-struct SVisAreaInfo
-{
- float fHeight;
- Vec3 vAmbientColor;
- bool bAffectedByOutLights;
- bool bIgnoreSkyColor;
- bool bSkyOnly;
- float fViewDistRatio;
- bool bDoubleSide;
- bool bUseDeepness;
- bool bUseInIndoors;
- bool bOceanIsVisible;
- bool bIgnoreGI;
- bool bIgnoreOutdoorAO;
- float fPortalBlending;
-};
-
-struct SDebugFPSInfo
-{
- SDebugFPSInfo()
- : fAverageFPS(0.0f)
- , fMaxFPS(0.0f)
- , fMinFPS(0.0f)
- {
- }
- float fAverageFPS;
- float fMinFPS;
- float fMaxFPS;
-};
-
-struct SRainParams
-{
- SRainParams()
- : fAmount(0.f)
- , fCurrentAmount(0.f)
- , fRadius(0.f)
- , nUpdateFrameID(-1)
- , bIgnoreVisareas(false)
- , bDisableOcclusion(false)
- , matOccTrans(IDENTITY)
- , matOccTransRender(IDENTITY)
- , qRainRotation(IDENTITY)
- , areaAABB(AABB::RESET)
- , bApplySkyColor(false)
- , fSkyColorWeight(0.5f)
- {
- }
-
- Matrix44 matOccTrans; // Transformation matrix for rendering into a new occ map
- Matrix44 matOccTransRender; // Transformation matrix for rendering occluded rain using current occ map
- Quat qRainRotation; // Quaternion for the scene's rain entity rotation
- AABB areaAABB;
-
- Vec3 vWorldPos;
- Vec3 vColor;
-
- float fAmount;
- float fCurrentAmount;
- float fRadius;
-
- // Deferred rain params
- float fFakeGlossiness; // unused
- float fFakeReflectionAmount; // unused
- float fDiffuseDarkening;
- float fRainDropsAmount;
- float fRainDropsSpeed;
- float fRainDropsLighting;
- float fMistAmount;
- float fMistHeight;
- float fPuddlesAmount;
- float fPuddlesMaskAmount;
- float fPuddlesRippleAmount;
- float fSplashesAmount;
-
- int nUpdateFrameID;
-
- bool bApplyOcclusion;
- bool bIgnoreVisareas;
- bool bDisableOcclusion;
-
-// Summary:
-// Common scene rain parameters shared across engine and editor
- bool bApplySkyColor;
- float fSkyColorWeight;
-
- // Bus ID to listen to
-};
-
-struct SSnowParams
-{
- SSnowParams()
- : m_vWorldPos(0, 0, 0)
- , m_fRadius(0.0)
- , m_fSnowAmount(0.0)
- , m_fFrostAmount(0.0)
- , m_fSurfaceFreezing(0.0)
- , m_nSnowFlakeCount(0)
- , m_fSnowFlakeSize(0.0)
- , m_fSnowFallBrightness(0.0)
- , m_fSnowFallGravityScale(0.0)
- , m_fSnowFallWindScale(0.0)
- , m_fSnowFallTurbulence(0.0)
- , m_fSnowFallTurbulenceFreq(0.0)
- {
- }
-
- Vec3 m_vWorldPos;
- float m_fRadius;
-
- // Surface params.
- float m_fSnowAmount;
- float m_fFrostAmount;
- float m_fSurfaceFreezing;
-
-
- // Snowfall params.
- int m_nSnowFlakeCount;
- float m_fSnowFlakeSize;
- float m_fSnowFallBrightness;
- float m_fSnowFallGravityScale;
- float m_fSnowFallWindScale;
- float m_fSnowFallTurbulence;
- float m_fSnowFallTurbulenceFreq;
-};
-
-
-struct IScreenshotCallback
-{
- //
- virtual ~IScreenshotCallback(){}
- virtual void SendParameters(void* data, uint32 width, uint32 height, f32 minx, f32 miny, f32 maxx, f32 maxy) = 0;
- //
-};
-
-class IStreamedObjectListener
-{
-public:
- //
- virtual void OnCreatedStreamedObject(const char* filename, void* pHandle) = 0;
- virtual void OnRequestedStreamedObject(void* pHandle) = 0;
- virtual void OnReceivedStreamedObject(void* pHandle) = 0;
- virtual void OnUnloadedStreamedObject(void* pHandle) = 0;
- virtual void OnBegunUsingStreamedObjects(void** pHandles, size_t numHandles) = 0;
- virtual void OnEndedUsingStreamedObjects(void** pHandles, size_t numHandles) = 0;
- virtual void OnDestroyedStreamedObject(void* pHandle) = 0;
- //
-protected:
- virtual ~IStreamedObjectListener() {}
-};
-
-#pragma pack(push, 16)
-
-struct SFogVolumeData
-{
- AABB avgAABBox;
- ColorF fogColor;
- int m_volumeType;
- Vec3 m_heightFallOffBasePoint;
- float m_densityOffset;
- Vec3 m_heightFallOffDirScaled;
- float m_globalDensity;
-
- SFogVolumeData() :
- avgAABBox(AABB::RESET),
- m_globalDensity(0.0f),
- m_densityOffset(0.0f),
- m_volumeType(0),
- m_heightFallOffBasePoint(Vec3(0, 0, 0)),
- m_heightFallOffDirScaled(Vec3(0, 0, 0)),
- fogColor(ColorF(1.0f, 1.0f, 1.0f, 1.0f))
- {
- }
-
-};
-
-// Summary:
-// Light volumes data
-
-#define LIGHTVOLUME_MAXLIGHTS 16
-
-struct SLightVolume
-{
- struct SLightData
- {
- SLightData()
- : vPos(0, 0, 0, 0)
- , vColor(0, 0, 0, 0)
- , vParams(0, 0, 0, 0) {}
- SLightData(const Vec4& vInPos, const Vec4& vInColor, const Vec4& vInParams)
- : vPos(vInPos)
- , vColor(vInColor)
- , vParams(vInParams) {}
-
- Vec4 vPos;
- Vec4 vColor;
- Vec4 vParams;
- };
-
- SLightVolume()
- {
- pData.reserve(LIGHTVOLUME_MAXLIGHTS);
- }
-
- typedef DynArray LightDataVector;
-
- DEFINE_ALIGNED_DATA(LightDataVector, pData, 16);
-};
-
-#pragma pack(pop)
-
-struct CRNTmpData
-{
- struct SRNUserData
- {
- int m_narrDrawFrames[MAX_RECURSION_LEVELS];
- SLodDistDissolveTransitionState lodDistDissolveTransitionState;
- Matrix34 objMat;
- OcclusionTestClient m_OcclState;
- struct IClipVolume* m_pClipVolume;
- SBending m_Bending;
- SBending m_BendingPrev;
- Vec3 vCurrentWind;
- uint32 nBendingLastFrame : 29;
- uint32 bWindCurrent : 1;
- uint32 bBendingSet : 1;
- uint16 nCubeMapId;
- uint16 nCubeMapIdCacheClearCounter;
- uint8 nWantedLod;
- CRenderObject* m_pRenderObject[MAX_STATOBJ_LODS_NUM];
- CRenderObject* m_arrPermanentRenderObjects[MAX_STATOBJ_LODS_NUM];
- } userData;
-
- CRNTmpData() { memset(this, 0, sizeof(*this)); assert((void*)this == (void*)&this->userData); nPhysAreaChangedProxyId = ~0; }
- CRNTmpData* pNext, * pPrev;
- CRNTmpData** pOwnerRef;
- uint32 nFrameInfoId;
- uint32 nPhysAreaChangedProxyId;
-
- void Unlink()
- {
- if (!pNext || !pPrev)
- {
- return;
- }
- pNext->pPrev = pPrev;
- pPrev->pNext = pNext;
- pNext = pPrev = NULL;
- }
-
- void Link(CRNTmpData* Before)
- {
- if (pNext || pPrev)
- {
- return;
- }
- pNext = Before->pNext;
- Before->pNext->pPrev = this;
- Before->pNext = this;
- pPrev = Before;
- }
-
- int Count()
- {
- int nCounter = 0;
- for (CRNTmpData* pElem = pNext; pElem != this; pElem = pElem->pNext)
- {
- nCounter++;
- }
- return nCounter;
- }
-
- void OffsetPosition(const Vec3& delta)
- {
- userData.objMat.SetTranslation(userData.objMat.GetTranslation() + delta);
- }
-};
-
-
-// Summary:
-// Interface to the 3d Engine.
-struct I3DEngine
- : public IProcess
-{
- struct SObjectsStreamingStatus
- {
- int nReady;
- int nInProgress;
- int nTotal;
- int nActive;
- int nAllocatedBytes;
- int nMemRequired;
- int nMeshPoolSize; // in MB
-
- };
-
- struct OceanAnimationData
- {
- float fWindDirection;
- float fWindSpeed;
- float fWavesSpeed;
- float fWavesAmount;
- float fWavesSize;
- float fWindDirectionU;
- float fWindDirectionV;
- };
-
- struct SStremaingBandwidthData
- {
- SStremaingBandwidthData()
- {
- memset(this, 0, sizeof(SStremaingBandwidthData));
- }
- float fBandwidthActual;
- float fBandwidthRequested;
- };
-
- enum eStreamingSubsystem
- {
- eStreamingSubsystem_Textures,
- eStreamingSubsystem_Objects,
- eStreamingSubsystem_Audio,
- };
-
- using LoadStaticObjectAsyncResult = AZStd::function)>;
-
- struct StaticObjectAsyncLoadRequest
- {
- StaticObjectAsyncLoadRequest() = default;
-
- LoadStaticObjectAsyncResult m_callback;
- string m_filename;
- string m_geomName;
- bool m_useStreaming;
- unsigned long m_loadingFlags;
- };
-
- struct CausticsParams
- {
- float tiling = 0.0f;
- float distanceAttenuation = 0.0f;
- float height = 0.0f;
- float depth = 0.0f;
- float intensity = 0.0f;
- };
-
-
- //
- // Summary:
- // Initializes the 3D Engine.
- // See Also:
- // ShutDown
- // Notes:
- // Only call once, after creating the instance.
- virtual bool Init() = 0;
-
-
- // Summary:
- // Sets the path used to load levels.
- // See Also:
- // LoadLevel
- // Arguments:
- // szFolderName - Should contains the folder to be used
- virtual void SetLevelPath(const char* szFolderName) = 0;
-
- virtual bool CheckMinSpec(uint32 nMinSpec) = 0;
-
- virtual void PrepareOcclusion(const CCamera& rCamera) = 0;
- virtual void EndOcclusion() = 0;
- // Description:
- // Will load a level from the folder specified with SetLevelPath. If a
- // level is already loaded, the resources will be deleted before.
- // See Also:
- // SetLevelPath
- // Arguments:
- // szFolderName - Name of the subfolder to load
- // szMissionName - Name of the mission
- // Return Value:
- // A boolean which indicate the result of the function; true is
- // succeed, or false if failed.
- // Summary:
- // Load a level.
- virtual bool LoadLevel(const char* szFolderName, const char* szMissionName) = 0;
- virtual bool InitLevelForEditor(const char* szFolderName, const char* szMissionName) = 0;
- virtual bool LevelLoadingInProgress() = 0;
- // Summary:
- // Handles any work needed at start of new frame.
- // Notes:
- // Should be called for every frame.
- virtual void OnFrameStart() = 0;
-
- // Description:
- // Must be called after the game completely finishes loading the level.
- // 3D engine uses it to pre-cache some resources needed for rendering.
- // See Also:
- // LoadLevel
- // Summary:
- // Pre-caches some resources need for rendering.
- virtual void PostLoadLevel() = 0;
-
- // Description:
- // Loads the required assets for a null level.
- virtual void LoadEmptyLevel() = 0;
-
- // Summary:
- // Clears all rendering resources, all objects, characters and materials, voxels and terrain.
- // Notes:
- // Should always be called before LoadLevel, and also before loading textures from a script.
- virtual void UnloadLevel() = 0;
-
-
- // Summary:
- // Updates the 3D Engine.
- // Notes:
- // Should be called for every frame.
- virtual void Update() = 0;
-
- // Summary:
- // Returns the Camera used for Rendering on 3DEngine Side, normaly equal to the view camera, except if frozen with e_camerafreeze
- // Notes:
- // Only valid during RenderWorld(else the camera of the last frame is used)
- // This is the camera which should be used for all Engine side culling (since e_camerafreeze allows easy debugging then)
- virtual const CCamera& GetRenderingCamera() const = 0;
- virtual float GetZoomFactor() const = 0;
-
- // Summary:
- // clear all per frame temp data used in SRenderingPass
- virtual void Tick() = 0;
-
- // Summary:
- // Update all ShaderItems flags, only required after shaders were reloaded at runtime
- virtual void UpdateShaderItems() = 0;
-
- // Summary:
- // Deletes the 3D Engine instance.
- virtual void Release() = 0;
-
- // Summary:
- // Draws the world.
- // See Also:
- // SetCamera
- // Arguments:
- // szDebugName - name that can be visualized for debugging purpose, must not be 0
- virtual void RenderWorld(int nRenderFlags, const SRenderingPassInfo& passInfo, const char* szDebugName) = 0;
-
- virtual void RenderSceneReflection(int nRenderFlags, const SRenderingPassInfo& passInfo) = 0;
-
- // Summary:
- // Prepares for the world stream update, should be called before rendering
- virtual void PreWorldStreamUpdate(const CCamera& cam) = 0;
-
- // Summary:
- // Performs the actual world streaming update. PreWorldStreamUpdate must be called before
- virtual void WorldStreamUpdate() = 0;
-
- // Summary:
- // Shuts down the 3D Engine.
- virtual void ShutDown() = 0;
-
- // Summary:
- // Loads a static object from a CGF file. Does not increment the static object's reference counter. The reference returned is not guaranteed to be valid when run outside the main thread. Best used for priming the cache
- // See Also:
- // IStatObj
- // Arguments:
- // fileName - CGF Filename - should not be 0 or ""
- // geomName - Optional name of geometry inside CGF.
- // subObject - [Out]Optional Out parameter,Pointer to the
- // loadingFlags - Zero or a bitwise combination of the flags from ELoadingFlags, defined in IMaterial.h, under the interface IMaterialManager.
- // data - Raw buffer contain CGF data.
- // dataSize - Size of the raw data buffer.
- // Return Value:
- // A pointer to an object derived from IStatObj.
- virtual IStatObj* LoadStatObjUnsafeManualRef(const char* fileName, const char* geomName = nullptr, /*[Out]*/ IStatObj::SSubObject** subObject = nullptr,
- bool useStreaming = true, unsigned long loadingFlags = 0, const void* data = nullptr, int dataSize = 0) = 0;
-
- // Summary:
- // Loads a static object from a CGF file. Increments the static object's reference counter. This method is threadsafe. Not suitable for preloading
- // See Also:
- // IStatObj
- // Arguments:
- // fileName - CGF Filename - should not be 0 or "", even if data is provided.
- // geomName - Optional name of geometry inside CGF.
- // subObject - [Out]Optional Out parameter,Pointer to the
- // loadingFlags - Zero or a bitwise combination of the flags from ELoadingFlags, defined in IMaterial.h, under the interface IMaterialManager.
- // data - Raw buffer contain CGF data.
- // dataSize - Size of the raw data buffer.
- // Return Value:
- // A smart pointer to an object derived from IStatObj.
- virtual _smart_ptr LoadStatObjAutoRef(const char* fileName, const char* geomName = nullptr, /*[Out]*/ IStatObj::SSubObject** subObject = nullptr,
- bool useStreaming = true, unsigned long loadingFlags = 0, const void* data = nullptr, int dataSize = 0) = 0;
-
- // Summary:
- // Flushes queued async mesh loads.
- virtual void ProcessAsyncStaticObjectLoadRequests() = 0;
-
- // Summary:
- // Loads a static object from a CGF file asynchronously and invokes a callback on completion.
- // Actual load will occur on the main thread.
- // See Also:
- // IStatObj
- // Arguments:
- // callback - The user callback to invoke on completion.
- // szFileName - CGF Filename - should not be 0 or ""
- // szGeomName - Optional name of geometry inside CGF.
- // ppSubObject - [Out]Optional Out parameter,Pointer to the
- // nLoadingFlags - Zero or a bitwise combination of the flags from ELoadingFlags,
- // defined in IMaterial.h, under the interface IMaterialManager.
- // Return Value:
- // None
- virtual void LoadStatObjAsync(LoadStaticObjectAsyncResult resultCallback, const char* szFileName, const char* szGeomName = nullptr, bool bUseStreaming = true, unsigned long nLoadingFlags = 0) = 0;
-
- // Summary:
- // Finds a static object created from the given filename
- // See Also:
- // IStatObj
- // Arguments:
- // szFileName - CGF Filename - should not be 0 or ""
- // Return Value:
- // A pointer to an object derived from IStatObj.
- virtual IStatObj* FindStatObjectByFilename(const char* filename) = 0;
-
- // Summary:
- // Gets gsm range
- // Return Value:
- // An integer representing the gsm range.
- virtual const float GetGSMRange() = 0;
-
- // Summary:
- // Gets gsm range step
- // Return Value:
- // An integer representing the gsm range step
- virtual const float GetGSMRangeStep() = 0;
-
- // Summary:
- // Gets the amount of loaded objects.
- // Return Value:
- // An integer representing the amount of loaded objects.
- virtual int GetLoadedObjectCount() { return 0; }
-
- // Summary:
- // Fills pObjectsArray with pointers to loaded static objects
- // if pObjectsArray is NULL only fills nCount parameter with amount of loaded objects.
- virtual void GetLoadedStatObjArray(IStatObj** pObjectsArray, int& nCount) = 0;
-
- // Summary:
- // Gets stats on streamed objects
- virtual void GetObjectsStreamingStatus(SObjectsStreamingStatus& outStatus) = 0;
-
- // Summary:
- // Gets stats on the streaming bandwidth requests from subsystems
- // Arguments:
- // subsystem - the streaming subsystem we want bandwidth data for
- // outData - structure containing the bandwidth data for the subsystem requested
- virtual void GetStreamingSubsystemData(int subsystem, SStremaingBandwidthData& outData) = 0;
-
- // Summary:
- // Registers an entity to be rendered.
- // Arguments:
- // pEntity - The entity to render
- virtual void RegisterEntity(IRenderNode* pEntity, int nSID = -1, int nSIDConsideredSafe = -1) = 0;
-
- // Summary:
- // Selects an entity for debugging.
- // Arguments:
- // pEntity - The entity to render
- virtual void SelectEntity(IRenderNode* pEntity) = 0;
-
- //////////////////////////////////////////////
- // Start Confetti //////////////////////////
- // Summary:
- // Return the setting for sun shadows. Return false for sub classes without sun shadows settings.
- virtual bool IsSunShadows(){ return false; };
- // End Confetti//////////////////////////////
- //////////////////////////////////////////////
-
- // Summary:
- // Offers same functionality as Cry3DEngineBase::MakeSystemMaterialFromShader
- virtual _smart_ptr MakeSystemMaterialFromShaderHelper(const char* sShaderName, SInputShaderResources* Res = NULL) = 0;
-
- virtual bool CheckMinSpecHelper(uint32 nMinSpec) = 0;
-
- virtual void OnCasterDeleted(IShadowCaster* pCaster) = 0;
-
- virtual void GetStatObjAndMatTables(DynArray* pStatObjTable, DynArray<_smart_ptr>* pMatTable, DynArray* pStatInstGroupTable, uint32 nObjTypeMask) = 0;
-
-#ifndef _RELEASE
- enum EDebugDrawListAssetTypes
- {
- DLOT_ALL = 0,
- DLOT_CHARACTER = BIT(2),
- DLOT_STATOBJ = BIT(3)
- };
-
- struct SObjectInfoToAddToDebugDrawList
- {
- const char* pName;
- const char* pClassName;
- const char* pFileName;
- IRenderNode* pRenderNode;
- uint32 numTris;
- uint32 numVerts;
- uint32 texMemory;
- uint32 meshMemory;
- EDebugDrawListAssetTypes type;
- const AABB* pBox;
- const Matrix34* pMat;
- };
-
- virtual void AddObjToDebugDrawList(SObjectInfoToAddToDebugDrawList& objInfo) = 0;
- virtual bool IsDebugDrawListEnabled() const = 0;
-#endif
-
-
- // Summary:
- // Notices the 3D Engine to stop rendering a specified entity.
- // Arguments:
- // pEntity - The entity to stop render
- virtual void UnRegisterEntityDirect(IRenderNode* pEntity) = 0;
- virtual void UnRegisterEntityAsJob(IRenderNode* pEnt) = 0;
- // Summary:
- // Returns whether a world pos is under water.
- virtual bool IsUnderWater(const Vec3& vPos) const = 0;
-
- // Summary:
- // Returns whether ocean volume is visible or not.
- virtual void SetOceanRenderFlags(uint8 nFlags) = 0;
- virtual uint8 GetOceanRenderFlags() const = 0;
- virtual uint32 GetOceanVisiblePixelsCount() const = 0;
-
- // Summary:
- // Gets the closest walkable bottom z straight beneath the given reference position.
- // Notes:
- // This function will take into account both the global terrain elevation and local voxel (or other solid walkable object).
- // Arguments:
- // referencePos - Position from where to start searching downwards.
- // maxRelevantDepth - Max depth caller is interested in relative to referencePos (for ray casting performance reasons).
- // objtypes - expects physics entity flags. Use this to specify what object types make a valid bottom for you.
- // Return Value:
- // A float value which indicate the global world z of the bottom level beneath the referencePos.
- // If the referencePos is below terrain but not inside any voxel area BOTTOM_LEVEL_UNKNOWN is returned.
- virtual float GetBottomLevel(const Vec3& referencePos, float maxRelevantDepth, int objtypes) = 0;
- // A set of overloads for enabling users to use different sets of input params. Basically, only
- // referencePos is mandatory. The overloads as such don't need to be virtual but this seems to be
- // a purely virtual interface.
- virtual float GetBottomLevel(const Vec3& referencePos, float maxRelevantDepth = 10.0f) = 0;
- virtual float GetBottomLevel(const Vec3& referencePos, int objflags) = 0;
-
- // Summary:
- // Gets the ocean water level. Fastest option, always prefer is only ocean height required.
- // Notes:
- // This function will take into account just the global water level.
- // Return Value:
- // A float value which indicate the water level. In case no water was
- // found at the specified location, the value WATER_LEVEL_UNKNOWN will
- // be returned.
- virtual float GetWaterLevel() = 0;
-
- // Summary:
- // Gets the closest walkable bottom z straight beneath the given reference position.
- // - Use with caution the accurate query - SLOW
- // Notes:
- // This function will take into account both the global water level and any water volume present.
- // Function is provided twice for performance with diff. arguments.
- // Arguments:
- // pvPos - Desired position to inspect the water level
- // pent - Pointer to return the physical entity to test against (optional)
- // Return Value:
- // A float value which indicate the water level. In case no water was
- // found at the specified location, the value WATER_LEVEL_UNKNOWN will
- // be returned.
- virtual float GetWaterLevel(const Vec3* pvPos, IPhysicalEntity* pent = NULL, bool bAccurate = false) = 0;
-
- // Summary:
- // Gets the ocean water level for a specified position.
- // - Use with caution the accurate query - SLOW
- // Notes:
- // This function only takes into account ocean water.
- // Arguments:
- // pCurrPos - Position to check water level
- // Return Value:
- // A float value which indicate the water level.
- virtual float GetAccurateOceanHeight(const Vec3& pCurrPos) const = 0;
-
- // Summary:
- // Gets caustics parameters.
- virtual CausticsParams GetCausticsParams() const = 0;
-
- // Summary:
- // Gets ocean animation parameters.
- virtual OceanAnimationData GetOceanAnimationParams() const = 0;
-
- // Summary:
- // Gets HDR setup parameters.
- // Return Value:
- virtual void GetHDRSetupParams (Vec4 pParams[5]) const = 0;
-
- // Summary:
- // Removes all particles and decals from the world.
- virtual void ResetParticlesAndDecals() = 0;
-
- // Summary:
- // Creates new decals on the walls, static objects, terrain and entities.
- // Arguments:
- // Decal - Structure describing the decal effect to be applied
- virtual void CreateDecal(const CryEngineDecalInfo& Decal) = 0;
-
- // Summary:
- // Removes decals in a specified range.
- // Arguments:
- // vAreaBox - Specify the area in which the decals will be removed
- // pEntity - if not NULL will only delete decals attached to this entity
- virtual void DeleteDecalsInRange(AABB* pAreaBox, IRenderNode* pEntity) = 0;
-
- // Summary:
- // Sets the current sun base color.
- virtual void SetSunColor(Vec3 vColor) = 0;
-
- // Summary:
- // Gets the current sun animated color.
- virtual Vec3 GetSunAnimColor() = 0;
-
- // Summary:
- // Sets the current sky brightening multiplier.
- virtual void SetSunAnimColor(const Vec3& color) = 0;
-
- // Summary:
- // Sets the current sun animation speed.
- virtual float GetSunAnimSpeed() = 0;
-
- // Summary:
- virtual void SetSunAnimSpeed(float sunAnimSpeed) = 0;
-
- // Summary:
- // Gets the current sun animation phase.
- virtual AZ::u8 GetSunAnimPhase() = 0;
- // Summary:
- // Sets the current sun animation phase.
- virtual void SetSunAnimPhase(AZ::u8 sunAnimPhase) = 0;
-
- // Summary:
- // Gets the current sun animation index.
- virtual AZ::u8 GetSunAnimIndex() = 0;
-
- // Summary:
- // Sets the current sun animation index.
- virtual void SetSunAnimIndex(AZ::u8 sunAnimIndex) = 0;
-
- // Summary:
- // Sets current rain parameters.
- virtual void SetRainParams(const SRainParams& rainParams) = 0;
-
- // Summary:
- // Gets the validity and fills current rain parameters.
- virtual bool GetRainParams(SRainParams& rainParams) = 0;
-
- // Summary:
- // Sets current snow surface parameters.
- virtual void SetSnowSurfaceParams(const Vec3& vCenter, float fRadius, float fSnowAmount, float fFrostAmount, float fSurfaceFreezing) = 0;
-
- // Summary:
- // Gets current snow surface parameters.
- virtual bool GetSnowSurfaceParams(Vec3& vCenter, float& fRadius, float& fSnowAmount, float& fFrostAmount, float& fSurfaceFreezing) = 0;
-
- // Summary:
- // Sets current snow parameters.
- virtual void SetSnowFallParams(int nSnowFlakeCount, float fSnowFlakeSize, float fSnowFallBrightness, float fSnowFallGravityScale, float fSnowFallWindScale, float fSnowFallTurbulence, float fSnowFallTurbulenceFreq) = 0;
-
- // Summary:
- // Gets current snow parameters.
- virtual bool GetSnowFallParams(int& nSnowFlakeCount, float& fSnowFlakeSize, float& fSnowFallBrightness, float& fSnowFallGravityScale, float& fSnowFallWindScale, float& fSnowFallTurbulence, float& fSnowFallTurbulenceFreq) = 0;
-
- // Summary:
- // Sets the view distance scale.
- // Arguments:
- // fScale - may be between 0 and 1, 1.f = Unmodified view distance set by level designer, value of 0.5 will reduce it twice
- // Notes:
- // This value will be reset automatically to 1 on next level loading.
- virtual void SetMaxViewDistanceScale(float fScale) = 0;
-
- // Summary:
- // Gets the view distance.
- // Return Value:
- // A float value representing the maximum view distance.
- virtual float GetMaxViewDistance(bool bScaled = true) = 0;
-
- virtual const SFrameLodInfo& GetFrameLodInfo() const = 0;
- virtual void SetFrameLodInfo(const SFrameLodInfo& frameLodInfo) = 0;
-
- // Summary:
- // Sets the fog color.
- virtual void SetFogColor(const Vec3& vFogColor) = 0;
-
- // Summary:
- // Gets the fog color.
- virtual Vec3 GetFogColor() = 0;
-
- // Summary:
- // Gets various sky light parameters.
- virtual void GetSkyLightParameters(Vec3& sunDir, Vec3& sunIntensity, float& Km, float& Kr, float& g, Vec3& rgbWaveLengths) = 0;
-
- // Summary:
- // Sets various sky light parameters.
- virtual void SetSkyLightParameters(const Vec3& sunDir, const Vec3& sunIntensity, float Km, float Kr, float g, const Vec3& rgbWaveLengths, bool forceImmediateUpdate = false) = 0;
-
- // Return Value:
- // In logarithmic scale -4.0 .. 4.0
- virtual float GetLightsHDRDynamicPowerFactor() const = 0;
-
- // Return true if tessellation is allowed for given render object
- virtual bool IsTessellationAllowed(const CRenderObject* pObj, const SRenderingPassInfo& passInfo, bool bIgnoreShadowPass = false) const = 0;
-
- // allows to modify material on render nodes at run-time (make sure it is properly restored back)
- virtual void SetRenderNodeMaterialAtPosition(EERType eNodeType, const Vec3& vPos, _smart_ptr pMat) = 0;
-
- // override the camera precache point with the requested position for the current round
- virtual void OverrideCameraPrecachePoint(const Vec3& vPos) = 0;
-
- // begin streaming of meshes and textures for specified position, pre-cache stops after fTimeOut seconds
- virtual int AddPrecachePoint(const Vec3& vPos, const Vec3& vDir, float fTimeOut = 3.f, float fImportanceFactor = 1.0f) = 0;
- virtual void ClearPrecachePoint(int id) = 0;
- virtual void ClearAllPrecachePoints() = 0;
-
- virtual void GetPrecacheRoundIds(int pRoundIds[MAX_STREAM_PREDICTION_ZONES]) = 0;
-
- virtual void TraceFogVolumes(const Vec3& vPos, const AABB& objBBox, SFogVolumeData& fogVolData, const SRenderingPassInfo& passInfo, bool fogVolumeShadingQuality) = 0;
-
- //DOC-IGNORE-BEGIN
-
- // Internal functions, mostly used by the editor, which won't be documented for now
-
- // Summary:
- // Removes all static objects on the map (for editor)
- virtual void RemoveAllStaticObjects(int nSID = DEFAULT_SID) = 0;
-
- // Summary:
- // Sets group parameters
- virtual bool SetStatInstGroup(int nGroupId, const IStatInstGroup& siGroup, int nSID = 0) = 0;
-
- // Summary:
- // Gets group parameters
- virtual bool GetStatInstGroup(int nGroupId, IStatInstGroup& siGroup, int nSID = 0) = 0;
-
- //DOC-IGNORE-END
-
- // Summary:
- // Notifies of an explosion, and maybe creates an hole in the terrain
- // Description:
- // This function should usually make sure that no static objects are near before making the hole.
- // Arguments:
- // vPos - Position of the explosion
- // fRadius - Radius of the explosion
- // bDeformTerrain - Allow to deform the terrain
- virtual void OnExplosion(Vec3 vPos, float fRadius, bool bDeformTerrain = true) = 0;
-
- // Summary:
- // Sets the physics material enumerator
- // Arguments:
- // pPhysMaterialEnumerator - The physics material enumarator to set
- virtual void SetPhysMaterialEnumerator(IPhysMaterialEnumerator* pPhysMaterialEnumerator) = 0;
-
- // Summary:
- // Gets the physics material enumerator
- // Return Value:
- // A pointer to an IPhysMaterialEnumerator derived object.
- virtual IPhysMaterialEnumerator* GetPhysMaterialEnumerator() = 0;
-
- //DOC-IGNORE-BEGIN
- //Internal functions
-
- // Summary:
- // Allows to enable fog in editor
- virtual void SetupDistanceFog() = 0;
-
- // Summary:
- // Loads environment settings for specified mission
- virtual void LoadMissionDataFromXMLNode(const char* szMissionName) = 0;
-
- virtual void LoadEnvironmentSettingsFromXML(XmlNodeRef pInputNode, int nSID = DEFAULT_SID) = 0;
-
- // Summary:
- // This one is called by the editor when the terrain editing tools are not being built.
- // This is the case when the game developers are using external tools to author terrain.
- // The Octree data and the terrain heightmap data are stored in the same file.
- // This method makes sure only the non-terrain data of the Octree is loaded.
- virtual bool LoadCompiledOctreeForEditor() = 0;
-
- //DOC-IGNORE-END
-
- //DOC-IGNORE-BEGIN
- // Set direction to the sun
- // virtual void SetSunDir( const Vec3& vNewSunDir ) = 0;
-
- // Summary:
- // Return non-normalized direction to the sun
- virtual Vec3 GetSunDir() const = 0;
-
- // Summary:
- // Return normalized direction to the sun
- virtual Vec3 GetSunDirNormalized() const = 0;
-
- // Summary:
- // Return realtime (updated every frame with real sun position) normalized direction to the scene
- virtual Vec3 GetRealtimeSunDirNormalized() const = 0;
-
- //Internal function used by 3d engine and renderer
- // Summary:
- // Gets distance to the sector containig ocean water
- virtual float GetDistanceToSectorWithWater() = 0;
- //DOC-IGNORE-END
-
- // Summary:
- // Gets the sun color
- // Notes:
- // Should have been specified in the editor.
- // Return Value:
- // An rgb value contained in a Vec3 object.
- virtual Vec3 GetSunColor() const = 0;
-
- // Summary:
- // Retrieves the current SSAO multiplier
- // Notes:
- // Return Value:
- // scalar value
- virtual float GetSSAOAmount() const = 0;
-
- // Summary:
- // Retrieves the current SSAO contrast multiplier
- // Notes:
- // Return Value:
- // scalar value
- virtual float GetSSAOContrast() const = 0;
- // Summary:
- // Frees entity render info.
- virtual void FreeRenderNodeState(IRenderNode* pEntity) = 0;
-
- // Summary:
- // Adds the level's path to a specified filename.
- // Arguments:
- // szFileName - The filename for which we need to add the path
- // Return Value:
- // Full path for the filename; including the level path and the filename appended after.
- virtual const char* GetLevelFilePath(const char* szFileName) = 0;
-
- // Summary:
- // Displays statistic on the 3d Engine.
- // Arguments:
- // fTextPosX - X position for the text
- // 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, bool bEnhanced) = 0;
-
- // Summary:
- // Displays CPU and GPU memory usage statistics on screen
- virtual void DisplayMemoryStatistics() = 0;
-
- // Summary:
- // Draws text right aligned at the y pixel precision.
- virtual void DrawTextRightAligned(const float x, const float y, const char* format, ...) PRINTF_PARAMS(4, 5) = 0;
- virtual void DrawTextRightAligned(const float x, const float y, const float scale, const ColorF& color, const char* format, ...) PRINTF_PARAMS(6, 7) = 0;
-
- virtual void DrawBBoxHelper(const Vec3& vMin, const Vec3& vMax, ColorB col = Col_White) = 0;
- virtual void DrawBBoxHelper(const AABB& box, ColorB col = Col_White) = 0;
-
- // Summary:
- // Enables or disables portal at a specified position.
- // Arguments:
- // vPos - Position to place the portal
- // bActivate - Set to true in order to enable the portal, or to false to disable
- // szEntityName -
- virtual void ActivatePortal(const Vec3& vPos, bool bActivate, const char* szEntityName) = 0;
-
- //DOC-IGNORE-BEGIN
- // Summary:
- // Counts memory usage
- virtual void GetMemoryUsage(ICrySizer* pSizer) const = 0;
-
- // Summary:
- // Counts resource memory usage
- // Arguments:
- // cstAABB - Use the whole level AABB if you want to grab the resources
- // from the whole level. For height level, use something BIG
- // (ie: +-FLT_MAX)
- virtual void GetResourceMemoryUsage(ICrySizer* pSizer, const AABB& cstAABB) = 0;
- //DOC-IGNORE-END
-
- // Summary:
- // Creates a new VisArea.
- // Return Value:
- // A pointer to a newly created VisArea object
- virtual IVisArea* CreateVisArea(uint64 visGUID) = 0;
-
- // Summary:
- // Deletes a VisArea.
- // Arguments:
- // pVisArea - A pointer to the VisArea to delete
- virtual void DeleteVisArea(IVisArea* pVisArea) = 0;
-
- //mat: todo
-
- // Summary:
- // Updates the VisArea
- // Arguments:
- // pArea -
- // pPoints -
- // nCount -
- // szName -
- // info -
- // bReregisterObjects -
- virtual void UpdateVisArea(IVisArea* pArea, const Vec3* pPoints, int nCount, const char* szName, const SVisAreaInfo& info, bool bReregisterObjects) = 0;
-
- // Summary:
- // Determines if two VisAreas are connected.
- // Description:
- // Used to determine if a sound is potentially hearable between two VisAreas.
- // Arguments:
- // pArea1 - A pointer to a VisArea
- // pArea2 - A pointer to a VisArea
- // nMaxRecursion - Maximum number of recursions to be done
- // bSkipDisabledPortals - Indicate if disabled portals should be skipped
- // Return Value:
- // A boolean value set to true if the two VisAreas are connected, else false will be returned.
- virtual bool IsVisAreasConnected(IVisArea* pArea1, IVisArea* pArea2, int nMaxRecursion = 1, bool bSkipDisabledPortals = true) = 0;
-
- // Summary:
- // Creates a ClipVolume.
- // Return Value:
- // A pointer to a newly created ClipVolume object
- virtual IClipVolume* CreateClipVolume() = 0;
-
- // Summary:
- // Deletes a ClipVolume.
- // Arguments:
- // pClipVolume - A pointer to the ClipVolume to delete
- virtual void DeleteClipVolume(IClipVolume* pClipVolume) = 0;
-
- // Summary:
- // Updates a ClipVolume
- // Arguments:
- // pClipVolume - Pointer to volume that needs updating
- // pRenderMesh - Pointer to new render mesh
- // worldTM - Updated world transform
- // szName - Updated ClipVolume name
- virtual void UpdateClipVolume(IClipVolume* pClipVolume, _smart_ptr pRenderMesh, IBSPTree3D* pBspTree, const Matrix34& worldTM, bool bActive, uint32 flags, const char* szName) = 0;
-
- //mat: todo
-
- // Summary:
- // Creates instance of IRenderNode object with specified type.
- virtual IRenderNode* CreateRenderNode(EERType type) = 0;
-
- // Summary:
- // Delete RenderNode object.
- virtual void DeleteRenderNode(IRenderNode* pRenderNode) = 0;
-
-
- // Summary:
- // Gets wind direction and force, averaged within a box.
- virtual Vec3 GetWind(const AABB& box, bool bIndoors) const = 0;
-
- // Summary:
- // Gets the global wind vector.
- virtual Vec3 GetGlobalWind(bool bIndoors) const = 0;
-
- // Summary:
- // Gets wind direction and forace at the sample points provided.
- // Note: the positions defining the samples will be overwritten
- // with the accumulated wind influences.
- virtual bool SampleWind(Vec3* pSamples, int nSamples, const AABB& volume, bool bIndoors) const = 0;
-
- // Description:
- // Gets the VisArea which is present at a specified point.
- // Arguments:
- // vPos:
- // Return Value:
- // VisArea containing point, if any. 0 otherwise.
- virtual IVisArea* GetVisAreaFromPos(const Vec3& vPos) = 0;
-
- // Description:
- // Tests for intersection against Vis Areas.
- // Arguments:
- // box: Volume to test for intersection.
- // pNodeCache (out, optional): Set to a cached pointer, for quicker calls to ClipToVisAreas.
- // Return Value:
- // Whether box intersects any vis areas.
- virtual bool IntersectsVisAreas(const AABB& box, void** pNodeCache = 0) = 0;
-
- // Description:
- // Clips geometry against the boundaries of VisAreas.
- // Arguments:
- // pInside: Vis Area to clip inside of. If 0, clip outside all Vis Areas.
- // sphere -
- // vNormal -
- // pNodeChache -
- // Return Value:
- // Whether it was clipped
- virtual bool ClipToVisAreas(IVisArea* pInside, Sphere& sphere, Vec3 const& vNormal, void* pNodeCache = 0) = 0;
-
- // Summary:
- // Enables or disables ocean rendering.
- // Arguments:
- // bOcean - Will enable or disable the rendering of ocean
- virtual void EnableOceanRendering(bool bOcean) = 0;
-
- // Description:
- // Register a texture load handler
- virtual void AddTextureLoadHandler(ITextureLoadHandler* pHandler) = 0;
-
- // Description
- // Unregister a texture load handler
- virtual void RemoveTextureLoadHandler(ITextureLoadHandler* pHandler) = 0;
-
- // Description:
- // Get a texture load handler for a given extension
- virtual ITextureLoadHandler* GetTextureLoadHandlerForImage(const char* ext) = 0;
- // Summary:
- // Creates a new light source.
- // Return Value:
- // Pointer to newly created light or -1 if it fails.
- virtual struct ILightSource* CreateLightSource() = 0;
-
- // Summary:
- // Deletes a light.
- // Arguments:
- // Pointer to the light
- virtual void DeleteLightSource(ILightSource* pLightSource) = 0;
-
- // Summary:
- // Gives access to the list holding all static light sources
- // Return Value:
- // An array holding all the CDLight pointers.
- virtual const PodArray* GetLightEntities() = 0;
-
- // Summary:
- // Gives access to list holding all lighting volumes
- // Return Value:
- // An array holding all the SLightVolume pointers.
- virtual void GetLightVolumes(threadID nThreadID, SLightVolume*& pLightVols, uint32& nNumVols) = 0;
-
- // Summary:
- // Registers a volume for lighting
- // Return Value:
- // The index of the registered volume.
- virtual uint16 RegisterVolumeForLighting(const Vec3& vPos, f32 fRadius, uint8 nClipVolumeRef, const SRenderingPassInfo& passInfo) = 0;
-
- // Summary:
- // Reload the heightmap.
- // Description:
- // Reloading the heightmap will resets all decals and particles.
- // Notes:
- // In future will restore deleted vegetations
- // Returns:
- // success
- virtual bool RestoreTerrainFromDisk(int nSID = 0) = 0;
-
- //DOC-IGNORE-BEGIN
- // tmp
- virtual const char* GetFilePath(const char* szFileName) { return GetLevelFilePath(szFileName); }
- //DOC-IGNORE-END
-
- // Summary:
- // Post processing effects interfaces.
- virtual class IPostEffectGroupManager* GetPostEffectGroups() const = 0;
- virtual class IPostEffectGroup* GetPostEffectBaseGroup() const = 0;
-
- // Most code should use either GetPostEffectGroups() or GetPostEffectBaseGroup() instead of these
- virtual void SetPostEffectParam(const char* pParam, float fValue, bool bForceValue = false) const = 0;
- virtual void SetPostEffectParamVec4(const char* pParam, const Vec4& pValue, bool bForceValue = false) const = 0;
- virtual void SetPostEffectParamString(const char* pParam, const char* pszArg) const = 0;
-
- virtual void GetPostEffectParam(const char* pParam, float& fValue) const = 0;
- virtual void GetPostEffectParamVec4(const char* pParam, Vec4& pValue) const = 0;
- virtual void GetPostEffectParamString(const char* pParam, const char*& pszArg) const = 0;
-
- virtual int32 GetPostEffectID(const char* pPostEffectName) = 0;
-
- virtual void ResetPostEffects(bool bOnSpecChange = false) = 0;
- //Disable post effect groups other than default and base.
- virtual void DisablePostEffects() = 0;
-
- virtual void SetShadowsGSMCache(bool bCache) = 0;
- virtual void SetCachedShadowBounds(const AABB& shadowBounds, float fAdditionalCascadesScale) = 0;
- virtual void SetRecomputeCachedShadows(uint nUpdateStrategy = 0) = 0;
-
- // Summary:
- // In debug mode check memory heap and makes assert, do nothing in release
- virtual void CheckMemoryHeap() = 0;
-
- // Summary:
- // Removes all decals attached to specified entity.
- virtual void DeleteEntityDecals(IRenderNode* pEntity) = 0;
-
- // Summary:
- // Disables CGFs unloading.
- virtual void LockCGFResources() = 0;
-
- // Summary:
- // Enables CGFs unloading (this is default state), this function will also release all not used CGF's.
- virtual void UnlockCGFResources() = 0;
-
- // Summary:
- // Release all unused CGFs.
- virtual void FreeUnusedCGFResources() = 0;
-
-
- // Summary:
- // Creates static object containing empty IndexedMesh.
- virtual IStatObj* CreateStatObj() = 0;
- virtual IStatObj* CreateStatObjOptionalIndexedMesh(bool createIndexedMesh) = 0;
-
- // Summary:
- // Creates the instance of the indexed mesh.
- virtual IIndexedMesh* CreateIndexedMesh() = 0;
-
- // Summary:
- // Saves/loads state of engine objects.
- virtual void SerializeState(TSerialize ser) = 0;
-
- // Summary:
- // Cleanups after save/load.
- virtual void PostSerialize(bool bReading) = 0;
-
- // Description:
- // Retrieve pointer to the material i/o interface.
- virtual IMaterialHelpers& GetMaterialHelpers() = 0;
-
- // Description:
- // Retrieve pointer to the material manager interface.
- virtual IMaterialManager* GetMaterialManager() = 0;
-
- // Description:
- // Retrieve pointer to the object manager interface.
- virtual IObjManager* GetObjManager() = 0;
-
- //////////////////////////////////////////////////////////////////////////
- // CGF Loader.
- //////////////////////////////////////////////////////////////////////////
- // Description:
- // Creates a chunkfile content instance
- // Returns 'NULL' if the memory for the instance could not be allocated
- virtual CContentCGF* CreateChunkfileContent(const char* filename) = 0;
-
- // Description:
- // Deletes the chunkfile content instance
- virtual void ReleaseChunkfileContent(CContentCGF*) = 0;
-
- // Description:
- // Loads the contents of a chunkfile into the given CContentCGF.
- // Returns 'false' on error.
- virtual bool LoadChunkFileContent(CContentCGF* pCGF, const char* filename, bool bNoWarningMode = false, bool bCopyChunkFile = true) = 0;
-
- // Description:
- // Loads the contents of a chunkfile into the given CContentCGF.
- // Returns 'false' on error.
- virtual bool LoadChunkFileContentFromMem(CContentCGF* pCGF, const void* pData, size_t nDataLen, uint32 nLoadingFlags, bool bNoWarningMode = false, bool bCopyChunkFile = true) = 0;
-
- // Description:
- // Creates ChunkFile.
- virtual IChunkFile* CreateChunkFile(bool bReadOnly = false) = 0;
-
- //////////////////////////////////////////////////////////////////////////
- // Chunk file writer.
- //////////////////////////////////////////////////////////////////////////
- enum EChunkFileFormat
- {
- eChunkFileFormat_0x745,
- eChunkFileFormat_0x746,
- };
- virtual ChunkFile::IChunkFileWriter* CreateChunkFileWriter(EChunkFileFormat eFormat, AZ::IO::IArchive* pPak, const char* filename) const = 0;
- virtual void ReleaseChunkFileWriter(ChunkFile::IChunkFileWriter* p) const = 0;
-
- // Description:
- // Returns true if the ocean was created successfully.
- virtual bool CreateOcean(_smart_ptr pTerrainWaterMat, float waterLevel) = 0;
-
- // Description:
- // Deletes the ocean if it exists, otherwise does nothing.
- virtual void DeleteOcean() = 0;
-
- // Description:
- // Changes ocean material if the ocean exists.
- virtual void ChangeOceanMaterial(_smart_ptr pMat) = 0;
-
- // Description:
- // Changes ocean water level if the ocean exists.
- virtual void ChangeOceanWaterLevel(float fWaterLevel) = 0;
-
- virtual void InitMaterialDefautMappingAxis(_smart_ptr pMat) = 0;
-
- // Description:
- // Returns interface to visarea manager.
- virtual IVisAreaManager* GetIVisAreaManager() = 0;
-
- // Description:
- // Places camera into every visarea or every manually set pre-cache points and render the scenes.
- virtual void PrecacheLevel(bool bPrecacheAllVisAreas, Vec3* pPrecachePoints, int nPrecachePointsNum) = 0;
-
- // Description:
- // Proposes 3dengine to load on next frame all shaders and textures synchronously.
- virtual void ProposeContentPrecache() = 0;
-
-
-
- // Description:
- // Returns TOD interface.
- virtual ITimeOfDay* GetTimeOfDay() = 0;
-
- // Description:
- // Updates the sky material paths. LoadSkyMaterial will handle loading these materials.
- virtual void SetSkyMaterialPath(const string& skyMaterialPath) = 0;
- virtual void SetSkyLowSpecMaterialPath(const string& skyMaterialPath) = 0;
-
- // Description:
- // Loads the sky material for the level. e_SkyType will determine if we load the low spec sky material or the regular sky material.
- virtual void LoadSkyMaterial() = 0;
-
- // Description:
- // Returns SkyBox material.
- virtual _smart_ptr GetSkyMaterial() = 0;
-
- // Description:
- // Sets SkyBox Material.
- virtual void SetSkyMaterial(_smart_ptr pSkyMat) = 0;
-
- // Description:
- // Sets global 3d engine parameter.
- virtual void SetGlobalParameter(E3DEngineParameter param, const Vec3& v) = 0;
- void SetGlobalParameter(E3DEngineParameter param, float val) { SetGlobalParameter(param, Vec3(val, 0, 0)); };
-
- // Description:
- // Retrieves global 3d engine parameter.
- virtual void GetGlobalParameter(E3DEngineParameter param, Vec3& v) = 0;
- float GetGlobalParameter(E3DEngineParameter param) { Vec3 v(0, 0, 0); GetGlobalParameter(param, v); return v.x; };
-
- virtual void SetShadowMode(EShadowMode shadowMode) = 0;
- virtual EShadowMode GetShadowMode() const = 0;
- virtual void AddPerObjectShadow(IShadowCaster* pCaster, float fConstBias, float fSlopeBias, float fJitter, const Vec3& vBBoxScale, uint nTexSize) = 0;
- virtual void RemovePerObjectShadow(IShadowCaster* pCaster) = 0;
- virtual struct SPerObjectShadow* GetPerObjectShadow(IShadowCaster* pCaster) = 0;
- virtual void GetCustomShadowMapFrustums(struct ShadowMapFrustum*& arrFrustums, int& nFrustumCount) = 0;
-
- // Description:
- // Saves pStatObj to a stream.
- // Notes:
- // Full mesh for generated ones, path/geom otherwise
- virtual int SaveStatObj(IStatObj* pStatObj, TSerialize ser) = 0;
- // Description:
- // Loads statobj from a stream
- virtual IStatObj* LoadStatObj(TSerialize ser) = 0;
-
- // Description:
- // Returns true if input line segment intersect clouds sprites.
- virtual bool CheckIntersectClouds(const Vec3& p1, const Vec3& p2) = 0;
-
- // Description:
- // Removes references to RenderMesh
- virtual void OnRenderMeshDeleted(IRenderMesh* pRenderMesh) = 0;
-
- // Used to highlight an object under the reticule
- virtual void DebugDraw_UpdateDebugNode() = 0;
-
- // Description:
- // Used by editor during AO computations
- virtual bool RayObjectsIntersection2D(Vec3 vStart, Vec3 vEnd, Vec3& vHitPoint, EERType eERType) = 0;
-
-
- // Description:
- // Used by editor during object alignment
- virtual bool RenderMeshRayIntersection(IRenderMesh* pRenderMesh, SRayHitInfo& hitInfo, _smart_ptr pCustomMtl = 0) = 0;
-
- virtual void CheckCreateRNTmpData(CRNTmpData** ppInfo, IRenderNode* pRNode, const SRenderingPassInfo& passInfo) = 0;
-
- // Description:
- // Frees lod transition state
- virtual void FreeRNTmpData(CRNTmpData** ppInfo) = 0;
-
- // Description:
- // Returns true if the Octree is ready.
- virtual bool IsObjectTreeReady() = 0;
-
- virtual IOctreeNode* GetIObjectTree() = 0;
-
- // Description:
- // Call function 2 times (first to get the size then to fill in the data)
- // Arguments:
- // pObjects - 0 if only the count is required
- // Return Value:
- // Count returned
- virtual uint32 GetObjectsByType(EERType objType, IRenderNode** pObjects = 0) = 0;
- virtual uint32 GetObjectsByTypeInBox(EERType objType, const AABB& bbox, IRenderNode** pObjects = 0, ObjectTreeQueryFilterCallback filterCallback = nullptr) = 0;
- virtual uint32 GetObjectsInBox(const AABB& bbox, IRenderNode** pObjects = 0) = 0;
- virtual uint32 GetObjectsByFlags(uint dwFlag, IRenderNode** pObjects = 0) = 0;
-
- // variant which takes a POD array which is resized in the function itself
- virtual void GetObjectsByTypeInBox(EERType objType, const AABB& bbox, PodArray* pLstObjects, ObjectTreeQueryFilterCallback filterCallback = nullptr) = 0;
-
- // Called from editor whenever an object is modified by the user
- virtual void OnObjectModified(IRenderNode* pRenderNode, uint dwFlags) = 0;
-
- virtual void FillDebugFPSInfo(SDebugFPSInfo&) = 0;
-
- virtual const char* GetLevelFolder() = 0;
-
- virtual bool IsAreaActivationInUse() = 0;
-
- virtual void RenderRenderNode_ShadowPass(IShadowCaster* pRNode, const SRenderingPassInfo& passInfo, AZ::LegacyJobExecutor* pJobExecutor) = 0;
-
- virtual IOpticsManager* GetOpticsManager() = 0;
-
- // Description:
- // Syncs and performs outstanding operations for the Asyncrhon ProcessStreaming Update
- virtual void SyncProcessStreamingUpdate() = 0;
-
- // Set Callback for Editor to store additional information in Minimap tool
- virtual void SetScreenshotCallback(IScreenshotCallback* pCallback) = 0;
-
- // Show/Hide objects by layer (useful for streaming and performance)
- virtual void ActivateObjectsLayer(uint16 nLayerId, bool bActivate, bool bPhys, bool bObjects, bool bStaticLights, const char* pLayerName, IGeneralMemoryHeap* pHeap = NULL, bool bCheckLayerActivation = true) = 0;
-
- // Get object layer memory usage
- virtual void GetLayerMemoryUsage(uint16 nLayerId, ICrySizer* pSizer, int* pNumBrushes, int* pNumDecals) const = 0;
-
- // Collect layer ID's to skip loading objects from these layers, e.g. to skip console specific layers
- virtual void SkipLayerLoading(uint16 nLayerId, bool bClearList) = 0;
-
- // Activate streaming of render node and all sub-components
- virtual void PrecacheRenderNode(IRenderNode* pObj, float fEntDistanceReal) = 0;
-
- virtual IDeferredPhysicsEventManager* GetDeferredPhysicsEventManager() = 0;
-
- virtual void SetStreamableListener(IStreamedObjectListener* pListener) = 0;
-
- // following functions are used by SRenderingPassInfo
- virtual CCamera* GetRenderingPassCamera(const CCamera& rCamera) = 0;
-
- struct SSvoStaticTexInfo
- {
- SSvoStaticTexInfo()
- {
- ZeroStruct(*this);
- }
-
- // SVO data pools
- ITexture* pTexTree;
- ITexture* pTexOpac;
- ITexture* pTexRgb0;
- ITexture* pTexRgb1;
- ITexture* pTexDynl;
- ITexture* pTexRgb2;
- ITexture* pTexRgb3;
- ITexture* pTexNorm;
- ITexture* pTexAldi;
-
- ITexture* pGlobalSpecCM;
-
- float fGlobalSpecCM_Mult;
- int nTexDimXY;
- int nTexDimZ;
- int nBrickSize;
- bool bSvoReady;
- bool bSvoFreeze;
- };
-
- struct SLightTI
- {
- Vec4 vPosR;
- Vec4 vDirF;
- Vec4 vCol;
- float fSortVal;
- class ITexture* pCM;
- };
-
- virtual void GetSvoStaticTextures(I3DEngine::SSvoStaticTexInfo& svoInfo, PodArray* pLightsTI_S, PodArray* pLightsTI_D) = 0;
-
- struct SSvoNodeInfo
- {
- AABB wsBox;
- AABB tcBox;
- int nAtlasOffset;
- };
-
- virtual void GetSvoBricksForUpdate(PodArray& arrNodeInfo, bool getDynamic) = 0;
-
-#if defined(USE_GEOM_CACHES)
- // Summary:
- // Loads a geometry cache from a CAX file.
- // See Also:
- // IGeomCache
- // Arguments:
- // szFileName - CAX Filename - should not be 0 or ""
- // Return Value:
- // A pointer to an object derived from IGeomCache.
- virtual IGeomCache* LoadGeomCache(const char* szFileName) = 0;
-
- // Finds a geom cache created from the given filename
- // See Also:
- // IGeomCache
- // Arguments:
- // szFileName - CAX Filename - should not be 0 or ""
- // Return Value:
- // A pointer to an object derived from IGeomCache.
- virtual IGeomCache* FindGeomCacheByFilename(const char* szFileName) = 0;
-#endif
-
- // Summary:
- // Loads a designer object from a stream of _decoded_ binary node. (Base64Decode)
- // Arguments:
- // szBinaryStream - decoded stream + size
- virtual IStatObj* LoadDesignerObject(int nVersion, const char* szBinaryStream, int size) = 0;
-
- // Summary:
- // Makes sure all queued culling jobs are completely finished.
- // This is useful when adding or removing Components that trigger AZ::Job creation
- // like the terrain system. It is important to complete those jobs before removing
- // such type of components.
- virtual void WaitForCullingJobsCompletion() = 0;
-
- //
-};
-
-#pragma pack(pop)
-
-#include
-
-// state of 3dengine during rendering
-// used to prevent global state
-struct SRenderingPassInfo
-{
- enum EShadowMapType
- {
- SHADOW_MAP_NONE = 0,
- SHADOW_MAP_GSM,
- SHADOW_MAP_LOCAL,
- SHADOW_MAP_CACHED,
- SHADOW_MAP_CACHED_MGPU_COPY
- };
-
- // enum flags to identify which objects to skip for this pass
- enum ESkipRenderingFlags
- {
- SHADOWS = BIT(0),
- ENTITIES = BIT(3),
- WATEROCEAN = BIT(5),
- DECALS = BIT(7),
- MERGED_MESHES = BIT(10),
- ROADS = BIT(13),
- WATER_VOLUMES = BIT(14),
- CLOUDS = BIT(15),
- CUBEMAP_GEN = BIT(16),
- GEOM_CACHES = BIT(17),
- DISABLE_RENDER_CHUNK_MERGE = BIT(18),
-
- // below are precombined flags
- STATIC_OBJECTS = ENTITIES,
- DEFAULT_FLAGS = SHADOWS | ENTITIES | WATEROCEAN | DECALS | MERGED_MESHES | ROADS | WATER_VOLUMES | CLOUDS | GEOM_CACHES,
- DEFAULT_RECURSIVE_FLAGS = ENTITIES | WATEROCEAN | DECALS | MERGED_MESHES | ROADS | WATER_VOLUMES | CLOUDS | GEOM_CACHES
- };
-
- // creating function for RenderingPassInfo, the create functions will fetch all other necessary
- // information like thread id/frame id, etc
- static SRenderingPassInfo CreateGeneralPassRenderingInfo(const CCamera& rCamera, uint32 nRenderingFlags = DEFAULT_FLAGS, bool bAuxWindow = false);
- static SRenderingPassInfo CreateRecursivePassRenderingInfo(const CCamera& rCamera, uint32 nRenderingFlags = DEFAULT_RECURSIVE_FLAGS);
- static SRenderingPassInfo CreateShadowPassRenderingInfo(const CCamera& rCamera, int nLightFlags, int nShadowMapLod, bool bExtendedLod, bool bIsMGPUCopy, uint32* pShadowGenMask, uint32 nSide, uint32 nShadowFrustumID, uint32 nRenderingFlags = DEFAULT_FLAGS);
- static SRenderingPassInfo CreateTempRenderingInfo(const CCamera& rCamera, const SRenderingPassInfo& rPassInfo);
- static SRenderingPassInfo CreateTempRenderingInfo(uint32 nRenderingFlags, const SRenderingPassInfo& rPassInfo);
-
- // state getter
- bool IsGeneralPass() const;
-
- bool IsRecursivePass() const;
- uint32 GetRecursiveLevel() const;
-
- bool IsShadowPass() const;
- bool IsCachedShadowPass() const;
- EShadowMapType GetShadowMapType() const;
- bool IsDisableRenderChunkMerge() const;
-
- bool IsAuxWindow() const;
-
- threadID ThreadID() const;
- void SetThreadID(threadID id) { m_nThreadID = static_cast(id); }
-
- int GetFrameID() const;
- uint32 GetMainFrameID() const;
-
- const CCamera& GetCamera() const;
- bool IsCameraUnderWater() const;
-
- float GetZoomFactor() const;
- float GetInverseZoomFactor() const;
- bool RenderShadows() const;
- bool RenderEntities() const;
- bool RenderWaterOcean() const;
- bool RenderDecals() const;
- bool RenderWaterVolumes() const;
- bool RenderClouds() const;
- bool RenderGeomCaches() const;
-
- bool IsRenderingCubemap() const;
-
- uint32* ShadowGenMaskAddress() const;
- uint32 ShadowFrustumID() const;
- uint8 ShadowFrustumSide() const;
- uint8 ShadowFrustumLod() const;
-
- CRenderView* GetRenderView() const;
-
- SRenderingPassInfo(threadID id)
- {
- SRenderingPassInfo();
- SetThreadID(id);
- m_pRenderView = gEnv->pRenderer->GetRenderViewForThread(id);
- }
-
-private:
-
- // private constructor, creation is only allowed with create functions
- SRenderingPassInfo()
- : pShadowGenMask(NULL)
- , nShadowSide(0)
- , nShadowLod(0)
- , nShadowFrustumId(0)
- , m_bAuxWindow(0)
- , m_nRenderStackLevel(0)
- , m_eShadowMapRendering(static_cast(SHADOW_MAP_NONE))
- , m_bCameraUnderWater(0)
- , m_nRenderingFlags(0)
- , m_fZoomFactor(0.0f)
- , m_pCamera(NULL)
- {
- threadID nThreadID = 0;
- gEnv->pRenderer->EF_Query(EFQ_MainThreadList, nThreadID);
- m_nThreadID = aznumeric_caster(nThreadID);
- m_nRenderFrameID = gEnv->pRenderer->GetFrameID();
- m_nRenderMainFrameID = gEnv->pRenderer->GetFrameID(false);
- m_pRenderView = gEnv->pRenderer->GetRenderViewForThread(m_nThreadID);
- }
-
- void InitRenderingFlags(uint32 nRenderingFlags);
- void SetCamera(const CCamera& cam);
-
- uint8 m_nThreadID;
- uint8 m_nRenderStackLevel;
- uint8 m_eShadowMapRendering; // State flag denoting what type of shadow map is being currently rendered into
- uint8 m_bCameraUnderWater;
-
- uint32 m_nRenderingFlags;
-
- float m_fZoomFactor;
-
- int m_nRenderFrameID;
- uint32 m_nRenderMainFrameID;
-
- const CCamera* m_pCamera;
-
- // Render view used for this rendering pass
- CRenderView* m_pRenderView;
-
- // members used only in shadow pass
- uint32* pShadowGenMask;
- uint32 nShadowFrustumId;
- uint8 nShadowSide : 4;
- uint8 nShadowLod : 4;
- uint8 m_bAuxWindow;
-};
-
-///////////////////////////////////////////////////////////////////////////////
-inline bool SRenderingPassInfo::IsGeneralPass() const
-{
- return m_nRenderStackLevel == 0 && m_bAuxWindow == 0 && static_cast(m_eShadowMapRendering) == SHADOW_MAP_NONE;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline bool SRenderingPassInfo::IsRecursivePass() const
-{
- return m_nRenderStackLevel > 0;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline uint32 SRenderingPassInfo::GetRecursiveLevel() const
-{
- return m_nRenderStackLevel;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline bool SRenderingPassInfo::IsShadowPass() const
-{
- return static_cast(m_eShadowMapRendering) != SHADOW_MAP_NONE;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline bool SRenderingPassInfo::IsCachedShadowPass() const
-{
- return IsShadowPass() &&
- (GetShadowMapType() == SRenderingPassInfo::SHADOW_MAP_CACHED ||
- GetShadowMapType() == SRenderingPassInfo::SHADOW_MAP_CACHED_MGPU_COPY);
-}
-///////////////////////////////////////////////////////////////////////////////
-inline SRenderingPassInfo::EShadowMapType SRenderingPassInfo::GetShadowMapType() const
-{
- assert(IsShadowPass());
- return static_cast(m_eShadowMapRendering);
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline bool SRenderingPassInfo::IsAuxWindow() const
-{
- return m_bAuxWindow != 0;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline threadID SRenderingPassInfo::ThreadID() const
-{
- return m_nThreadID;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline int SRenderingPassInfo::GetFrameID() const
-{
- return m_nRenderFrameID;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline uint32 SRenderingPassInfo::GetMainFrameID() const
-{
- return m_nRenderMainFrameID;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline const CCamera& SRenderingPassInfo::GetCamera() const
-{
- assert(m_pCamera != NULL);
- return *m_pCamera;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline bool SRenderingPassInfo::IsCameraUnderWater() const
-{
- return m_bCameraUnderWater != 0;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline float SRenderingPassInfo::GetZoomFactor() const
-{
- return m_fZoomFactor;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline float SRenderingPassInfo::GetInverseZoomFactor() const
-{
- return 1.0f / m_fZoomFactor;
-}
-
-
-////////////////////////////////////////////////////////////////////////////////
-inline bool SRenderingPassInfo::RenderShadows() const
-{
- return (m_nRenderingFlags& SRenderingPassInfo::SHADOWS) != 0;
-}
-
-////////////////////////////////////////////////////////////////////////////////
-inline bool SRenderingPassInfo::RenderEntities() const
-{
- return (m_nRenderingFlags& SRenderingPassInfo::ENTITIES) != 0;
-}
-
-////////////////////////////////////////////////////////////////////////////////
-inline bool SRenderingPassInfo::RenderWaterOcean() const
-{
- return (m_nRenderingFlags& SRenderingPassInfo::WATEROCEAN) != 0;
-}
-
-////////////////////////////////////////////////////////////////////////////////
-inline bool SRenderingPassInfo::RenderDecals() const
-{
- return (m_nRenderingFlags& SRenderingPassInfo::DECALS) != 0;
-}
-
-////////////////////////////////////////////////////////////////////////////////
-inline bool SRenderingPassInfo::RenderWaterVolumes() const
-{
- return (m_nRenderingFlags& SRenderingPassInfo::WATER_VOLUMES) != 0;
-}
-
-////////////////////////////////////////////////////////////////////////////////
-inline bool SRenderingPassInfo::RenderClouds() const
-{
- return (m_nRenderingFlags& SRenderingPassInfo::CLOUDS) != 0;
-}
-
-////////////////////////////////////////////////////////////////////////////////
-inline bool SRenderingPassInfo::RenderGeomCaches() const
-{
- return (m_nRenderingFlags& SRenderingPassInfo::GEOM_CACHES) != 0;
-}
-
-////////////////////////////////////////////////////////////////////////////////
-inline bool SRenderingPassInfo::IsRenderingCubemap() const
-{
- return (m_nRenderingFlags& SRenderingPassInfo::CUBEMAP_GEN) != 0;
-}
-
-////////////////////////////////////////////////////////////////////////////////
-inline bool SRenderingPassInfo::IsDisableRenderChunkMerge() const
-{
- return (m_nRenderingFlags& SRenderingPassInfo::DISABLE_RENDER_CHUNK_MERGE) != 0;
-}
-
-////////////////////////////////////////////////////////////////////////////////
-inline uint32* SRenderingPassInfo::ShadowGenMaskAddress() const
-{
- assert(pShadowGenMask);
- return pShadowGenMask;
-}
-
-////////////////////////////////////////////////////////////////////////////////
-inline uint32 SRenderingPassInfo::ShadowFrustumID() const
-{
- return nShadowFrustumId;
-}
-
-////////////////////////////////////////////////////////////////////////////////
-inline uint8 SRenderingPassInfo::ShadowFrustumSide() const
-{
- return nShadowSide;
-}
-
-////////////////////////////////////////////////////////////////////////////////
-inline uint8 SRenderingPassInfo::ShadowFrustumLod() const
-{
- return nShadowLod;
-}
-////////////////////////////////////////////////////////////////////////////////
-inline CRenderView* SRenderingPassInfo::GetRenderView() const
-{
- return m_pRenderView;
-}
-////////////////////////////////////////////////////////////////////////////////
-inline void SRenderingPassInfo::SetCamera(const CCamera& cam)
-{
- m_pCamera = gEnv->p3DEngine->GetRenderingPassCamera(cam);
- m_bCameraUnderWater = gEnv->p3DEngine->IsUnderWater(cam.GetPosition());
- m_fZoomFactor = 0.2f + 0.8f * (RAD2DEG(cam.GetFov()) / 60.f);
-}
-
-////////////////////////////////////////////////////////////////////////////////
-inline void SRenderingPassInfo::InitRenderingFlags(uint32 nRenderingFlags)
-{
- m_nRenderingFlags = nRenderingFlags;
-#if (ALLOW_CONST_CVAR_MODIFICATIONS)
- static ICVar* pDefaultMaterial = gEnv->pConsole->GetCVar("e_DefaultMaterial");
- static ICVar* pShadows = gEnv->pConsole->GetCVar("e_Shadows");
- static ICVar* pEntities = gEnv->pConsole->GetCVar("e_Entities");
- static ICVar* pWaterOcean = gEnv->pConsole->GetCVar("e_WaterOcean");
- static ICVar* pDecals = gEnv->pConsole->GetCVar("e_Decals");
- static ICVar* pWaterVolumes = gEnv->pConsole->GetCVar("e_WaterVolumes");
- static ICVar* pClouds = gEnv->pConsole->GetCVar("e_Clouds");
- static ICVar* pGeomCaches = gEnv->pConsole->GetCVar("e_GeomCaches");
-
- if (pShadows->GetIVal() == 0)
- {
- m_nRenderingFlags &= ~SRenderingPassInfo::SHADOWS;
- }
- if (pEntities->GetIVal() == 0)
- {
- m_nRenderingFlags &= ~SRenderingPassInfo::ENTITIES;
- }
- if (pWaterOcean->GetIVal() == 0)
- {
- m_nRenderingFlags &= ~SRenderingPassInfo::WATEROCEAN;
- }
- if (pDecals->GetIVal() == 0)
- {
- m_nRenderingFlags &= ~SRenderingPassInfo::DECALS;
- }
- if (pWaterVolumes->GetIVal() == 0)
- {
- m_nRenderingFlags &= ~SRenderingPassInfo::WATER_VOLUMES;
- }
- if (pClouds->GetIVal() == 0)
- {
- m_nRenderingFlags &= ~SRenderingPassInfo::CLOUDS;
- }
- if (pGeomCaches->GetIVal() == 0)
- {
- m_nRenderingFlags &= ~SRenderingPassInfo::GEOM_CACHES;
- }
-
- // on dedicated server, never render any object at all
- if (gEnv->IsDedicated())
- {
- m_nRenderingFlags = 0;
- }
-#endif // (ALLOW_CONST_CVAR_MODIFICATIONS)
-}
-
-////////////////////////////////////////////////////////////////////////////////
-inline SRenderingPassInfo SRenderingPassInfo::CreateGeneralPassRenderingInfo(const CCamera& rCamera, uint32 nRenderingFlags, bool bAuxWindow)
-{
- static ICVar* pCameraFreeze = gEnv->pConsole->GetCVar("e_CameraFreeze");
-
- // Update Camera only if e_camerafreeze is not set
- const CCamera& rCameraToSet = (pCameraFreeze && pCameraFreeze->GetIVal() != 0) ? gEnv->p3DEngine->GetRenderingCamera() : rCamera;
-
- SRenderingPassInfo passInfo;
- passInfo.SetCamera(rCameraToSet);
- passInfo.InitRenderingFlags(nRenderingFlags);
- passInfo.m_bAuxWindow = bAuxWindow;
-
- return passInfo;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline SRenderingPassInfo SRenderingPassInfo::CreateRecursivePassRenderingInfo(const CCamera& rCamera, uint32 nRenderingFlags)
-{
- static ICVar* pRecursionViewDistRatio = gEnv->pConsole->GetCVar("e_RecursionViewDistRatio");
-
- SRenderingPassInfo passInfo;
- passInfo.m_nRenderStackLevel = 1;
- passInfo.SetCamera(rCamera);
-
- // adjust view distance in recursive mode by adjusting the ZoomFactor
- passInfo.m_fZoomFactor /= pRecursionViewDistRatio->GetFVal();
-
- passInfo.InitRenderingFlags(nRenderingFlags);
-
- return passInfo;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline SRenderingPassInfo SRenderingPassInfo::CreateShadowPassRenderingInfo(const CCamera& rCamera, int nLightFlags, int nShadowMapLod, bool bExtendedLod, bool bIsMGPUCopy, uint32* pShadowGenMask, uint32 nSide, uint32 nShadowFrustumID, uint32 nRenderingFlags)
-{
- SRenderingPassInfo passInfo;
- passInfo.SetCamera(rCamera);
- passInfo.InitRenderingFlags(nRenderingFlags);
-
- // set correct shadow map type
- if (nLightFlags & DLF_SUN)
- {
- assert(nShadowMapLod >= 0 && nShadowMapLod < 8);
- if (bExtendedLod)
- {
- passInfo.m_eShadowMapRendering = bIsMGPUCopy ? static_cast(SHADOW_MAP_CACHED_MGPU_COPY) : static_cast(SHADOW_MAP_CACHED);
- }
- else
- {
- passInfo.m_eShadowMapRendering = static_cast(SHADOW_MAP_GSM);
- }
- }
- else if (nLightFlags & (DLF_POINT | DLF_PROJECT | DLF_AREA_LIGHT))
- {
- passInfo.m_eShadowMapRendering = static_cast(SHADOW_MAP_LOCAL);
- }
- else
- {
- passInfo.m_eShadowMapRendering = static_cast(SHADOW_MAP_NONE);
- }
-
- passInfo.pShadowGenMask = pShadowGenMask;
- passInfo.nShadowSide = nSide;
- passInfo.nShadowLod = nShadowMapLod;
- passInfo.nShadowFrustumId = nShadowFrustumID;
-
- return passInfo;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline SRenderingPassInfo SRenderingPassInfo::CreateTempRenderingInfo(const CCamera& rCamera, const SRenderingPassInfo& rPassInfo)
-{
- SRenderingPassInfo passInfo = rPassInfo;
- passInfo.SetCamera(rCamera);
-
- passInfo.pShadowGenMask = NULL;
- passInfo.nShadowSide = 0;
- passInfo.nShadowFrustumId = 0;
-
- return passInfo;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline SRenderingPassInfo SRenderingPassInfo::CreateTempRenderingInfo(uint32 nRenderingFlags, const SRenderingPassInfo& rPassInfo)
-{
- SRenderingPassInfo passInfo = rPassInfo;
- passInfo.m_nRenderingFlags = nRenderingFlags;
- return passInfo;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-// class to wrap a special counter used to presort SRendItems
-// this is used to fix random ordering introduced by parallelization
-// of parts of the 3DEngine
-struct SRendItemSorter
-{
- // Deferred PreProcess needs a special ordering, use these to prefix the values
- // to ensure the deferred shading pass is after all LPV objects
- enum EDeferredPreprocess
- {
- eLPVPass = 0,
- eDeferredShadingPass = BIT(30)
- };
-
- static SRendItemSorter CreateRendItemSorter(const SRenderingPassInfo& passInfo);
- static SRendItemSorter CreateShadowPassRendItemSorter(const SRenderingPassInfo& passInfo);
- static SRendItemSorter CreateParticleRendItemSorter(const SRenderingPassInfo& passInfo);
- static SRendItemSorter CreateDeferredPreProcessRendItemSorter(const SRenderingPassInfo& passInfo, EDeferredPreprocess deferredPrerocessType);
- static SRendItemSorter CreateDefaultRendItemSorter();
-
- void IncreaseOctreeCounter() { nValue += eOctreeNodeCounter; }
- void IncreaseObjectCounter() { nValue += eObjectCounter; }
- void IncreaseGroupCounter() { nValue += eGroupCounter; }
-
- void IncreaseParticleCounter() { nValue += eParticleCounter; }
- uint32 ParticleCounter() const { return nValue & ~eRecursivePassMask; }
-
- uint32 ShadowFrustumID() const { return nValue & ~eRecursivePassMask; }
-
- uint32 GetValue() const { return nValue; }
-
- bool operator<(const SRendItemSorter& rOther) const
- {
- return nValue < rOther.nValue;
- }
-
- bool IsRecursivePass() const { return (nValue & eRecursivePassMask) != 0; }
-
- SRendItemSorter()
- : nValue(0) {}
- explicit SRendItemSorter(uint32 _nValue)
- : nValue(_nValue) {}
-
-private:
- // encode various counter in a single value
- enum
- {
- eRecursivePassMask = BIT(31)
- }; // present in all combinations
-
- // flags used for regular SRendItems
- enum
- {
- eObjectCounter = BIT(0)
- }; // bits 0-14 used
- enum
- {
- eOctreeNodeCounter = BIT(14)
- }; // bits 15-27 used
- enum
- {
- eGroupCounter = BIT(27)
- }; // bits 28-31 used
-
- // flags used for Particles
- enum
- {
- eParticleCounter = BIT(0)
- };
-
- uint32 nValue;
-};
-
-///////////////////////////////////////////////////////////////////////////////
-inline SRendItemSorter SRendItemSorter::CreateRendItemSorter(const SRenderingPassInfo& passInfo)
-{
- SRendItemSorter rendItemSorter;
- rendItemSorter.nValue = 0;
- rendItemSorter.nValue |= passInfo.IsRecursivePass() ? eRecursivePassMask : 0;
- return rendItemSorter;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline SRendItemSorter SRendItemSorter::CreateShadowPassRendItemSorter(const SRenderingPassInfo& passInfo)
-{
- SRendItemSorter rendItemSorter;
- rendItemSorter.nValue = passInfo.ShadowFrustumID();
- rendItemSorter.nValue |= passInfo.IsRecursivePass() ? eRecursivePassMask : 0;
- return rendItemSorter;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline SRendItemSorter SRendItemSorter::CreateParticleRendItemSorter(const SRenderingPassInfo& passInfo)
-{
- SRendItemSorter rendItemSorter;
- rendItemSorter.nValue = 0;
- rendItemSorter.nValue |= passInfo.IsRecursivePass() ? eRecursivePassMask : 0;
- return rendItemSorter;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline SRendItemSorter SRendItemSorter::CreateDeferredPreProcessRendItemSorter(const SRenderingPassInfo& passInfo, EDeferredPreprocess deferredPrerocessType)
-{
- SRendItemSorter rendItemSorter;
- rendItemSorter.nValue = 0;
- rendItemSorter.nValue |= passInfo.IsRecursivePass() ? eRecursivePassMask : 0;
- rendItemSorter.nValue |= deferredPrerocessType;
- return rendItemSorter;
-}
-
-///////////////////////////////////////////////////////////////////////////////
-inline SRendItemSorter SRendItemSorter::CreateDefaultRendItemSorter()
-{
- SRendItemSorter rendItemSorter;
- rendItemSorter.nValue = 0;
- return rendItemSorter;
-}
-
-//Legacy Bus for communicating with SVOGI from the legacy engine code.
-class SVOGILegacyRequests
- : public AZ::EBusTraits
-{
-public:
- //////////////////////////////////////////////////////////////////////////
- // EBusTraits overrides
- static const AZ::EBusHandlerPolicy HandlerPolicy = AZ::EBusHandlerPolicy::Single;
- static const AZ::EBusAddressPolicy AddressPolicy = AZ::EBusAddressPolicy::Single;
- using MutexType = AZStd::recursive_mutex;
-// static const bool LocklessDispatch = true;
- //////////////////////////////////////////////////////////////////////////
-
- //////////////////////////////////////////////////////////////////////////
- // Triggers an update of voxel data.
- virtual void UpdateVoxelData() = 0;
-
- //////////////////////////////////////////////////////////////////////////
- // Triggers an update of voxel data to GPU.
- virtual void UpdateRenderData() = 0;
-
- //////////////////////////////////////////////////////////////////////////
- // Called at framestart
- virtual void OnFrameStart(const SRenderingPassInfo& passInfo) = 0;
-
- //////////////////////////////////////////////////////////////////////////
- // Gets the textures bound for GI plus lighting data.
- virtual void GetSvoStaticTextures(I3DEngine::SSvoStaticTexInfo& svoInfo, PodArray* pLightsTI_S, PodArray* pLightsTI_D) = 0;
-
- //////////////////////////////////////////////////////////////////////////
- // Generates a list of bricks that need to be updated in compute shaders.
- virtual void GetSvoBricksForUpdate(PodArray& arrNodeInfo, bool getDynamic) = 0;
-
- //////////////////////////////////////////////////////////////////////////
- // Causes the GI system to free all voxel data.
- virtual void ReleaseData() = 0;
-
- //////////////////////////////////////////////////////////////////////////
- // Register and unregister a mutex to protect assets during rendering.
- virtual void RegisterMutex(AZStd::mutex* mutex) = 0;
- virtual void UnregisterMutex() = 0;
-
-};
-using SVOGILegacyRequestBus = AZ::EBus;
-
-
-#endif // CRYINCLUDE_CRYCOMMON_I3DENGINE_H
-
diff --git a/Code/CryEngine/CryCommon/I3DEngine_info.h b/Code/CryEngine/CryCommon/I3DEngine_info.h
deleted file mode 100644
index f1c601fcc6..0000000000
--- a/Code/CryEngine/CryCommon/I3DEngine_info.h
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
-* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
-* its licensors.
-*
-* For complete copyright and license terms please see the LICENSE at the root of this
-* distribution (the "License"). All use of this software is governed by the License,
-* or, if provided, by the license below or the license accompanying this file. Do not
-* remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-*
-*/
-// Original file Copyright Crytek GMBH or its affiliates, used under license.
-
-#ifndef CRYINCLUDE_CRYCOMMON_I3DENGINE_INFO_H
-#define CRYINCLUDE_CRYCOMMON_I3DENGINE_INFO_H
-#pragma once
-
-#include "TypeInfo_impl.h"
-#include "IShader_info.h"
-#include // <> required for Interfuscator
-
-STRUCT_INFO_BEGIN(SVisAreaManChunkHeader)
-STRUCT_VAR_INFO(nVersion, TYPE_INFO(int8))
-STRUCT_VAR_INFO(nDummy, TYPE_INFO(int8))
-STRUCT_VAR_INFO(nFlags, TYPE_INFO(int8))
-STRUCT_VAR_INFO(nFlags2, TYPE_INFO(int8))
-STRUCT_VAR_INFO(nChunkSize, TYPE_INFO(int))
-STRUCT_VAR_INFO(nVisAreasNum, TYPE_INFO(int))
-STRUCT_VAR_INFO(nPortalsNum, TYPE_INFO(int))
-STRUCT_VAR_INFO(nOcclAreasNum, TYPE_INFO(int))
-STRUCT_INFO_END(SVisAreaManChunkHeader)
-
-STRUCT_INFO_BEGIN(SOcTreeNodeChunk)
-STRUCT_VAR_INFO(nChunkVersion, TYPE_INFO(int16))
-STRUCT_VAR_INFO(ucChildsMask, TYPE_INFO(int16))
-STRUCT_VAR_INFO(nodeBox, TYPE_INFO(AABB))
-STRUCT_VAR_INFO(nObjectsBlockSize, TYPE_INFO(int32))
-STRUCT_INFO_END(SOcTreeNodeChunk)
-
-STRUCT_INFO_BEGIN(SHotUpdateInfo)
-STRUCT_VAR_INFO(nHeigtmap, TYPE_INFO(uint32))
-STRUCT_VAR_INFO(nObjTypeMask, TYPE_INFO(uint32))
-STRUCT_VAR_INFO(areaBox, TYPE_INFO(AABB))
-STRUCT_INFO_END(SHotUpdateInfo)
-
-STRUCT_INFO_BEGIN(SCommonFileHeader)
-STRUCT_VAR_INFO(signature, TYPE_ARRAY(4, TYPE_INFO(char)))
-STRUCT_VAR_INFO(file_type, TYPE_INFO(uint8))
-STRUCT_VAR_INFO(flags, TYPE_INFO(uint8))
-STRUCT_VAR_INFO(version, TYPE_INFO(uint16))
-STRUCT_INFO_END(SCommonFileHeader)
-
-#endif // CRYINCLUDE_CRYCOMMON_I3DENGINE_INFO_H
diff --git a/Code/CryEngine/CryCommon/IEntityRenderState.h b/Code/CryEngine/CryCommon/IEntityRenderState.h
index 912f4632ab..29b1bdc463 100644
--- a/Code/CryEngine/CryCommon/IEntityRenderState.h
+++ b/Code/CryEngine/CryCommon/IEntityRenderState.h
@@ -286,7 +286,6 @@ struct IRenderNode
// Physicalizes node.
virtual void Physicalize([[maybe_unused]] bool bInstant = false) {}
- // Make sure I3DEngine::FreeRenderNodeState(this) is called in destructor of derived class.
virtual ~IRenderNode() { assert(!m_pRNTmpData); };
// Summary:
@@ -731,8 +730,8 @@ struct IWaterVolumeRenderNode
virtual void SetAuxPhysParams(pe_params_area*) = 0;
virtual void CreateOcean(uint64 volumeID, /* TBD */ bool keepSerializationParams = false) = 0;
- virtual void CreateArea(uint64 volumeID, const Vec3* pVertices, unsigned int numVertices, const Vec2& surfUVScale, const Plane& fogPlane, bool keepSerializationParams = false, int nSID = -1) = 0;
- virtual void CreateRiver(uint64 volumeID, const Vec3* pVertices, unsigned int numVertices, float uTexCoordBegin, float uTexCoordEnd, const Vec2& surfUVScale, const Plane& fogPlane, bool keepSerializationParams = false, int nSID = -1) = 0;
+ virtual void CreateArea(uint64 volumeID, const Vec3* pVertices, unsigned int numVertices, const Vec2& surfUVScale, const Plane_tpl& fogPlane, bool keepSerializationParams = false, int nSID = -1) = 0;
+ virtual void CreateRiver(uint64 volumeID, const Vec3* pVertices, unsigned int numVertices, float uTexCoordBegin, float uTexCoordEnd, const Vec2& surfUVScale, const Plane_tpl& fogPlane, bool keepSerializationParams = false, int nSID = -1) = 0;
virtual void CreateRiver(uint64 volumeID, const AZStd::vector& verticies, const AZ::Transform& transform, float uTexCoordBegin, float uTexCoordEnd, const AZ::Vector2& surfUVScale, const AZ::Plane& fogPlane, bool keepSerializationParams = false, int nSID = -1) = 0;
virtual void SetAreaPhysicsArea(const Vec3* pVertices, unsigned int numVertices, bool keepSerializationParams = false) = 0;
diff --git a/Code/CryEngine/CryCommon/ILocalMemoryUsage.h b/Code/CryEngine/CryCommon/ILocalMemoryUsage.h
deleted file mode 100644
index fd1e7e3693..0000000000
--- a/Code/CryEngine/CryCommon/ILocalMemoryUsage.h
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
-* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
-* its licensors.
-*
-* For complete copyright and license terms please see the LICENSE at the root of this
-* distribution (the "License"). All use of this software is governed by the License,
-* or, if provided, by the license below or the license accompanying this file. Do not
-* remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-*
-*/
-// Original file Copyright Crytek GMBH or its affiliates, used under license.
-
-// Description : Interface for LocalMemoryUsage
-
-
-#ifndef CRYINCLUDE_CRYCOMMON_ILOCALMEMORYUSAGE_H
-#define CRYINCLUDE_CRYCOMMON_ILOCALMEMORYUSAGE_H
-#pragma once
-
-
-class CCamera;
-struct IRenderer;
-
-struct ILocalMemoryUsage
-{
- virtual ~ILocalMemoryUsage(){}
- virtual void OnRender(IRenderer* pRenderer, const CCamera* camera) = 0;
- virtual void OnUpdate() = 0;
- virtual void DeleteGlobalData() = 0;
-};
-
-#endif // CRYINCLUDE_CRYCOMMON_ILOCALMEMORYUSAGE_H
diff --git a/Code/CryEngine/CryCommon/IMaterial.h b/Code/CryEngine/CryCommon/IMaterial.h
index 81d612397f..020ddcc871 100644
--- a/Code/CryEngine/CryCommon/IMaterial.h
+++ b/Code/CryEngine/CryCommon/IMaterial.h
@@ -273,7 +273,7 @@ struct IMaterial
//////////////////////////////////////////////////////////////////////////
// material name
//////////////////////////////////////////////////////////////////////////
- //! Set material name, (Do not use this directly, to change material name use I3DEngine::RenameMatInfo method).
+ //! Set material name, (Do not use this directly
virtual void SetName(const char* pName) = 0;
//! Returns material name.
virtual const char* GetName() const = 0;
@@ -404,7 +404,6 @@ struct IMaterial
//////////////////////////////////////////////////////////////////////////
// Makes this specific material enter sketch mode.
- // Se also: I3DEngine::LoadCGF, in I3DEngine.h.
// Current supported sketch modes:
// - 0, no sketch.
// - 1, normal sketch mode.
diff --git a/Code/CryEngine/CryCommon/IMovieSystem.h b/Code/CryEngine/CryCommon/IMovieSystem.h
index c22394e1b3..ce4e59d43c 100644
--- a/Code/CryEngine/CryCommon/IMovieSystem.h
+++ b/Code/CryEngine/CryCommon/IMovieSystem.h
@@ -26,7 +26,6 @@
#include
#include
#include
-#include
#include
#include
diff --git a/Code/CryEngine/CryCommon/IObjManager.h b/Code/CryEngine/CryCommon/IObjManager.h
index acbd5c5d18..a63a252976 100644
--- a/Code/CryEngine/CryCommon/IObjManager.h
+++ b/Code/CryEngine/CryCommon/IObjManager.h
@@ -202,7 +202,6 @@ struct IObjManager
// time counters
virtual bool IsAfterWater(const Vec3& vPos, const SRenderingPassInfo& passInfo) = 0;
- virtual void GetObjectsStreamingStatus(I3DEngine::SObjectsStreamingStatus& outStatus) = 0;
virtual void FreeNotUsedCGFs() = 0;
virtual void MakeUnitCube() = 0;
diff --git a/Code/CryEngine/CryCommon/IShader.h b/Code/CryEngine/CryCommon/IShader.h
index 1e8553ac57..7fcbdefebb 100644
--- a/Code/CryEngine/CryCommon/IShader.h
+++ b/Code/CryEngine/CryCommon/IShader.h
@@ -52,7 +52,6 @@ struct SShaderItem;
class ITexture;
struct IMaterial;
struct SParam;
-class CMaterial;
struct SShaderSerializeContext;
struct IAnimNode;
struct SSkinningData;
diff --git a/Code/CryEngine/CryCommon/ISystem.h b/Code/CryEngine/CryCommon/ISystem.h
index 9b1e817602..96d9a6ad10 100644
--- a/Code/CryEngine/CryCommon/ISystem.h
+++ b/Code/CryEngine/CryCommon/ISystem.h
@@ -66,7 +66,6 @@ struct IConsole;
struct IRemoteConsole;
struct IRenderer;
struct IProcess;
-struct I3DEngine;
struct ITimer;
struct ICryFont;
struct IMovieSystem;
@@ -123,8 +122,6 @@ namespace Serialization {
struct IArchiveHost;
}
-struct ILocalMemoryUsage;
-
typedef void* WIN_HWND;
class CCamera;
@@ -793,7 +790,6 @@ struct SSystemUpdateStats
// ISystem
struct SSystemGlobalEnvironment
{
- I3DEngine* p3DEngine;
AZ::IO::IArchive* pCryPak;
AZ::IO::FileIOBase* pFileIO;
IFileChangeMonitor* pFileChangeMonitor;
@@ -801,7 +797,6 @@ struct SSystemGlobalEnvironment
IOpticsManager* pOpticsManager;
ITimer* pTimer;
ICryFont* pCryFont;
- ILocalMemoryUsage* pLocalMemoryUsage;
::IConsole* pConsole;
ISystem* pSystem = nullptr;
ILog* pLog;
@@ -1113,25 +1108,9 @@ struct ISystem
virtual void DoWorkDuringOcclusionChecks() = 0;
virtual bool NeedDoWorkDuringOcclusionChecks() = 0;
- // Summary:
- // Renders subsystems.
- virtual void Render() = 0;
- // Summary:
- // Begins rendering frame.
- virtual void RenderBegin() = 0;
- // Summary:
- // Ends rendering frame and swap back buffer.
- virtual void RenderEnd(bool bRenderStats = true, bool bMainWindow = true) = 0;
-
//! Update screen and call some important tick functions during loading.
virtual void SynchronousLoadingTick(const char* pFunc, int line) = 0;
- // Description:
- // Renders the statistics; this is called from RenderEnd, but if the
- // Host application (Editor) doesn't employ the Render cycle in ISystem,
- // it may call this method to render the essential statistics.
- virtual void RenderStatistics() = 0;
-
// Summary:
// Returns the current used memory.
virtual uint32 GetUsedMemory() = 0;
@@ -1229,7 +1208,6 @@ struct ISystem
virtual ICryFont* GetICryFont() = 0;
virtual IMemoryManager* GetIMemoryManager() = 0;
virtual IMovieSystem* GetIMovieSystem() = 0;
- virtual I3DEngine* GetI3DEngine() = 0;
virtual ::IConsole* GetIConsole() = 0;
virtual IRemoteConsole* GetIRemoteConsole() = 0;
// Returns:
diff --git a/Code/CryEngine/CryCommon/ITimeOfDay.h b/Code/CryEngine/CryCommon/ITimeOfDay.h
deleted file mode 100644
index b491ea9359..0000000000
--- a/Code/CryEngine/CryCommon/ITimeOfDay.h
+++ /dev/null
@@ -1,286 +0,0 @@
-/*
-* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
-* its licensors.
-*
-* For complete copyright and license terms please see the LICENSE at the root of this
-* distribution (the "License"). All use of this software is governed by the License,
-* or, if provided, by the license below or the license accompanying this file. Do not
-* remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-*
-*/
-// Original file Copyright Crytek GMBH or its affiliates, used under license.
-#pragma once
-
-struct SBezierKey;
-struct ITimeOfDayUpdateCallback;
-struct ISplineInterpolator;
-
-
-//! Interface to the Time Of Day functionality.
-struct ITimeOfDay
-{
- enum ETimeOfDayParamID
- {
- PARAM_SUN_COLOR,
- PARAM_SUN_INTENSITY,
- PARAM_SUN_SPECULAR_MULTIPLIER,
-
- PARAM_FOG_COLOR,
- PARAM_FOG_COLOR_MULTIPLIER,
- PARAM_VOLFOG_HEIGHT,
- PARAM_VOLFOG_DENSITY,
- PARAM_FOG_COLOR2,
- PARAM_FOG_COLOR2_MULTIPLIER,
- PARAM_VOLFOG_HEIGHT2,
- PARAM_VOLFOG_DENSITY2,
- PARAM_VOLFOG_HEIGHT_OFFSET,
-
- PARAM_FOG_RADIAL_COLOR,
- PARAM_FOG_RADIAL_COLOR_MULTIPLIER,
- PARAM_VOLFOG_RADIAL_SIZE,
- PARAM_VOLFOG_RADIAL_LOBE,
-
- PARAM_VOLFOG_FINAL_DENSITY_CLAMP,
-
- PARAM_VOLFOG_GLOBAL_DENSITY,
- PARAM_VOLFOG_RAMP_START,
- PARAM_VOLFOG_RAMP_END,
- PARAM_VOLFOG_RAMP_INFLUENCE,
-
- PARAM_VOLFOG_SHADOW_DARKENING,
- PARAM_VOLFOG_SHADOW_DARKENING_SUN,
- PARAM_VOLFOG_SHADOW_DARKENING_AMBIENT,
- PARAM_VOLFOG_SHADOW_RANGE,
-
- PARAM_VOLFOG2_HEIGHT,
- PARAM_VOLFOG2_DENSITY,
- PARAM_VOLFOG2_HEIGHT2,
- PARAM_VOLFOG2_DENSITY2,
- PARAM_VOLFOG2_GLOBAL_DENSITY,
- PARAM_VOLFOG2_RAMP_START,
- PARAM_VOLFOG2_RAMP_END,
- PARAM_VOLFOG2_COLOR1,
- PARAM_VOLFOG2_ANISOTROPIC1,
- PARAM_VOLFOG2_COLOR2,
- PARAM_VOLFOG2_ANISOTROPIC2,
- PARAM_VOLFOG2_BLEND_FACTOR,
- PARAM_VOLFOG2_BLEND_MODE,
- PARAM_VOLFOG2_COLOR,
- PARAM_VOLFOG2_ANISOTROPIC,
- PARAM_VOLFOG2_RANGE,
- PARAM_VOLFOG2_INSCATTER,
- PARAM_VOLFOG2_EXTINCTION,
- PARAM_VOLFOG2_GLOBAL_FOG_VISIBILITY,
- PARAM_VOLFOG2_FINAL_DENSITY_CLAMP,
-
- PARAM_SKYLIGHT_SUN_INTENSITY,
- PARAM_SKYLIGHT_SUN_INTENSITY_MULTIPLIER,
-
- PARAM_SKYLIGHT_KM,
- PARAM_SKYLIGHT_KR,
- PARAM_SKYLIGHT_G,
-
- PARAM_SKYLIGHT_WAVELENGTH_R,
- PARAM_SKYLIGHT_WAVELENGTH_G,
- PARAM_SKYLIGHT_WAVELENGTH_B,
-
- PARAM_NIGHSKY_HORIZON_COLOR,
- PARAM_NIGHSKY_HORIZON_COLOR_MULTIPLIER,
- PARAM_NIGHSKY_ZENITH_COLOR,
- PARAM_NIGHSKY_ZENITH_COLOR_MULTIPLIER,
- PARAM_NIGHSKY_ZENITH_SHIFT,
-
- PARAM_NIGHSKY_START_INTENSITY,
-
- PARAM_NIGHSKY_MOON_COLOR,
- PARAM_NIGHSKY_MOON_COLOR_MULTIPLIER,
- PARAM_NIGHSKY_MOON_INNERCORONA_COLOR,
- PARAM_NIGHSKY_MOON_INNERCORONA_COLOR_MULTIPLIER,
- PARAM_NIGHSKY_MOON_INNERCORONA_SCALE,
- PARAM_NIGHSKY_MOON_OUTERCORONA_COLOR,
- PARAM_NIGHSKY_MOON_OUTERCORONA_COLOR_MULTIPLIER,
- PARAM_NIGHSKY_MOON_OUTERCORONA_SCALE,
-
- PARAM_CLOUDSHADING_SUNLIGHT_MULTIPLIER,
- PARAM_CLOUDSHADING_SUNLIGHT_CUSTOM_COLOR,
- PARAM_CLOUDSHADING_SUNLIGHT_CUSTOM_COLOR_MULTIPLIER,
- PARAM_CLOUDSHADING_SUNLIGHT_CUSTOM_COLOR_INFLUENCE,
-
- PARAM_SUN_SHAFTS_VISIBILITY,
- PARAM_SUN_RAYS_VISIBILITY,
- PARAM_SUN_RAYS_ATTENUATION,
- PARAM_SUN_RAYS_SUNCOLORINFLUENCE,
- PARAM_SUN_RAYS_CUSTOMCOLOR,
-
- PARAM_OCEANFOG_COLOR, // Remove when ocean related feature toggle is removed.
- PARAM_OCEANFOG_COLOR_MULTIPLIER, // Remove when ocean related feature toggle is removed.
- PARAM_OCEANFOG_DENSITY, // Remove when ocean related feature toggle is removed.
-
- PARAM_SKYBOX_MULTIPLIER,
-
- PARAM_HDR_FILMCURVE_SHOULDER_SCALE,
- PARAM_HDR_FILMCURVE_LINEAR_SCALE,
- PARAM_HDR_FILMCURVE_TOE_SCALE,
- PARAM_HDR_FILMCURVE_WHITEPOINT,
-
- PARAM_HDR_COLORGRADING_COLOR_SATURATION,
- PARAM_HDR_COLORGRADING_COLOR_BALANCE,
-
- PARAM_HDR_EYEADAPTATION_SCENEKEY,
- PARAM_HDR_EYEADAPTATION_MIN_EXPOSURE,
- PARAM_HDR_EYEADAPTATION_MAX_EXPOSURE,
- PARAM_HDR_EYEADAPTATION_EV_MIN,
- PARAM_HDR_EYEADAPTATION_EV_MAX,
- PARAM_HDR_EYEADAPTATION_EV_AUTO_COMPENSATION,
- PARAM_HDR_BLOOM_AMOUNT,
-
- PARAM_COLORGRADING_FILTERS_GRAIN,
- PARAM_COLORGRADING_FILTERS_PHOTOFILTER_COLOR,
- PARAM_COLORGRADING_FILTERS_PHOTOFILTER_DENSITY,
-
- PARAM_COLORGRADING_DOF_FOCUSRANGE,
- PARAM_COLORGRADING_DOF_BLURAMOUNT,
-
- PARAM_SHADOWSC0_BIAS,
- PARAM_SHADOWSC0_SLOPE_BIAS,
- PARAM_SHADOWSC1_BIAS,
- PARAM_SHADOWSC1_SLOPE_BIAS,
- PARAM_SHADOWSC2_BIAS,
- PARAM_SHADOWSC2_SLOPE_BIAS,
- PARAM_SHADOWSC3_BIAS,
- PARAM_SHADOWSC3_SLOPE_BIAS,
- PARAM_SHADOWSC4_BIAS,
- PARAM_SHADOWSC4_SLOPE_BIAS,
- PARAM_SHADOWSC5_BIAS,
- PARAM_SHADOWSC5_SLOPE_BIAS,
- PARAM_SHADOWSC6_BIAS,
- PARAM_SHADOWSC6_SLOPE_BIAS,
- PARAM_SHADOWSC7_BIAS,
- PARAM_SHADOWSC7_SLOPE_BIAS,
-
- PARAM_SHADOW_JITTERING,
-
- PARAM_HDR_DYNAMIC_POWER_FACTOR,
- PARAM_TERRAIN_OCCL_MULTIPLIER,
- PARAM_SUN_COLOR_MULTIPLIER,
-
- PARAM_TOTAL
- };
-
- struct SPresetInfo
- {
- const char* m_pName;
- bool m_bCurrent;
- };
-
- enum EVariableType
- {
- TYPE_FLOAT,
- TYPE_COLOR
- };
- struct SVariableInfo
- {
- const char* name; //!< Variable name.
- const char* displayName; //!< Variable user readable name.
- const char* group; //!< Group name.
- int nParamId;
- EVariableType type;
- float fValue[3]; //!< Value of the variable (3 needed for color type).
- ISplineInterpolator* pInterpolator; //!< Splines that control variable value.
- };
- struct SAdvancedInfo
- {
- float fStartTime;
- float fEndTime;
- float fAnimSpeed;
- };
- struct SEnvironmentInfo
- {
- SEnvironmentInfo()
- : bSunLinkedToTOD(true)
- , sunRotationLatitude(0)
- , sunRotationLongitude(0){}
- bool bSunLinkedToTOD;
- float sunRotationLatitude;
- float sunRotationLongitude;
- };
-
- //
- virtual ~ITimeOfDay(){}
-
- virtual int GetPresetCount() const = 0;
- virtual bool GetPresetsInfos(SPresetInfo* resultArray, unsigned int arraySize) const = 0;
- virtual bool SetCurrentPreset(const char* szPresetName) = 0;
- virtual bool AddNewPreset(const char* szPresetName) = 0;
- virtual bool RemovePreset(const char* szPresetName) = 0;
- virtual bool SavePreset(const char* szPresetName) const = 0;
- virtual bool LoadPreset(const char* szFilePath) = 0;
- virtual void ResetPreset(const char* szPresetName) = 0;
-
- virtual bool ImportPreset(const char* szPresetName, const char* szFilePath) = 0;
- virtual bool ExportPreset(const char* szPresetName, const char* szFilePath) const = 0;
-
- //! Access to variables that control time of the day appearance.
- virtual int GetVariableCount() const = 0;
- virtual bool GetVariableInfo(int nIndex, SVariableInfo& varInfo) const = 0;
- virtual void SetVariableValue(int nIndex, float fValue[3]) = 0;
-
- //! Editor interface.
- virtual bool InterpolateVarInRange(int nIndex, float fMin, float fMax, unsigned int nCount, Vec3* resultArray) const = 0;
- virtual uint GetSplineKeysCount(int nIndex, int nSpline) const = 0;
- virtual bool GetSplineKeysForVar(int nIndex, int nSpline, SBezierKey* keysArray, unsigned int keysArraySize) const = 0;
- virtual bool SetSplineKeysForVar(int nIndex, int nSpline, const SBezierKey* keysArray, unsigned int keysArraySize) = 0;
- virtual bool UpdateSplineKeyForVar(int nIndex, int nSpline, float fTime, float newValue) = 0;
-
- virtual void ResetVariables() = 0;
-
- //! Sets the time of the day specified in hours.
- virtual void SetTime(float fHour, bool bForceUpdate = false, bool bForceEnvUpdate = true) = 0;
- virtual float GetTime() = 0;
-
- //! Sun position.
- virtual void SetSunPos(float longitude, float latitude) = 0;
- virtual float GetSunLatitude() = 0;
- virtual float GetSunLongitude() = 0;
-
- //! Updates the current ToD.
- virtual void Tick() = 0;
-
-
- virtual void SetPaused(bool paused) = 0;
-
- virtual void SetAdvancedInfo(const SAdvancedInfo& advInfo) = 0;
- virtual void GetAdvancedInfo(SAdvancedInfo& advInfo) = 0;
-
- //! Updates engine parameters after variable values have been changed.
- virtual void Update(bool bInterpolate = true, bool bForceUpdate = false, bool bForceEnvUpdate = true) = 0;
- virtual void SetUpdateCallback(ITimeOfDayUpdateCallback* pCallback) = 0;
-
- virtual void BeginEditMode() = 0;
- virtual void EndEditMode() = 0;
-
- virtual void Serialize(XmlNodeRef& node, bool bLoading) = 0;
- virtual void Serialize(TSerialize ser) = 0;
-
- virtual void SetTimer(ITimer* pTimer) = 0;
- virtual void SetEnvironmentSettings(const SEnvironmentInfo& envInfo) = 0;
- virtual void LerpWith(const ITimeOfDay& other, float lerpValue, ITimeOfDay& output) const = 0;
-
- //! Multiplayer serialization.
- static const int NETSER_FORCESET = BIT(0);
- static const int NETSER_COMPENSATELAG = BIT(1);
- static const int NETSER_STATICPROPS = BIT(2);
- virtual void NetSerialize(TSerialize ser, float lag, uint32 flags) = 0;
-};
-
-struct ITimeOfDayUpdateCallback
-{
- //
- virtual ~ITimeOfDayUpdateCallback(){}
- virtual void BeginUpdate() = 0;
- virtual bool GetCustomValue(ITimeOfDay::ETimeOfDayParamID paramID, int dim, float* pValues, float& blendWeight) = 0;
- virtual void EndUpdate() = 0;
- //
-};
-
diff --git a/Code/CryEngine/CryCommon/Mocks/I3DEngineMock.h b/Code/CryEngine/CryCommon/Mocks/I3DEngineMock.h
deleted file mode 100644
index b0936ddbdd..0000000000
--- a/Code/CryEngine/CryCommon/Mocks/I3DEngineMock.h
+++ /dev/null
@@ -1,528 +0,0 @@
-/*
-* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
-* its licensors.
-*
-* For complete copyright and license terms please see the LICENSE at the root of this
-* distribution (the "License"). All use of this software is governed by the License,
-* or, if provided, by the license below or the license accompanying this file. Do not
-* remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-*
-*/
-#pragma once
-
-#include
-
-#include
-#include
-#include
-
-// the following was generated using google's python script to autogenerate mocks.
-// however, it needed some hand-editing to make it work, so if you add functions to I3DEngine,
-// it will probably be better to just manually add them here than try to run the script again.
-
-class I3DEngineMock
- : public I3DEngine
-{
-public:
- // From IProcess
- MOCK_METHOD1(SetFlags,
- void(int));
- MOCK_METHOD0(GetFlags,
- int(void));
-
- // From I3DEngine
- MOCK_METHOD0(Init,
- bool());
- MOCK_METHOD1(SetLevelPath,
- void(const char* szFolderName));
- MOCK_METHOD1(CheckMinSpec,
- bool(uint32 nMinSpec));
- MOCK_METHOD1(PrepareOcclusion,
- void(const CCamera& rCamera));
- MOCK_METHOD0(EndOcclusion,
- void());
- MOCK_METHOD2(LoadLevel,
- bool(const char* szFolderName, const char* szMissionName));
- MOCK_METHOD2(InitLevelForEditor,
- bool(const char* szFolderName, const char* szMissionName));
- MOCK_METHOD0(LevelLoadingInProgress,
- bool());
- MOCK_METHOD0(OnFrameStart,
- void());
- MOCK_METHOD0(PostLoadLevel,
- void());
- MOCK_METHOD0(LoadEmptyLevel,
- void());
- MOCK_METHOD0(UnloadLevel,
- void());
- MOCK_METHOD0(Update,
- void());
- MOCK_CONST_METHOD0(GetRenderingCamera,
- const CCamera&());
- MOCK_CONST_METHOD0(GetZoomFactor,
- float());
- MOCK_METHOD0(Tick,
- void());
- MOCK_METHOD0(UpdateShaderItems,
- void());
- MOCK_METHOD0(Release,
- void());
- MOCK_METHOD3(RenderWorld,
- void(int nRenderFlags, const SRenderingPassInfo& passInfo, const char* szDebugName));
- MOCK_METHOD2(RenderSceneReflection,
- void(int nRenderFlags, const SRenderingPassInfo& passInfo));
- MOCK_METHOD1(PreWorldStreamUpdate,
- void(const CCamera& cam));
- MOCK_METHOD0(WorldStreamUpdate,
- void());
- MOCK_METHOD0(ShutDown,
- void());
- MOCK_METHOD7(LoadStatObjUnsafeManualRef,
- IStatObj*(const char* fileName, const char* geomName, IStatObj::SSubObject** subObject,
- bool useStreaming, unsigned long loadingFlags, const void* data, int dataSize));
- MOCK_METHOD7(LoadStatObjAutoRef,
- _smart_ptr(const char* fileName, const char* geomName, IStatObj::SSubObject** subObject,
- bool useStreaming, unsigned long loadingFlags, const void* data, int dataSize));
- MOCK_METHOD0(ProcessAsyncStaticObjectLoadRequests,
- void());
- MOCK_METHOD5(LoadStatObjAsync,
- void(LoadStaticObjectAsyncResult resultCallback, const char* szFileName, const char* szGeomName, bool bUseStreaming, unsigned long nLoadingFlags));
- MOCK_METHOD1(FindStatObjectByFilename,
- IStatObj*(const char* filename));
- MOCK_METHOD0(GetGSMRange,
- const float());
- MOCK_METHOD0(GetGSMRangeStep,
- const float());
- MOCK_METHOD0(GetLoadedObjectCount,
- int());
- MOCK_METHOD2(GetLoadedStatObjArray,
- void(IStatObj** pObjectsArray, int& nCount));
- MOCK_METHOD1(GetObjectsStreamingStatus,
- void(SObjectsStreamingStatus& outStatus));
- MOCK_METHOD2(GetStreamingSubsystemData,
- void(int subsystem, SStremaingBandwidthData& outData));
- MOCK_METHOD3(RegisterEntity,
- void(IRenderNode* pEntity, int nSID, int nSIDConsideredSafe));
- MOCK_METHOD1(SelectEntity,
- void(IRenderNode* pEntity));
- MOCK_METHOD0(IsSunShadows,
- bool());
- MOCK_METHOD2(MakeSystemMaterialFromShaderHelper
- , _smart_ptr(const char* sShaderName, SInputShaderResources* Res));
- MOCK_METHOD1(CheckMinSpecHelper
- , bool(uint32 nMinSpec));
- MOCK_METHOD1(OnCasterDeleted
- , void(IShadowCaster* pCaster));
- MOCK_METHOD4(GetStatObjAndMatTables,
- void(DynArray* pStatObjTable, DynArray<_smart_ptr>* pMatTable, DynArray* pStatInstGroupTable, uint32 nObjTypeMask));
-#ifndef _RELEASE
- MOCK_METHOD1(AddObjToDebugDrawList,
- void(SObjectInfoToAddToDebugDrawList& objInfo));
- MOCK_CONST_METHOD0(IsDebugDrawListEnabled,
- bool());
-#endif
- MOCK_METHOD1(UnRegisterEntityDirect,
- void(IRenderNode* pEntity));
- MOCK_METHOD1(UnRegisterEntityAsJob,
- void(IRenderNode* pEnt));
- MOCK_CONST_METHOD1(IsUnderWater,
- bool(const Vec3& vPos));
- MOCK_METHOD1(SetOceanRenderFlags,
- void(uint8 nFlags));
- MOCK_CONST_METHOD0(GetOceanRenderFlags,
- uint8());
- MOCK_CONST_METHOD0(GetOceanVisiblePixelsCount,
- uint32());
- MOCK_METHOD3(GetBottomLevel,
- float(const Vec3& referencePos, float maxRelevantDepth, int objtypes));
- MOCK_METHOD2(GetBottomLevel,
- float(const Vec3& referencePos, float maxRelevantDepth));
- MOCK_METHOD2(GetBottomLevel,
- float(const Vec3& referencePos, int objflags));
- MOCK_METHOD0(GetWaterLevel,
- float());
- MOCK_METHOD3(GetWaterLevel,
- float(const Vec3* pvPos, IPhysicalEntity* pent, bool bAccurate));
- MOCK_CONST_METHOD1(GetAccurateOceanHeight,
- float(const Vec3& pCurrPos));
- MOCK_CONST_METHOD0(GetCausticsParams,
- CausticsParams());
- MOCK_CONST_METHOD0(GetOceanAnimationParams,
- OceanAnimationData());
- MOCK_CONST_METHOD1(GetHDRSetupParams,
- void(Vec4 pParams[5]));
- MOCK_METHOD0(ResetParticlesAndDecals,
- void());
- MOCK_METHOD1(CreateDecal,
- void(const CryEngineDecalInfo& Decal));
- MOCK_METHOD2(DeleteDecalsInRange,
- void(AABB* pAreaBox, IRenderNode* pEntity));
- MOCK_METHOD1(SetSunColor,
- void(Vec3 vColor));
- MOCK_METHOD0(GetSunAnimColor,
- Vec3());
- MOCK_METHOD1(SetSunAnimColor,
- void(const Vec3& color));
- MOCK_METHOD0(GetSunAnimSpeed,
- float());
- MOCK_METHOD1(SetSunAnimSpeed,
- void(float sunAnimSpeed));
- MOCK_METHOD0(GetSunAnimPhase,
- AZ::u8());
- MOCK_METHOD1(SetSunAnimPhase,
- void(AZ::u8 sunAnimPhase));
- MOCK_METHOD0(GetSunAnimIndex,
- AZ::u8());
- MOCK_METHOD1(SetSunAnimIndex,
- void(AZ::u8 sunAnimIndex));
- MOCK_METHOD1(SetRainParams,
- void(const SRainParams& rainParams));
- MOCK_METHOD1(GetRainParams,
- bool(SRainParams& rainParams));
- MOCK_METHOD5(SetSnowSurfaceParams,
- void(const Vec3& vCenter, float fRadius, float fSnowAmount, float fFrostAmount, float fSurfaceFreezing));
- MOCK_METHOD5(GetSnowSurfaceParams,
- bool(Vec3& vCenter, float& fRadius, float& fSnowAmount, float& fFrostAmount, float& fSurfaceFreezing));
- MOCK_METHOD7(SetSnowFallParams,
- void(int nSnowFlakeCount, float fSnowFlakeSize, float fSnowFallBrightness, float fSnowFallGravityScale, float fSnowFallWindScale, float fSnowFallTurbulence, float fSnowFallTurbulenceFreq));
- MOCK_METHOD7(GetSnowFallParams,
- bool(int& nSnowFlakeCount, float& fSnowFlakeSize, float& fSnowFallBrightness, float& fSnowFallGravityScale, float& fSnowFallWindScale, float& fSnowFallTurbulence, float& fSnowFallTurbulenceFreq));
- MOCK_METHOD1(SetMaxViewDistanceScale,
- void(float fScale));
- MOCK_METHOD1(GetMaxViewDistance,
- float(bool));
- MOCK_CONST_METHOD0(GetFrameLodInfo,
- const SFrameLodInfo&());
- MOCK_METHOD1(SetFrameLodInfo,
- void(const SFrameLodInfo& frameLodInfo));
- MOCK_METHOD1(SetFogColor,
- void(const Vec3& vFogColor));
- MOCK_METHOD0(GetFogColor,
- Vec3());
- MOCK_METHOD6(GetSkyLightParameters,
- void(Vec3& sunDir, Vec3& sunIntensity, float& Km, float& Kr, float& g, Vec3& rgbWaveLengths));
- MOCK_METHOD7(SetSkyLightParameters,
- void(const Vec3& sunDir, const Vec3& sunIntensity, float Km, float Kr, float g, const Vec3& rgbWaveLengths, bool forceImmediateUpdate));
- MOCK_CONST_METHOD0(GetLightsHDRDynamicPowerFactor,
- float());
- MOCK_CONST_METHOD3(IsTessellationAllowed,
- bool(const CRenderObject* pObj, const SRenderingPassInfo& passInfo, bool bIgnoreShadowPass));
- MOCK_METHOD3(SetRenderNodeMaterialAtPosition,
- void(EERType eNodeType, const Vec3& vPos, _smart_ptr pMat));
- MOCK_METHOD1(OverrideCameraPrecachePoint,
- void(const Vec3& vPos));
- MOCK_METHOD4(AddPrecachePoint,
- int(const Vec3& vPos, const Vec3& vDir, float fTimeOut, float fImportanceFactor));
- MOCK_METHOD1(ClearPrecachePoint,
- void(int id));
- MOCK_METHOD0(ClearAllPrecachePoints,
- void());
- MOCK_METHOD1(GetPrecacheRoundIds,
- void(int pRoundIds[MAX_STREAM_PREDICTION_ZONES]));
- MOCK_METHOD5(TraceFogVolumes,
- void(const Vec3& vPos, const AABB& objBBox, SFogVolumeData& fogVolData, const SRenderingPassInfo& passInfo, bool fogVolumeShadingQuality));
-
- MOCK_METHOD1(RemoveAllStaticObjects,
- void(int));
- MOCK_METHOD3(SetStatInstGroup,
- bool(int nGroupId, const IStatInstGroup& siGroup, int nSID));
- MOCK_METHOD3(GetStatInstGroup,
- bool(int, IStatInstGroup&, int));
- MOCK_METHOD3(OnExplosion,
- void(Vec3, float, bool));
- MOCK_METHOD1(SetPhysMaterialEnumerator,
- void(IPhysMaterialEnumerator* pPhysMaterialEnumerator));
- MOCK_METHOD0(GetPhysMaterialEnumerator,
- IPhysMaterialEnumerator*());
- MOCK_METHOD0(SetupDistanceFog,
- void());
- MOCK_METHOD1(LoadMissionDataFromXMLNode,
- void(const char* szMissionName));
- MOCK_METHOD2(LoadEnvironmentSettingsFromXML,
- void(XmlNodeRef, int));
- MOCK_METHOD0(LoadCompiledOctreeForEditor,
- bool());
- MOCK_CONST_METHOD0(GetSunDir,
- Vec3());
- MOCK_CONST_METHOD0(GetSunDirNormalized,
- Vec3());
- MOCK_CONST_METHOD0(GetRealtimeSunDirNormalized,
- Vec3());
- MOCK_METHOD0(GetDistanceToSectorWithWater,
- float());
- MOCK_CONST_METHOD0(GetSunColor,
- Vec3());
- MOCK_CONST_METHOD0(GetSSAOAmount,
- float());
- MOCK_CONST_METHOD0(GetSSAOContrast,
- float());
- MOCK_METHOD1(FreeRenderNodeState,
- void(IRenderNode* pEntity));
- MOCK_METHOD1(GetLevelFilePath,
- const char*(const char* szFileName));
- MOCK_METHOD4(DisplayInfo,
- void(float& fTextPosX, float& fTextPosY, float& fTextStepY, bool bEnhanced));
- MOCK_METHOD0(DisplayMemoryStatistics,
- void());
-
- // Can't mock methods with variable parameters so just create empty bodies for them.
- void DrawTextRightAligned([[maybe_unused]] const float x, [[maybe_unused]] const float y, [[maybe_unused]] const char* format, ...) override {}
- void DrawTextRightAligned([[maybe_unused]] const float x, [[maybe_unused]] const float y, [[maybe_unused]] const float scale, [[maybe_unused]] const ColorF& color, [[maybe_unused]] const char* format, ...) override {}
-
- MOCK_METHOD3(DrawBBoxHelper
- , void (const Vec3& vMin, const Vec3& vMax, ColorB col));
- MOCK_METHOD2(DrawBBoxHelper
- , void (const AABB& box, ColorB col));
-
- MOCK_METHOD3(ActivatePortal,
- void(const Vec3& vPos, bool bActivate, const char* szEntityName));
- MOCK_CONST_METHOD1(GetMemoryUsage,
- void(ICrySizer* pSizer));
- MOCK_METHOD2(GetResourceMemoryUsage,
- void(ICrySizer* pSizer, const AABB& cstAABB));
- MOCK_METHOD1(CreateVisArea,
- IVisArea*(uint64 visGUID));
- MOCK_METHOD1(DeleteVisArea,
- void(IVisArea* pVisArea));
- MOCK_METHOD6(UpdateVisArea,
- void(IVisArea* pArea, const Vec3* pPoints, int nCount, const char* szName, const SVisAreaInfo& info, bool bReregisterObjects));
- MOCK_METHOD4(IsVisAreasConnected,
- bool(IVisArea* pArea1, IVisArea* pArea2, int nMaxRecursion, bool bSkipDisabledPortals));
- MOCK_METHOD0(CreateClipVolume,
- IClipVolume*());
- MOCK_METHOD1(DeleteClipVolume,
- void(IClipVolume* pClipVolume));
- MOCK_METHOD7(UpdateClipVolume,
- void(IClipVolume* pClipVolume, _smart_ptr pRenderMesh, IBSPTree3D* pBspTree, const Matrix34& worldTM, bool bActive, uint32 flags, const char* szName));
- MOCK_METHOD1(CreateRenderNode,
- IRenderNode*(EERType type));
- MOCK_METHOD1(DeleteRenderNode,
- void(IRenderNode* pRenderNode));
- MOCK_METHOD1(SetWind,
- void(const Vec3& vWind));
- MOCK_CONST_METHOD2(GetWind,
- Vec3(const AABB& box, bool bIndoors));
- MOCK_CONST_METHOD1(GetGlobalWind,
- Vec3(bool bIndoors));
- MOCK_CONST_METHOD4(SampleWind,
- bool(Vec3* pSamples, int nSamples, const AABB& volume, bool bIndoors));
- MOCK_METHOD1(GetVisAreaFromPos,
- IVisArea*(const Vec3& vPos));
- MOCK_METHOD2(IntersectsVisAreas,
- bool(const AABB& box, void** pNodeCache));
- MOCK_METHOD4(ClipToVisAreas,
- bool(IVisArea* pInside, Sphere& sphere, Vec3 const& vNormal, void* pNodeCache));
- MOCK_METHOD1(EnableOceanRendering,
- void(bool bOcean));
- MOCK_METHOD1(AddTextureLoadHandler,
- void(ITextureLoadHandler* pHandler));
- MOCK_METHOD1(RemoveTextureLoadHandler,
- void(ITextureLoadHandler* pHandler));
- MOCK_METHOD1(GetTextureLoadHandlerForImage,
- ITextureLoadHandler*(const char* ext));
- MOCK_METHOD0(CreateLightSource,
- struct ILightSource*());
- MOCK_METHOD1(DeleteLightSource,
- void(ILightSource* pLightSource));
- MOCK_METHOD0(GetLightEntities,
- const PodArray* ());
- MOCK_METHOD3(GetLightVolumes,
- void(threadID nThreadID, SLightVolume*& pLightVols, uint32& nNumVols));
- MOCK_METHOD4(RegisterVolumeForLighting,
- uint16(const Vec3& vPos, f32 fRadius, uint8 nClipVolumeRef, const SRenderingPassInfo& passInfo));
- MOCK_METHOD1(RestoreTerrainFromDisk,
- bool(int));
- MOCK_METHOD1(GetFilePath,
- const char*(const char* szFileName));
- MOCK_CONST_METHOD0(GetPostEffectGroups,
- class IPostEffectGroupManager*());
- MOCK_CONST_METHOD0(GetPostEffectBaseGroup,
- class IPostEffectGroup*());
- MOCK_CONST_METHOD3(SetPostEffectParam,
- void(const char* pParam, float fValue, bool bForceValue));
- MOCK_CONST_METHOD3(SetPostEffectParamVec4,
- void(const char* pParam, const Vec4& pValue, bool bForceValue));
- MOCK_CONST_METHOD2(SetPostEffectParamString,
- void(const char* pParam, const char* pszArg));
- MOCK_CONST_METHOD2(GetPostEffectParam,
- void(const char* pParam, float& fValue));
- MOCK_CONST_METHOD2(GetPostEffectParamVec4,
- void(const char* pParam, Vec4& pValue));
- MOCK_CONST_METHOD2(GetPostEffectParamString,
- void(const char* pParam, const char*& pszArg));
- MOCK_METHOD1(GetPostEffectID,
- int32(const char* pPostEffectName));
- MOCK_METHOD1(ResetPostEffects,
- void(bool));
- MOCK_METHOD0(DisablePostEffects,
- void());
- MOCK_METHOD1(SetShadowsGSMCache,
- void(bool bCache));
- MOCK_METHOD2(SetCachedShadowBounds,
- void(const AABB& shadowBounds, float fAdditionalCascadesScale));
- MOCK_METHOD1(SetRecomputeCachedShadows,
- void(uint));
- MOCK_METHOD0(CheckMemoryHeap,
- void());
- MOCK_METHOD1(DeleteEntityDecals,
- void(IRenderNode* pEntity));
- MOCK_METHOD0(LockCGFResources,
- void());
- MOCK_METHOD0(UnlockCGFResources,
- void());
- MOCK_METHOD0(FreeUnusedCGFResources,
- void());
- MOCK_METHOD0(CreateStatObj,
- IStatObj*());
- MOCK_METHOD1(CreateStatObjOptionalIndexedMesh,
- IStatObj*(bool createIndexedMesh));
- MOCK_METHOD0(CreateIndexedMesh,
- IIndexedMesh*());
- MOCK_METHOD1(SerializeState,
- void(TSerialize ser));
- MOCK_METHOD1(PostSerialize,
- void(bool bReading));
- MOCK_METHOD0(GetMaterialHelpers,
- IMaterialHelpers&());
- MOCK_METHOD0(GetMaterialManager,
- IMaterialManager*());
- MOCK_METHOD0(GetObjManager,
- IObjManager*());
- MOCK_METHOD1(CreateChunkfileContent,
- CContentCGF*(const char* filename));
- MOCK_METHOD1(ReleaseChunkfileContent,
- void(CContentCGF*));
- MOCK_METHOD4(LoadChunkFileContent,
- bool(CContentCGF* pCGF, const char* filename, bool bNoWarningMode, bool bCopyChunkFile));
- MOCK_METHOD6(LoadChunkFileContentFromMem,
- bool(CContentCGF* pCGF, const void* pData, size_t nDataLen, uint32 nLoadingFlags, bool bNoWarningMode, bool bCopyChunkFile));
- MOCK_METHOD1(CreateChunkFile,
- IChunkFile*(bool));
- MOCK_CONST_METHOD3(CreateChunkFileWriter,
- ChunkFile::IChunkFileWriter*(EChunkFileFormat eFormat, AZ::IO::IArchive* pPak, const char* filename));
- MOCK_CONST_METHOD1(ReleaseChunkFileWriter,
- void(ChunkFile::IChunkFileWriter* p));
- MOCK_METHOD2(CreateOcean,
- bool(_smart_ptr pTerrainWaterMat, float waterLevel));
- MOCK_METHOD0(DeleteOcean,
- void());
- MOCK_METHOD1(ChangeOceanMaterial,
- void(_smart_ptr pMat));
- MOCK_METHOD1(ChangeOceanWaterLevel,
- void(float fWaterLevel));
- MOCK_METHOD1(InitMaterialDefautMappingAxis
- , void(_smart_ptr pMat));
- MOCK_METHOD0(GetIVisAreaManager,
- IVisAreaManager*());
- MOCK_METHOD3(PrecacheLevel,
- void(bool bPrecacheAllVisAreas, Vec3* pPrecachePoints, int nPrecachePointsNum));
- MOCK_METHOD0(ProposeContentPrecache,
- void());
- MOCK_METHOD0(GetTimeOfDay,
- ITimeOfDay*());
- MOCK_METHOD1(SetSkyMaterialPath,
- void(const string& skyMaterialPath));
- MOCK_METHOD1(SetSkyLowSpecMaterialPath,
- void(const string& skyMaterialPath));
- MOCK_METHOD0(LoadSkyMaterial,
- void());
- MOCK_METHOD0(GetSkyMaterial,
- _smart_ptr());
- MOCK_METHOD1(SetSkyMaterial,
- void(_smart_ptr pSkyMat));
- MOCK_METHOD2(SetGlobalParameter,
- void(E3DEngineParameter param, const Vec3& v));
- MOCK_METHOD2(GetGlobalParameter,
- void(E3DEngineParameter param, Vec3& v));
- MOCK_METHOD1(SetShadowMode,
- void(EShadowMode shadowMode));
- MOCK_CONST_METHOD0(GetShadowMode,
- EShadowMode());
- MOCK_METHOD6(AddPerObjectShadow,
- void(IShadowCaster* pCaster, float fConstBias, float fSlopeBias, float fJitter, const Vec3& vBBoxScale, uint nTexSize));
- MOCK_METHOD1(RemovePerObjectShadow,
- void(IShadowCaster* pCaster));
- MOCK_METHOD1(GetPerObjectShadow,
- struct SPerObjectShadow*(IShadowCaster* pCaster));
- MOCK_METHOD2(GetCustomShadowMapFrustums,
- void(struct ShadowMapFrustum*& arrFrustums, int& nFrustumCount));
- MOCK_METHOD2(SaveStatObj,
- int(IStatObj* pStatObj, TSerialize ser));
- MOCK_METHOD1(LoadStatObj,
- IStatObj*(TSerialize ser));
- MOCK_METHOD2(CheckIntersectClouds,
- bool(const Vec3& p1, const Vec3& p2));
- MOCK_METHOD1(OnRenderMeshDeleted,
- void(IRenderMesh* pRenderMesh));
- MOCK_METHOD0(DebugDraw_UpdateDebugNode,
- void());
- MOCK_METHOD4(RayObjectsIntersection2D,
- bool(Vec3 vStart, Vec3 vEnd, Vec3& vHitPoint, EERType eERType));
- MOCK_METHOD3(RenderMeshRayIntersection,
- bool(IRenderMesh* pRenderMesh, SRayHitInfo& hitInfo, _smart_ptr pCustomMtl));
- MOCK_METHOD3(CheckCreateRNTmpData
- , void(CRNTmpData** ppInfo, IRenderNode* pRNode, const SRenderingPassInfo& passInfo));
- MOCK_METHOD1(FreeRNTmpData,
- void(CRNTmpData** ppInfo));
- MOCK_METHOD0(IsObjectTreeReady
- , bool());
- MOCK_METHOD0(GetIObjectTree
- , IOctreeNode*());
- MOCK_METHOD2(GetObjectsByType,
- uint32(EERType, IRenderNode**));
- MOCK_METHOD4(GetObjectsByTypeInBox,
- uint32(EERType objType, const AABB& bbox, IRenderNode** pObjects, ObjectTreeQueryFilterCallback filterCallback));
- MOCK_METHOD2(GetObjectsInBox,
- uint32(const AABB& bbox, IRenderNode** pObjects));
- MOCK_METHOD2(GetObjectsByFlags,
- uint32(uint, IRenderNode**));
- MOCK_METHOD4(GetObjectsByTypeInBox,
- void(EERType objType, const AABB& bbox, PodArray* pLstObjects, ObjectTreeQueryFilterCallback filterCallback));
- MOCK_METHOD2(OnObjectModified,
- void(IRenderNode* pRenderNode, uint dwFlags));
- MOCK_METHOD1(FillDebugFPSInfo,
- void(SDebugFPSInfo&));
- MOCK_METHOD0(GetLevelFolder,
- const char*());
- MOCK_METHOD0(IsAreaActivationInUse,
- bool());
- MOCK_METHOD3(RenderRenderNode_ShadowPass,
- void(IShadowCaster* pRNode, const SRenderingPassInfo& passInfo, AZ::LegacyJobExecutor* pJobExecutor));
- MOCK_METHOD0(GetOpticsManager,
- IOpticsManager*());
- MOCK_METHOD0(SyncProcessStreamingUpdate,
- void());
- MOCK_METHOD1(SetScreenshotCallback,
- void(IScreenshotCallback* pCallback));
- MOCK_METHOD8(ActivateObjectsLayer,
- void(uint16 nLayerId, bool bActivate, bool bPhys, bool bObjects, bool bStaticLights, const char* pLayerName, IGeneralMemoryHeap* pHeap, bool bCheckLayerActivation));
- MOCK_CONST_METHOD4(GetLayerMemoryUsage,
- void(uint16 nLayerId, ICrySizer* pSizer, int* pNumBrushes, int* pNumDecals));
- MOCK_METHOD2(SkipLayerLoading,
- void(uint16 nLayerId, bool bClearList));
- MOCK_METHOD2(PrecacheRenderNode,
- void(IRenderNode* pObj, float fEntDistanceReal));
- MOCK_METHOD0(GetDeferredPhysicsEventManager,
- IDeferredPhysicsEventManager*());
- MOCK_METHOD1(SetStreamableListener,
- void(IStreamedObjectListener* pListener));
- MOCK_METHOD1(GetRenderingPassCamera,
- CCamera*(const CCamera& rCamera));
- MOCK_METHOD3(GetSvoStaticTextures,
- void(I3DEngine::SSvoStaticTexInfo& svoInfo, PodArray* pLightsTI_S, PodArray* pLightsTI_D));
- MOCK_METHOD2(GetSvoBricksForUpdate,
- void(PodArray& arrNodeInfo, bool getDynamic));
-#if defined(USE_GEOM_CACHES)
- MOCK_METHOD1(LoadGeomCache,
- IGeomCache*(const char* szFileName));
- MOCK_METHOD1(FindGeomCacheByFilename,
- IGeomCache*(const char* szFileName));
-#endif
- MOCK_METHOD3(LoadDesignerObject,
- IStatObj*(int nVersion, const char* szBinaryStream, int size));
-
- MOCK_METHOD0(WaitForCullingJobsCompletion,
- void());
-};
-
diff --git a/Code/CryEngine/CryCommon/Mocks/IRendererMock.h b/Code/CryEngine/CryCommon/Mocks/IRendererMock.h
index 2021e96172..757c586261 100644
--- a/Code/CryEngine/CryCommon/Mocks/IRendererMock.h
+++ b/Code/CryEngine/CryCommon/Mocks/IRendererMock.h
@@ -12,11 +12,15 @@
#pragma once
#include
-#include // needed for SRenderingPassInfo definition
#include
#include
#include
+struct SRendItemSorter {};
+struct SRenderingPassInfo {};
+struct SClipVolumeBlendInfo {};
+struct SFogVolumeData {};
+
// the following was generated using google's python script to autogenerate mocks.
// however, it needed some hand-editing to make it work, so if you add functions to IRenderer,
// it will probably be better to just manually add them here than try to run the script again
diff --git a/Code/CryEngine/CryCommon/Mocks/ISystemMock.h b/Code/CryEngine/CryCommon/Mocks/ISystemMock.h
index 5edd84fd75..4d2e80a2f3 100644
--- a/Code/CryEngine/CryCommon/Mocks/ISystemMock.h
+++ b/Code/CryEngine/CryCommon/Mocks/ISystemMock.h
@@ -37,12 +37,6 @@ public:
void());
MOCK_METHOD0(NeedDoWorkDuringOcclusionChecks,
bool());
- MOCK_METHOD0(Render,
- void());
- MOCK_METHOD0(RenderBegin,
- void());
- MOCK_METHOD2(RenderEnd,
- void(bool, bool));
MOCK_METHOD2(SynchronousLoadingTick,
void(const char* pFunc, int line));
MOCK_METHOD0(RenderStatistics,
@@ -124,8 +118,6 @@ public:
IMovieSystem * ());
MOCK_METHOD0(GetIAudioSystem,
Audio::IAudioSystem * ());
- MOCK_METHOD0(GetI3DEngine,
- I3DEngine * ());
MOCK_METHOD0(GetIConsole,
::IConsole * ());
MOCK_METHOD0(GetIRemoteConsole,
diff --git a/Code/CryEngine/CryCommon/Mocks/StubTimer.h b/Code/CryEngine/CryCommon/Mocks/StubTimer.h
index fe3a11fb42..cd275ac17b 100644
--- a/Code/CryEngine/CryCommon/Mocks/StubTimer.h
+++ b/Code/CryEngine/CryCommon/Mocks/StubTimer.h
@@ -11,6 +11,8 @@
*/
#pragma once
+#include
+
//! Simple stub timer that exposes a single simple interface for setting the current time.
class StubTimer
: public ITimer
diff --git a/Code/CryEngine/CryCommon/RendElement.h b/Code/CryEngine/CryCommon/RendElement.h
index c3dc1c080d..41bcf2bf67 100644
--- a/Code/CryEngine/CryCommon/RendElement.h
+++ b/Code/CryEngine/CryCommon/RendElement.h
@@ -119,7 +119,7 @@ struct IRenderElement
virtual void mfCenter(Vec3& centr, CRenderObject* pObj) = 0;
virtual void mfGetBBox(Vec3& vMins, Vec3& vMaxs) = 0;
virtual void mfReset() = 0;
- virtual void mfGetPlane(Plane& pl) = 0;
+ virtual void mfGetPlane(Plane_tpl& pl) = 0;
virtual void mfExport(struct SShaderSerializeContext& SC) = 0;
virtual void mfImport(struct SShaderSerializeContext& SC, uint32& offset) = 0;
virtual void mfPrecache(const SShaderItem& SH) = 0;
@@ -265,7 +265,7 @@ public:
void mfPrecache([[maybe_unused]] const SShaderItem& SH) override {}
void mfExport([[maybe_unused]] struct SShaderSerializeContext& SC) override { CryFatalError("mfExport has not been implemented for this render element type"); }
void mfImport([[maybe_unused]] struct SShaderSerializeContext& SC, [[maybe_unused]] uint32& offset) override { CryFatalError("mfImport has not been implemented for this render element type"); }
- void mfGetPlane(Plane& pl) override;
+ void mfGetPlane(Plane_tpl& pl) override;
void* mfGetPointer([[maybe_unused]] ESrcPointer ePT, [[maybe_unused]] int* Stride, [[maybe_unused]] EParamType Type, [[maybe_unused]] ESrcPointer Dst, [[maybe_unused]] int Flags) override { return nullptr; }
uint16 mfGetFlags() override { return m_Flags; }
diff --git a/Code/CryEngine/CryCommon/WindowsUtils.h b/Code/CryEngine/CryCommon/WindowsUtils.h
deleted file mode 100644
index 96b3a86606..0000000000
--- a/Code/CryEngine/CryCommon/WindowsUtils.h
+++ /dev/null
@@ -1,215 +0,0 @@
-/*
-* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
-* its licensors.
-*
-* For complete copyright and license terms please see the LICENSE at the root of this
-* distribution (the "License"). All use of this software is governed by the License,
-* or, if provided, by the license below or the license accompanying this file. Do not
-* remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-*
-*/
-// Original file Copyright Crytek GMBH or its affiliates, used under license.
-
-#pragma once
-
-#if defined(WIN32)
-#include "CryWindows.h"
-#include "IRenderer.h"
-#include "IImage.h"
-#include "smartptr.h"
-#include "ImageExtensionHelper.h"
-
-// Types supported by CreateResourceFromTexture
-enum EResourceType
-{
- eResourceType_IconBig,
- eResourceType_IconSmall,
- eResourceType_Cursor,
-};
-
-// Loads a (DDS) texture resource from the renderer into a Win32 GDI resource.
-// Returns a HICON that must be closed with DestroyIcon(), or NULL on failure.
-static HICON CreateResourceFromTexture(IRenderer* pRenderer, const char* path, EResourceType type)
-{
- if (!pRenderer || !path || !*path)
- {
- // Invalid parameter passed
- return NULL;
- }
-
- // Find the target dimensions of the GDI resource
- const int nRequestedWidth = GetSystemMetrics(type == eResourceType_IconBig ? SM_CXICON : type == eResourceType_IconSmall ? SM_CXSMICON : SM_CXCURSOR);
- const int nRequestedHeight = GetSystemMetrics(type == eResourceType_IconBig ? SM_CYICON : type == eResourceType_IconSmall ? SM_CYSMICON : SM_CYCURSOR);
- if (nRequestedWidth != nRequestedHeight || nRequestedHeight <= 0 || nRequestedWidth <= 0)
- {
- // Don't support non-squares icons or cursors
- return NULL;
- }
-
- // Load texture.
- // in this case, we want to fall back on a null, not substiture the missing texture.
- _smart_ptr pImage = pRenderer->EF_LoadImage(path, FIM_NOFALLBACKS);
- if (!pImage || pImage->mfGet_depth() != 1 || pImage->mfGet_NumSides() != 1 || pImage->mfGetTileMode() != eTM_None)
- {
- // Can't load texture, or texture is a cube-map or volume texture, or uses tiling of some kind
- return NULL;
- }
- byte* pImgRaw = pImage->mfGet_image(0);
- const ETEX_Format texFormat = pImage->mfGetFormat();
-
- // Pick first mip level smaller than the GDI resource
- int nMip = 0;
- size_t offset = 0;
- int nMipWidth = pImage->mfGet_width();
- int nMipHeight = pImage->mfGet_height();
- while (nMipWidth > nRequestedWidth)
- {
- ++nMip;
- offset += pRenderer->GetTextureFormatDataSize(nMipWidth, nMipHeight, 1, 1, texFormat);
- nMipWidth = max(nMipWidth / 2, 1);
- nMipHeight = max(nMipHeight / 2, 1);
- }
- pImgRaw += offset;
- if (nMip >= pImage->mfGet_numMips())
- {
- // No appropriate mip in the texture
- // Note: Consider creating a full mip-chain on the texture so this can't happen
- return NULL;
- }
- const size_t nRawSize = pRenderer->GetTextureFormatDataSize(nMipWidth, nMipHeight, 1, 1, texFormat);
-
-#if 0
- // Check that DDS indexing is correct here
- offset += nRawSize;
- for (int nIdx = nMip + 1; nIdx < pImage->mfGet_numMips(); ++nIdx)
- {
- const int w = max(nMipWidth >> (nIdx - nMip), 1);
- const int h = max(nMipHeight >> (nIdx - nMip), 1);
- offset += pRenderer->GetTextureFormatDataSize(w, h, 1, 1, texFormat);
- }
- assert(offset == pImage->mfGet_ImageSize());
-#endif
-
- // Type of bitmap to create
- BITMAPV5HEADER bi = { 0 };
- bi.bV5Size = sizeof(BITMAPV5HEADER);
- bi.bV5Width = nRequestedWidth;
- bi.bV5Height = -nRequestedHeight;
- bi.bV5Planes = 1;
- bi.bV5BitCount = 32;
- bi.bV5Compression = BI_BITFIELDS;
- // The following mask specification specifies a supported 32 BPP alpha format for Windows XP+
- bi.bV5AlphaMask = 0xFF000000;
- bi.bV5RedMask = 0x00FF0000;
- bi.bV5GreenMask = 0x0000FF00;
- bi.bV5BlueMask = 0x000000FF;
-
- // Create the DIB section with an alpha channel
- const HDC hdc = GetDC(NULL);
- void* lpBits;
- const HBITMAP hBitmap = CreateDIBSection(hdc, (BITMAPINFO*)&bi, DIB_RGB_COLORS, &lpBits, NULL, 0);
- ReleaseDC(NULL, hdc);
- if (!hBitmap || !lpBits)
- {
- // Can't allocate OS bitmap
- return NULL;
- }
- GdiFlush();
-
- // Decompress texture
- const bool bTryDecompress = texFormat != eTF_R8G8B8A8 && texFormat != eTF_B8G8R8A8 && texFormat != eTF_B8G8R8X8;
- byte* const pImgDecomp = bTryDecompress ? new byte[nMipWidth * nMipHeight * sizeof(int32)] : pImgRaw;
- const bool bImgDecompressed = bTryDecompress && pRenderer->DXTDecompress(pImgRaw, nRawSize, pImgDecomp, nMipWidth, nMipHeight, 1, texFormat, false, sizeof(int32));
-
- // Check which conversions need to be performed
- const bool bSRGB = (pImage->mfGet_Flags() & CImageExtensionHelper::EIF_SRGBRead) != 0;
- const bool bSwap = (texFormat == eTF_R8G8B8A8) || bTryDecompress;
-
- HICON result = NULL;
- if (!bTryDecompress || bImgDecompressed)
- {
- // Assign texture data with mismatching sizes
- // Note: Any pixels not in the selected mip will become 100% transparent black, no resizing is performed
- const size_t sourceRowStride = nMipWidth;
- const size_t targetRowStride = nRequestedWidth;
- const uint32* pSourceRow = (uint32*)pImgDecomp;
- uint32* pTargetRow = (uint32*)lpBits;
-
- assert(sourceRowStride <= targetRowStride);
- assert(nMipHeight <= nRequestedHeight);
- assert(pSourceRow != pTargetRow);
- assert(pSourceRow && pTargetRow);
-
- uint8 gammaTable[256];
- if (!bSRGB)
- {
- // Linear to sRGB table
- const float gamma = 1.0f / 2.2f;
- const float gammaMultiplier = 255.0f / powf(255.0f, gamma);
- for (int i = 0; i < 256; ++i)
- {
- gammaTable[i] = uint8(powf(float(i), gamma) * gammaMultiplier);
- }
- }
- else if (bSwap)
- {
- // sRGB to sRGB table (no change)
- for (int i = 0; i < 256; ++i)
- {
- gammaTable[i] = uint8(i);
- }
- }
-
- for (int y = 0; y < nMipHeight; ++y, pSourceRow += sourceRowStride, pTargetRow += targetRowStride)
- {
- if (!bSwap && bSRGB)
- {
- memcpy(pTargetRow, pSourceRow, sourceRowStride * sizeof(uint32));
- }
- else
- {
- const uint32* pSourceTexel = pSourceRow;
- uint32* pTargetTexel = pTargetRow;
- for (int x = 0; x < nMipWidth; ++x, ++pSourceTexel, ++pTargetTexel)
- {
- const uint8 red = gammaTable[uint8(*pSourceTexel >> 0)];
- const uint8 green = gammaTable[uint8(*pSourceTexel >> 8)];
- const uint8 blue = gammaTable[uint8(*pSourceTexel >> 16)];
- const uint32 alpha = *pSourceTexel & 0xFF000000;
- *pTargetTexel = (red << (bSwap ? 16 : 0)) | (green << 8) | (blue << (bSwap ? 0 : 16)) | alpha;
- }
- }
-
- // Fill remaining columns with zeros
- memset(pTargetRow + sourceRowStride, 0, (targetRowStride - sourceRowStride) * sizeof(uint32));
- }
-
- // Fill remaining rows with zeros
- for (int y = nMipHeight; y < nRequestedHeight; ++y)
- {
- memset(pTargetRow, 0, targetRowStride * sizeof(uint32));
- pTargetRow += targetRowStride;
- }
-
- // Convert to GDI icon
- ICONINFO iconinfo = {0};
- iconinfo.fIcon = type == eResourceType_Cursor ? FALSE : TRUE;
- iconinfo.hbmMask = ::CreateBitmap(nRequestedWidth, nRequestedHeight, 1, 1, NULL);
- iconinfo.hbmColor = hBitmap;
- result = ::CreateIconIndirect(&iconinfo);
- DeleteObject(iconinfo.hbmMask);
- }
-
- // Clean up
- DeleteObject(hBitmap);
- if (bTryDecompress)
- {
- delete[] pImgDecomp;
- }
- pImage.reset();
-
- return result;
-}
-
-#endif
diff --git a/Code/CryEngine/CryCommon/crycommon_files.cmake b/Code/CryEngine/CryCommon/crycommon_files.cmake
index ef49370c08..7d169c2643 100644
--- a/Code/CryEngine/CryCommon/crycommon_files.cmake
+++ b/Code/CryEngine/CryCommon/crycommon_files.cmake
@@ -14,9 +14,6 @@ set(FILES
CryCommon.cpp
Allocator.h
FinalizingSpline.h
- Gem.h
- I3DEngine.h
- I3DEngine_info.h
IAudioInterfacesCommonData.h
IAudioSystem.h
IChunkFile.h
@@ -86,7 +83,6 @@ set(FILES
ITexture.h
IThreadManager.h
IThreadTask.h
- ITimeOfDay.h
ITimer.h
IValidator.h
IVideoRenderer.h
@@ -143,7 +139,6 @@ set(FILES
CryAssert.h
CryCrc32.h
CryCustomTypes.h
- CryEngineDecalInfo.h
CryFile.h
CryFixedArray.h
CryFixedString.h
@@ -292,7 +287,6 @@ set(FILES
platform_impl.cpp
Win32specific.h
Win64specific.h
- WindowsUtils.h
CryExtension/CryCreateClassInstance.h
CryExtension/CryGUID.h
CryExtension/CryTypeID.h
@@ -317,7 +311,6 @@ set(FILES
CryPool/STLWrapper.h
CryPool/ThreadSafe.h
stl/STLAlignedAlloc.h
- ILocalMemoryUsage.h
Serialization/Assert.h
Serialization/BitVector.h
Serialization/BitVectorImpl.h
diff --git a/Code/CryEngine/CryCommon/crycommon_testing_files.cmake b/Code/CryEngine/CryCommon/crycommon_testing_files.cmake
index ca133c2497..d20a33f791 100644
--- a/Code/CryEngine/CryCommon/crycommon_testing_files.cmake
+++ b/Code/CryEngine/CryCommon/crycommon_testing_files.cmake
@@ -10,7 +10,6 @@
#
set(FILES
- Mocks/I3DEngineMock.h
Mocks/IAudioSystemMock.h
Mocks/IConsoleMock.h
Mocks/ICryPakMock.h
diff --git a/Code/CryEngine/CryFont/CryFont.cpp b/Code/CryEngine/CryFont/CryFont.cpp
deleted file mode 100644
index ab39a0fa4d..0000000000
--- a/Code/CryEngine/CryFont/CryFont.cpp
+++ /dev/null
@@ -1,845 +0,0 @@
-/*
-* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
-* its licensors.
-*
-* For complete copyright and license terms please see the LICENSE at the root of this
-* distribution (the "License"). All use of this software is governed by the License,
-* or, if provided, by the license below or the license accompanying this file. Do not
-* remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-*
-*/
-// Original file Copyright Crytek GMBH or its affiliates, used under license.
-
-// Description : CCryFont class.
-
-
-#include "CryFont_precompiled.h"
-
-#if !defined(USE_NULLFONT_ALWAYS)
-
-#include "CryFont.h"
-#include "CryPath.h"
-#include "FFont.h"
-#include "FontTexture.h"
-#include "FontRenderer.h"
-#include "ILocalizationManager.h"
-
-#include
-#include
-
-// Static member definitions
-const Vec2i CCryFont::defaultGlyphSize = Vec2i(ICryFont::defaultGlyphSizeX, ICryFont::defaultGlyphSizeY);
-
-#if !defined(_RELEASE)
-static void DumpFontTexture(IConsoleCmdArgs* pArgs)
-{
- if (pArgs->GetArgCount() != 2)
- {
- return;
- }
-
- const char* pFontName = pArgs->GetArg(1);
-
- if (pFontName && *pFontName && *pFontName != '0')
- {
- string fontFile("@devroot@/");
- fontFile += pFontName;
- fontFile += ".bmp";
-
- CFFont* pFont = (CFFont*) gEnv->pCryFont->GetFont(pFontName);
- if (pFont)
- {
- pFont->GetFontTexture()->WriteToFile(fontFile.c_str());
- gEnv->pLog->LogWithType(IMiniLog::eInputResponse, "Dumped \"%s\" texture to \"%s\"!", pFontName, fontFile.c_str());
- }
- }
-}
-
-static void DumpFontNames([[maybe_unused]] IConsoleCmdArgs* pArgs)
-{
- string names = gEnv->pCryFont->GetLoadedFontNames();
- gEnv->pLog->LogWithType(IMiniLog::eInputResponse, "Currently loaded fonts: %s", names.c_str());
-}
-
-static void ReloadFonts([[maybe_unused]] IConsoleCmdArgs* pArgs)
-{
- gEnv->pCryFont->ReloadAllFonts();
-}
-#endif
-
-namespace
-{
- //! Stores paths to styled font assets for a given set of languages
- //! This struct stores the XML data contained within the tag of
- //! an enclosing definition:
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- struct FontTagXml
- {
- //! \return True if all font asset paths are non-empty, false otherwise
- bool IsValid() const
- {
- // Note that "lang" can be empty
- return !m_fontFilename.empty()
- && !m_boldFontFilename.empty()
- && !m_italicFontFilename.empty()
- && !m_boldItalicFontFilename.empty();
- }
-
- string m_lang; //!< Stores a comma-separated list of languages this collection of fonts applies to.
- //!< If this is an empty string, it implies that these set of fonts will be applied
- //!< by default (when a language is being used but no fonts in the font family are
- //!< mapped to that language).
-
- string m_fontFilename; //!< Font used when no styling is applied.
- string m_boldFontFilename; //!< Bold-styled font
- string m_italicFontFilename; //!< Italic-styled font
- string m_boldItalicFontFilename; //!< Bold-italic-styled font
- };
-
- //! Stores parsed font family XML data.
- //! This struct contains the name of the font family and a list of font
- //! file XML data for all the language-specific mappings of this
- //! font family.
- //!
- //! Example XML:
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- //!
- struct FontFamilyTagXml
- {
- //! Returns true if all font file fields were parsed, false otherwise.
- bool IsValid() const
- {
- for (const FontTagXml& fontTagXml : m_fontTagsXml)
- {
- if (!fontTagXml.IsValid())
- {
- return false;
- }
- }
-
- // Every font family must have a name
- return !m_fontFamilyName.empty();
- }
-
- string m_fontFamilyName; //!< Value of the "name" font-family tag attribute
- AZStd::list m_fontTagsXml; //!< List of child tag data.
- };
-
- //! Returns true if the XML tree was traversed successfully, false otherwise.
- //!
- //! Note that, if this function returns true, it simply means that there were
- //! no unexpected structure issues with the given XML tree, it doesn't
- //! necessarily mean that all the required fields were parsed.
- bool ParseFontFamilyXml(const XmlNodeRef& node, FontFamilyTagXml& xmlData)
- {
- if (!node)
- {
- return false;
- }
-
- //
- if (AZStd::string(node->getTag()) == "fontfamily")
- {
- const int numAttributes = node->getNumAttributes();
-
- if (numAttributes <= 0)
- {
- // Expecting at least one attribute
- return false;
- }
-
- string name;
-
- for (int i = 0, count = node->getNumAttributes(); i < count; ++i)
- {
- const char* key = "";
- const char* value = "";
- if (node->getAttributeByIndex(i, &key, &value))
- {
- if (string(key) == "name")
- {
- name = value;
- }
- else
- {
- // Unexpected font tag attribute
- return false;
- }
- }
- }
-
- name.Trim();
- if (!name.empty())
- {
- xmlData.m_fontFamilyName = name;
- }
- else
- {
- // Font family must have a name
- return false;
- }
- }
-
- //
- if (AZStd::string(node->getTag()) == "font")
- {
- xmlData.m_fontTagsXml.push_back(FontTagXml());
-
- string lang;
- for (int i = 0, count = node->getNumAttributes(); i < count; ++i)
- {
- const char* key = "";
- const char* value = "";
- if (node->getAttributeByIndex(i, &key, &value))
- {
- if (string(key) == "lang")
- {
- lang = value;
- }
- else
- {
- // Unexpected font tag attribute
- return false;
- }
- }
- }
-
- lang.Trim();
- if (!lang.empty())
- {
- xmlData.m_fontTagsXml.back().m_lang = lang;
- }
- }
-
- //
- else if (AZStd::string(node->getTag()) == "file")
- {
- const int numAttributes = node->getNumAttributes();
-
- if (numAttributes <= 0)
- {
- // Expecting at least one attribute
- return false;
- }
-
- string path;
- string tags;
-
- for (int i = 0, count = node->getNumAttributes(); i < count; ++i)
- {
- const char* key = "";
- const char* value = "";
- if (node->getAttributeByIndex(i, &key, &value))
- {
- if (string(key) == "path")
- {
- path = value;
- }
- else if (string(key) == "tags")
- {
- tags = value;
- }
- else
- {
- // Unexpected font tag attribute
- return false;
- }
- }
- }
-
- tags.Trim();
- if (tags.empty())
- {
- xmlData.m_fontTagsXml.back().m_fontFilename = path;
- }
- else if (tags == "b")
- {
- xmlData.m_fontTagsXml.back().m_boldFontFilename = path;
- }
- else if (tags == "i")
- {
- xmlData.m_fontTagsXml.back().m_italicFontFilename = path;
- }
- else
- {
- // We'll just assume any other tag indicates bold italic
- xmlData.m_fontTagsXml.back().m_boldItalicFontFilename = path;
- }
- }
-
- for (int i = 0, count = node->getChildCount(); i < count; ++i)
- {
- XmlNodeRef child = node->getChild(i);
- if (!ParseFontFamilyXml(child, xmlData))
- {
- return false;
- }
- }
-
- return true;
- }
-
- //! Only attempt XML file load if file exists.
- //! There are use-cases where the XML path is not fully known (such as
- //! when referencing font family names from font family XML files), and
- //! attempting to load the XML files directly via ISystem() methods can
- //! produce a lot of warning noise.
- XmlNodeRef SafeLoadXmlFromFile(const string& xmlPath)
- {
- if (gEnv->pCryPak->IsFileExist(xmlPath.c_str()))
- {
- return GetISystem()->LoadXmlFromFile(xmlPath.c_str());
- }
-
- return XmlNodeRef();
- }
-
-}
-
-CCryFont::CCryFont(ISystem* pSystem)
- : m_pSystem(pSystem)
- , m_fonts()
- , m_rndPropIsRGBA(false)
- , m_rndPropHalfTexelOffset(0.5f)
-{
- assert(m_pSystem);
-
- CryLogAlways("Using FreeType %d.%d.%d", FREETYPE_MAJOR, FREETYPE_MINOR, FREETYPE_PATCH);
-
- // Persist fonts for application lifetime to prevent unnecessary work
- REGISTER_CVAR(r_persistFontFamilies, r_persistFontFamilies, VF_NULL, "Persist loaded font families for lifetime of application.");
-
-#if !defined(_RELEASE)
- REGISTER_COMMAND("r_DumpFontTexture", DumpFontTexture, 0,
- "Dumps the specified font's texture to a bitmap file\n"
- "Use r_DumpFontTexture to get the loaded font names\n"
- "Usage: r_DumpFontTexture ");
- REGISTER_COMMAND("r_DumpFontNames", DumpFontNames, 0,
- "Logs a list of fonts currently loaded");
- REGISTER_COMMAND("r_ReloadFonts", ReloadFonts, VF_NULL,
- "Reload all fonts");
-#endif
-}
-
-CCryFont::~CCryFont()
-{
- // Persist fonts for application lifetime to prevent unnecessary work
- m_persistedFontFamilies.clear();
-
- for (FontMapItor it = m_fonts.begin(), itEnd = m_fonts.end(); it != itEnd; )
- {
- CFFont* pFont = it->second;
- ++it; // iterate as Release() below will remove font from the map
- SAFE_RELEASE(pFont);
- }
-}
-
-void CCryFont::Release()
-{
- delete this;
-}
-
-IFFont* CCryFont::NewFont(const char* pFontName)
-{
- string name = pFontName;
- name.MakeLower();
-
- FontMapItor it = m_fonts.find(CONST_TEMP_STRING(name.c_str()));
- if (it != m_fonts.end())
- {
- return it->second;
- }
-
- CFFont* pFont = new CFFont(m_pSystem, this, name.c_str());
- m_fonts.insert(FontMapItor::value_type(name, pFont));
- return pFont;
-}
-
-IFFont* CCryFont::GetFont(const char* pFontName) const
-{
- FontMapConstItor it = m_fonts.find(CONST_TEMP_STRING(string(pFontName).MakeLower()));
- return it != m_fonts.end() ? it->second : 0;
-}
-
-FontFamilyPtr CCryFont::LoadFontFamily(const char* pFontFamilyName)
-{
- FontFamilyPtr fontFamily(nullptr);
- string fontFamilyPath;
- string fontFamilyFullPath;
-
- XmlNodeRef root = LoadFontFamilyXml(pFontFamilyName, fontFamilyPath, fontFamilyFullPath);
-
- if (root)
- {
- FontFamilyTagXml xmlData;
- const bool parseSuccess = ParseFontFamilyXml(root, xmlData);
- if (parseSuccess && xmlData.IsValid())
- {
- const char* currentLanguage = gEnv->pSystem->GetLocalizationManager()->GetLanguage();
- FontTagXml* defaultFont = nullptr;
- FontTagXml* langSpecificFont = nullptr;
-
- // Note that we don't break out of this for-loop early because we
- // want to find both the default font family and the
- // language-specific font family. We prefer the lang-specific
- // family but will fall back on the default if it doesn't exist.
- for (FontTagXml& fontTagXml : xmlData.m_fontTagsXml)
- {
- if (fontTagXml.m_lang.empty())
- {
- defaultFont = &fontTagXml;
- }
- else
- {
- int searchPos = 0;
- string langToken;
-
- // "lang" font-tag attribute could be comma-separated
- while (!(langToken = fontTagXml.m_lang.Tokenize(",", searchPos)).empty())
- {
- if (langToken.Trim() == currentLanguage)
- {
- langSpecificFont = &fontTagXml;
- break;
- }
- }
- }
- }
-
- if (langSpecificFont || defaultFont)
- {
- // Prefer lang-specific font-family over default, if it exists
- FontTagXml* fontTagXml = langSpecificFont ? langSpecificFont : defaultFont;
-
- // Pre-pend font family's path to make font family XML paths
- // relative to font family file
- fontTagXml->m_fontFilename = fontFamilyPath + fontTagXml->m_fontFilename;
- fontTagXml->m_boldFontFilename = fontFamilyPath + fontTagXml->m_boldFontFilename;
- fontTagXml->m_italicFontFilename = fontFamilyPath + fontTagXml->m_italicFontFilename;
- fontTagXml->m_boldItalicFontFilename = fontFamilyPath + fontTagXml->m_boldItalicFontFilename;
-
- IFFont* normal = LoadFont(fontTagXml->m_fontFilename.c_str());
- IFFont* bold = LoadFont(fontTagXml->m_boldFontFilename.c_str());
- IFFont* italic = LoadFont(fontTagXml->m_italicFontFilename.c_str());
- IFFont* boldItalic = LoadFont(fontTagXml->m_boldItalicFontFilename.c_str());
-
- // Only continue if all fonts were created successfully
- if (normal && bold && italic && boldItalic)
- {
- fontFamily.reset(new FontFamily(),
- [this](FontFamily* pFontFamily)
- {
- ReleaseFontFamily(pFontFamily);
- });
-
- // Map the font family name both by path and by name defined
- // within the Font Family XML itself. This allows font
- // families to also be referenced simply by name.
- if (!AddFontFamilyToMaps(fontFamilyFullPath, xmlData.m_fontFamilyName, fontFamily))
- {
- SAFE_RELEASE(normal);
- SAFE_RELEASE(bold);
- SAFE_RELEASE(italic);
- SAFE_RELEASE(boldItalic);
-
- return nullptr;
- }
-
- fontFamily->familyName = xmlData.m_fontFamilyName;
- fontFamily->normal = normal;
- fontFamily->bold = bold;
- fontFamily->italic = italic;
- fontFamily->boldItalic = boldItalic;
- }
- else
- {
- SAFE_RELEASE(normal);
- SAFE_RELEASE(bold);
- SAFE_RELEASE(italic);
- SAFE_RELEASE(boldItalic);
- }
- }
- }
- }
-
- if (!fontFamily)
- {
- // Unable to load font family XML, so load font normally and associate
- // it with a font family
- IFFont* pFont = LoadFont(pFontFamilyName);
-
- if (pFont)
- {
- // Create a font family from a single font by assigning all the
- // font family stylings to the same font
- fontFamily.reset(new FontFamily(),
- [this](FontFamily* pFontFamily)
- {
- ReleaseFontFamily(pFontFamily);
- });
-
- // Use filepath as familyName so font loading/unloading doesn't break with duplicate file names
- fontFamily->familyName = pFontFamilyName;
-
- if (!AddFontFamilyToMaps(pFontFamilyName, fontFamily->familyName, fontFamily))
- {
- SAFE_RELEASE(pFont);
-
- return nullptr;
- }
-
- // Assign all stylings to the same font
- fontFamily->normal = pFont;
- fontFamily->bold = pFont;
- fontFamily->italic = pFont;
- fontFamily->boldItalic = pFont;
-
- // The other three stylings need to have their ref count
- // incremented (even though in this particular case its all the
- // same font) because when ReleaseFontFamily executes all fonts
- // in the family will be (corresondingly) Release'd.
- fontFamily->bold->AddRef();
- fontFamily->italic->AddRef();
- fontFamily->boldItalic->AddRef();
- }
- }
-
- // Persist fonts for application lifetime to prevent unnecessary work
- if (r_persistFontFamilies > 0)
- {
- m_persistedFontFamilies.emplace_back(FontFamilyPtr(fontFamily));
- }
-
- return fontFamily;
-}
-
-FontFamilyPtr CCryFont::GetFontFamily(const char* pFontFamilyName)
-{
- FontFamilyPtr fontFamily = nullptr;
-
- // The given string could either be: a font family name (defined in font
- // family XML), a file path (for regular fonts mapped as font families),
- // or just the filename of a font itself. Fonts are mapped by font family
- // name or by filepath, so attempt lookup using the map first since it's
- // the fastest.
- string loweredName = string(pFontFamilyName).Trim().MakeLower();
- auto it = m_fontFamilies.find(PathUtil::MakeGamePath(loweredName).c_str());
- if (it != m_fontFamilies.end())
- {
- fontFamily = FontFamilyPtr(it->second);
- }
- else
- {
- // Iterate through all fonts, returning the first match where simply
- // the filename of a font could be a match. This case will likely be
- // hit when text markup references a font that doesn't belong to a
- // font family.
- for (const auto& fontFamilyIter : m_fontFamilies)
- {
- const AZStd::string& mappedFontFamilyName = fontFamilyIter.first;
- string mappedFilenameNoExtension = PathUtil::GetFileName(mappedFontFamilyName.c_str());
-
- string searchStringFilenameNoExtension = PathUtil::GetFileName(loweredName);
-
- if (mappedFilenameNoExtension == searchStringFilenameNoExtension)
- {
- fontFamily = FontFamilyPtr(fontFamilyIter.second);
- break;
- }
- }
- }
-
- return fontFamily;
-}
-
-void CCryFont::AddCharsToFontTextures(FontFamilyPtr pFontFamily, const char* pChars, int glyphSizeX, int glyphSizeY)
-{
- pFontFamily->normal->AddCharsToFontTexture(pChars, glyphSizeX, glyphSizeY);
- pFontFamily->bold->AddCharsToFontTexture(pChars, glyphSizeX, glyphSizeY);
- pFontFamily->italic->AddCharsToFontTexture(pChars, glyphSizeX, glyphSizeY);
- pFontFamily->boldItalic->AddCharsToFontTexture(pChars, glyphSizeX, glyphSizeY);
-}
-
-void CCryFont::SetRendererProperties(IRenderer* pRenderer)
-{
- if (pRenderer)
- {
- m_rndPropIsRGBA = (pRenderer->GetFeatures() & RFT_RGBA) != 0;
- m_rndPropHalfTexelOffset = 0.0f;
- }
-}
-
-void CCryFont::GetMemoryUsage(ICrySizer* pSizer) const
-{
- if (!pSizer->Add(*this))
- {
- return;
- }
-
- pSizer->AddObject(m_fonts);
-}
-
-string CCryFont::GetLoadedFontNames() const
-{
- string ret;
- for (FontMapConstItor it = m_fonts.begin(), itEnd = m_fonts.end(); it != itEnd; ++it)
- {
- CFFont* pFont = it->second;
- if (pFont)
- {
- if (!ret.empty())
- {
- ret += ",";
- }
- ret += pFont->GetName();
- }
- }
- return ret;
-}
-
-void CCryFont::OnLanguageChanged()
-{
- ReloadAllFonts();
-
- EBUS_EVENT(LanguageChangeNotificationBus, LanguageChanged);
-}
-
-void CCryFont::ReloadAllFonts()
-{
- // Persist fonts for application lifetime to prevent unnecessary work
- m_persistedFontFamilies.clear();
-
- AZStd::list fontFamilyFilenames;
- AZStd::list fontFamilyWeakPtrs;
-
- // Iterate through all currently loaded font families
- for (auto it : m_fontFamilyReverseLookup)
- {
- fontFamilyWeakPtrs.push_back(it.first);
- fontFamilyFilenames.push_back(it.second->first);
- }
-
- // Release font-family resources and unmap them
- for (auto fontFamily : fontFamilyWeakPtrs)
- {
- ReleaseFontFamily(fontFamily);
- }
-
- // Reload the font families
- for (auto familyFilename : fontFamilyFilenames)
- {
- LoadFontFamily(familyFilename.c_str());
- }
-
- // All UI text components need to reload their font assets (both in-game
- // and in-editor).
- EBUS_EVENT(FontNotificationBus, OnFontsReloaded);
-}
-
-void CCryFont::UnregisterFont(const char* pFontName)
-{
- FontMapItor it = m_fonts.find(CONST_TEMP_STRING(pFontName));
-
-#if defined(AZ_ENABLE_TRACING)
- IFFont* fontPtr = it->second;
-#endif
-
- if (it != m_fonts.end())
- {
- m_fonts.erase(it);
- }
-
-#if defined(AZ_ENABLE_TRACING)
- // Make sure the font being released isn't currently in use by a font family.
- // If it is, the FontFamily will have a dangling pointer and will cause a
- // crash when the FontFamily eventually gets released.
- for (auto reverseMapEntry : m_fontFamilyReverseLookup)
- {
- FontFamily* fontFamily = reverseMapEntry.first;
- AZ_Assert(fontFamily->normal != fontPtr,
- "The following font is being freed but still in use by a FontFamily: %s",
- pFontName);
- AZ_Assert(fontFamily->italic != fontPtr,
- "The following font is being freed but still in use by a FontFamily: %s",
- pFontName);
- AZ_Assert(fontFamily->bold != fontPtr,
- "The following font is being freed but still in use by a FontFamily: %s",
- pFontName);
- AZ_Assert(fontFamily->boldItalic != fontPtr,
- "The following font is being freed but still in use by a FontFamily: %s",
- pFontName);
- }
-#endif
-}
-
-IFFont* CCryFont::LoadFont(const char* pFontName)
-{
- string fontName = pFontName;
- fontName.MakeLower();
-
- IFFont* font = GetFont(fontName);
- if (font)
- {
- font->AddRef(); // use existing loaded font
- }
- else
- {
- // attempt to create and load a new font, use the font pathname as the font name
- font = NewFont(fontName);
- if (!font)
- {
- string errorMsg = "Error creating a new font named ";
- errorMsg += fontName;
- errorMsg += ".";
- CryWarning(VALIDATOR_MODULE_SYSTEM, VALIDATOR_ERROR, errorMsg.c_str());
- }
- else
- {
- // creating font adds one to its refcount so no need for AddRef here
- if (!font->Load(fontName))
- {
- string errorMsg = "Error loading a font from ";
- errorMsg += fontName;
- errorMsg += ".";
- CryWarning(VALIDATOR_MODULE_SYSTEM, VALIDATOR_ERROR, errorMsg);
- font->Release();
- font = nullptr;
- }
- }
- }
-
- return font;
-}
-
-void CCryFont::ReleaseFontFamily(FontFamily* pFontFamily)
-{
- // Ensure that Font Family was mapped prior to destruction
- const bool isMapped = m_fontFamilyReverseLookup.find(pFontFamily) != m_fontFamilyReverseLookup.end();
- if (!isMapped)
- {
- return;
- }
-
- // Note that the FontFamily is mapped both by filename and by "family name"
- auto it = m_fontFamilyReverseLookup[pFontFamily];
- m_fontFamilies.erase(it);
- string familyName(pFontFamily->familyName);
- m_fontFamilies.erase(familyName.MakeLower().c_str());
-
- // Reverse lookup is used to avoid needing to store filename path with
- // the font family, so we need to remove that entry also.
- m_fontFamilyReverseLookup.erase(pFontFamily);
-
- SAFE_RELEASE(pFontFamily->normal);
- SAFE_RELEASE(pFontFamily->bold);
- SAFE_RELEASE(pFontFamily->italic);
- SAFE_RELEASE(pFontFamily->boldItalic);
-}
-
-bool CCryFont::AddFontFamilyToMaps(const char* pFontFamilyFilename, const char* pFontFamilyName, FontFamilyPtr fontFamily)
-{
- if (!pFontFamilyFilename || !pFontFamilyName || !fontFamily.get())
- {
- return false;
- }
-
- // We don't support "updating" mapped values.
- AZStd::string loweredFilename(PathUtil::MakeGamePath(string(pFontFamilyFilename)).c_str());
- AZStd::to_lower(loweredFilename.begin(), loweredFilename.end());
- if (m_fontFamilies.find(loweredFilename) != m_fontFamilies.end())
- {
- string warnMsg;
- warnMsg.Format("Couldn't load Font Family '%s': already loaded", pFontFamilyFilename);
- CryWarning(VALIDATOR_MODULE_SYSTEM, VALIDATOR_WARNING, warnMsg.c_str());
- return false;
- }
-
- // Similarly, we don't support Font Family XMLs that have the same font
- // family name (we assume all Font Family names are unique).
- AZStd::string loweredFontFamilyName(pFontFamilyName);
- AZStd::to_lower(loweredFontFamilyName.begin(), loweredFontFamilyName.end());
- if (m_fontFamilies.find(loweredFontFamilyName) != m_fontFamilies.end())
- {
- string warnMsg;
- warnMsg.Format("Couldn't load Font Family '%s': already loaded", pFontFamilyName);
- CryWarning(VALIDATOR_MODULE_SYSTEM, VALIDATOR_WARNING, warnMsg.c_str());
- return false;
- }
-
- // First, insert by filename
- AZStd::pair> insertPair(loweredFilename, fontFamily);
- auto iterPosition = m_fontFamilies.insert(insertPair).first;
- m_fontFamilyReverseLookup[fontFamily.get()] = iterPosition;
-
- // Then, by Font Family name
- AZStd::pair> nameInsertPair(loweredFontFamilyName, fontFamily);
- m_fontFamilies.insert(nameInsertPair);
-
- return true;
-}
-
-XmlNodeRef CCryFont::LoadFontFamilyXml(const char* pFontFamilyName, string& outputDirectory, string& outputFullPath)
-{
- outputFullPath = pFontFamilyName;
- outputDirectory = PathUtil::GetPath(pFontFamilyName);
- XmlNodeRef root = SafeLoadXmlFromFile(outputFullPath);
-
- // When parsing a tag in markup, only the font name is given and
- // not a path, so we try to build a "best guess" path from the name.
- if (!root)
- {
- string fileNoExtension(PathUtil::GetFileName(pFontFamilyName));
- string fileExtension(PathUtil::GetExt(pFontFamilyName));
-
- if (fileExtension.empty())
- {
- fileExtension = ".fontfamily";
- }
-
- // Try: "fonts/fontName.fontfamily"
- outputDirectory = string("fonts/");
- outputFullPath = outputDirectory + fileNoExtension + fileExtension;
- root = SafeLoadXmlFromFile(outputFullPath);
-
- // Finally, try: "fonts/fontName/fontName.fontfamily"
- if (!root)
- {
- outputDirectory = string("fonts/") + fileNoExtension + "/";
- outputFullPath = outputDirectory + fileNoExtension + fileExtension;
- root = SafeLoadXmlFromFile(outputFullPath);
- }
- }
-
- return root;
-}
-
-#endif
-
diff --git a/Code/CryEngine/CryFont/CryFont.def b/Code/CryEngine/CryFont/CryFont.def
deleted file mode 100644
index 43bfe0b13d..0000000000
--- a/Code/CryEngine/CryFont/CryFont.def
+++ /dev/null
@@ -1,3 +0,0 @@
-EXPORTS
- ModuleInitISystem @2
- CryModuleGetMemoryInfo @8
diff --git a/Code/CryEngine/CryFont/CryFont.h b/Code/CryEngine/CryFont/CryFont.h
deleted file mode 100644
index 726818f5a7..0000000000
--- a/Code/CryEngine/CryFont/CryFont.h
+++ /dev/null
@@ -1,108 +0,0 @@
-/*
-* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
-* its licensors.
-*
-* For complete copyright and license terms please see the LICENSE at the root of this
-* distribution (the "License"). All use of this software is governed by the License,
-* or, if provided, by the license below or the license accompanying this file. Do not
-* remove or modify any license notices. This file is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-*
-*/
-// Original file Copyright Crytek GMBH or its affiliates, used under license.
-
-#ifndef CRYINCLUDE_CRYFONT_CRYFONT_H
-#define CRYINCLUDE_CRYFONT_CRYFONT_H
-#pragma once
-
-
-#if !defined(USE_NULLFONT_ALWAYS)
-
-#include
-#include
-#include
-#include