Commit Graph
86814 Commits
Author SHA1 Message Date
Joseph-Eugene Winzer 83523ebbdc SUPERNOVA: Corrects left mouse click behavior
This still needs work especially concerning actions that need two
objects like ACTION_USE or ACTION_GIVE.
2018-01-23 00:00:11 +00:00
Joseph-Eugene Winzer d70ded12f6 SUPERNOVA: Fixes that objects are removed when taken 2018-01-23 00:00:11 +00:00
Joseph-Eugene Winzer 4fc7f73442 SUPERNOVA: Converts Inventory as GuiElements
By encapsulating the inventory state in GuiElements we can through out
inventory_object
2018-01-23 00:00:11 +00:00
Joseph-Eugene Winzer aa22029ffe SUPERNOVA: Removes isVisible flag from GuiElement 2018-01-23 00:00:11 +00:00
Joseph-Eugene Winzer 36263aaa0b SUPERNOVA: Fixes font rendering 2018-01-23 00:00:11 +00:00
Joseph-Eugene Winzer e0aa700dac SUPERNOVA: Renames charcterWidth() to textWidth() 2018-01-23 00:00:11 +00:00
Joseph-Eugene Winzer 2a19f34bb5 SUPERNOVA: Adds table for octal cp437 umlauts 2018-01-23 00:00:11 +00:00
Joseph-Eugene Winzer 4c26b418cd SUPERNOVA: Makes Inventory::get() return nullObject 2018-01-23 00:00:11 +00:00
Joseph-Eugene Winzer 5224c4d313 SUPERNOVA: Refactors room definitions
Calling renderImage() directly causes unintended side effects since
e9d7b7ca0f as drawImage() besides rendering also set visibility flags.
2018-01-23 00:00:11 +00:00
Joseph-Eugene Winzer 4d3e1eed8e SUPERNOVA: Corrects OPEN to more descriptive OPENABLE 2018-01-23 00:00:11 +00:00
Joseph-Eugene Winzer 40c609c40b SUPERNOVA: Adds debugging code for rendering available sections 2018-01-23 00:00:11 +00:00
Joseph-Eugene Winzer e9375ea3ee SUPERNOVA: Adds tons of stuff
Most notably changes are,
    Handling of object state when calling drawImage() for
    inverse section rendering
    Beginning to convert GUI to GuiElements (_guiCommandButton)
    Mouse Input handling

This is still WIP but better than the glitchfest before.
2018-01-23 00:00:11 +00:00
Joseph-Eugene Winzer 0f7266a6b4 SUPERNOVA: Removes warnings for Inventory code 2018-01-23 00:00:11 +00:00
Joseph-Eugene Winzer c903ede023 SUPERNOVA: Fixes renderRoom() by limiting the section range 2018-01-22 23:54:42 +00:00
Joseph-Eugene Winzer b959453b39 SUPERNOVA: removeMessage() now restores the screen on destruction 2018-01-22 23:54:42 +00:00
Joseph-Eugene Winzer 28b6430eaa SUPERNOVA: Fixes typo in definition of objects 2018-01-22 23:54:42 +00:00
Joseph-Eugene Winzer dc12a0fd23 SUPERNOVA: Enables renderImage() to render inverse sections
Besides the addition of inverse sections, the 'fullscreen' parameter was
removed as it was used only for testing purposes in the beginning.
2018-01-22 23:54:41 +00:00
Joseph-Eugene Winzer a54c9084c1 SUPERNOVA: Removes 'inverse section' case
This code section was converted from the original source, where the
sections are directly drawn to the screen instead of buffered.
If a section > 128 is set as parameter, the function takes the
dimensions of section - 128 and draws this region of section 0 to the
screen, thus restoring it.
It would not make sense loading part of section 0 in seperate Surfaces
especially since kMaxSection is smaller than 128 the else branch is
never entered so removing it doesn't change the programs behavior.
2018-01-22 23:54:41 +00:00
Joseph-Eugene Winzer 6d655b19fc SUPERNOVA: Adds GuiElement Class 2018-01-22 23:54:41 +00:00
Joseph-Eugene Winzer a8f62802cc SUPERNOVA: Extends Object Class 2018-01-22 23:54:41 +00:00
Joseph-Eugene Winzer 718cae659c SUPERNOVA: Adds info to NOTES 2018-01-22 23:54:41 +00:00
Joseph-Eugene Winzer 30389746c8 SUPERNOVA: Fixes bathroom location on minimap 2018-01-22 23:54:41 +00:00
Joseph-Eugene Winzer 7c8f5bdd3d SUPERNOVA: Adds missing copyright header 2018-01-22 23:54:41 +00:00
Joseph-Eugene Winzer 69f6ef0efd SUPERNOVA: Cosmetic changes in console code 2018-01-22 23:54:41 +00:00
Joseph-Eugene Winzer b6887b0740 SUPERNOVA: Converts strings back to cp437 2018-01-22 23:54:41 +00:00
Joseph-Eugene Winzer 30308fbe8d SUPERNOVA: Implements GUI routines and refactors code
Of course the short description does not adequately describe the changes
made with this commit and I assume this won't be the last big
restructuring unfortunately.

