Commit graph

251 commits

Author SHA1 Message Date
staphen
5b21e0188f Fix order of operations during game initialization 2022-01-15 06:47:09 +01:00
obligaron
ff5de056fa
Add all (boolean) Game Settings to Settingsmenu (#3616) 2021-11-26 23:43:46 +01:00
Gleb Mazovetskiy
c57644970f Move UiFlags and UiPanels into their own files
The first breaks circular dependency between `DiabloUI` and `text_render`.
The latter one moves `UiPanels` to a more appropriate place.
2021-11-25 12:22:27 +01:00
obligaron
677303cba9
Reduce use of view globals in game menu 2021-11-20 21:57:32 +01:00
Anders Jenbo
082be73dd4 Expose all quest titles for translation 2021-09-26 00:17:02 +02:00
Anders Jenbo
464fd77238 Clean up quests.cpp global naming 2021-09-22 04:21:53 +02:00
qndel
6d35fee7f9 fix quest panel 2021-09-19 10:15:14 +01:00
Anders Jenbo
7771a08d03 Translatable mainpanel 2021-09-19 07:21:52 +02:00
Anders Jenbo
e68c8cc834 Reuse EntranceBoundaryContains in portal logic 2021-09-12 02:51:34 +02:00
Juliano Leal Goncalves
8a93087fb7 ♻️ Extract quest entrance boundary check to a member function on QuestStruct 2021-09-12 02:30:08 +02:00
Juliano Leal Goncalves
3e24a58ba6 ♻️ Replace 'questxoff' and 'questyoff' globals with single 'questEntranceOffsets' 2021-09-12 02:30:08 +02:00
ephphatha
b12de6fe12 Use scoped enum for Direction
Identified and removed an instance of Direction being used as an argument for a bool parameter

Removed a single-use temporary variable being cast from sprite frame to direction to size_t

Co-authored-by: Anders Jenbo <anders@jenbo.dk>

Fix alignment of WalkSettings array
2021-09-12 02:27:47 +02:00
Anders Jenbo
7169882b1f Implement new font rendering 2021-09-12 01:37:28 +02:00
Andrew James
784057780c
Prevent OOB access when initialising quest pools (#2775) 2021-09-07 01:07:46 +02:00
Juliano Leal Goncalves
ce40344ae9 🚚 Rename 'QuestDataStruct' struct to 'QuestData' 2021-09-06 12:54:40 +02:00
Juliano Leal Goncalves
ce23cd6bce 🚚 Rename 'QuestData' global array to 'QuestsData'
This will allow us to disambiguate from the 'QuestDataStruct' after the 'Struct' suffix is removed.
2021-09-06 12:54:40 +02:00
Juliano Leal Goncalves
1f7cfcf945 ♻️ Replace 'ReturnLvlX' and 'ReturnLvlY' globals with single 'ReturnLvlPosition' 2021-09-06 00:31:25 +02:00
Juliano Leal Goncalves
940a120bf9 ♻️ Replace 'ViewX' and 'ViewY' globals with single 'ViewPosition' 2021-09-04 18:06:28 -04:00
Juliano Leal Goncalves
0baffa6e33 🚚 Rename 'QuestStruct' to 'Quest' 2021-09-02 05:46:01 +02:00
Juliano Leal Goncalves
20db8d1a11 🚚 Rename 'MonsterStruct' to 'Monster' 2021-09-01 22:26:37 +02:00
Juliano Leal Goncalves
01823e1324 ♻️ Replace 'cursmx' and 'cursmy' globals with single 'cursPosition' 2021-08-30 06:45:51 +02:00
Anders Jenbo
d7c6d8b189 Use proper Direction type for AddMissile midir 2021-08-25 20:24:45 +02:00
vlad
dc61f5de31 Improved Questlog
- completed quests are displayed
  - completely reworked quest log item drawing
  - spacing and positioning depends on list size
- removed "Quest Log" title and "close Quest Log"
- selection follows cursor
- changed quest book ordering from alphabetical to explicitly modeled (added new field to QuestDataStruct)
2021-08-23 01:07:58 +02:00
Anders Jenbo
5ddcd90ff9 Make NetSendCmdQuest() take a quest structure as input 2021-08-20 12:13:17 +02:00
Anders Jenbo
4891258775 Clean up quest init 2021-08-20 12:13:17 +02:00
Anders Jenbo
783e946fd3 Make enabeling quests a command 2021-08-19 20:36:12 +02:00
BC Ko
40c804c0ba Replace QuestStatus() with IsAvailable() in QuestStruct 2021-08-19 02:12:20 +02:00
BC Ko
e5434e03b3
2602 Use range-based for-loop for Quests (#2612) 2021-08-19 01:42:49 +02:00
BC Ko
ba5adc01f1
Use quest_id enum in QuestStatus 2021-08-15 20:48:24 +00:00
Aaron Sun
3ee90ca629 Add options for sub-panel alignment 2021-08-07 16:09:32 +02:00
4aron5un
4c8210df21
Center the sub-panels (Quest, Character, Spell and Inventory) (#2498) 2021-08-05 21:27:07 +02:00
ephphatha
0575716eac Rename UiFlags members to group related options 2021-07-31 20:22:40 +02:00
ephphatha
4ad53232a0 Convert the UiFlags enum to a scoped enum type
Replace operator&& with named function
2021-07-31 20:22:40 +02:00
Anders Jenbo
de0b3a38b8 Apply code style 2021-07-20 02:51:39 +02:00
Anders Jenbo
e5fc7fd17c Move remaning symbols in to anonymous namespaces 2021-07-20 02:51:39 +02:00
Anders Jenbo
9c4e34f988 Player by reference 2021-07-20 01:35:56 +02:00
ephphatha
0efb134e18 Add tests for quest randomisation code
Required splitting the code to a separate function so it can be tested in isolation
2021-07-16 15:13:32 +02:00
Anders Jenbo
77b72da276 ♻️Use monster by reference when possible 2021-07-14 20:22:35 -07:00
Anders Jenbo
ef6275caac Clean up private function names 2021-07-12 17:59:22 -07:00
Andrew James
af60158274
Object by reference in SyncObjectAnimation functions (#2344) 2021-07-10 14:03:44 +02:00
ephphatha
19ae61811f Refactor AddObject to take Point instead of int x/y 2021-07-09 17:58:34 +02:00
Anders Jenbo
903d4bd2e1 Scope all for loops
This caused 7 of the loops to be rewriteen using range by clang-tidy
2021-07-08 08:14:03 -07:00
Anders Jenbo
467b74dc06 Rename object globals 2021-07-08 02:01:14 -07:00
Anders Jenbo
9b8bf92575 Rename quest globals 2021-07-08 02:01:14 -07:00
Anders Jenbo
96bf75b502 Rename player globals 2021-07-08 02:01:14 -07:00
Anders Jenbo
07ad083fda Rename monster globals 2021-07-08 02:01:14 -07:00
Anders Jenbo
56d3b5d710 clang-tidy/Android Stuidio cleanups 5 2021-07-05 13:14:47 -07:00
Gleb Mazovetskiy
55464eec78 Fix -Wmissing-braces
Fixes warnings such as this one:

```
../../../../../../Source/engine/render/text_render.hpp:83:33: warning: suggest braces around initialization of subobject [-Wmissing-braces]
        return DrawString(out, text, { position.x, position.y, out.w() - position.x, 0 }, flags, spacing, lineHeight, drawTextCursor);
                                       ^~~~~~~~~~~~~~~~~~~~~~
```
2021-07-03 19:08:45 -07:00
Gleb Mazovetskiy
cb0dae8590 🚚 Rename CelOutputBuf to Surface and extract 2021-07-03 05:33:32 -07:00
Anders Jenbo
129342d07a Clang-tidy: GlobalConstantCase 2021-07-02 22:56:56 +02:00