From 2ab9c02a42924b6bda4548db4e085dfa1e0b9e09 Mon Sep 17 00:00:00 2001 From: Randy Heit Date: Fri, 4 May 2012 02:56:28 +0000 Subject: [PATCH] - Use SetOrigin() instead of P_TryMove to set the dropped item's position in AActor::DropInventory(). Also removed dropdist, since it wasn't used. SVN r3620 (trunk) --- src/p_mobj.cpp | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/p_mobj.cpp b/src/p_mobj.cpp index a878bf571..c5f9bc51e 100644 --- a/src/p_mobj.cpp +++ b/src/p_mobj.cpp @@ -680,7 +680,6 @@ bool AActor::UseInventory (AInventory *item) AInventory *AActor::DropInventory (AInventory *item) { - fixed_t dropdist; angle_t an; AInventory *drop = item->CreateTossable (); @@ -689,12 +688,7 @@ AInventory *AActor::DropInventory (AInventory *item) return NULL; } an = angle >> ANGLETOFINESHIFT; - /* 92682 = sqrt(2) * FRACUNIT */ - dropdist = FixedMul (92682, radius + 8*FRACUNIT + item->radius); - drop->x = x; - drop->y = y; - drop->z = z + 10*FRACUNIT; - P_TryMove (drop, x, y, true); + drop->SetOrigin(x, y, z + 10*FRACUNIT); drop->angle = angle; drop->velx = velx + 5 * finecosine[an]; drop->vely = vely + 5 * finesine[an];