Skip to content

Commit 9d7612c

Browse files
committed
[ZH] Remove unnecessary NULL pointer test in ..CrateCollide::executeCrateBehavior
1 parent 6026f2c commit 9d7612c

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

GeneralsMD/Code/GameEngine/Source/GameLogic/Object/Collide/CrateCollide/SabotageSupplyCenterCrateCollide.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ Bool SabotageSupplyCenterCrateCollide::executeCrateBehavior( Object *other )
149149
controller->getScoreKeeper()->addMoneyEarned( cash );
150150

151151
//Play the "cash stolen" EVA event if the local player is the victim!
152-
if( other && other->isLocallyControlled() )
152+
if( other->isLocallyControlled() )
153153
{
154154
TheEva->setShouldPlay( EVA_CashStolen );
155155
}

GeneralsMD/Code/GameEngine/Source/GameLogic/Object/Collide/CrateCollide/SabotageSupplyDropzoneCrateCollide.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ Bool SabotageSupplyDropzoneCrateCollide::executeCrateBehavior( Object *other )
159159
controller->getScoreKeeper()->addMoneyEarned( cash );
160160

161161
//Play the "cash stolen" EVA event if the local player is the victim!
162-
if( other && other->isLocallyControlled() )
162+
if( other->isLocallyControlled() )
163163
{
164164
TheEva->setShouldPlay( EVA_CashStolen );
165165
}

0 commit comments

Comments
 (0)