ThomasChr
c91feb71f9
make light objects unseen when saving level change data, because level change data (instead of real save data) does not save light source and if the light objects will be marked as seen there lights won't be created and they stay dark
3 years ago
obligaron
b87711bc08
Reintroduce Player::spellFrom to seperate teleport cursor from queued spell
3 years ago
Eric Robinson
81e3c7abaa
Remove fixed bugfix comments, apply golem fix
3 years ago
obligaron
eeca953615
Introduce UpdateHellfireFlag to set missing CF_HELLFIRE flag
3 years ago
Gleb Mazovetskiy
957bd03b98
Remove `FMT_COMPILE` in "cold" places
...
Removes most `FMT_COMPILE` calls.
`FMT_COMPILE` results in better performance but larger code size.
Removes `FMT_COMPILE` calls for places that are called infrequently,
i.e. not on every frame.
RG-99 binary size reduced by ~4 KiB.
3 years ago
Eric Robinson
f75f66d54b
Add `playerdat` ( #5763 )
3 years ago
Gleb Mazovetskiy
98294e0ad5
Optimize `MissileData`: 32 bytes -> 24
...
23 bytes used, 1 spare byte in the padding.
3 years ago
KPhoenix
d813f13700
`enum spell_id` -> `enum class SpellID`
3 years ago
KPhoenix
7947b99511
Implement new enum class
3 years ago
Eric Robinson
ef3a57b7d9
`enum spell_type` -> `enum class SpellType` ( #5674 )
3 years ago
Eric Robinson
30c1991039
`enum _mai_id` -> `enum class MonsterAIID` ( #5683 )
3 years ago
DakkJaniels
d683039bdd
stop shaking camera if dead diablo loaded from save. ( #4149 )
3 years ago
Gleb Mazovetskiy
6d274c9547
`UNPACKED_SAVES`: Saves without MPQs
...
Reduces rg99 binary size by ~70 KiB.
3 years ago
KPhoenix
8db521727d
`enum missile_id` -> `enum class MissileID`
...
Changes `enum missile_id` to `enum class MissileID`
3 years ago
Anders Jenbo
a29fc3a074
Correct casing for Player::isWalking()
3 years ago
Gleb Mazovetskiy
ec12d7ce44
Player: Optimize to save 40 bytes
3 years ago
Mikołaj Piróg
4cff046ba9
Replace toHitSpecial member with a function & fix wrong arguments being passed ( #5337 )
4 years ago
Mikołaj Piróg
5e340d3261
Replace level member with a member function in monster ( #5336 )
4 years ago
Mikołaj Piróg
32b3333bfb
Exp overflow fix ( #5070 )
4 years ago
Stephen C. Wills
c91702ffbc
Don't use MyPlayer in SaveHotkeys() ( #5292 )
4 years ago
qndel
ef5a4de227
typos + code cleanup
4 years ago
obligaron
2493f06116
ActorPosition: Remove offset, offset2 and velocity
4 years ago
obligaron
1cfd1ca99d
Fix double casting bug - use separated info for casted and queued spells
4 years ago
obligaron
ca1949a87f
Don't recalculate leveltype (from currlevel) in SaveGameData
4 years ago
Gleb Mazovetskiy
b21ebffaf2
Clean up player graphic loading
4 years ago
ephphatha
975eb3674b
Add helper to check if a monster belongs to a player
...
Co-authored-by: Anders Jenbo <anders@jenbo.dk>
4 years ago
Anders Jenbo
d1189388f5
Use user by reference
4 years ago
Gleb Mazovetskiy
04c3d85179
Remove `MAX_PATH`
...
Rather than using the Windows-like `MAX_PATH`, what we really want is 2
things:
1. Maximum path of a file in an MPQ. This is now `MaxMpqPathSize`.
2. Max size for the known monster paths. This is now 64 for sounds and
TRNs, which is more than enough (picked arbitrarily).
4 years ago
Gleb Mazovetskiy
7ad0ec925f
Reduce sizes of Monster (goal)Vars
...
sizeof(Monster): 168 -> 144
4 years ago
Mikołaj Piróg
262fa9ac2d
Rename MonsterData members ( #5000 )
4 years ago
ephphatha
1337ff6ea2
Add check if a monster potentially has leashed minions
4 years ago
ephphatha
4fef842b0b
Remove use of ID/index from PlaceGroup
...
use getId helper for leader id
Co-authored-by: Anders Jenbo <anders@jenbo.dk>
4 years ago
ephphatha
1e0f2c149c
Add getLeader helper for monsters in a pack
4 years ago
Gleb Mazovetskiy
33ac2cca8e
♻️ Make Monster counters `size_t`
4 years ago
Anders Jenbo
38113c0ad8
Convert monster_goal in to a scoped enum
4 years ago
Anders Jenbo
2d21fc372e
Remove more miniwin code
4 years ago
Anders Jenbo
6a8fd04067
Use player by references ( #4938 )
4 years ago
Stephen C. Wills
4398c1e06a
Use absolute coordinates for temp position when north-walking ( #4937 )
4 years ago
Cesar Canassa
e538acb248
📝 Fixes Doxygen warnings ( #4904 )
4 years ago
Mikołaj Piróg
15989609a8
Members' name changes and comments in Monster struct ( #4861 )
4 years ago
obligaron
3c571bf64b
Avoid overflow of tickCounterOfCurrentFrame ( #4893 )
...
* When MFLAG_ALLOW_SPECIAL is set, don't call processAnimation (avoid overflow of tickCounterOfCurrentFrame)
4 years ago
aetn23
bf568fe480
Remove assert to check if value is in bounds
4 years ago
Mikołaj Piróg
dda0b96ea5
Remove #defines in player.h and add constexpr where applicable ( #4896 )
...
* Change defines to constexpr int in player.h
* Add const or constexpr to player.h/cpp where applicable
* Update tests with changed names of player constatns
* remove unecessary variable
4 years ago
k-bar
26de74f4a2
AnimationInfo class correct style ( #4870 )
...
* AnimationInfo class correct case-style for private members
clang-tidy warnings:
readability-identifier-naming invalid case style for private member
* AnimationInfo class correct case-style for members
clang-tidy warnings:
readability-identifier-naming invalid case style for member
* AnimationInfo class correct case-style for methods
clang-tidy warnings:
readability-identifier-naming invalid case style for method
* AnimationInfo class use nodiscard
clang-tidy warnings:
modernize-use-nodiscard function should be marked [[nodiscard]]
4 years ago
Gleb Mazovetskiy
6949a6f418
Monster: Remove MType/MData pointers
...
These pointers are redundant, replaces them with methods.
4 years ago
obligaron
a6132a1aa8
Ensure that no overflow happens when loading (invalid) data
4 years ago
Andrew James
ace09d5f45
Address int-arithmetic-overflow in loadsave.cpp ( #4853 )
4 years ago
Mikołaj Piróg
7cab074aa5
Correct members' names in monster.h ( #4850 )
...
* Fix case in AnimStruct
* Rename CMonster members
4 years ago
Gleb Mazovetskiy
3178dd5158
Replace most uses of `sprintf` with `fmt` ( #4837 )
4 years ago
k-bar
c2432d23e8
Berserk light fix
4 years ago