Focus of this commit was to implement/fix the code so the main user
interface can be rendered. Bugs in the core routines for rendering
Messages and Images were fixed as well.
2018-01-22 23:54:26 +00:00
Joseph-Eugene Winzer 87a0dd970a SUPERNOVA: Fixes Message positioning 2018-01-22 23:42:08 +00:00
Joseph-Eugene Winzer 2c17586c76 SUPERNOVA: Fixes parameters passed to fillRect() 2018-01-22 23:42:08 +00:00
Joseph-Eugene Winzer 4a68aef1d6 SUPERNOVA: Fixes ScreenBufferStack 2018-01-22 23:42:08 +00:00
Joseph-Eugene Winzer 84eb970bb9 SUPERNOVA: Fixes endianess issue for drawing cursor 2018-01-22 23:42:08 +00:00
Joseph-Eugene Winzer 11b6227517 SUPERNOVA: Buffer Music files 2018-01-22 23:42:08 +00:00
Joseph-Eugene Winzer 1b220e75e5 SUPERNOVA: Implements playSoundMod() 2018-01-22 23:42:08 +00:00
Joseph-Eugene Winzer ef1bbce68e SUPERNOVA: Buffers sections of image on init 2018-01-22 23:42:08 +00:00
Joseph-Eugene Winzer 1ae1134706 SUPERNOVA: Converts mouse cursor data 2018-01-22 23:42:08 +00:00
Joseph-Eugene Winzer 7c4a763710 SUPERNOVA: Replaces magic numbers 2018-01-22 23:42:08 +00:00
Joseph-Eugene Winzer 9e21dc42ee SUPERNOVA: Implements rendering of newspaper articles
The resolution will change dynamically depending what image is about to
be rendered. As there are no other GUI elements shown that depend on the
screen resolution when the artciles are rendered, there shouldn't be any
problems.
2018-01-22 23:42:08 +00:00
Joseph-Eugene Winzer cd080b820a SUPERNOVA: Buffers audio samples on startup 2018-01-22 23:42:08 +00:00
Joseph-Eugene Winzer 6c4768a051 SUPERNOVA: Reformatting
Substitute size_t with ScummVM defined uint type
2018-01-22 23:42:07 +00:00
Joseph-Eugene Winzer 018cff8c42 SUPERNOVA: Enables debug console and preload images 2018-01-22 23:42:07 +00:00
Joseph-Eugene Winzer 5ebe90a45e SUPERNOVA: Implements loading of newspaper images
While the 640x480 images are loaded correctly, they are displayed
cropped to 320x240, the default resolution.
2018-01-22 23:42:02 +00:00
Joseph-Eugene Winzer be5f3a6319 SUPERNOVA: Fixes file name creation 2018-01-22 23:40:38 +00:00
Joseph-Eugene Winzer 29021aa7dd SUPERNOVA: Refactoring 2018-01-22 23:40:27 +00:00
Joseph-Eugene Winzer 7da3ab2611 SUPERNOVA: Enables rendering of debug console 2018-01-22 23:34:50 +00:00
Joseph-Eugene Winzer a3b6352050 SUPERNOVA: Formatting 2018-01-22 23:34:49 +00:00
Joseph-Eugene Winzer 38e9e2d3e7 SUPERNOVA: Adds missing copyright notes 2018-01-22 23:34:49 +00:00
Joseph-Eugene Winzer 932b3669d3 SUPERNOVA: Adds room specific game logic
This is the game logic for the first act of the game.
It will see restructuring to remove gotos/jumps and hardcoded
differences in game behavior depending on settings (e.g. sound on/off).
2018-01-22 23:34:49 +00:00
Joseph-Eugene Winzer e6802ed633 SUPERNOVA: Refactoring 2018-01-22 23:34:49 +00:00
Joseph-Eugene Winzer 74b822c220 SUPERNOVA: Refactors and adds GameManager functions 2018-01-22 23:34:49 +00:00
Joseph-Eugene Winzer f2e3a4d9c4 SUPERNOVA: Changes return type to int for getDOSTicks()
The maximum return value is 0x1800B0, so easily covered by int
 (assuming 32bit+ architecture)
2018-01-22 23:34:49 +00:00
Joseph-Eugene Winzer 534bd38370 SUPERNOVA: Extends renderText()
Restructures the renderText() function for providing a renderText(text)
overload that starts rendering the string where the last call stopped.
2018-01-22 23:34:49 +00:00