Commit Graph

90 Commits (a2d86a9fa495ed08435bb0393aaf5fae188b68df)

Author SHA1 Message Date
Chris Burel ca297fdf38 Remove unused variables
Signed-off-by: Chris Burel <burelc@amazon.com>
4 years ago
Steve Pham 4d4f10beb8
Clang/GCC compiler settings update [SECURITY] (#7358)
- Add the following compilation flags for clang
  -fpie
  -fstack-protector-all
  -fstack-check (non-release)

- Add the following compilation flags for gcc
  -fpie
  -fstack-protector-all

- Fix -Wunused-result errors from above compilation flag updates

- Add _FORTIFY_SOURCE=2 to GCC DEFINES

Signed-off-by: Steve Pham <82231385+spham-amzn@users.noreply.github.com>
4 years ago
Chris Galvan 8151856e83 Removed legacy Editor config spec
Signed-off-by: Chris Galvan <chgalvan@amazon.com>
4 years ago
Esteban Papp 6fad254b59 Merge branch 'development' into optimization/unused_files
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>

# Conflicts:
#	Code/Editor/IEditorImpl.cpp
#	Code/Editor/IEditorImpl.h
#	Gems/LmbrCentral/Code/Tests/lmbrcentral_editor_tests_files.cmake
4 years ago
John Jones-Steele d346d45848
File menu open level and save level as dialogs not properly recognized as modals #6605 (#7072)
* WIP

Signed-off-by: John Jones-Steele <82226755+jjjoness@users.noreply.github.com>

* Fixes to ModalWindowDismisser

Signed-off-by: John Jones-Steele <82226755+jjjoness@users.noreply.github.com>

* Redisables Import test as fails on Jenkins

Signed-off-by: John Jones-Steele <82226755+jjjoness@users.noreply.github.com>

* Redisables Import test and Edit Platform as fails on Jenkins

Signed-off-by: John Jones-Steele <82226755+jjjoness@users.noreply.github.com>

* Replace skip in TestSuite_Main.py

Signed-off-by: John Jones-Steele <82226755+jjjoness@users.noreply.github.com>
4 years ago
Esteban Papp 4d62351628 Fixes for Linux no unity builds
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp fd4014b278 PR comments
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp c13ceea767 Some fixes for Windows non-unity builds
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp c00d3105c6 Removes some CryAssert methods that are not being used because we redirected it all to AZ_Assert
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp 03543a9e8e Removes ColorUtils from Code/Editor
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp fba00b0b2b Removes ComponentPalette/CategoriesList and ComponentPalette/ComponentDataModel from Code/Editor/Plugins/ComponentEntityEditorPlugin
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp 3d1b30deda Removes Triangulate from Code/Editor
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp 46cc160d8c Removes smartptr and TRefCountBase from Code/Editor
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp 53f7594ab6 Removes ImageBT from Code/Editor
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp 796780af11 Removes ImageASC from Code/Editor
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp 821c352e6a Removes GdiUtil and cleanups GuidUtil from Code/Editor
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp 63aaa0cba4 Removes DynamicArray2D from Code/Editor
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp 0d94e5cb0d Removes bitarray.h from Code/Editor
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp 9107af5af7 Removes IObservable/Observable from Code/Editor
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp 6b7b8c45a7 Removes UIEnumerations from Code/Editor
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp 43b35add36 Removes ImagePainter and some Terrain leftovers from Code/Editor
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Chris Galvan 3f0bd92853 Removed some unused EditorUtils functions
Signed-off-by: Chris Galvan <chgalvan@amazon.com>
4 years ago
Chris Galvan 233349ffe3 Removed unused Editor code from EditMode/Geometry/Include/LightmapCompiler
Signed-off-by: Chris Galvan <chgalvan@amazon.com>
4 years ago
Jeremy Ong a96387ee35 Fix compile issues blocking adoption of Pix 2108
Signed-off-by: Jeremy Ong <jcong@amazon.com>
4 years ago
godpiao d3c50419a0
optimization ReverseUpAndDown function (#5972)
change CImageEx:: ReverseUpDown function to avoid new uint32(width*height).

Signed-off-by: godpiao <godpiao@qq.com>
4 years ago
Artur K 56904d1799
Cry Legacy: the Lessening (#5961)
* Generic Cleanup

Removals:

* Unused cvars,member variables and defines
* Windows media center edition support routines
* CSystem - removed debug_GetCallStackRaw/GetRootWindowMessageHandler/
UnloadDLL/ShutdownModuleLibraries

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Fix CryMessageBox return values in Windows build

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Remove named selection group and a few smaller unused functionalities

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Remove ObjectManager export functionality + 2 deprecated functions

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Remove object legacy freeze/hide support from ObjectManager

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Remove ObjectManager duplicate name dection, as well as object renaming

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Remove ObjectManager serialization and selection callbacks

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* ObjectManager - remove MoveObjects/HitTestObject/EndEditParams and related members/functions

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Remove a bunch of unused clone related functionality + misc

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* ObjectManager - misc removals

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* ObjectManager - more removals

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Remove unused object selection/retrieval in ObjectManager and LoadObjects in ObjectLoader

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* CBaseObject - remove unused material layers mask support

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* More CBaseObject cleanups.

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* CBaseObject - remove SubObj functions and IMouseCreateCallback

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Remove unused procedural floor management, helper scale and tags.

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* CBaseObject - remove more unused methods.

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Removals in multiple places.

CBaseObject - unused `OBJTYPE_DUMMY` flag removed, member `IsSameClass`
CObjectArchive removed unused methods/members
CObjectManager removed unused `Update` method

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* More removals

IDisplayViewport - HitTestLine/GetGridStep/setHitcontext/
GetConstructionPlane
Unused Cry_Matrix44 template specializations.

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* O3DE.exe Project-Centric "Open Editor" fix (#5852)

* The O3DE.exe Open Editor button now attempts to open the Editor in the
build directory of the project being opened.

If their is no Editor within the build directory of the Project, it uses
the Editor.exe in the current O3DE.exe executable directory if it exists

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Engine .gitignore now ignores the build directory if placed in the
AutomatedTesting project

Previously it was just ignoring a `[Bb]uild` directory if it was
directly within the engine root.
This change matches the behavior of the project templates.

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Renamed the ProjectUtils GetEditorDirectory function to
GetEditorExecutablePath

Added a platform specific implementation for retrieving the path to the
Editor executable in the GetEditorExectuablePath function.

It first attempts to locate the Editor via checking the project build
directory for an Editor executable before falling back to checking the
binary directory of the currently running O3DE executable.

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Correct the MacOS GetEditorExecutablePath to return the Editor path

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>
Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Adding missing C++20 std::erase implementations (#5735)

There were already implementations for std::erase_if.
This adds the counterpart AZStd::erase versions

resolves #5734

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>
Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* More removals and refactors

`ShowMessage` and `CryMessageBox` return void now
Simplify code in `CSystem::WarningV`
Remove unused `CryGetTicksPerSec`
Remove unused WinBase functionality
Replace `nanosleep` call in WinBase with `std::this_thread::sleep_for`
Remove unused Win32Wrapper routines
Remove unused IFunctorBase.h and IEntityObjectListener.h
Fix VectorAndArray.cpp compilation
Use QMessageBox instead of CryMessageBox in the editor.
Remove empty ArchiveVars platform specific files

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Fix test code.

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Remove an unused  function

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* CBaseObject and undo description removals.

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* A bunch of removals

* Remove IRenderNode
* Remove editor's KDTree
* Remove StatObjBus, InstanceStatObjEventBus::ReleaseData is redundant (
same functionality in the only available handler is triggered by
`OnCryEditorCloseScene`)
* Remove CExportManager::AddStatObj/AddMeshes/AddMesh,
IExportManager::ExportSingleStatObj
* Remove CIconManager/IIconManager::GetObject
* Remove CBaseObject::IntersectRayMesh
* Remove IIndexedMesh and related structs.
* Unused IUndoObject::GetDescription and all derived implementations.
* Unused CUndoBaseLibrary/CUndoBaseLibraryManager
* Unused Matrix34_tpl typedefs
* Legacy Xml classes cleanup

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Remove unused `Vec3ToVector3D` helper

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* fix - remove unused static variable

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

Co-authored-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>
4 years ago
Artur K eca2e36687
Fix clang 13 compilation problems (#5791)
* Fix clang 13 compilation problems

Re-instated ShowPlayedSequencesDebug logic by introducing no-op lambda
which replaces missing `Draw2dLabel` functionality ( added TODO marker
there )

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* apply review suggestions

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Fix type in assert message

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>
4 years ago
AMZN-stankowi 6e70097ad7
Fixed all errors with default seeds (#5489)
* Cleaning up errors with default assets, used in bundled release builds

Signed-off-by: AMZN-stankowi <4838196+AMZN-stankowi@users.noreply.github.com>

* Updated simple asset references to be to the product, not source assets

Signed-off-by: AMZN-stankowi <4838196+AMZN-stankowi@users.noreply.github.com>
4 years ago
lumberyard-employee-dm 5fc4551ac0
[LYN-8041] Enable relocation of the Project Game Release Layout (#5380)
* Enable relocation of the Project Game Release Layout

Relocating the Project Game Release Layout to another directory on the file system failed due to the querying of the engine root failing due to the ComponentApplication::m_engineRoot not using the project path stored in the SettingsRegisry if the engine root cannot be detected

Removed the ApplicationRequestBus GetEngineRoot function.
The ComponentApplicationRequestBus has a function of the same name that returns the same path.

Removed the deprecated GetAppRoot function.
The path it returns has no defined value. It was not the engine root or the project root.
Removed unused CFileUtil and CFileUtil_impl functions that were invoking the ApplicationREquestBus GetEngineRoot function.
On the way to update the functions it was discovered that they aren't called

Added a CalculateBranchToken overload that can populate a fixed_string to avoid heap allocations

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Protect against an empty list of artifacts to remove when generating the
engine.pak

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>
4 years ago
Steve Pham 16a7b896ee
Fix to prevent using legacy windows based logic to create a Path on Linx (#4704)
Signed-off-by: Steve Pham <spham@amazon.com>
4 years ago
Steve Pham 70636572ff
Fix casing of editor_xml filenames to match casing in .ly files (#4640)
Signed-off-by: Steve Pham <spham@amazon.com>
4 years ago
lumberyard-employee-dm f648cb1fd8
Update the FileIO Aliases (#4186)
* Update the FileIOAlias naming to make the cache, project root and engine
root paths more clear

The alias of `@root@`, `@assets@`, and `@projectplatformcache@` has been
collapsed to `@projectproductassets@`

The alias of `@devroot@` and `@engroot@` has been collapsed to
`@engroot@`

The alias of `@devassets@` and `@projectroot@` has been collapsed to
`@projectroot@`

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Updated use of devassets and devroot properties in python

Those properties now use projectroot and engroot

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Updating the alias @engroot@ alias path comment in each platform specific LocalFileIO_*.cpp file

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Removed hardcoded size of 9 for the product asset alias.

The ResolvePath function now just appends the @projectproductassets@
alias with the input path

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Remove duplicate @projectproductassets@ check in ProcessFileTreeRequest

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Fix for typos in Hydra python test

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Updated LocalFileIO::Copy call on Windows to use the Unicode aware CopyFileW API

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Updated the AWSMetreicsGemAllocatorFixture to properly suppress asset
cache write errors for Test file creation.

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Removed unneeded call to set the @projectproductasstes@ alias at the bottom of the AssetSeedManagerTest SetUp

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Added a deprecated alias map to the FileIO System

When a deprecated alias is accessed, the FileIO System logs an AZ_Error and indicates the alias that should be used

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Updated python test scripts to use the projectroot binding

Retrieving the AutomatedTesting project path based on "<devroot>/AutomatedTesting" has been removed.

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Updated references to devroot and devgame within the codebase

The GetAbsoluteDevGameFolderPath functions has been replaced with direct call to AZ::Utils::GetProjectPath
The GetAbsoluteDevRootFolderPath functions has been replaced with direct calls to AZ::Utils::GetEnginePath

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Updated <engroot>/AutomatedTesting references to projectroot


Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Replaced references that assumes the project path is <engroot>/AutomatedTesting with <projectroot> in the AutomatedTesting python test

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Correct casing in emfxworkspace file


Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Removed newly added AppendPathParts function
Removed the Path constructors which accepts a PathIterable instance

The PathIterable isn't safe to return to a user of the Path class as it might be referencing temporary paths supplied via PathView arguments

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Fixed unused parameter warning

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Undid change to the LexicallyProximate function to set the path result to the base path.

It needs to return the *this path if the pathResult is empty

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Moved the LocalFileIO ConvertToAbsolutePath implementations to AZ::Utils

Fixed the ConvertToAbsolutePath implementation for Unix platforms to use a buffer that is size PATH_MAX(4096 on all our supported Unix platforms).
Because the buffer before was AZ::IO::MaxPathLength which as a size of 1024, this was resulting in the Unix `realpath` function smashing the stack when it converts a path to an absolute path that is longer than 1024 characters

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Updated the EditorCore.Tests to attach the AZ Environment to the EditorCore shared library that is statically loaded on launch.

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Fixed for DeprecatedAlaisesKeyVisitor Visit function causing the non string_view overloads being hidden causing a hidden base class function warning

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Changed the AWSMetricsGemMock to use a temporary for writing test assets

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Updated the LocalFileIO::ResolvePath function to use HasRootPath to determine if a path starts with a root path such as "D:", "D:/" or "/"

IsAbsolute was not the corect check as the path of "D:" is a relative
path.
To be absolute according to the Windows the path must have a root
directory. i.e "D:/" or "D:\"

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Removed absolute path comment from LocalFile_UnixLike.cpp and LocalFile_Android.cpp FindFiles implementations
Updated the ConvertToAlias to supply an AZ::IO::FixedMaxPath

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Replaced usage of the @projectproductassets@ alias with @engroot@ when referring to the LmbrCentral source folder in the CopyDependencyBuilderTest and the SeedBuilderTests

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Updated the ScriptCanvas Upgrade Tool to output backed up files to the
Project User Path instead of the engine root

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Fixed whitespacing issues in Application.cpp

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Remove unnecessary creation of a FixedMaxPath in the UpgradeTool.cpp

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Modified testSeedFolder variable in the SeedBuilderTests to use the
@engroot@ alias instead of @projectproductassets@/.. alias when
referring to the LmbrCentral Gem source path

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Updated references to the Project Asset Cache in the PythonTests.

Those tests no longer use the logic `azlmbr.paths.projectroot / "Cache" / "pc"` to retrieve a path to the cache root but instead the `azlmbr.paths.projectproductassets` constant

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Fixed the FileIO Deprecated Alias test on Windows

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Removing @projectsourceassets@ alias, as it is only used once.

Updated the PhysX EditorSystemComponent.cpp to query the ProjectPath
form the SettingsRegistry.

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Replaced @projectproductassets@ alias with @products@

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Rollback changes to the PhysX EditorSystemComponent.cpp

The changes to use the ProjectPath from the SettingsRegistry has been implemented in PR #4497

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>
4 years ago
lumberyard-employee-dm 58c227ceb1
Implemented C++23 deleted nullptr_t constructor/assignment for AZStd string classes (#4158)
* Added string and string_view class constructor overloads which is deleted that prevents initializing them from a nullptr or an integer type

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Fixed locations where string and string_view were initialized with
nullptr

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Fix IArchive::IsInstalledToHDD signature

Updated calls to ConvertAbsolutePathToAliasedPath to use an
list initialization instead of nullptr

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>
4 years ago
lumberyard-employee-dm 447832dd81
Updated the GameApplication to mount the engine.pak (#4128)
* Updated the GameApplication to mount the engine.pak

This allows loading the autoexec.cfg and bootstrap.game.<config>.<platform>.setreg from the engine.pak files
The engine.pak is searched for in the following order: <ExecutableDirectory>/engine.pak, followed by <ProjectCacheRoot>/engine.pak

Removed a lot of unused APIs from the AZ::IO::Archive feature suite
Updated many of the AZ::IO::Archive classes to use AZ::IO::Path internally.
The logic to search for files within an Archive has been updated to use AZ::IO::Path and to remove case-insensitve string comparisons
Somehow removed the CryFile dependency on anything Cry

Updated the Settings Registry to support reading from the FileIOBase and therefore Archive files in the GameLauncher via the `SetUseFileIO` function

Removed AzFramework Dependency on md5 3rdParty library

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Linux build fix

Added an include of <stdio.h> before the <rapidxml/rapidxml.h> include as it usesnprintf.

Added `static` to the constexpr constants in ExtractFileDescription in SettingsRegistryImpl.cpp to fix clang compile issue

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Updated the case used to mount the Engine PAK file in the GameApplication to be Engine.pak to match the other locations where it is mounted

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Updated the proper FFont call to FileIOBase::Size to supply the correct
integer type of AZ::u64 instead of size_t
This fixes building on platforms where size_t is type defined to be
unsigned long

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Fixed segmentation fault in Archive::Unregister when outputing the filename of the Archive file being closed

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Fix calls to OpenPack in the Legacy LevelSystem

The LevelSystem was calling the incorrect overload of OpenPack that
accepts BindRoot for the mounted level.pak instead of the overload that
that passes a memory block object.

This was causing the level pak files to be mounted using an invalid
directory, causing file accesses inside the level pak to fail.

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Updated the error messages in the ZipDir CacheFactory class to use AZ_Warning directly

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>

* Updated the ArchiveFileIO m_trackedFiles container to store mapped type as an AZ::IO::Path

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>
4 years ago
Esteban Papp 7f157f152d Code/Editor
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp c805d443d2 Merge branch 'development' into cmake/warn_virtual
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>

# Conflicts:
#	Code/Legacy/CryCommon/IConsole.h
#	Code/Legacy/CrySystem/LocalizedStringManager.h
#	Code/Legacy/CrySystem/XConsole.h
#	Code/Legacy/CrySystem/XConsoleVariable.h
#	Code/Legacy/CrySystem/XML/XmlUtils.cpp
#	cmake/Platform/Common/Clang/Configurations_clang.cmake
4 years ago
Esteban Papp 46c6923bf7
Enabling warnings around format security
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Artur K 2a2847b15d
Legacy code cleanup - part 3 (#3903)
* Legacy cleanup - part 3

Not much is left that can be easily removed,
so I think this will be last cleanup before the legacy functionality is replaced.

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* fix windows build, remove a few more things, re-add one file

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Remove legacy RenderBus + more cleanups

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Remove MaterialOwnerBus.h

Clean-up in Cry_Matrix34/33

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>
4 years ago
Esteban Papp 49d35e0788 Final fixes for MSVC
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp 6773af91bc fixes windows warnings
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Esteban Papp 0df55c3a7f enabling warn format security and some fixes
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
Artur K 96a5f06ca3
Legacy cleanup, part 2 (#3659)
* Legacy cleanup, part 2

There are still things that can be removed, those will be likely done in part three:
`The Return of the Cleanup` :)

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Fix windows build

Somehow there were some unfixed errors from enabled warnings?
I'm unsure if I've pulled repo in unstable state, or those were somehow
missed.

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>
4 years ago
Esteban Papp 906ace3d03 Merge branch 'development' into cmake/linux_fix_warn_unused
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago
amzn-phist db1a89a492
Fix level creation on Linux (#3488)
* Fix level creation on Linux

Creating a new level on linux would fail due to backslashes being used in mkdir.
Fixed the slashes to use the AZ_CORRECT_FILESYSTEM_SEPARATOR.

Signed-off-by: amzn-phist <52085794+amzn-phist@users.noreply.github.com>

* Removed extra line that wasn't needed

Signed-off-by: amzn-phist <52085794+amzn-phist@users.noreply.github.com>
4 years ago
Esteban Papp ae4cfc3bd3 Merge branch 'development' into cmake/linux_fix_warn_unused
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>

# Conflicts:
#	Code/Framework/AzCore/AzCore/Math/Guid.h
#	cmake/Platform/Common/MSVC/Configurations_msvc.cmake
4 years ago
Esteban Papp b9daf7f7c3
Enabling several warnings on MSVC that are not enabled by default and are good to have 4 years ago
Esteban Papp f20d17398c Merge branch 'development' into cmake/linux_fix_warn_unused
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>

# Conflicts:
#	Code/Editor/Objects/TrackGizmo.cpp
4 years ago
Artur K 45b2336dce
Legacy cleanup (#3383)
* WIP - small legacy cleanup

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* More cleanups + build fixes

Use AZstd instead of std types in a few places.
Remove m_nameTable.

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Legacy code cleanups

Remove unused methods using legacy functionality

* EditorViewportWidget::AdjustObjectPosition
* DisplayContext - remove `renderer` pointer
* DisplayContext - log errors when functions using `renderer` are called
* CTrackGizmo::DrawAxis - log errors when function uses `renderer`.
* Legacy CCamera - remove Project, Unproject and CalcScreenBounds
* Remove all unused methods from Cry_GeoDistance.h/Cry_GeoIntersect.h
* Remove Lineseg_Triangle from Cry_GeoOverlap.h
* IEntityRenderState.h - remove unused types
* SMeshColor remove Lerp method and associated constructor.
* IMaterial.h - remove unused types and a few methods
* IRenderMesh.h - remove a few unused methods and use int8 instead of
byte
* IRender.h - remove almost all of the contents
* IShader.h - remove unused types and a few methods
* IStatObj.h - remove unused types and a few methods
* SSystemGlobalEnvironment - remove `renderer` pointer
* IRenderGraph - remove 2 unused methods
* physinterface.h - remove almost all of the contents
* CXmlUtils no longer inherits ISystemEventListener
* CXmlNode no longer has custom new/delete
* Remove IRenderer from some test mocks.

Removed files:
* CryName.h
* Cry_MatrixDiag.h
* Cry_XOptimise.h
* HeapAllocator.h
* IRendererMock.h
* PoolAllocator.h

Things to consider:
* Remove GetMemoryUsage & friends.

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Apply review suggestions

IMovieSystem.h - remove unused includes.

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Move unreachable code to `#if 0` block

This is hopefully temporary measure until the original functionality is
re-implemented

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Fix bad merge I messed up.

Fix bad merge I messed up, by re-removing FrameProfiler.h from crycommon_files.cmake (this was removed in an earlier commit this morning: https://github.com/o3de/o3de/pull/3394).

Signed-off-by: bosnichd <bosnichd@amazon.com>

* Update Code/Framework/AzCore/AzCore/std/string/string_view.h

Co-authored-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>
Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* implement review suggestion

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* following review, using LYSHINE_ATOM_TODO to guard

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* Remove commented out include

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

* EditorViewportWidget.cpp: Convert commented out code to  guarded one

Signed-off-by: nemerle <96597+nemerle@users.noreply.github.com>

Co-authored-by: bosnichd <bosnichd@amazon.com>
Co-authored-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>
4 years ago
Esteban Papp 6b96be82ea Merge branch 'development' into cmake/linux_fix_warn_unused
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>

# Conflicts:
#	Code/Legacy/CrySystem/Log.cpp
#	Code/Tools/Standalone/Source/Driller/Annotations/AnnotationHeaderView.cpp
#	Code/Tools/Standalone/Source/Driller/AreaChart.cpp
#	Code/Tools/Standalone/Source/Driller/AreaChart.hxx
#	Code/Tools/Standalone/Source/Driller/ChannelDataView.cpp
#	Code/Tools/Standalone/Source/Driller/DrillerCaptureWindow.cpp
#	Code/Tools/Standalone/Source/Driller/Profiler/ProfilerDataView.cpp
4 years ago
Esteban Papp e2acd66c46 Fixes Guid formatting
Signed-off-by: Esteban Papp <81431996+amznestebanpapp@users.noreply.github.com>
4 years ago