diff --git a/docs/rh-log.txt b/docs/rh-log.txt index 014236c75..2f7183785 100644 --- a/docs/rh-log.txt +++ b/docs/rh-log.txt @@ -1,4 +1,16 @@ -June 8, 2009 +June 9, 2009 (Changes by Graf Zahl) +- Fixed: R_DrawSkyStriped used frontyScale without initializing it first. +- Fixed: P_LineAttack may not check the puff actor for MF6_FORCEPAIN because + it's not necessarily spawned yet. +- Fixed: FWeaponSlots::PickNext/PrevWeapon must be limited to one iteration + through the weapon slots. Otherwise they will hang if there's no weapons + in a player's inventory. +- Added Line_SetTextureScale. +- Fixed: sv_smartaim 3 treated the player like a shootable decoration. +- Added A_CheckIfInTargetLOS +- Removed redundant A_CheckIfTargetInSight. + +June 8, 2009 - Fixed: The initial play of a GME song always started track 0. - Fixed: The RAWINPUT buffer that GetRawInputData() fills in is 40 bytes on Win32 but 48 bytes on Win64, so Raw Mouse on x64 builds was getting random diff --git a/src/g_shared/a_weapons.cpp b/src/g_shared/a_weapons.cpp index e606d8cb5..0bd4f6b54 100644 --- a/src/g_shared/a_weapons.cpp +++ b/src/g_shared/a_weapons.cpp @@ -974,6 +974,7 @@ static bool FindMostRecentWeapon(player_t *player, int *slot, int *index) AWeapon *FWeaponSlots::PickNextWeapon(player_t *player) { int startslot, startindex; + int slotschecked = 0; if (player->mo == NULL) { @@ -997,6 +998,7 @@ AWeapon *FWeaponSlots::PickNextWeapon(player_t *player) if (++index >= Slots[slot].Size()) { index = 0; + slotschecked++; if (++slot >= NUM_WEAPON_SLOTS) { slot = 0; @@ -1009,7 +1011,7 @@ AWeapon *FWeaponSlots::PickNextWeapon(player_t *player) return weap; } } - while (slot != startslot || index != startindex); + while ((slot != startslot || index != startindex) && slotschecked < NUM_WEAPON_SLOTS); } return player->ReadyWeapon; } @@ -1027,6 +1029,7 @@ AWeapon *FWeaponSlots::PickNextWeapon(player_t *player) AWeapon *FWeaponSlots::PickPrevWeapon (player_t *player) { int startslot, startindex; + int slotschecked = 0; if (player->mo == NULL) { @@ -1049,6 +1052,7 @@ AWeapon *FWeaponSlots::PickPrevWeapon (player_t *player) { if (--index < 0) { + slotschecked++; if (--slot < 0) { slot = NUM_WEAPON_SLOTS - 1; @@ -1062,7 +1066,7 @@ AWeapon *FWeaponSlots::PickPrevWeapon (player_t *player) return weap; } } - while (slot != startslot || index != startindex); + while ((slot != startslot || index != startindex) && slotschecked < NUM_WEAPON_SLOTS); } return player->ReadyWeapon; } diff --git a/src/p_map.cpp b/src/p_map.cpp index 41c1951d3..f1ef571af 100644 --- a/src/p_map.cpp +++ b/src/p_map.cpp @@ -3244,7 +3244,8 @@ AActor *P_LineAttack (AActor *t1, angle_t angle, fixed_t distance, } } // [GZ] If MF6_FORCEPAIN is set, we need to call P_DamageMobj even if damage is 0! - if (damage || puff->flags6 & MF6_FORCEPAIN) + // Note: The puff may not yet be spawned here so we must check the class defaults, not the actor. + if (damage || (puffDefaults->flags6 & MF6_FORCEPAIN)) { int flags = DMG_INFLICTOR_IS_PUFF; // Allow MF5_PIERCEARMOR on a weapon as well. diff --git a/src/r_plane.cpp b/src/r_plane.cpp index bb6df2bf2..9be0b0b5d 100644 --- a/src/r_plane.cpp +++ b/src/r_plane.cpp @@ -906,7 +906,7 @@ static void R_DrawSkyStriped (visplane_t *pl) { lastskycol[x] = 0xffffffff; } - wallscan (pl->minx, pl->maxx, top, bot, swall, lwall, frontyScale, + wallscan (pl->minx, pl->maxx, top, bot, swall, lwall, rw_pic->yScale, backskytex == NULL ? R_GetOneSkyColumn : R_GetTwoSkyColumns); yl = yh; yh += drawheight;