Commit Graph
35 Commits
Author SHA1 Message Date
Eugene Sandulenko abea37c9bb ALL: Update ScummVM project license to GPLv3+ 2021-12-26 18:48:43 +01:00
Orgad Shaneh 3a51911db2 NANCY: Use nullptr
Using clang-tidy modernize-use-nullptr
2021-11-14 15:51:59 +02:00
Orgad Shaneh c1343e8051 NANCY: Use override
Using clang-tidy modernize-use-override
2021-11-14 14:34:14 +02:00
fracturehill 85f8bf294d NANCY: Includes cleanup
Reordered and cleaned up #includes in the engine.
2021-04-01 21:25:32 +03:00
fracturehill ff078328bc NANCY: Includes cleanup
Cleaned up the engine's #includes. Also moved the NancyEngine::GameState enum to commontypes.h and renamed it to NancyState.
2021-03-26 01:17:07 +02:00
fracturehill b175c5fd10 NANCY: Initialize class members
Class members that get properly initialized after the constructor now also get default values during construction to silence warnings. Also fixed a couple of broken entries in response.cpp that were uncovered by these changes.
2021-03-25 19:52:53 +02:00
fracturehill 1907b5f741 NANCY: Remove static members of GraphicsManager
Made GraphicsManager's static members non-static.
2021-03-24 17:20:46 +01:00
fracturehill 56c005ef2c NANCY: Mark functions and iterators as const
Added the const keyword to several auto & iterators inside for loops, as well as to a number of class member functions.
2021-03-24 17:20:46 +01:00
fracturehill bfc6586f78 NANCY: Add reserve() calls before initializing arrays
Added calls to reserve() before initializing most arrays in the engine to reduce unnecessary allocations when pushing back elements one by one.
2021-03-24 17:20:46 +01:00
fracturehill e9adea4c4e NANCY: Formatting fixes
Almost every file in the engine code was using spaces instead of tabs, which is now fixed. Also added some missing spaces in a couple of files.
2021-03-24 17:20:46 +01:00
fracturehill da559b5fe0 NANCY: Display The Vampire Diaries video correctly
The Vampire Diaries' videos are all upside down after decompression, need a palette to be loaded from a separate bitmap file, and background videos are also quarter size (1/2 width and height). This commit adds a GraphicsManager function for loading a Surface or a raw buffer into a ManagedSurface, applying all transformations needed to display it correctly.
2021-03-24 17:20:46 +01:00
fracturehill 5440559918 NANCY: Add support for 8-bit color
Added generic methods for getting the pixel format and transparent color. Also added a method for loading an image directly into a ManagedSurface, which also loads the palette and lets The Vampire Diaries logo display properly.
2021-03-24 17:20:46 +01:00
fracturehill b34fcec89a NANCY: Add loading images from .bmp files
Added code that allows The Vampire Diaries to load its image resources, which are stored in separate .bmp files. However, they are in a different pixel format than the ones from later games, so they don't yet display correctly on screen.
2021-03-24 17:20:46 +01:00
fracturehill b3222b7439 NANCY: Resource manager improvements
The resource manager now keeps track of its cif trees and calls to loadImage() and loadData() don't need to specify a cif tree. In order to support The Vampire Diaries, IFFs can now be loaded from their own dedicated .iff file, and the engine doesn't require a cif tree to be loaded on boot.
2021-03-24 17:20:46 +01:00
fracturehill 20f432f8d3 NANCY: Engine refactor
Made all states (Scene, Credits, Help, etc.) singletons, as well as subclasses of a common State parent with a proper state switching API. Moved the OnPause virtual function from RenderObject to ActionRecord and hooked it into the state switching code. Also got rid of the NancyEngine pointer that got passed around between most classes, and replaced it with several convenience macros. As a result of these changes action records that render to the viewport no longer disappear after opening the menu, and state changes feel snappier.
2021-03-24 17:20:46 +01:00
fracturehill 3aaf2a9bea NANCY: Major engine rewrite
Rewrote most of the engine using a much more object-oriented approach and using more of ScummVM's common classes. This design deviates quite a lot from the original engine's, but should be more maintainable and extensible in the future.
2021-03-24 17:20:46 +01:00
fracturehill d97ca12d6c NANCY: Initial commit 2021-03-24 17:20:46 +01:00
Walter van Niftrik 0284d2172f NANCY: WIP 2021-03-24 17:20:46 +01:00
Walter van Niftrik d5ea0c840a NANCY: Rename debug commands 2021-03-24 17:20:46 +01:00
Walter van Niftrik ef8daa9f3f NANCY: Add exporting to .cif 2021-03-24 17:20:46 +01:00
Walter van Niftrik 3efe6a6f76 NANCY: Add partial .avf video support 2021-03-24 17:20:46 +01:00
Walter van Niftrik 1df38bd500 NANCY: Add support for .cif patches 2021-03-24 17:20:46 +01:00
Walter van Niftrik dd91f7e4f5 NANCY: Add support for multiple CifTrees loaded simultaneously 2021-03-24 17:20:46 +01:00
Walter van Niftrik aa1f0bd1ac NANCY: Cleanup 2021-03-24 17:20:46 +01:00
Walter van Niftrik 48c60a01af NANCY: Fix regression in CifTree 2.0 handling 2021-03-24 17:20:46 +01:00
Walter van Niftrik 9720ba812a NANCY: Add support for Nancy 6 CifTree format 2021-03-24 17:20:46 +01:00
Walter van Niftrik 164778ba12 NANCY: Refactor resource manager 2021-03-24 17:20:46 +01:00
Walter van Niftrik e989b0e1c8 NANCY: Add debug commands for dumping a resource and loading a new CifTree 2021-03-24 17:20:46 +01:00
Walter van Niftrik dbb64b77e1 NANCY: Make CifTree case insensitive 2021-03-24 17:20:46 +01:00
Walter van Niftrik ba12d04986 NANCY: Add heuristic for long filenames in CifTree 2021-03-24 17:20:46 +01:00
Walter van Niftrik d245afd843 NANCY: Add partial support for CifTree 2.1 2021-03-24 17:20:46 +01:00
Walter van Niftrik 410861661a NANCY: Refactor resource manager 2021-03-24 17:20:46 +01:00
Walter van Niftrik 892ac7f835 NANCY: Refactor resource manager 2021-03-24 17:20:46 +01:00
Walter van Niftrik 13024420cb NANCY: Load more data from info blocks 2021-03-24 17:20:46 +01:00
Walter van Niftrik fd1f0767f8 NANCY: Add resource decompressor 2021-03-24 17:20:46 +01:00