Commit Graph

579 Commits

Author SHA1 Message Date
RichieSams
031be61b07 ZVISION: Clean up the ZVision constructor 2013-10-02 09:09:48 -05:00
RichieSams
229e4fe3be ZVISION: Move creation of the managers to ZVision::initialize()
In order to make the ZVision constructor as lightweight as possible
2013-10-02 09:09:48 -05:00
RichieSams
ea5a6a7bde ZVISION: Fix debug typo copy-paste error 2013-10-02 09:09:47 -05:00
RichieSams
a6ae661ef8 ZVISION: Add newline at end of file 2013-10-02 09:09:46 -05:00
RichieSams
7854f05b79 ZVISION: Remove empty file 2013-10-02 09:09:32 -05:00
RichieSams
11576c5aa9 ZVISION: Rename ZVisionGameIds to use standard format 2013-09-29 21:41:43 -05:00
RichieSams
07c3231214 ZVISION: Remove memory corrupting assignment
This was a code error left over from previous changes. We just create a
new TextFramgment each time and hand it to List::push_back()
2013-09-25 02:32:42 -05:00
RichieSams
cd3dc276d9 ZVISION: Only save a thumbnail of the backbuffer instead of the whole thing 2013-09-25 02:30:37 -05:00
RichieSams
d8bee6be13 ZVISION: Set the state value at each frame of a return animation
Some Puzzles trigger off the intermediate frames
2013-09-25 02:30:02 -05:00
RichieSams
dfb37fb2f0 ZVISION: Remove CLIPs from mutateImage
Due to the math of the Panorama/Tilt, all pixel offsets are going to be closer
to the center of the image. Also, mutateImage is now being called on a
finished buffer, rather than an image at a time. Therefore, it no longer has to
handle image wrapping. Thus, there is no case in which a pixel offset would
be outside the image bounds.
2013-09-24 17:34:34 -05:00
RichieSams
29db14c7dd ZVISION: Don't cast away const-ness 2013-09-24 13:49:05 +02:00
RichieSams
dfba1a0144 ZVISION: Don't cast away const-ness 2013-09-22 17:57:16 -05:00
RichieSams
fdd477df61 ZVISION: Free AlphaDataEntry Surfaces before deleting them 2013-09-22 17:57:15 -05:00
RichieSams
a7ffd9ade6 ZVISION: Cleanup all AlphaEntries after use 2013-09-22 15:55:22 -05:00
RichieSams
9d1b0e1f8b ZVISION: Assert that we don't exceed our hardcoded number of lines 2013-09-22 15:52:56 -05:00
RichieSams
dd0a6fe0e3 ZVISION: Convert hardcoded number to an anonymous enum 2013-09-22 15:52:24 -05:00
RichieSams
713baa3769 ZVISION: Fix memory leak in SaveManager 2013-09-22 15:47:16 -05:00
RichieSams
9fefed67f4 ZVISION: Fix signed/unsigned mismatch 2013-09-22 15:11:38 -05:00
RichieSams
79573d0331 ZVISION: Fix shadowing in the Direction constructor 2013-09-22 15:10:23 -05:00
RichieSams
9a5305a977 ZVISION: Add vertical pipes to prevent multi-line comments 2013-09-22 14:55:32 -05:00
RichieSams
48979c557b ZVISION: Remove animation.o since animation.cpp is now gone 2013-09-22 14:41:56 -05:00
RichieSams
69bcb76d05 ZVISION: Add documentation to RenderManager 2013-09-21 13:37:39 -05:00
RichieSams
7a557c4bcd ZVISION: Add documentation to TruetypeFont 2013-09-21 13:37:38 -05:00
RichieSams
cfe176619a ZVISION: Remove unused function arguments 2013-09-21 13:37:38 -05:00
RichieSams
2d9c9e8c7f ZVISION: Remove unused animation functions 2013-09-21 13:37:18 -05:00
RichieSams
7ff86ba6f9 ZVISION: Add documentation for RlfAnimation 2013-09-21 00:31:59 -05:00
RichieSams
1ced56fee7 ZVISION: Add documentation to SaveManager 2013-09-21 00:09:05 -05:00
RichieSams
8f7fa517d6 ZVISION: Directly access _globalState instead of using setStateValue
setStateValue does a _referenceTable lookup and potentially adds Puzzles
to _puzzlesToCheck. We know that _referenceTable and _puzzlesToCheck
with be cleared during ScriptManager::changeLocation(), so using
setStateValues ends up just being wasteful.
2013-09-21 00:08:36 -05:00
RichieSams
51fc627c05 ZVISION: Clear out the current state table values before loading any from a save file 2013-09-21 00:05:38 -05:00
RichieSams
ca80deea62 ZVISION: Only allow save slots in the range [1, 20]
This is the range supported by the ZNem / ZGI save menus
2013-09-21 00:04:31 -05:00
RichieSams
8557b06197 ZVISION: Load the state values before changing location 2013-09-21 00:03:49 -05:00
RichieSams
d06c64d076 ZVISION: Append chars to a Common::String object instead of using a static buffer 2013-09-17 11:05:49 -05:00
RichieSams
6148a0a878 ZVISION: Add a check against reading newer save game versions 2013-09-17 11:04:41 -05:00
RichieSams
6664f31ed2 ZVISION: Convert the current save version to a const 2013-09-17 11:03:49 -05:00
RichieSams
5ec472ae2f ZVISION: Add version support for save files 2013-09-16 22:10:26 -05:00
RichieSams
a0a67a2d47 ZVISION: Partially implement InputControl 2013-09-16 00:17:27 -05:00
RichieSams
4af62cfd3a ZVISION: Register the "fonts" directory with SearchMan 2013-09-16 00:17:27 -05:00
RichieSams
035ee29f1d ZVISION: Initialize StringManager 2013-09-16 00:17:26 -05:00
RichieSams
0c28fbca7c ZVISION: Remove extraneous empty line 2013-09-16 00:17:25 -05:00
RichieSams
ff5b7ba2a8 ZVISION: Draw string to 0, 0 instead of destX, destY 2013-09-16 00:17:25 -05:00
RichieSams
2b60cc8a0c ZVISION: Test for file.open() success before continuing with font loading 2013-09-16 00:17:24 -05:00
RichieSams
c7e2bdd2b2 ZVISION: Remove extraneous function 2013-09-16 00:17:24 -05:00
RichieSams
a2c36a16b5 ZVISION: Fix parseTag font name logic 2013-09-16 00:17:15 -05:00
RichieSams
d59cf9fda6 ZVISION: Convert StringManager::parseStr to use readWideLine() 2013-09-16 00:10:35 -05:00
RichieSams
14cfc65c0d ZVISION: Use wide-to-ASCII conversion to read a line instead of stream.readLine()
SeekableReadStream::readLine() wasn't finding the CRLF's properly
2013-09-16 00:09:03 -05:00
RichieSams
4c4f08a99e ZVISION: Convert cmdRenderText to use new function syntax 2013-09-16 00:05:24 -05:00
RichieSams
1f9f392279 ZVISION: Enable auto saving 2013-09-16 00:04:34 -05:00
RichieSams
2187245012 ZVISION: Remove all AlphaEntries on room change 2013-09-16 00:04:23 -05:00
RichieSams
3a6cb86489 ZVISION: Add methods to clear and remove AlphaEntries 2013-09-16 00:04:03 -05:00
RichieSams
cdd793ed22 ZVISION: Check is a dirty rect is empty before extending it
So extends dont extend from 0,0
2013-09-16 00:03:35 -05:00
RichieSams
7ce6823158 ZVISION: Convert _alphaDataEntries to a HashMap
So entries can be easily identified and removed if necessary
2013-09-16 00:02:57 -05:00
RichieSams
41afb2dd90 ZVISION: Move clearing dirty rects to after they are blitted instead the beginning of each frame 2013-09-16 00:00:52 -05:00
RichieSams
2b2f85063a ZVISION: Clean up StringManager and SaveManager after use 2013-09-15 16:27:19 -05:00
RichieSams
d82ff7aea8 ZVISION: Create Console method to render text 2013-09-15 16:26:49 -05:00
RichieSams
c312b147fa ZVISION: Create an instance of StringManager 2013-09-15 15:01:01 -05:00
RichieSams
82ea7ca0e7 ZVISION: Create the StringManager class
This parses the XXXXX.STR files into styled fonts and phrases. The styles
and the phrases are used in the game for messages to the user and for
general purpose fonts.
2013-09-15 15:01:00 -05:00
RichieSams
05b3b170d4 ZVISION: Add more documentation for clearWorkingWindowTo555Color() 2013-09-15 15:01:00 -05:00
RichieSams
dc8c7ca2c0 ZVISION: Add RenderManager text support 2013-09-15 15:00:59 -05:00
RichieSams
c643718dae ZVISION: Clean up the TruetypeFont class and add alpha support
Remove caching. We don't render font enough to warrant it. Use
Graphics::TextAlign instead of rolling our own. Remove methods
we don't use.
2013-09-15 15:00:59 -05:00
RichieSams
f6c36aa14c ZVISION: Create an instance of the SaveManager 2013-09-15 15:00:58 -05:00
RichieSams
a2d19c7a6e ZVISION: Actually store the ZVision pointer 2013-09-15 15:00:58 -05:00
RichieSams
2900aaa90a ZVISION: Add a reminder for how inventory is accessed 2013-09-15 15:00:57 -05:00
RichieSams
5cd1d2d1c2 ZVISION: Ensure getControl always returns something 2013-09-15 15:00:57 -05:00
RichieSams
6ee253a4d8 ZVISION: Add focus support for the ScriptManager 2013-09-15 15:00:56 -05:00
RichieSams
0d78208562 ZVISION: Add focus support for Controls 2013-09-15 15:00:56 -05:00
RichieSams
259d11762d ZVISION: Add support for ActionRandom and ActionTimer
They were already implemented, they just weren't being used
2013-09-15 15:00:55 -05:00
RichieSams
36a0b666b3 ZVISION: Add better alpha support for blitting
Instead of blitting directly to the working window, we cache the alpha pixels,
then blit directly to the backbuffer instead of to the working window. This
ensures that if the alpha'd content changes, the old changes won't appear
in any new frames
2013-09-15 15:00:54 -05:00
RichieSams
3986f333ef ZVISION: Move dirty rect extension to the correct function
Source control mishap
2013-09-15 15:00:54 -05:00
RichieSams
466eba1e9f ZVISION: Fix signed/unsigned mismatch 2013-09-15 15:00:53 -05:00
RichieSams
8ba295d710 ZVISION: Add key press support to the main event loop 2013-09-15 15:00:42 -05:00
RichieSams
0eeeeded92 ZVISION: Add ScriptManager support for key press events 2013-09-15 15:00:41 -05:00
RichieSams
b50afa2b15 ZVISION: Remove unused function 2013-09-15 15:00:40 -05:00
RichieSams
752807b471 ZVISION: Add method to copy a portion of the working window to a surface 2013-09-15 15:00:32 -05:00
RichieSams
d3b6caab2f ZVISION: Remove unused key functions 2013-09-15 14:07:02 -05:00
RichieSams
c20a9ac6ae ZVISION: Add key press support to Controls 2013-09-15 14:06:11 -05:00
RichieSams
d643ca1571 ZVISION: Remove unused Console functions 2013-09-15 14:04:58 -05:00
RichieSams
0874212fa7 ZVISION: Cleanup _currentFrameBuffer during descruction 2013-09-09 11:16:46 -05:00
RichieSams
4a4330cec7 ZVISION: Cleanup the cached frame before loading the next one 2013-09-09 11:16:45 -05:00
RichieSams
f5f053d335 ZVISION: Use default dpi for font 2013-09-09 11:16:45 -05:00
RichieSams
072b852cdc ZVISION: Remove extraneous methods from TrueTypeFont 2013-09-09 11:16:44 -05:00
RichieSams
edd1a117ae ZVISION: Cache animation frames so they can be re-rendered when the background moves 2013-09-09 11:16:44 -05:00
RichieSams
9e563f0113 ZVISION: Add comments to AnimationControl::process() 2013-09-09 11:16:43 -05:00
RichieSams
077f0b2491 ZVISION: Update LeverControl to use the new RlfAnimation outputs 2013-09-09 11:16:43 -05:00
RichieSams
8354f23628 ZVISION: Add a debug assert to make sure we're not trying to render ouside the working window 2013-09-09 11:16:42 -05:00
RichieSams
31cdf227d2 ZVISION: Clip animations to the working window 2013-09-09 11:16:42 -05:00
RichieSams
3b7189993c ZVISION: Let Rlf animations output Surfaces instead of uint16 arrays 2013-09-09 11:16:41 -05:00
RichieSams
f9b9bf5b9b ZVISION: Create method for transposing a surface 2013-09-09 11:16:40 -05:00
RichieSams
a415964c6d ZVISION: Create method for clipping a rect to the working window 2013-09-09 11:16:40 -05:00
RichieSams
511cb7447e ZVISION: Create method for converting image space to working window space 2013-09-09 11:16:39 -05:00
RichieSams
c7358ed4f7 ZVISION: Create class for rendering TrueType fonts 2013-09-09 11:16:39 -05:00
RichieSams
af94158723 ZVISION: Save a thumbnail of the RenderManager backbuffer instead of the actual screen
This prevents things like the GMM being in the thumbnail
2013-09-09 11:16:38 -05:00
RichieSams
87e78e4c33 ZVISION: Create method for getting the RenderManager backbuffer 2013-09-09 11:16:38 -05:00
RichieSams
106522661c ZVISION: Create method for rendering to the working window with binary alpha 2013-09-09 11:16:37 -05:00
RichieSams
6e806e51ad ZVISION: Stop avi playback once the animation is finished 2013-09-09 11:16:37 -05:00
RichieSams
b1587f8ba0 ZVISION: Implement ActionPlayPreloadAnimation 2013-09-09 11:16:36 -05:00
RichieSams
5c3cfaa6d2 ZVISION: Implement ActionPreloadAnimation::execute() 2013-09-09 11:16:36 -05:00
RichieSams
46278f6f59 ZVISION: Implement AnimationControl
This handles playing animations asyncronously over numerous frames
2013-09-09 11:16:35 -05:00
RichieSams
6a9572670c ZVISION: Add method for getting a pointer to a Control 2013-09-09 11:16:28 -05:00
RichieSams
eeace477a0 ZVISION: Set a Puzzle as completed before executing its ResultActions 2013-09-07 18:06:20 -05:00
RichieSams
81184d342c ZVISION: Delete a Control * when removing it from _activeControls 2013-09-07 18:05:47 -05:00