From 1b55520a8b90b01c5d9ca3cdbf30acac7f924916 Mon Sep 17 00:00:00 2001 From: Randy Heit Date: Tue, 18 Dec 2007 03:25:19 +0000 Subject: [PATCH] - Fixed: Heretic's mace never respawned in deathmatch games. - Fixed: At resolutions taller than 600 pixels or so, tall sky textures were drawn a row too low. This was quite visible on Hexen MAP06. - Fixed: P_CheckSlopeWalk() must return false if floorsector != sector, or the actor will be yanked down to the floorsector by P_TryMove(). - Fixed: ClearActorInventory, GiveActorInventory, and TakeActorInventory only affected the first actor with the given TID. - Fixed: The color boxes for the colorpicker menu items were drawn a little too low. SVN r603 (trunk) --- docs/rh-log.txt | 9 ++++++ src/g_heretic/a_hereticweaps.cpp | 2 ++ src/m_options.cpp | 2 +- src/p_acs.cpp | 54 +++++++++++++++++++++++++++----- src/p_map.cpp | 6 ++-- src/r_sky.cpp | 5 +++ 6 files changed, 67 insertions(+), 11 deletions(-) diff --git a/docs/rh-log.txt b/docs/rh-log.txt index feff8b35c6..01808992ed 100644 --- a/docs/rh-log.txt +++ b/docs/rh-log.txt @@ -1,4 +1,13 @@ December 17, 2007 +- Fixed: Heretic's mace never respawned in deathmatch games. +- Fixed: At resolutions taller than 600 pixels or so, tall sky textures were + drawn a row too low. This was quite visible on Hexen MAP06. +- Fixed: P_CheckSlopeWalk() must return false if floorsector != sector, or + the actor will be yanked down to the floorsector by P_TryMove(). +- Fixed: ClearActorInventory, GiveActorInventory, and TakeActorInventory + only affected the first actor with the given TID. +- Fixed: The color boxes for the colorpicker menu items were drawn a little + too low. - Fixed: Clean scaling at 720x480 looked borked. - New: When using the D3D9 framebuffer, palette blending is now applied only to the 3D area of the screen. This means the console and (the primary diff --git a/src/g_heretic/a_hereticweaps.cpp b/src/g_heretic/a_hereticweaps.cpp index 3c23368eec..638c5d5706 100644 --- a/src/g_heretic/a_hereticweaps.cpp +++ b/src/g_heretic/a_hereticweaps.cpp @@ -1096,6 +1096,8 @@ void A_SpawnMace (AActor *self) mace->FirstSpot = firstSpot; mace->NumMaceSpots = numspots; mace->DoRespawn (); + // We want this mace to respawn. + mace->flags &= ~MF_DROPPED; } } diff --git a/src/m_options.cpp b/src/m_options.cpp index bbb8b1defc..267e4d2c67 100644 --- a/src/m_options.cpp +++ b/src/m_options.cpp @@ -1698,7 +1698,7 @@ void M_OptDrawer () { int box_x, box_y; box_x = (CurrentMenu->indent - 35 - 160) * CleanXfac + screen->GetWidth()/2; - box_y = (y - 98) * CleanYfac + screen->GetHeight()/2; + box_y = (y - ((gameinfo.gametype & GAME_Raven) ? 99 : 100)) * CleanYfac + screen->GetHeight()/2; screen->Clear (box_x, box_y, box_x + 32*CleanXfac, box_y + (fontheight-1)*CleanYfac, item->a.colorcvar->GetIndex()); } diff --git a/src/p_acs.cpp b/src/p_acs.cpp index 7ddca519b2..f965246f25 100644 --- a/src/p_acs.cpp +++ b/src/p_acs.cpp @@ -4231,7 +4231,19 @@ int DLevelScript::RunScript () break; case PCD_CLEARACTORINVENTORY: - ClearInventory (SingleActorFromTID(STACK(3), NULL)); + if (STACK(3) == 0) + { + ClearInventory(NULL); + } + else + { + FActorIterator it(STACK(3)); + AActor *actor; + for (actor = it.Next(); actor != NULL; actor = it.Next()) + { + ClearInventory(actor); + } + } sp--; break; @@ -4241,9 +4253,23 @@ int DLevelScript::RunScript () break; case PCD_GIVEACTORINVENTORY: - GiveInventory (SingleActorFromTID(STACK(3), NULL), - FBehavior::StaticLookupString (STACK(2)), STACK(1)); - sp -= 3; + { + const char *type = FBehavior::StaticLookupString(STACK(2)); + if (STACK(3) == 0) + { + GiveInventory(NULL, FBehavior::StaticLookupString(STACK(2)), STACK(1)); + } + else + { + FActorIterator it(STACK(3)); + AActor *actor; + for (actor = it.Next(); actor != NULL; actor = it.Next()) + { + GiveInventory(actor, type, STACK(1)); + } + } + sp -= 3; + } break; case PCD_GIVEINVENTORYDIRECT: @@ -4257,9 +4283,23 @@ int DLevelScript::RunScript () break; case PCD_TAKEACTORINVENTORY: - TakeInventory (SingleActorFromTID(STACK(3), NULL), - FBehavior::StaticLookupString (STACK(2)), STACK(1)); - sp -= 3; + { + const char *type = FBehavior::StaticLookupString(STACK(2)); + if (STACK(3) == 0) + { + TakeInventory(NULL, type, STACK(1)); + } + else + { + FActorIterator it(STACK(3)); + AActor *actor; + for (actor = it.Next(); actor != NULL; actor = it.Next()) + { + TakeInventory(actor, type, STACK(1)); + } + } + sp -= 3; + } break; case PCD_TAKEINVENTORYDIRECT: diff --git a/src/p_map.cpp b/src/p_map.cpp index 88e002f8d2..26dc0d4d2c 100644 --- a/src/p_map.cpp +++ b/src/p_map.cpp @@ -2302,7 +2302,7 @@ bool P_CheckSlopeWalk (AActor *actor, fixed_t &xmove, fixed_t &ymove) { // Can't climb up slopes of ~45 degrees or more if (actor->flags & MF_NOCLIP) { - return true; + return (actor->floorsector == actor->Sector); } else { @@ -2338,7 +2338,7 @@ bool P_CheckSlopeWalk (AActor *actor, fixed_t &xmove, fixed_t &ymove) desty -= FixedMul (plane->b, t); xmove = destx - actor->x; ymove = desty - actor->y; - return true; + return (actor->floorsector == actor->Sector); } else if (t > 0) { // Desired location is in front of (above) the plane @@ -2349,7 +2349,7 @@ bool P_CheckSlopeWalk (AActor *actor, fixed_t &xmove, fixed_t &ymove) desty += FixedMul (plane->b, t); xmove = destx - actor->x; ymove = desty - actor->y; - return true;//(plane->c >= STEEPSLOPE); + return (actor->floorsector == actor->Sector);//(plane->c >= STEEPSLOPE); } } } diff --git a/src/r_sky.cpp b/src/r_sky.cpp index 05c8402992..51e991436e 100644 --- a/src/r_sky.cpp +++ b/src/r_sky.cpp @@ -97,6 +97,11 @@ void R_InitSkyMap () { skytexturemid = 199 * skytex1->yScale; skystretch = 0; + // At heights above 600 pixels, the sky is drawn slightly too low. + if (SCREENHEIGHT > 600) + { + skytexturemid += FRACUNIT; + } } skyheight = fskyheight << skystretch;