Fixed beeing able to drop carryheavy in non-walk

floating-point
Bernhard Bonigl 2012-04-13 17:49:09 +02:00
parent fe261ffca0
commit 9a4295f745
2 changed files with 2 additions and 3 deletions

View File

@ -623,7 +623,7 @@ public func FxIntSearchInteractionObjectsTimer(object target, effect, int time)
}
// if carrying heavy, add drop-carry-heavy-button
if(target->~IsCarryingHeavy())
if(target->~IsCarryingHeavy() && target->GetAction() == "Walk")
ActionButton(target, i++, target->GetCarryHeavy(), ACTIONTYPE_CARRYHEAVY, hotkey++);
// add vehicles
@ -806,4 +806,3 @@ public func ReorderCrewSelectors(object leaveout)
j++;
}
}

View File

@ -855,7 +855,7 @@ public func ObjectControl(int plr, int ctrl, int x, int y, int strength, bool re
{
if(ObjectControlInteract(plr,ctrl))
return true;
else if(IsCarryingHeavy())
else if(IsCarryingHeavy() && GetAction() == "Walk")
{
GetCarryHeavy()->Drop();
return true;