Commit Graph
149 Commits
Author SHA1 Message Date
Anders Jenbo ef6275caac Clean up private function names 2021-07-12 17:59:22 -07:00
Anders Jenbo 4bf4e42230 Move local symbols to anonymous namespace 2021-07-12 17:59:22 -07:00
ephphatha af7adda161 Refactor GetLight/SetLight to take Points instead of x/y params
Doing both functions at once as they are called from the same places with the same arguments.

They also operate on char values internally but get treated as if they are ints, might be more appropriate to use int8_t/uint8_t?
2021-07-09 18:52:49 +10:00
ephphatha 8dbbdcca0d remove unnecessary cast from MakeLightTable
Also changed the c-style cast to static_cast with appropriate type for destination.
2021-07-08 07:53:40 -07:00
Anders Jenbo 9ebdb6db69 General clean up 2021-07-08 03:30:25 -07:00
Anders Jenbo 467b74dc06 Rename object 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 dce78dde62 Rename lighting globals 2021-07-08 02:01:14 -07:00
Anders Jenbo bc59218d0d More clang-tidy/Android Studio cleanups 2021-07-04 19:34:37 +02:00
Anders Jenbo a7c7fa0030 Fully apply clang-tidy/format to all files 2021-07-03 16:41:43 -07:00
Anders Jenbo ecea12fc15 Clang-tidy: ParameterCase 2021-07-03 15:46:39 -07:00
qndel dadf418fe0 fix typo (#2266) 2021-06-29 19:15:01 +02:00
Anders Jenbo b1d237c823 More init clean up (#2262) 2021-06-29 06:37:38 +02:00
Anders Jenbo 5537fe748e Clean up debug code 2021-06-27 16:16:39 -07:00
Anders Jenbo 22b632f04a ♻️Clean up implicit bool conversions 2021-06-26 08:57:59 -07:00
Gleb Mazovetskiy e40b1963f9 🚚 engine.h: Extract CelSprite and file loading 2021-06-21 01:36:20 -07:00
Juliano Leal Goncalves b3ec79af4f Leverage 'Point' in Lighting and Player functions (#2048) 2021-05-24 17:28:52 +02:00
Anders Jenbo 44b58c4970 Clean up L5dflags flags 2021-05-19 14:09:33 +02:00
Anders Jenbo 0c2042fa52 ♻️ Player by reference
Update Source/items.cpp
Update Source/lighting.cpp
Update Source/pack.cpp
asd


ads


as
2021-05-13 01:47:46 +02:00
Anders Jenbo 92db72719d 🔥 Remove some unused code 2021-05-05 10:16:45 +02:00
Anders Jenbo 3746723f52 ♻️Add type to MIN-files and TRN-files 2021-05-05 04:03:23 +02:00
Anders Jenbo fa0b286693 ♻️Typed file loading
Tthis gives us the option to specify what type a file should be loaded
as, avoidng the need to case it and does some automatic checks on the
fitness of the data, while making the process simpler.

If no type is given then the type will be set to std::byte which limit
what operations can be performed on the data.
2021-05-04 19:08:37 +02:00
Anders Jenbo 654a2b8834 ♻️Clean up automap code
Use Point for x,y pairs. Make helpers for drawing door and squares
2021-05-02 15:27:38 +02:00
Gleb Mazovetskiy 0bfc147b78 🧹 Remove DiabloAllocPtr and friends (#1824) 2021-05-02 07:06:18 +02:00
Gleb Mazovetskiy 052b4c12f5 ♻️ LoadFileInMem: Remove nullptr at call sites
This is now the default argument, no need to provide it explicitly.
2021-05-01 20:51:55 +02:00
Gleb Mazovetskiy 1b8b62a8c2 ♻️ Store CEL width with the sprite itself
Instead of passing the CEL sprite width when drawing, store the CEL
width at load time in the new `CelSprite` struct.

Implemented for most sprites except towners, missiles, or monsters.
2021-05-01 20:51:55 +02:00
Anders Jenbo 2bd13451a1 ♻️Apply point positioning to all remaning entities 2021-04-25 01:25:48 +02:00
Anders Jenbo e4cfad3196 ♻️Use points instead of individual fileds for player structure 2021-04-24 04:46:08 +02:00
Anders Jenbo 1e3ed903be 🎨 strip redundant else 2021-04-22 00:39:48 +02:00
Anders Jenbo 373f28736f 🎨 Acceptable parts of modernize-* 2021-04-19 22:42:19 +02:00
Anders Jenbo bb4e1960e7 🎨 modernize-use-nullptr 2021-04-19 16:02:05 +02:00
Anders Jenbo 997c1dba55 🚚 Split up all.h in to proper header relations 2021-04-16 01:04:54 +02:00
qndel e24f3c83de fix automap 2021-04-15 19:11:15 +02:00
qndel ced74f76f9 fix gharbad and vision 2021-04-12 17:20:39 +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 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
Anders Jenbo a2656637e4 🎨 Format source 2021-03-31 00:52:47 +02:00
pionere a841be2708 ✅ Test CrawlTable 2021-03-21 14:23:19 +01:00
Anders Jenbo 8d6d508222 Correct some incorrect bool operations 2021-03-09 22:27:11 +01:00
Anders Jenbo a60a620e51 Update bugfix comment 2021-03-05 06:23:12 +01:00
qndel 1b304e7bb3 [diablo/hellfire] 🐛 Correct unitialized variable in AddVision 2021-03-05 06:20:41 +01:00
Anders Jenbo 327042c2e5 Strip out debug features from the release builds
leveldebug and lightmax still remains
2021-02-19 22:04:11 +01:00
pionere f5c1079d6f eliminate unused code 2021-02-19 22:04:11 +01:00
Anders Jenbo 93b82e3b7a Fix regression of static lights from fix of dynamic ones
This issue was introduced in 1f532040a8
2021-01-31 14:00:22 +01:00
qndel 1f532040a8 Fix dynamically added lights being overwritten by default light
This issues could be seen when opening the final room in the Arkaine's
Valor quest.
2021-01-31 09:34:29 +01:00
qndel 3627d9df9d Formatting vCrawlTable 2021-01-31 04:50:28 +01:00
qndel 6e096143f0 Add no-light define and fix usage 2021-01-31 04:13:44 +01:00
Anders Jenbo 8c261d0966 Merge remaning clean Hellfire code paths 2021-01-09 19:04:31 +01:00