Commit graph

226 commits

Author SHA1 Message Date
Anders Jenbo
6ba343e309 🎨 Acceptable parts of misc-* 2021-04-19 20:11:41 +02:00
Anders Jenbo
b978d80119 🎨 llvm-include-order 2021-04-19 20:11:20 +02:00
Anders Jenbo
bb4e1960e7 🎨 modernize-use-nullptr 2021-04-19 16:02:05 +02:00
Anders Jenbo
c89bd9c001 🚨 Fix remaning warnings for clang and gcc 2021-04-19 02:44:39 +02:00
Anders Jenbo
946ff5b0fa ♻️Performe static casts when load save game data 2021-04-18 23:27:21 +02:00
Anders Jenbo
61d15e23db 🎨 Apply direction enum to monsters and relations
Missiles _mimfnum is being used for a lot more then just directions and
can also be a 16 degree direction so can't apply enum verbs and
restricitons to it in most cases. This in turns also affects SetMissDir
and some other functions that have to stay int.
2021-04-18 23:13:03 +02:00
staphen
4faf09c2df Consolidate logic for Mana Shield and player damage. 2021-04-18 21:12:16 +02:00
Anders Jenbo
997c1dba55 🚚 Split up all.h in to proper header relations 2021-04-16 01:04:54 +02:00
Anders Jenbo
6e1a106a38 🚚 Move header we implement into the project 2021-04-16 01:04:54 +02:00
Anders Jenbo
67a7ff98c5 🚨 Clean up compiler warnings 2021-04-16 01:04:54 +02:00
Anders Jenbo
f450d6a125 🚚 Move defines to there proper files 2021-04-16 01:04:54 +02:00
Yuri Pourre
ed1ddfdece Exposes player id from multi_send_packet 2021-04-14 17:36:31 +02:00
Anders Jenbo
e7ae8ddd04 🚚 Move all enums to there respective headers 2021-04-10 16:30:00 +02:00
Anders Jenbo
ba6b031fa1
Enable all remaning assertions (#1453) 2021-04-10 13:25:05 +02:00
Anders Jenbo
9d037bafff 🚨 Fix remaning clang warnings 2021-04-10 12:21:21 +02:00
Anders Jenbo
b46750ace3 ♻️ Change _qflags to a meaningful bool 2021-04-10 07:31:53 +02:00
Anders Jenbo
61244c4d93 ♻️ Rearange and apply more enums 2021-04-10 05:24:01 +02:00
Anders Jenbo
20186e0370 🎨 Replace TRUE/FALSE with true/false
fix


Fix


fix
2021-04-09 15:13:02 +02:00
Anders Jenbo
93d42b62b8 ♻️ Change BOOL to bool 2021-04-09 15:13:02 +02:00
Anders Jenbo
4ee84aea1a ♻️ Change BOOLEAN to bool
fixup BOOLEAN
2021-04-09 15:13:02 +02:00
Anders Jenbo
b1ffdca0a3 ♻️ make better use of enums 2021-04-08 20:29:16 +02:00
Juliano Leal Goncalves
e33ea53086 ♻️ Pass ItemStruct on inv AutoGetItem function 2021-04-07 18:34:02 +02:00
Juliano Leal Goncalves
3b015085de ♻️ Pass ItemStruct on item RespawnItem function 2021-04-07 18:34:02 +02:00
Juliano Leal Goncalves
b5a89578f0 ♻️ Pass ItemStruct on inv InvGetItem function 2021-04-07 18:34:02 +02:00
Gleb Mazovetskiy
da7567f06e InitPlrGfx: Only alloc enough for the class
Previously, the allocation size was the maximum size over all the classes.

RAM usage per player:

* Before: 2.2 MiB (any class)
* After:
  * Warrior: 2.0 MiB
  * Rogue: 1.5 MiB
  * Sorcerer: 1.6 MiB
  * Monk: 1.7 MiB

We now also only allocate memory in multi-player as needed.

This means the game will only use as much RAM for player graphics
as there are players currently in the game.

Less RAM is used for each player because class is now taken into account.
2021-04-07 06:52:07 +02:00
Anders Jenbo
bfb3c11c2b 🎨 Change namespace to devilution 2021-04-06 15:21:25 +02:00
Anders Jenbo
630e507f63 🚚 Apply namespace 2021-04-06 15:21:25 +02:00
Juliano Leal Goncalves
9021f8daa5 ♻️ Pluralize global 'item' array variable 2021-04-06 11:45:28 +02:00
Anders Jenbo
81934158c9 💚 Add missing headers 2021-04-04 06:02:16 +02:00
Anders Jenbo
97716c26ec 🐛 Update xp bar when gaining xp 2021-04-04 05:57:59 +02:00
Anders Jenbo
bba73ea20f Handle mixed item origins in multiplayer 2021-04-01 14:52:44 +02:00
Anders Jenbo
ca2c2ba5e7 🚨 Handle a bunch of warnings from CLang 2021-03-29 06:26:31 +02:00
Anders Jenbo
fbd86cd3c5 🎨 Mark noreturn functions as such 2021-03-26 02:24:32 +01:00
Anders Jenbo
a69a76941e ♻️ Clean up InitCutscene 2021-03-24 21:50:19 +01:00
Anders Jenbo
8f09cc3034 [diablo] 🐛 Correct spelling of Sorcerer
Fixes #1074
2021-03-21 12:18:10 +01:00
Anders Jenbo
17803d5923 ♻️ Apply proper types to PlayerStruct 2021-03-14 15:38:23 +01:00
Andi
7368778cb2
Remove items dropping before entering level (#1010) 2021-03-06 10:57:29 +01:00
Anders Jenbo
c71efb5960 Better assertions on item generation tests
[Diablo/Hellfire] Also clear PkItemStruct when calling PackItem() to
avoid garbage data ending up in the saves.
2021-03-03 09:30:09 +01:00
Anders Jenbo
f87bc0ca8b Clea up some duplicate item code 2021-02-27 23:04:06 +01:00
pionere
f5c1079d6f eliminate unused code 2021-02-19 22:04:11 +01:00
pionere
d5a0fa8e85 get rid of a few warnings 2021-02-19 22:04:11 +01:00
qndel
ab9911064f unify checks for single and multiplayer 2021-02-18 22:32:01 +01:00
qndel
c0f5749728 Fix RNG diverging during level generation depending on the code path
The consequences has mostly mitigated after wards, but this will make things make more sens when analysing the state of the code.
2021-02-01 06:44:16 +01:00
Anders Jenbo
9c0bc202c8 Fix additional wrong checks for monsters lights 2021-01-31 08:36:06 +01:00
Anders Jenbo
247d7497ce Unify item sync code 2021-01-26 03:14:40 +01:00
Anders Jenbo
3d93478a6c Some additional clean up 2021-01-25 01:21:18 +01:00
Anders Jenbo
c3b4b5193f Unify a chunk of Hellfire code 2021-01-18 03:25:52 +01:00
Anders Jenbo
dcb8bc8c2c Unify majority of netcode 2021-01-13 18:09:56 +01:00
Anders Jenbo
6786ebbd1a Merge branch 'master' of github.com:diasurgical/devilution 2021-01-11 19:28:45 +01:00
Anders Jenbo
869c490715 [hellfire] NetSendCmdGItem 2021-01-11 11:09:24 +01:00