Robin Eklind
eaf8fbd0e7
Merge pull request #1312 from mewpull/cleanup4
...
Update player struct to use more booleans.
7 years ago
Robin Eklind
0554e11640
Merge pull request #1313 from mewpull/split-PWVel-into-two-vars
...
split PWVel into two global variables, PWVel and AnimLenFromClass
7 years ago
Robin Eklind
5371d13154
Make use of item_special_effect enums.
7 years ago
Robin Eklind
002ad4056c
split PWVel into two global variables, PWVel and AnimLenFromClass
...
Background:
From the values of PWVel, I think it is
actually two global variables that have
been merged into one.
int PWVel[4][3] = {
{ 2048, 1024, 512 },
{ 2048, 1024, 512 },
{ 2048, 1024, 512 },
{ 8, 8, 8 }
};
I think it should be:
int PWVel[3][3] = {
{ 2048, 1024, 512 },
{ 2048, 1024, 512 },
{ 2048, 1024, 512 }
};
int AnimLenFromClass[3] = {
{ 8, 8, 8 }
};
Then, this code in PM_DoWalk would make more sense:
Before:
vel = 8;
if (currlevel != 0) {
vel = PWVel[3][plr[pnum]._pClass];
}
After:
AnimLen = 8;
if (currlevel != 0) {
AnimLen = AnimLenFromClass[plr[pnum]._pClass];
}
7 years ago
Robin Eklind
105a583ce0
Use TRUE and FALSE enums for setlevel.
...
Also simplify if conditions to make
use of boolean values.
(If the cleanup4 PR ends up increasing
inserts/deletions, then this commit is
probably at fault.)
7 years ago
Robin Eklind
b727d158ab
Make _pSLvlVisited into a boolean.
...
_pSLvlVisited is only ever used in boolean contexts.
7 years ago
Robin Eklind
29eb52b6d0
Make _pLvlVisited into a boolean.
...
_pLvlVisited is only ever used in boolean contexts.
7 years ago
Robin Eklind
a443e5091e
Make _pInfraFlag a boolean.
...
_pInfraFlag is only ever used in boolean contexts.
7 years ago
Robin Eklind
59167447ba
msg: use enum for RSPLTYPE_INVALID in msg.cpp
7 years ago
Robin Eklind
983d2d6769
Make _pLvlChanging into a boolean.
...
_pLvlChanging is only ever used in boolean contexts.
7 years ago
Robin Eklind
f59439a8ff
Make _pInvincible into a boolean.
...
_pInvincible is only ever used in boolean contexts.
7 years ago
Robin Eklind
3f4a539bf7
Make _pBlockFlag into a boolean.
...
_pBlockFlag is only ever used in boolean contexts.
7 years ago
Robin Eklind
8b85ba2489
Merge pull request #1309 from mewpull/rename-InitNewSeed
...
multi: rename InitNewSeed to InitLevelType
7 years ago
Robin Eklind
8402bbaff5
player: replace WALK_NONE with -1 for lightning index
7 years ago
Robin Eklind
9b6e866878
Update Source/multi.cpp
...
Co-Authored-By: Anders Jenbo <anders@jenbo.dk>
7 years ago
Robin Eklind
98ac9ebaf3
multi: use name from PSX for InitLevelType
7 years ago
Robin Eklind
f47e29d60d
multi: rename InitNewSeed to DTypeFromDLvl
7 years ago
Robin Eklind
624b84e8cc
Merge pull request #1308 from Predelnik/PR
...
Cast pointer to ptrdiff_t to make code less undefined for 64-bit.
7 years ago
Sergey Semushin
c4c2132ac6
Cast pointer to ptrdiff_t to make code less undefined for 64-bit.
7 years ago
Anders Jenbo
a52d36a90f
Correct value of DLRG_CHAMBER
7 years ago
Robin Eklind
4cbf8c9ec3
Rename global pCelBuff to pSPentSpn2Cels
...
This is to avoid confusion, as pCelBuff is also
commonly used as a parameter name.
The naming follows the convention used by
TextBox2.CEL and TextSlid.CEL, as seen in
stores.cpp
pSTextBoxCels = LoadFileInMem("Data\\TextBox2.CEL", NULL);
pSPentSpn2Cels = LoadFileInMem("Data\\PentSpn2.CEL", NULL);
pSTextSlidCels = LoadFileInMem("Data\\TextSlid.CEL", NULL);
7 years ago
galaxyhaxz
0da0dbc9a3
Fix AddCbolt conditional
7 years ago
Adam Newgas
c55c61f23a
Update comments to doxygen style.
7 years ago
Adam Newgas
79ad7b9d9e
Add some comments to some tricky to understand functions.
7 years ago
Adam Newgas
fc8882b7db
Add some bugfix notes.
7 years ago
Adam Newgas
66a1c246e6
Add dlrg_flag enum.
7 years ago
Adam Newgas
3d1d01ce86
More use of DMAXX/DMAXY
7 years ago
Adam Newgas
f363cfa85f
Use DMAXX/DMAXY and BFLAG_EXPLORED in drlg_l2.cpp
7 years ago
Alex Sweet
10ebca4efd
Fix load/save monster padding
7 years ago
Robin Eklind
d113d3a158
debug: add ICURS_GOLD_LARGE enum
7 years ago
Sergey Semushin
6e36190221
Fix typo in LoadPremium, SavePremium.
7 years ago
Sergey Semushin
15d046dc64
Fix typo in SaveObject.
7 years ago
Robin Eklind
aa151d98e8
Merge pull request #1302 from mewpull/background
...
Add BACKGROUND.md to detail project background.
7 years ago
Alex Sweet
e1bc0c40eb
Undo style changes
7 years ago
Alex Sweet
a0f9a9b758
Move SavePlayer and SaveItem down
7 years ago
Alex Sweet
0386165da7
Fix incorrect arg name in forward declarations
7 years ago
Alex Sweet
74011382b4
Removed unused #pragma packs
7 years ago
Alex Sweet
636a8108f9
Fix line endings
7 years ago
Alex Sweet
3f82acec52
Use filthy Windows types
7 years ago
Alex Sweet
aed31ce684
Style fixes
7 years ago
Alex Sweet
c124514391
Add missing pragma pack to some structs
7 years ago
Alex Sweet
356f0361f9
Bufix - pointers
7 years ago
Alex Sweet
9c207f601d
Refactor packing functions
7 years ago
Alex Sweet
a0c295811d
Load 32 bit save files
7 years ago
Anders Jenbo
c16553c65d
Fix GCC builds
7 years ago
Anders Jenbo
aca1b85f2c
Merge branch 'master' of github.com:diasurgical/devilution
7 years ago
Anders Jenbo
b86cfe5f6c
Merge branch 'master' of github.com:diasurgical/devilutionX
7 years ago
Robin Eklind
deb187be9b
miniwin: remove comment for unused SDL key-codes
...
Should we later notice that there are more keys
not being translated, we can refer back to this
commit for the remaining SDL key-codes.
7 years ago
Robin Eklind
929be99acf
miniwin: fix keycode translation of SDLK_MENU
7 years ago
Robin Eklind
2e9f835205
miniwin: map additional keycodes
...
Prior to this commit, several keyboard keys would
not be translated, as detailed by the following
debug message:
DUMMY: translate_sdl_key : unknown key: name== sym=0x3D scan=46 mod=0x0
With this commit, all keys on regular US keyboards
should be translated correctly.
7 years ago