mirror of
https://github.com/1dot13/source.git
synced 2026-07-22 13:40:22 +02:00
- New Feature: The rosine system now allows to capture enemy soldeirs via using handcuffs on them. They can e transferred to a prison the player controls, and be interrogated there.
- GameDir revision 1568 is required for this feature. - Savegame compatibility is maintained. git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@5709 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -4142,6 +4142,24 @@ INT8 DrawUIMovementPath( SOLDIERTYPE *pSoldier, INT32 usMapPos, UINT32 uiFlags )
|
||||
gsUIHandleShowMoveGridLocation = sActionGridNo;
|
||||
}
|
||||
}
|
||||
else if ( uiFlags == MOVEUI_TARGET_HANDCUFF )
|
||||
{
|
||||
sActionGridNo = FindAdjacentGridEx( pSoldier, usMapPos, &ubDirection, NULL, FALSE, TRUE );
|
||||
if ( sActionGridNo == -1 )
|
||||
{
|
||||
sActionGridNo = usMapPos;
|
||||
}
|
||||
|
||||
sAPCost = GetAPsToHandcuff( pSoldier, sActionGridNo );
|
||||
|
||||
sAPCost += UIPlotPath( pSoldier, sActionGridNo, NO_COPYROUTE, fPlot, TEMPORARY, (UINT16)pSoldier->usUIMovementMode, NOT_STEALTH, FORWARD, pSoldier->bActionPoints);
|
||||
|
||||
if ( sActionGridNo != pSoldier->sGridNo )
|
||||
{
|
||||
gfUIHandleShowMoveGrid = TRUE;
|
||||
gsUIHandleShowMoveGridLocation = sActionGridNo;
|
||||
}
|
||||
}
|
||||
else if ( uiFlags == MOVEUI_TARGET_MERCS )
|
||||
{
|
||||
INT32 sGotLocation = NOWHERE;
|
||||
@@ -4494,6 +4512,21 @@ BOOLEAN UIMouseOnValidAttackLocation( SOLDIERTYPE *pSoldier )
|
||||
return( FALSE );
|
||||
}
|
||||
|
||||
if ( ubItemCursor == HANDCUFFCURS )
|
||||
{
|
||||
if ( HasItemFlag( (&(pSoldier->inv[HANDPOS]))->usItem, HANDCUFFS ) )
|
||||
{
|
||||
if ( gfUIFullTargetFound )
|
||||
{
|
||||
usMapPos = MercPtrs[ gusUIFullTargetID ]->sGridNo;
|
||||
|
||||
return( TRUE );
|
||||
}
|
||||
}
|
||||
|
||||
return( FALSE );
|
||||
}
|
||||
|
||||
if ( ubItemCursor == BOMBCURS )
|
||||
{
|
||||
if ( usMapPos == pSoldier->sGridNo )
|
||||
|
||||
Reference in New Issue
Block a user