mirror of
https://github.com/TwilitRealm/dusklight
synced 2026-09-01 00:13:05 -04:00
Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 2e19ffbf50 | |||
| 4a632ff5dc | |||
| 93f9ad6f1d |
@@ -157,10 +157,11 @@ f32 daAlink_c::damageMagnification(BOOL i_checkZoraMag, int param_1) {
|
||||
}
|
||||
|
||||
#if TARGET_PC
|
||||
base_mag *= dusk::getSettings().game.damageMultiplier;
|
||||
if (dusk::getSettings().game.instantDeath) {
|
||||
base_mag = 9999.0f;
|
||||
return 9999.0f; // don't need to multiply this further, 9999 is plenty
|
||||
}
|
||||
|
||||
base_mag *= dusk::getSettings().game.damageMultiplier;
|
||||
#endif
|
||||
|
||||
if (checkWolf() && !checkCargoCarry() && param_1 == 0) {
|
||||
|
||||
+2
-1
@@ -606,7 +606,8 @@ void dMeter2_c::moveLife() {
|
||||
life_count = (dComIfGs_getMaxLife() / 5) * 4;
|
||||
}
|
||||
|
||||
s16 new_life = dComIfGs_getLife() + dComIfGp_getItemLifeCount();
|
||||
DUSK_IF_ELSE(int, s16) new_life = dComIfGs_getLife() + dComIfGp_getItemLifeCount(); // prevent an overflow with really large damage values
|
||||
|
||||
if (new_life > life_count) {
|
||||
new_life = life_count;
|
||||
} else if (new_life < 0) {
|
||||
|
||||
@@ -75,12 +75,12 @@ __declspec(allocate(".symdbh"))
|
||||
#if defined(__clang__)
|
||||
__attribute__((used))
|
||||
#endif
|
||||
constinit const SymdbDescriptor s_symdbDescriptor{kDescriptorMagic, 0, 0};
|
||||
constinit SymdbDescriptor s_symdbDescriptor{kDescriptorMagic, 0, 0};
|
||||
#elif defined(__APPLE__)
|
||||
__attribute__((section("__DATA,__symdbh"), used)) constinit const SymdbDescriptor
|
||||
s_symdbDescriptor{kDescriptorMagic, 0, 0};
|
||||
__attribute__((section("__DATA,__symdbh"), used)) constinit SymdbDescriptor s_symdbDescriptor{
|
||||
kDescriptorMagic, 0, 0};
|
||||
#else
|
||||
__attribute__((section("symdbh"), used)) constinit const SymdbDescriptor s_symdbDescriptor{
|
||||
__attribute__((section("symdbh"), used)) constinit SymdbDescriptor s_symdbDescriptor{
|
||||
kDescriptorMagic, 0, 0};
|
||||
#endif
|
||||
|
||||
@@ -92,7 +92,7 @@ struct State {
|
||||
uint64_t stringsLen = 0;
|
||||
uintptr_t imageBase = 0;
|
||||
// (rva, nameOff) of entries flagged kFlagInlineSites, sorted by rva
|
||||
std::vector<std::pair<uint64_t, uint32_t> > inlineSites;
|
||||
std::vector<std::pair<uint64_t, uint32_t>> inlineSites;
|
||||
bool loaded = false;
|
||||
bool initialized = false;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user