Commit graph

505 commits

Author SHA1 Message Date
ephphatha
1d560601f2 Remove duplicated argument to InvGetItem
This was obscuring efforts to track how ActiveItems and Items are referenced, hopefully can switch back to the Item& soon.
2021-11-23 19:08:41 +01:00
obligaron
677303cba9
Reduce use of view globals in game menu 2021-11-20 21:57:32 +01:00
Gleb Mazovetskiy
b8affd5fe5 Fix a few build warnings 2021-11-08 23:33:08 +01:00
Anders Jenbo
56170b3372 Clean up id normalization 2021-11-07 23:15:10 +01:00
ephphatha
335b0b9349 Use crawl table based search for item checks
fixes #3207
2021-11-07 20:13:31 +01:00
joewis
9cd6f206ad
Disable shift-clicking of items you don't have stats to wear 2021-11-01 00:54:59 +01:00
Gleb Mazovetskiy
64a88343e8 Refactor: Use item iterators in 7 more places 2021-10-31 13:28:08 +00:00
obligaron
2158faadab Use SDL_StartTextInput for gold drop dialog 2021-10-27 00:06:30 +02:00
obligaron
98ecd0ecc5 Introduce CloseGoldDrop 2021-10-27 00:06:30 +02:00
Joerg Wissen
a274c6eab4 Swap weapons between body and inventory with shift-click 2021-10-26 11:09:37 +02:00
obligaron
f142b63664 Disallow to swap gear while not standing/walking. 2021-10-24 23:07:15 +02:00
Joerg Wissen
4e7d6b8f9e
Optional feature to auto-refill belt from inventory (#983) 2021-10-21 22:57:08 +00:00
Bernd Stellwag
fcc0266703
Add new option to enable/disable item pickup sounds 2021-10-21 22:29:10 +00:00
staphen
ab13fba13f Use Rune Bomb or Cathedral Map to open Hive or Crypt 2021-10-12 15:21:37 +02:00
staphen
ee23f41e0c Enable opening Hive and Crypt using gamepad 2021-10-12 04:40:43 +02:00
Bernd Stellwag
f1a0aa3b49
Replace broken link with @see annotation to text representation of the linked image 2021-10-09 22:30:31 +02:00
Yuri Pourre
7d74336e6b Enhance ctrl + drop 2021-10-09 16:16:51 +02:00
ephphatha
4198a19787 Remove debug assert after picking up an item
Doesn't really do anything useful. If the target position doesn't contain an item on the local client the code looks for a matching dropped item and tries to pick that up instead. It doesn't really make sense to assert that an item exists at the target position or that it matches, a desync has already happened by this point if the checks on lines 1647 or 1649 are false.
2021-10-07 12:01:25 +02:00
Anders Jenbo
31ba8e2bc6 Validate additional network messages 2021-10-06 21:47:03 +02:00
Yuri Pourre
b8450dc792 Assign ctrl to drop items 2021-09-29 18:15:26 +02:00
obligaron
24c5ee8bd2 Draw belt item number for unusable scrolls 2021-09-26 10:50:00 +02:00
Gleb Mazovetskiy
ec13c333a9 Refactor: Use item iterators for scroll checks
Refs #2586
2021-09-24 01:56:44 +01:00
qndel
70dc796287 proper fix 2021-09-22 13:06:03 +02:00
qndel
81199b14af fix wrong armor display in multiplayer 2021-09-22 09:10:58 +02:00
Anders Jenbo
7771a08d03 Translatable mainpanel 2021-09-19 07:21:52 +02:00
Juliano Leal Goncalves
379a27b64a ♻️ Convert 'ItemType' enum to enum class
🎨 Rename 'ItemType' elements to enum class standards
2021-09-13 00:25:49 +02:00
Juliano Leal Goncalves
e39b33971f ♻️ Leverage 'IsAnyOf' 2021-09-13 00:25:49 +02:00
Juliano Leal Goncalves
094f308d22 🐛 Use 'Spell' instead of 'RSpell' for clearing used staff charges
Readied spell can be swapped to something else in between the cast and the hit frame, resulting in incorrect removal.

This is how currently belt and inventory scrolls are checked so we are now using a consistent strategy.
2021-09-12 05:02:06 +02:00
Juliano Leal Goncalves
776a3d4e84 🐛 Use 'Spell' instead of 'RSpell' for clearing used inventory scrolls
Readied spell can be swapped to something else in between the cast and the hit frame, resulting in incorrect removal.

This is how currently belt scrolls are checked so we are now using a consistent strategy.
2021-09-12 05:02:06 +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
BC Ko
9345c7cac7 Remove duplicate documentation 2021-08-30 14:05:18 +02:00
BC Ko
51f50570da documentation cleanup : inv 2021-08-30 13:54:35 +02:00
Juliano Leal Goncalves
bb2dfdfb73 🚚 Rename 'ItemStruct' to 'Item' 2021-08-30 13:40:08 +02:00
Juliano Leal Goncalves
01823e1324 ♻️ Replace 'cursmx' and 'cursmy' globals with single 'cursPosition' 2021-08-30 06:45:51 +02:00
Juliano Leal Goncalves
05d206720a ♻️ Replace 'icursW' and 'icursH' globals with single 'icursSize' 2021-08-30 06:45:51 +02:00
Juliano Leal Goncalves
317ebcdd3e ♻️ Replace 'icursW28' and 'icursH28' globals with single 'icursSize28' 2021-08-30 06:45:51 +02:00
Juliano Leal Goncalves
a469f7906e ♻️ Replace 'cursW' and 'cursH' globals with single 'cursSize' 2021-08-30 06:45:51 +02:00
Juliano Leal Goncalves
6c21638bee ♻️ Leverage 'Point' in 'SetCursorPos' function 2021-08-30 06:45:51 +02:00
Juliano Leal Goncalves
bbf529c65a 🚚 Rename 'PlayerStruct' to 'Player' 2021-08-30 06:44:18 +02:00
Anders Jenbo
4044fadeb5 Clean up some players references 2021-08-30 03:26:17 +02:00
Gleb Mazovetskiy
032eaf7491 External iterators for player items
Implements external iterators for player items.
2021-08-29 07:28:21 +02:00
Robin
62a33c61d9
objects: deduplicate logic in OperateShrineGloomy using ForEachItem function 2021-08-27 11:41:45 +02:00
BC Ko
4df798808e
2435 refactor global variable Items part 2 (#2673) 2021-08-26 08:06:48 +02:00
Thomas Christlieb
8f92248250 don't play 'Uh uh' sound everytime you pick up the cathedral map. fixes #1354 2021-08-23 14:45:31 +02:00
Anders Jenbo
5ddcd90ff9 Make NetSendCmdQuest() take a quest structure as input 2021-08-20 12:13:17 +02:00
Anders Jenbo
4a7fecb9c1 Fix OOB in inventory code 2021-08-13 03:59:29 +02:00
BC Ko
a02eaeecda use abs 2021-08-11 17:50:13 +02:00
BC Ko
a293abc2a6 cleanup manual value clamping: inv.cpp 2021-08-11 17:50:13 +02:00
Juliano Leal Goncalves
f64521a722 🐛 Centralize readied spell update on equipment change
This ensures all equipment changes will undergo the check to see if the readied spell needs to change, including auto-equipping items on pickup and with shift click.
2021-08-10 12:26:01 +02:00