mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-14 05:38:56 +00:00
DM: Use nullptr
Using clang-tidy modernize-use-nullptr
This commit is contained in:
parent
02cfffcb67
commit
8c0f10e817
@ -35,7 +35,7 @@ namespace DM {
|
||||
|
||||
static const PlainGameDescriptor DMGames[] = {
|
||||
{"dm", "Dungeon Master"},
|
||||
{0, 0}
|
||||
{nullptr, nullptr}
|
||||
};
|
||||
|
||||
static const DMADGameDescription gameDescriptions[] = {
|
||||
|
@ -1478,7 +1478,7 @@ Thing DungeonMan::getDiscardThing(uint16 thingType) {
|
||||
} else {
|
||||
projExpl.projectileDeleteEvent(squareThing);
|
||||
unlinkThingFromList(squareThing, Thing(0), currMapX, currMapY);
|
||||
projExpl.projectileDelete(squareThing, 0, currMapX, currMapY);
|
||||
projExpl.projectileDelete(squareThing, nullptr, currMapX, currMapY);
|
||||
}
|
||||
break;
|
||||
case kDMThingTypeArmour:
|
||||
|
@ -844,7 +844,7 @@ void EventManager::processCommandQueue() {
|
||||
displMan.drawViewport(k2_viewportAsBeforeSleepOrFreezeGame);
|
||||
_vm->_waitForInputMaxVerticalBlankCount = 0;
|
||||
_primaryMouseInput = _primaryMouseInputPartySleeping;
|
||||
_secondaryMouseInput = 0;
|
||||
_secondaryMouseInput = nullptr;
|
||||
_primaryKeyboardInput = _primaryKeyboardInputPartySleeping;
|
||||
_secondaryKeyboardInput = nullptr;
|
||||
discardAllInput();
|
||||
@ -890,7 +890,7 @@ void EventManager::processCommandQueue() {
|
||||
primaryKeyboardInputBackup = _primaryKeyboardInput;
|
||||
secondaryKeyboardInputBackup = _secondaryKeyboardInput;
|
||||
_primaryMouseInput = _primaryMouseInputFrozenGame;
|
||||
_secondaryMouseInput = 0;
|
||||
_secondaryMouseInput = nullptr;
|
||||
_primaryKeyboardInput = _primaryKeyboardInputFrozenGame;
|
||||
_secondaryKeyboardInput = nullptr;
|
||||
discardAllInput();
|
||||
|
@ -3806,7 +3806,7 @@ T0115171_BackFromT0115015_DrawProjectileAsObject:;
|
||||
blitToBitmapShrinkWithPalChange(bitmapRedBanana, _tmpBitmap, 48, 32, 48, 32, _palChangeSmoke);
|
||||
bitmapRedBanana = _tmpBitmap;
|
||||
}
|
||||
blitBoxFilledWithMaskedBitmap(bitmapRedBanana, _bitmapViewport, 0, getDerivedBitmap(kDMDerivedBitmapViewport), boxExplosionPatternD0C, _vm->getRandomNumber(4) + 87, _vm->getRandomNumber(64), k112_byteWidthViewport, Color(k0x0080_BlitDoNotUseMask | kDMColorFlesh), 0, 0, 136, 93);
|
||||
blitBoxFilledWithMaskedBitmap(bitmapRedBanana, _bitmapViewport, nullptr, getDerivedBitmap(kDMDerivedBitmapViewport), boxExplosionPatternD0C, _vm->getRandomNumber(4) + 87, _vm->getRandomNumber(64), k112_byteWidthViewport, Color(k0x0080_BlitDoNotUseMask | kDMColorFlesh), 0, 0, 136, 93);
|
||||
addDerivedBitmap(kDMDerivedBitmapViewport);
|
||||
warning("DISABLED CODE: f480_releaseBlock in drawObjectsCreaturesProjectilesExplosions");
|
||||
//f480_releaseBlock(k0_DerivedBitmapViewport | 0x8000);
|
||||
@ -3876,7 +3876,7 @@ T0115200_DrawExplosion:
|
||||
}
|
||||
} while ((thingParam = dungeon.getNextThing(thingParam))!= _vm->_thingEndOfList);
|
||||
|
||||
if ((fluxcageExplosion != 0) && (doorFrontViewDrawingPass != 1) && !_doNotDrawFluxcagesDuringEndgame) { /* Fluxcage is an explosion displayed as a field (like teleporters), above all other graphics */
|
||||
if ((fluxcageExplosion != nullptr) && (doorFrontViewDrawingPass != 1) && !_doNotDrawFluxcagesDuringEndgame) { /* Fluxcage is an explosion displayed as a field (like teleporters), above all other graphics */
|
||||
AL_1_viewSquareExplosionIndex -= 3; /* Convert square index for explosions back to square index */
|
||||
FieldAspect fieldAspect = _fieldAspects188[viewSquareIndex];
|
||||
(fieldAspect._nativeBitmapRelativeIndex)++; /* NativeBitmapRelativeIndex is now the index of the Fluxcage field graphic */
|
||||
|
@ -377,7 +377,7 @@ void ProjExpl::projectileDelete(Thing projectileThing, Thing *groupSlot, int16 m
|
||||
Projectile *projectile = (Projectile *)_vm->_dungeonMan->getThingData(projectileThing);
|
||||
Thing projectileSlotThing = projectile->_slot;
|
||||
if (projectileSlotThing.getType() != kDMThingTypeExplosion) {
|
||||
if (groupSlot != NULL) {
|
||||
if (groupSlot != nullptr) {
|
||||
Thing previousThing = *groupSlot;
|
||||
if (previousThing == _vm->_thingEndOfList) {
|
||||
Thing *genericThing = (Thing *)_vm->_dungeonMan->getThingData(projectileSlotThing);
|
||||
@ -415,7 +415,7 @@ void ProjExpl::processEvents48To49(TimelineEvent *event) {
|
||||
uint16 stepEnergy = curEvent->_Cu._projectile.getStepEnergy();
|
||||
if (projectile->_kineticEnergy <= stepEnergy) {
|
||||
_vm->_dungeonMan->unlinkThingFromList(projectileThingNewCell = projectileThing, Thing(0), destinationMapX, destinationMapY);
|
||||
projectileDelete(projectileThingNewCell, NULL, destinationMapX, destinationMapY);
|
||||
projectileDelete(projectileThingNewCell, nullptr, destinationMapX, destinationMapY);
|
||||
return;
|
||||
}
|
||||
projectile->_kineticEnergy -= stepEnergy;
|
||||
|
Loading…
Reference in New Issue
Block a user