From 0631cfe894f53f5b835455b3995d4ea767bf4bfc Mon Sep 17 00:00:00 2001 From: Luke Street Date: Sat, 28 Feb 2026 15:59:24 -0700 Subject: [PATCH] Fix all -Wconversion-null warnings --- include/JSystem/J2DGraph/J2DAnimation.h | 2 +- include/d/d_stage.h | 50 +++++++++++------------ include/dolphin/types.h | 6 ++- include/revolution/types.h | 6 ++- src/DynamicLink.cpp | 2 +- src/JSystem/J2DGraph/J2DPictureEx.cpp | 2 +- src/JSystem/J3DGraphBase/J3DShape.cpp | 2 +- src/JSystem/JAudio2/JASSimpleWaveBank.cpp | 2 +- src/JSystem/JAudio2/JAUSectionHeap.cpp | 2 +- src/JSystem/JKernel/JKRAram.cpp | 2 +- src/JSystem/JKernel/JKRFileCache.cpp | 2 +- src/JSystem/JKernel/JKRThread.cpp | 2 +- src/JSystem/JParticle/JPAEmitter.cpp | 2 +- src/d/actor/d_a_alink.cpp | 2 +- src/d/actor/d_a_alink_horse.inc | 2 +- src/d/actor/d_a_alink_swim.inc | 2 +- src/d/actor/d_a_b_dr.cpp | 2 +- src/d/actor/d_a_door_shutter.cpp | 2 +- src/d/actor/d_a_e_yh.cpp | 2 +- src/d/actor/d_a_e_ym.cpp | 2 +- src/d/actor/d_a_kago.cpp | 4 +- src/d/actor/d_a_npc_blue_ns.cpp | 4 +- src/d/actor/d_a_npc_fairy.cpp | 6 +-- src/d/actor/d_a_npc_grm.cpp | 4 +- src/d/actor/d_a_npc_henna.cpp | 2 +- src/d/actor/d_a_npc_kasi_hana.cpp | 6 +-- src/d/actor/d_a_npc_kasi_kyu.cpp | 6 +-- src/d/actor/d_a_npc_kasi_mich.cpp | 6 +-- src/d/actor/d_a_npc_maro.cpp | 2 +- src/d/actor/d_a_npc_shad.cpp | 2 +- src/d/actor/d_a_npc_ykw.cpp | 2 +- src/d/actor/d_a_obj_batta.cpp | 2 +- src/d/actor/d_a_obj_bed.cpp | 2 +- src/d/actor/d_a_obj_bky_rock.cpp | 2 +- src/d/actor/d_a_obj_digholl.cpp | 4 +- src/d/actor/d_a_obj_lv3Water.cpp | 2 +- src/d/actor/d_a_obj_lv6ChangeGate.cpp | 4 +- src/d/actor/d_a_obj_prop.cpp | 2 +- src/d/actor/d_a_obj_rope_bridge.cpp | 2 +- src/d/actor/d_a_obj_sekizoa.cpp | 2 +- src/d/actor/d_a_obj_stone.cpp | 2 +- src/d/actor/d_a_obj_vground.cpp | 4 +- src/d/actor/d_a_shop_item.cpp | 2 +- src/d/actor/d_a_tag_allmato.cpp | 2 +- src/d/d_bg_w_kcol.cpp | 6 +-- src/d/d_cc_d.cpp | 2 +- src/d/d_event_manager.cpp | 2 +- src/d/d_menu_dmap.cpp | 2 +- src/d/d_menu_letter.cpp | 4 +- src/d/d_meter2_draw.cpp | 2 +- src/d/d_msg_scrn_staff.cpp | 2 +- src/d/d_s_logo.cpp | 2 +- src/d/d_s_name.cpp | 4 +- src/d/d_stage.cpp | 10 ++--- 54 files changed, 108 insertions(+), 100 deletions(-) diff --git a/include/JSystem/J2DGraph/J2DAnimation.h b/include/JSystem/J2DGraph/J2DAnimation.h index c1408a898d..76d8d06171 100644 --- a/include/JSystem/J2DGraph/J2DAnimation.h +++ b/include/JSystem/J2DGraph/J2DAnimation.h @@ -59,7 +59,7 @@ public: J2DAnmVtxColor() { mKind = KIND_VTX_COLOR; for (int i = 0; i < ARRAY_SIZE(mAnmTableNum); i++) { - mAnmTableNum[i] = NULL; + mAnmTableNum[i] = 0; } for (int i = 0; i < ARRAY_SIZE(mVtxColorIndexData); i++) { mVtxColorIndexData[i] = NULL; diff --git a/include/d/d_stage.h b/include/d/d_stage.h index 335d432c75..6f558f87c0 100644 --- a/include/d/d_stage.h +++ b/include/d/d_stage.h @@ -573,7 +573,7 @@ public: virtual roomRead_class* getRoom(void) const { OSReport("Room non room data !!\n"); JUT_ASSERT(2100, FALSE); - return NULL; + return 0; } virtual void setMapInfo(stage_map_info_class* i_MapInfo) { mMapInfo = i_MapInfo; } virtual stage_map_info_class* getMapInfo(void) const { return mMapInfo; } @@ -589,7 +589,7 @@ public: virtual stage_palette_info_class* getPaletteInfo(void) const { OSReport("Room non palet data !!\n"); JUT_ASSERT(2130, FALSE); - return NULL; + return 0; } virtual void setPselectInfo(stage_pselect_info_class* i_PselectInfo) { UNUSED(i_PselectInfo); @@ -600,7 +600,7 @@ public: virtual stage_pselect_info_class* getPselectInfo(void) const { OSReport("Room non pselect data !!\n"); JUT_ASSERT(2141, FALSE); - return NULL; + return 0; } virtual void setEnvrInfo(stage_envr_info_class* i_EnvrInfo) { UNUSED(i_EnvrInfo); @@ -611,7 +611,7 @@ public: virtual stage_envr_info_class* getEnvrInfo(void) const { OSReport("Room non envr data !!\n"); JUT_ASSERT(2152, FALSE); - return NULL; + return 0; } virtual void setVrboxInfo(stage_vrbox_info_class* i_VrboxInfo) { mVrboxInfo = i_VrboxInfo; } virtual stage_vrbox_info_class* getVrboxInfo(void) const { return mVrboxInfo; } @@ -626,7 +626,7 @@ public: virtual stage_plight_info_class* getPlightInfo(void) const { OSReport("Room non plight data !!\n"); JUT_ASSERT(2178, FALSE); - return NULL; + return 0; } virtual void setPaletteNumInfo(int i_PaletteNumInfo) { UNUSED(i_PaletteNumInfo); @@ -637,7 +637,7 @@ public: virtual int getPaletteNumInfo(void) const { OSReport("Room non palette num data !!\n"); JUT_ASSERT(2190, FALSE); - return NULL; + return 0; } virtual void setPselectNumInfo(int i_PselectNumInfo) { UNUSED(i_PselectNumInfo); @@ -648,7 +648,7 @@ public: virtual int getPselectNumInfo(void) const { OSReport("Room non pselect num data !!\n"); JUT_ASSERT(2201, FALSE); - return NULL; + return 0; } virtual void setEnvrNumInfo(int i_EnvrNumInfo) { UNUSED(i_EnvrNumInfo); @@ -659,7 +659,7 @@ public: virtual int getEnvrNumInfo(void) const { OSReport("Room non envr num data !!\n"); JUT_ASSERT(2212, FALSE); - return NULL; + return 0; } virtual void setVrboxNumInfo(int i_VrboxNumInfo) { mVrboxNumInfo = i_VrboxNumInfo; } virtual int getVrboxNumInfo(void) const { return mVrboxNumInfo; } @@ -674,7 +674,7 @@ public: virtual int getPlightNumInfo(void) const { OSReport("Room non plight num data !!\n"); JUT_ASSERT(2227, FALSE); - return NULL; + return 0; } virtual void setLightVecInfo(stage_pure_lightvec_info_class* i_LightVecInfo) { mLightVecInfo = i_LightVecInfo; } virtual stage_pure_lightvec_info_class* getLightVecInfo(void) const { return mLightVecInfo; } @@ -689,7 +689,7 @@ public: virtual stage_stag_info_class* getStagInfo(void) const { OSReport("Room non stag data !!\n"); JUT_ASSERT(2260, FALSE); - return NULL; + return 0; } virtual void setSclsInfo(stage_scls_info_dummy_class* i_SclsInfo) { mSclsInfo = i_SclsInfo; } virtual stage_scls_info_dummy_class* getSclsInfo(void) const { return mSclsInfo; } @@ -702,7 +702,7 @@ public: virtual dStage_dPnt_c* getPntInf(void) const { OSReport("Room non Pnts data !\n"); JUT_ASSERT(2285, FALSE); - return NULL; + return 0; } virtual void setPathInfo(dStage_dPath_c* i_PathInfo) { UNUSED(i_PathInfo); @@ -713,7 +713,7 @@ public: virtual dStage_dPath_c* getPathInf(void) const { OSReport("Room non Path data !\n"); JUT_ASSERT(2296, FALSE); - return NULL; + return 0; } virtual void setPnt2Info(dStage_dPnt_c* i_Pnt2Info) { mPnt2Info = i_Pnt2Info; } virtual dStage_dPnt_c* getPnt2Inf(void) const { return mPnt2Info; } @@ -739,7 +739,7 @@ public: virtual dStage_MemoryConfig_c* getMemoryConfig(void) const { OSReport("Room non memory config data!\n"); JUT_ASSERT(2423, FALSE); - return NULL; + return 0; } virtual void setMemoryMap(dStage_MemoryMap_c* i_MemoryMap) { UNUSED(i_MemoryMap); @@ -749,7 +749,7 @@ public: virtual dStage_MemoryMap_c* getMemoryMap(void) const { OSReport("Room non memory map data!\n"); JUT_ASSERT(2442, FALSE); - return NULL; + return 0; } virtual void setMulti(dStage_Multi_c* i_Multi) { UNUSED(i_Multi); @@ -759,7 +759,7 @@ public: virtual dStage_Multi_c* getMulti(void) const { OSReport("Room non multi data!\n"); JUT_ASSERT(2457, FALSE); - return NULL; + return 0; } virtual void setOldMulti(void) { OSReport("Room non old multi data!\n"); @@ -772,7 +772,7 @@ public: virtual dStage_Multi_c* getOldMulti(void) const { OSReport("Room non old multi data!\n"); JUT_ASSERT(2472, FALSE); - return NULL; + return 0; } virtual void setLbnk(dStage_Lbnk_c* i_Lbnk) { mLbnk = i_Lbnk; } virtual dStage_Lbnk_c* getLbnk(void) const { return mLbnk; } @@ -786,7 +786,7 @@ public: virtual dStage_DMap_c* getDMap(void) const { OS_REPORT("Room non DMap data\n"); JUT_ASSERT(2513, FALSE); - return NULL; + return 0; } virtual void setDrTg(stage_tgsc_class* i_DrTg) { mDrTg = i_DrTg; } virtual stage_tgsc_class* getDrTg(void) const { return mDrTg; } @@ -804,7 +804,7 @@ public: virtual void* getMapPath(void) { OSReport("stage non 2d map path data !!\n"); JUT_ASSERT(2561, FALSE); - return NULL; + return 0; } virtual void setElst(dStage_Elst_c* i_Elst) { UNUSED(i_Elst); @@ -815,7 +815,7 @@ public: virtual dStage_Elst_c* getElst(void) { dStage_SetErrorRoom(); OSReport("Room no Elst Data!!\n"); - return NULL; + return 0; } public: @@ -901,7 +901,7 @@ public: /* vt[43] */ virtual stage_pure_lightvec_info_class* getLightVecInfo(void) const { OSReport("stage non LightVec data !!\n"); JUT_ASSERT(3007, FALSE); - return NULL; + return 0; } /* vt[44] */ virtual void setLightVecInfoNum(int i_LightVecInfoNum) { UNUSED(i_LightVecInfoNum); @@ -912,7 +912,7 @@ public: /* vt[45] */ virtual int getLightVecInfoNum(void) const { OSReport("stage non LightVecNum data !!\n"); JUT_ASSERT(3018, FALSE); - return NULL; + return 0; } /* vt[40] */ virtual void setPlightNumInfo(int i_PlightNumInfo) { mPlightNumInfo = i_PlightNumInfo; } /* vt[41] */ virtual int getPlightNumInfo(void) const { return mPlightNumInfo; } @@ -943,7 +943,7 @@ public: /* vt[65] */ virtual dStage_FileList2_dt_c* getFileList2Info(void) const { OSReport("stage non filelist2 data!\n"); JUT_ASSERT(3127, FALSE); - return NULL; + return 0; } /* vt[66] */ virtual void setFileListInfo(dStage_FileList_dt_c* list) { UNUSED(list); @@ -954,7 +954,7 @@ public: /* vt[67] */ virtual dStage_FileList_dt_c* getFileListInfo(void) const { OSReport("stage non filelist data!\n"); JUT_ASSERT(3142, FALSE); - return NULL; + return 0; } /* vt[68] */ virtual void setFloorInfo(dStage_FloorInfo_c* i_FloorInfo) { mFloorInfo = i_FloorInfo; } /* vt[69] */ virtual dStage_FloorInfo_c* getFloorInfo(void) const { return mFloorInfo; } @@ -976,7 +976,7 @@ public: /* vt[80] */ virtual dStage_Lbnk_c* getLbnk(void) const { OSReport("stage non Lbnk data!\n"); JUT_ASSERT(3238, FALSE); - return NULL; + return 0; } /* vt[81] */ virtual void setTresure(stage_tresure_class* i_Tresure) { mTresure = i_Tresure; } /* vt[82] */ virtual stage_tresure_class* getTresure(void) const { return mTresure; } @@ -995,7 +995,7 @@ public: virtual void* getUnit() { OSReport("stage non unit list data !!\n"); JUT_ASSERT(3325, 0); - return NULL; + return 0; } #endif /* vt[89] */ virtual void setMapPath(void* i_MapPath) { return; } diff --git a/include/dolphin/types.h b/include/dolphin/types.h index 5044dabbb5..8c7620a057 100644 --- a/include/dolphin/types.h +++ b/include/dolphin/types.h @@ -87,8 +87,12 @@ typedef unsigned int uint; #endif #ifndef NULL -#ifdef __cplusplus +#ifdef __cplusplus +#if __cplusplus >= 201103L +#define NULL nullptr +#else #define NULL 0 +#endif #else #define NULL ((void*)0) #endif diff --git a/include/revolution/types.h b/include/revolution/types.h index 355768087e..7b559fd505 100644 --- a/include/revolution/types.h +++ b/include/revolution/types.h @@ -71,8 +71,12 @@ typedef unsigned int uint; #endif #ifndef NULL -#ifdef __cplusplus +#ifdef __cplusplus +#if __cplusplus >= 201103L +#define NULL nullptr +#else #define NULL 0 +#endif #else #define NULL ((void*)0) #endif diff --git a/src/DynamicLink.cpp b/src/DynamicLink.cpp index 0d0ad35374..d83a937e4d 100644 --- a/src/DynamicLink.cpp +++ b/src/DynamicLink.cpp @@ -224,7 +224,7 @@ bool DynamicModuleControl::do_load() { if (mModule == NULL) { snprintf(buffer, 64, "/rel/Final/Release/%s.rel", mName); mModule = (OSModuleHeader*)JKRDvdToMainRam( - buffer, NULL, EXPAND_SWITCH_UNKNOWN1, NULL, heap, + buffer, NULL, EXPAND_SWITCH_UNKNOWN1, 0, heap, JKRDvdRipper::ALLOC_DIRECTION_FORWARD, 0, NULL, NULL); if (mModule != NULL) { mSize = 0; diff --git a/src/JSystem/J2DGraph/J2DPictureEx.cpp b/src/JSystem/J2DGraph/J2DPictureEx.cpp index 27cc68cc94..bf2ea7168a 100644 --- a/src/JSystem/J2DGraph/J2DPictureEx.cpp +++ b/src/JSystem/J2DGraph/J2DPictureEx.cpp @@ -917,7 +917,7 @@ JUTTexture* J2DPictureEx::getTexture(u8 param_0) const { u8 J2DPictureEx::getTextureCount() const { if (mMaterial == NULL) { - return NULL; + return 0; } return mMaterial->getTexGenBlock()->getTexGenNum(); diff --git a/src/JSystem/J3DGraphBase/J3DShape.cpp b/src/JSystem/J3DGraphBase/J3DShape.cpp index 485d4bca4f..befdf34a90 100644 --- a/src/JSystem/J3DGraphBase/J3DShape.cpp +++ b/src/JSystem/J3DGraphBase/J3DShape.cpp @@ -227,7 +227,7 @@ void J3DShape::makeVtxArrayCmd() { if (array[i] != 0) GDSetArray((GXAttr)(i + GX_VA_POS), array[i], stride[i]); else - GDSetArrayRaw((GXAttr)(i + GX_VA_POS), NULL, stride[i]); + GDSetArrayRaw((GXAttr)(i + GX_VA_POS), 0, stride[i]); } } diff --git a/src/JSystem/JAudio2/JASSimpleWaveBank.cpp b/src/JSystem/JAudio2/JASSimpleWaveBank.cpp index 9bc0bbf31d..c599a0e857 100644 --- a/src/JSystem/JAudio2/JASSimpleWaveBank.cpp +++ b/src/JSystem/JAudio2/JASSimpleWaveBank.cpp @@ -42,7 +42,7 @@ JASWaveArc* JASSimpleWaveBank::getWaveArc(u32 no) { int JASSimpleWaveBank::TWaveHandle::getWavePtr() const { void* base = mHeap->getBase(); if (base == NULL) { - return NULL; + return 0; } return (intptr_t)base + mWaveInfo.field_0x08; } diff --git a/src/JSystem/JAudio2/JAUSectionHeap.cpp b/src/JSystem/JAudio2/JAUSectionHeap.cpp index 8a9bbf8277..eb1f211070 100644 --- a/src/JSystem/JAudio2/JAUSectionHeap.cpp +++ b/src/JSystem/JAudio2/JAUSectionHeap.cpp @@ -40,7 +40,7 @@ namespace { field_0x4 = stack_14.getNumFiles(); field_0x8 = new s32[field_0x4]; if (!field_0x8) { - field_0x4 = NULL; + field_0x4 = 0; return; } for (u32 i = 0; i < field_0x4; i++) { diff --git a/src/JSystem/JKernel/JKRAram.cpp b/src/JSystem/JKernel/JKRAram.cpp index a16a0ffb0b..bbc49ff7eb 100644 --- a/src/JSystem/JKernel/JKRAram.cpp +++ b/src/JSystem/JKernel/JKRAram.cpp @@ -69,7 +69,7 @@ JKRAram::JKRAram(u32 audio_buffer_size, u32 audio_graph_size, s32 priority) if (mAramMemorySize) { mAramMemoryPtr = ARAlloc(mAramMemorySize); } else { - mAramMemoryPtr = NULL; + mAramMemoryPtr = 0; } OS_REPORT("ARAM audio area %08x: %08x\n", mAudioMemoryPtr, mAudioMemorySize); diff --git a/src/JSystem/JKernel/JKRFileCache.cpp b/src/JSystem/JKernel/JKRFileCache.cpp index d0162d95e5..4579a9ee88 100644 --- a/src/JSystem/JKernel/JKRFileCache.cpp +++ b/src/JSystem/JKernel/JKRFileCache.cpp @@ -192,7 +192,7 @@ u32 JKRFileCache::readResource(void* dst, u32 dstLength, u32, const char* path) if (findFile(finalPath, path)) { return readResource(dst, dstLength, filePath); } - return NULL; + return 0; } void JKRFileCache::removeResourceAll(void) { diff --git a/src/JSystem/JKernel/JKRThread.cpp b/src/JSystem/JKernel/JKRThread.cpp index 918f1012fc..cb5055012a 100644 --- a/src/JSystem/JKernel/JKRThread.cpp +++ b/src/JSystem/JKernel/JKRThread.cpp @@ -73,7 +73,7 @@ void JKRThread::setCommon_mesgQueue(JKRHeap* heap, int message_count) { sThreadList.append(&mThreadListLink); mCurrentHeap = NULL; - mCurrentHeapError = NULL; + mCurrentHeapError = 0; } void JKRThread::setCommon_heapSpecified(JKRHeap* heap, u32 stack_size, int param_3) { diff --git a/src/JSystem/JParticle/JPAEmitter.cpp b/src/JSystem/JParticle/JPAEmitter.cpp index fb03d52640..5e7ccbc6dd 100644 --- a/src/JSystem/JParticle/JPAEmitter.cpp +++ b/src/JSystem/JParticle/JPAEmitter.cpp @@ -39,7 +39,7 @@ void JPABaseEmitter::init(JPAEmitterManager* param_0, JPAResource* param_1) { mGlobalPrmClr.r = mGlobalPrmClr.g = mGlobalPrmClr.b = mGlobalPrmClr.a = mGlobalEnvClr.r = mGlobalEnvClr.g = mGlobalEnvClr.b = mGlobalEnvClr.a = 0xff; param_1->getBsp()->getPrmClr(&mPrmClr); param_1->getBsp()->getEnvClr(&mEnvClr); - mpUserWork = NULL; + mpUserWork = 0; mScaleOut = 1.0f; mEmitCount = 0.0f; initStatus(0x30); diff --git a/src/d/actor/d_a_alink.cpp b/src/d/actor/d_a_alink.cpp index a2b5a11f6d..aed6026b10 100644 --- a/src/d/actor/d_a_alink.cpp +++ b/src/d/actor/d_a_alink.cpp @@ -12223,7 +12223,7 @@ BOOL daAlink_c::checkGroundSpecialMode() { return procScreamWaitInit(); } - return NULL; + return 0; } int daAlink_c::commonCheckNextAction(int param_0) { diff --git a/src/d/actor/d_a_alink_horse.inc b/src/d/actor/d_a_alink_horse.inc index a637ef42cb..e9ce673c98 100644 --- a/src/d/actor/d_a_alink_horse.inc +++ b/src/d/actor/d_a_alink_horse.inc @@ -339,7 +339,7 @@ void daAlink_c::setHorseStirrup() { if (field_0x2fab & 1) { mDoMtx_stack_c::copy(mpLinkModel->getAnmMtx(field_0x30bc)); mDoMtx_stack_c::transM(-2.0f, -11.0f, 1.5f); - mDoMtx_stack_c::ZXYrotM(NULL, -0x8000, 0x4000); + mDoMtx_stack_c::ZXYrotM(0, -0x8000, 0x4000); mDoMtx_copy(mDoMtx_stack_c::get(), horse->getLeftStirrupMtx()); } diff --git a/src/d/actor/d_a_alink_swim.inc b/src/d/actor/d_a_alink_swim.inc index 857a3693f6..aa7cd98350 100644 --- a/src/d/actor/d_a_alink_swim.inc +++ b/src/d/actor/d_a_alink_swim.inc @@ -346,7 +346,7 @@ int daAlink_c::checkNextActionSwim() { int daAlink_c::checkSwimAction(int param_0) { f32 var_f31; if (checkWolf()) { - if (getMoveBGActorName(mLinkAcch.m_gnd, NULL) == PROC_Obj_ITA) { + if (getMoveBGActorName(mLinkAcch.m_gnd, 0) == PROC_Obj_ITA) { var_f31 = 200.0f; } else { var_f31 = mpHIO->mWolf.mWlSwim.m.mStartHeight; diff --git a/src/d/actor/d_a_b_dr.cpp b/src/d/actor/d_a_b_dr.cpp index 609ba1e94d..0a9d6c7a9a 100644 --- a/src/d/actor/d_a_b_dr.cpp +++ b/src/d/actor/d_a_b_dr.cpp @@ -4083,7 +4083,7 @@ int daB_DR_c::create() { gravity = -3.0f; mSound.init(¤t.pos, &eyePos, 3, 1); - mColliderStts.Init(0x19, NULL, this); + mColliderStts.Init(0x19, 0, this); fopAcM_OnStatus(this, 0x4000); diff --git a/src/d/actor/d_a_door_shutter.cpp b/src/d/actor/d_a_door_shutter.cpp index 60bde824e6..66441fb197 100644 --- a/src/d/actor/d_a_door_shutter.cpp +++ b/src/d/actor/d_a_door_shutter.cpp @@ -306,7 +306,7 @@ int daDoor20_c::checkOpenMsgDoor(int* param_1) { *param_1 = 0; return 1; } - field_0x624.init(NULL, msgNo, NULL, NULL); + field_0x624.init(NULL, msgNo, 0, NULL); int rv = field_0x624.checkOpenDoor(this, param_1); dMsgObject_endFlowGroup(); return rv; diff --git a/src/d/actor/d_a_e_yh.cpp b/src/d/actor/d_a_e_yh.cpp index 871708c0f9..369b19b216 100644 --- a/src/d/actor/d_a_e_yh.cpp +++ b/src/d/actor/d_a_e_yh.cpp @@ -2008,7 +2008,7 @@ static int daE_YH_Execute(e_yh_class* i_this) { J3DModel* model = i_this->mpMorf->getModel(); model->setBaseTRMtx(mDoMtx_stack_c::get()); - i_this->mpMorf->play(NULL, dComIfGp_getReverb(fopAcM_GetRoomNo(a_this))); + i_this->mpMorf->play(0, dComIfGp_getReverb(fopAcM_GetRoomNo(a_this))); i_this->mBrk->play(); i_this->mpMorf->modelCalc(); diff --git a/src/d/actor/d_a_e_ym.cpp b/src/d/actor/d_a_e_ym.cpp index 1bcc56551d..38e63b4fa4 100644 --- a/src/d/actor/d_a_e_ym.cpp +++ b/src/d/actor/d_a_e_ym.cpp @@ -3147,7 +3147,7 @@ void daE_YM_c::action() { cXyz unused_vec(field_0x68c, field_0x68c, field_0x68c); cXyz my_pos = current.pos; setMidnaBindEffect(this, &mSound, &my_pos, &scale); - mpMorf->play(NULL, dComIfGp_getReverb(fopAcM_GetRoomNo(this))); + mpMorf->play(0, dComIfGp_getReverb(fopAcM_GetRoomNo(this))); mpBrk->play(); } diff --git a/src/d/actor/d_a_kago.cpp b/src/d/actor/d_a_kago.cpp index 6eb85ad6f7..c2d2d8b489 100644 --- a/src/d/actor/d_a_kago.cpp +++ b/src/d/actor/d_a_kago.cpp @@ -511,7 +511,7 @@ void daKago_c::demo_skip(int param_0) { switch (param_0) { case 0: field_0x748 = 2; - field_0x74c = NULL; + field_0x74c = 0; break; case 1: field_0x728 = 0; @@ -525,7 +525,7 @@ void daKago_c::demo_skip(int param_0) { /* dSv_event_flag_c::M_051 - Main Event - Shadow Kargorok (?) (Large) event complete (Horse grass appears in various places) */ dComIfGs_onEventBit(dSv_event_flag_c::saveBitLabels[84]); field_0x748 = 7; - field_0x74c = NULL; + field_0x74c = 0; break; case 4: setSceneChange(0); diff --git a/src/d/actor/d_a_npc_blue_ns.cpp b/src/d/actor/d_a_npc_blue_ns.cpp index 7492657fd4..220c64af3f 100644 --- a/src/d/actor/d_a_npc_blue_ns.cpp +++ b/src/d/actor/d_a_npc_blue_ns.cpp @@ -736,14 +736,14 @@ void daNpcBlueNS_c::playMotion() { int daNpcBlueNS_c::setAction(int (daNpcBlueNS_c::*i_action)(int)) { field_0xdc0 = 3; if (mAction != NULL) { - (this->*mAction)(NULL); + (this->*mAction)(0); } field_0xdc0 = 0; mAction = i_action; if (mAction != NULL) { - (this->*mAction)(NULL); + (this->*mAction)(0); } return 1; diff --git a/src/d/actor/d_a_npc_fairy.cpp b/src/d/actor/d_a_npc_fairy.cpp index 850c5baa7b..f579985d22 100644 --- a/src/d/actor/d_a_npc_fairy.cpp +++ b/src/d/actor/d_a_npc_fairy.cpp @@ -883,7 +883,7 @@ void daNpc_Fairy_c::srchActors() { BOOL daNpc_Fairy_c::evtTalk() { if (chkAction(&daNpc_Fairy_c::talk)) { - (this->*mAction)(NULL); + (this->*mAction)(0); } else { mPreItemNo = 0; @@ -952,7 +952,7 @@ void daNpc_Fairy_c::action() { } if (mAction) { - (this->*mAction)(NULL); + (this->*mAction)(0); } } @@ -1124,7 +1124,7 @@ BOOL daNpc_Fairy_c::setAction(actionFunc action, int param_2) { mMode = 0xFFFF; if (mAction) { - (this->*mAction)(NULL); + (this->*mAction)(0); } mMode = 0; diff --git a/src/d/actor/d_a_npc_grm.cpp b/src/d/actor/d_a_npc_grm.cpp index 819b40db8c..c530f869f9 100644 --- a/src/d/actor/d_a_npc_grm.cpp +++ b/src/d/actor/d_a_npc_grm.cpp @@ -448,8 +448,8 @@ BOOL daNpc_grM_c::evtProc() { int face_motion, motion; if (ctrlMsgAnm(&face_motion, &motion, this, field_0xe2d)) { if (field_0xe26) { - mFaceMotionSeqMngr.setNo(face_motion, -1.0f, TRUE, NULL); - mMotionSeqMngr.setNo(motion, -1.0f, TRUE, NULL); + mFaceMotionSeqMngr.setNo(face_motion, -1.0f, TRUE, 0); + mMotionSeqMngr.setNo(motion, -1.0f, TRUE, 0); } } else if (tmp != 0 && field_0xe26) { setAfterTalkMotion(); diff --git a/src/d/actor/d_a_npc_henna.cpp b/src/d/actor/d_a_npc_henna.cpp index 53f945e50b..0eef1094f7 100644 --- a/src/d/actor/d_a_npc_henna.cpp +++ b/src/d/actor/d_a_npc_henna.cpp @@ -277,7 +277,7 @@ static void message_shop(npc_henna_class* i_this) { i_this->field_0x750 = 1; } if (i_this->field_0x750 != 0) { - fopAcM_OffStatus(actor, NULL); + fopAcM_OffStatus(actor, 0); cLib_offBit(actor->attention_info.flags, fopAc_AttnFlag_SPEAK_e | fopAc_AttnFlag_TALK_e); } else { fopAcM_OnStatus(actor, 0); diff --git a/src/d/actor/d_a_npc_kasi_hana.cpp b/src/d/actor/d_a_npc_kasi_hana.cpp index 2d592ec85e..e9544a9a52 100644 --- a/src/d/actor/d_a_npc_kasi_hana.cpp +++ b/src/d/actor/d_a_npc_kasi_hana.cpp @@ -853,7 +853,7 @@ BOOL daNpcKasiHana_c::main() { } if (mAction) { - (this->*mAction)(NULL); + (this->*mAction)(0); } mKasiMng.sendInfo(); @@ -1072,14 +1072,14 @@ BOOL daNpcKasiHana_c::setAction(actionFunc action) { mMode = -1; if (mAction) { - (this->*mAction)(NULL); + (this->*mAction)(0); } mMode = 0; mAction = action; if (mAction) { - (this->*mAction)(NULL); + (this->*mAction)(0); } return TRUE; diff --git a/src/d/actor/d_a_npc_kasi_kyu.cpp b/src/d/actor/d_a_npc_kasi_kyu.cpp index 27c4a0b6ba..8f3f9464cf 100644 --- a/src/d/actor/d_a_npc_kasi_kyu.cpp +++ b/src/d/actor/d_a_npc_kasi_kyu.cpp @@ -400,7 +400,7 @@ BOOL daNpcKasiKyu_c::main() { } if (mAction) { - (this->*mAction)(NULL); + (this->*mAction)(0); } playMotion(); @@ -621,14 +621,14 @@ BOOL daNpcKasiKyu_c::setAction(actionFunc action) { mMode = -1; if (mAction) { - (this->*mAction)(NULL); + (this->*mAction)(0); } mMode = 0; mAction = action; if (mAction) { - (this->*mAction)(NULL); + (this->*mAction)(0); } return TRUE; diff --git a/src/d/actor/d_a_npc_kasi_mich.cpp b/src/d/actor/d_a_npc_kasi_mich.cpp index 4b3d7ca068..86e0632047 100644 --- a/src/d/actor/d_a_npc_kasi_mich.cpp +++ b/src/d/actor/d_a_npc_kasi_mich.cpp @@ -400,7 +400,7 @@ BOOL daNpcKasiMich_c::main() { } if (mAction) { - (this->*mAction)(NULL); + (this->*mAction)(0); } playMotion(); @@ -621,14 +621,14 @@ BOOL daNpcKasiMich_c::setAction(actionFunc action) { mMode = -1; if (mAction) { - (this->*mAction)(NULL); + (this->*mAction)(0); } mMode = 0; mAction = action; if (mAction) { - (this->*mAction)(NULL); + (this->*mAction)(0); } return TRUE; diff --git a/src/d/actor/d_a_npc_maro.cpp b/src/d/actor/d_a_npc_maro.cpp index 7682afd2b1..1bcf6892d8 100644 --- a/src/d/actor/d_a_npc_maro.cpp +++ b/src/d/actor/d_a_npc_maro.cpp @@ -386,7 +386,7 @@ int daNpc_Maro_c::Execute() { setSellItemMax(getMaxNumItem()); field_0xf60 = -1; setMasterType(2); - mShopCamAction.setCamDataIdx(NULL); + mShopCamAction.setCamDataIdx(0); mShopCamAction.setCamAction(NULL); field_0x1131 = 1; } diff --git a/src/d/actor/d_a_npc_shad.cpp b/src/d/actor/d_a_npc_shad.cpp index fcd4d7abc0..1665797d58 100644 --- a/src/d/actor/d_a_npc_shad.cpp +++ b/src/d/actor/d_a_npc_shad.cpp @@ -1485,7 +1485,7 @@ bool daNpcShad_c::talk(void* param_1) { if (strcmp(dComIfGp_getStartStageName(), "R_SP116") == 0 || mCurAngle.y == fopAcM_searchPlayerAngleY(this)) { if (talkProc(NULL, TRUE, NULL)) { mActorMngr[0].entry(daPy_getPlayerActorClass()); - itemNo = NULL; + itemNo = 0; eventID = mFlow.getEventId(&itemNo); OS_REPORT("会話終了時 イベントID=%d アイテムNo=%d\n", eventID, itemNo); // At the end of the conversation, Event ID=%d Item No=%d diff --git a/src/d/actor/d_a_npc_ykw.cpp b/src/d/actor/d_a_npc_ykw.cpp index 7aac0c1340..9c2c816d37 100644 --- a/src/d/actor/d_a_npc_ykw.cpp +++ b/src/d/actor/d_a_npc_ykw.cpp @@ -1822,7 +1822,7 @@ BOOL daNpc_ykW_c::cutLv5DungeonClear(int param_0) { itemPos.y += 50.0f; unkActor1 = fopAcM_fastCreateItem(&itemPos, 0, fopAcM_GetRoomNo(this), &unkSxyz, - &unkXyz1, &unkFloat2, &unkFloat3, -1, NULL, NULL); + &unkXyz1, &unkFloat2, &unkFloat3, -1, 0, NULL); if (unkActor1 != NULL) { mDoAud_seStart(Z2SE_OBJ_YO_HEART_S, &itemPos, 0, 0); fopAcM_OnStatus(unkActor1, fopAcM_STATUS_UNK_0x4000); diff --git a/src/d/actor/d_a_obj_batta.cpp b/src/d/actor/d_a_obj_batta.cpp index 23ce104482..eb187f1ac0 100644 --- a/src/d/actor/d_a_obj_batta.cpp +++ b/src/d/actor/d_a_obj_batta.cpp @@ -509,7 +509,7 @@ int daObjBATTA_c::execute() { action(); mBrk->play(); mBtk->play(); - mpMorf->play(NULL, dComIfGp_getReverb(fopAcM_GetRoomNo(this))); + mpMorf->play(0, dComIfGp_getReverb(fopAcM_GetRoomNo(this))); mtx_set(); if (field_0x9f0 == 0) { mSph.SetC(current.pos); diff --git a/src/d/actor/d_a_obj_bed.cpp b/src/d/actor/d_a_obj_bed.cpp index 37de863ca6..06c2eb71da 100644 --- a/src/d/actor/d_a_obj_bed.cpp +++ b/src/d/actor/d_a_obj_bed.cpp @@ -30,7 +30,7 @@ void daObj_Bed_HIO_c::genMessage(JORMContext* ctx) { } #endif -daObj_Bed_HIOParam const daObj_Bed_Param_c::m = {NULL, -3.0f, 1.0f, 600.0f}; +daObj_Bed_HIOParam const daObj_Bed_Param_c::m = {0, -3.0f, 1.0f, 600.0f}; daObj_Bed_c::~daObj_Bed_c() { if (mpCollider != NULL) { diff --git a/src/d/actor/d_a_obj_bky_rock.cpp b/src/d/actor/d_a_obj_bky_rock.cpp index d2918eeaeb..08fc622c8c 100644 --- a/src/d/actor/d_a_obj_bky_rock.cpp +++ b/src/d/actor/d_a_obj_bky_rock.cpp @@ -68,7 +68,7 @@ int daBkyRock_c::draw() { mModels[mMode], &tevStr); if (field_0x57a) { - dMdl_c* dMdl = dMdl_mng_c::entry(mModels[2]->getModelData(), NULL, current.roomNo); + dMdl_c* dMdl = dMdl_mng_c::entry(mModels[2]->getModelData(), 0, current.roomNo); if (dMdl != NULL) { _pieceData* piece = mPieces; for (int i = 0; i < 20; i++, piece++) { diff --git a/src/d/actor/d_a_obj_digholl.cpp b/src/d/actor/d_a_obj_digholl.cpp index 0e9aca1f7c..d9fa7f3528 100644 --- a/src/d/actor/d_a_obj_digholl.cpp +++ b/src/d/actor/d_a_obj_digholl.cpp @@ -74,9 +74,9 @@ int daObjDigholl_c::execute() { } if (player->current.pos.abs(current.pos) < 1000.0f) { - dComIfGp_particle_setSimple(0x70f, ¤t.pos, 0xff, g_whiteColor, g_whiteColor, NULL, + dComIfGp_particle_setSimple(0x70f, ¤t.pos, 0xff, g_whiteColor, g_whiteColor, 0, 0.0f); - dComIfGp_particle_setSimple(0x73d, ¤t.pos, 0xff, g_whiteColor, g_whiteColor, NULL, + dComIfGp_particle_setSimple(0x73d, ¤t.pos, 0xff, g_whiteColor, g_whiteColor, 0, 0.0f); } diff --git a/src/d/actor/d_a_obj_lv3Water.cpp b/src/d/actor/d_a_obj_lv3Water.cpp index 704f35dcf5..e9b17c3ad6 100644 --- a/src/d/actor/d_a_obj_lv3Water.cpp +++ b/src/d/actor/d_a_obj_lv3Water.cpp @@ -31,7 +31,7 @@ public: }; daLv3Water_HIO_c::daLv3Water_HIO_c() { - mLevelControlWaitFrames = NULL; + mLevelControlWaitFrames = 0; } #if DEBUG diff --git a/src/d/actor/d_a_obj_lv6ChangeGate.cpp b/src/d/actor/d_a_obj_lv6ChangeGate.cpp index a28b3dca48..da9f2efe23 100644 --- a/src/d/actor/d_a_obj_lv6ChangeGate.cpp +++ b/src/d/actor/d_a_obj_lv6ChangeGate.cpp @@ -127,7 +127,7 @@ int daLv6ChangeGate_c::Execute(Mtx** param_0) { for (int i = 0; i < 12; i++) { cXyz spC(cyl_x_offset + mMoveTransX, 0.0f, 0.0f); - mDoMtx_stack_c::ZXYrotS(NULL, shape_angle.y, shape_angle.z); + mDoMtx_stack_c::ZXYrotS(0, shape_angle.y, shape_angle.z); mDoMtx_stack_c::multVec(&spC, &spC); spC += current.pos; @@ -251,7 +251,7 @@ void daLv6ChangeGate_c::init_modeBreak() { void daLv6ChangeGate_c::modeBreak() { cXyz effpos(mMoveTransX, 0.0f, 0.0f); - mDoMtx_stack_c::ZXYrotS(NULL, shape_angle.y, shape_angle.z); + mDoMtx_stack_c::ZXYrotS(0, shape_angle.y, shape_angle.z); mDoMtx_stack_c::multVec(&effpos, &effpos); effpos += current.pos; diff --git a/src/d/actor/d_a_obj_prop.cpp b/src/d/actor/d_a_obj_prop.cpp index fc2b773538..273e03b5f1 100644 --- a/src/d/actor/d_a_obj_prop.cpp +++ b/src/d/actor/d_a_obj_prop.cpp @@ -53,7 +53,7 @@ int daObjProp_c::Delete() { } int daObjProp_c::draw() { - g_env_light.settingTevStruct(NULL, ¤t.pos, &tevStr); + g_env_light.settingTevStruct(0, ¤t.pos, &tevStr); g_env_light.setLightTevColorType_MAJI(mpModel, &tevStr); mDoExt_modelUpdate(mpModel); return 1; diff --git a/src/d/actor/d_a_obj_rope_bridge.cpp b/src/d/actor/d_a_obj_rope_bridge.cpp index 9c0874ccab..402ca74b46 100644 --- a/src/d/actor/d_a_obj_rope_bridge.cpp +++ b/src/d/actor/d_a_obj_rope_bridge.cpp @@ -16,7 +16,7 @@ static char* l_ropeArcName = "L_Ropest"; void daObjRBridge_c::initBaseMtx() { mDoMtx_stack_c::transS(current.pos); - mDoMtx_stack_c::ZXYrotM(NULL, current.angle.y, 0); + mDoMtx_stack_c::ZXYrotM(0, current.angle.y, 0); MTXCopy(mDoMtx_stack_c::get(), mMtx); mpBrgModel->setBaseScale(scale); diff --git a/src/d/actor/d_a_obj_sekizoa.cpp b/src/d/actor/d_a_obj_sekizoa.cpp index 1e2ff2ccbd..7165ff0929 100644 --- a/src/d/actor/d_a_obj_sekizoa.cpp +++ b/src/d/actor/d_a_obj_sekizoa.cpp @@ -736,7 +736,7 @@ void daObj_Sekizoa_c::setAttnPos() { mpMorf[1]->modelCalc(); } if (mpMcaMorf != NULL) { - ((mDoExt_McaMorfSO*)mpMcaMorf)->play(NULL, 0); + ((mDoExt_McaMorfSO*)mpMcaMorf)->play(0, 0); if (mType == TYPE_1 || mType == TYPE_3 || mType == TYPE_5) { mDoMtx_stack_c::copy(mpMorf[0]->getModel()->getAnmMtx(7)); } else { diff --git a/src/d/actor/d_a_obj_stone.cpp b/src/d/actor/d_a_obj_stone.cpp index c5ddc061b9..b8b1677513 100644 --- a/src/d/actor/d_a_obj_stone.cpp +++ b/src/d/actor/d_a_obj_stone.cpp @@ -807,7 +807,7 @@ void daObjStone_c::init_modeBreak() { JPABaseEmitter* emitter = dComIfGp_particle_set( 0x15c, ¤t.pos, 0, &acStack_40, 0xff, &dPa_modelEcallBack::getEcallback(), fopAcM_GetRoomNo(this), 0, 0, 0); dPa_modelEcallBack::setModel(emitter, stone_bmd, tevStr, - 3, 0, NULL, 0); + 3, 0, 0, 0); for (int i = 0; i < 3; i = i + 1) { dComIfGp_particle_set( l_eff_id[i], diff --git a/src/d/actor/d_a_obj_vground.cpp b/src/d/actor/d_a_obj_vground.cpp index 47dae42331..3af6e0c5e7 100644 --- a/src/d/actor/d_a_obj_vground.cpp +++ b/src/d/actor/d_a_obj_vground.cpp @@ -47,7 +47,7 @@ int daObjVGnd_c::CreateHeap() { J3DAnmTextureSRTKey* pbtk = (J3DAnmTextureSRTKey*)dComIfG_getObjectRes(l_arcName, 0xb); JUT_ASSERT(198, pbtk != NULL); mpBtk = new mDoExt_btkAnm(); - if ((!mpBtk) || (!mpBtk->init(modelData, pbtk, 1, NULL, 1.0f, NULL, -1))) { + if ((!mpBtk) || (!mpBtk->init(modelData, pbtk, 1, 0, 1.0f, 0, -1))) { return 0; } } @@ -56,7 +56,7 @@ int daObjVGnd_c::CreateHeap() { J3DAnmTevRegKey* pbrk = (J3DAnmTevRegKey*)dComIfG_getObjectRes(l_arcName, 0x8); JUT_ASSERT(212, pbrk != NULL); mpBrk = new mDoExt_brkAnm(); - if ((!mpBrk) || (!mpBrk->init(modelData, pbrk, 1, NULL, 1.0f, NULL, -1))) { + if ((!mpBrk) || (!mpBrk->init(modelData, pbrk, 1, 0, 1.0f, 0, -1))) { return 0; } } diff --git a/src/d/actor/d_a_shop_item.cpp b/src/d/actor/d_a_shop_item.cpp index 136d429b9a..09ef16cb70 100644 --- a/src/d/actor/d_a_shop_item.cpp +++ b/src/d/actor/d_a_shop_item.cpp @@ -128,7 +128,7 @@ void daShopItem_c::CreateInit() { home.pos = current.pos; set_mtx(); - mpModel->setUserArea(NULL); + mpModel->setUserArea(0); } void daShopItem_c::set_mtx() { diff --git a/src/d/actor/d_a_tag_allmato.cpp b/src/d/actor/d_a_tag_allmato.cpp index b1a4549e2c..2a2c94acfb 100644 --- a/src/d/actor/d_a_tag_allmato.cpp +++ b/src/d/actor/d_a_tag_allmato.cpp @@ -517,7 +517,7 @@ int daTag_AllMato_c::checkCrsMato2() { } fopAc_ac_c* sp18 = NULL; - int sp14 = NULL; + int sp14 = 0; for (int i = 0; i < 499; i++) { for (int j = 0; j < mBouMatoActorNum; j++) { diff --git a/src/d/d_bg_w_kcol.cpp b/src/d/d_bg_w_kcol.cpp index 834669d042..e7b5c76ebd 100644 --- a/src/d/d_bg_w_kcol.cpp +++ b/src/d/d_bg_w_kcol.cpp @@ -689,9 +689,9 @@ void dBgWKCol::ShdwDraw(cBgS_ShdwDraw* param_0) { do { stepY_sp78 = 1000000; - best1_sp70 = NULL; - best2_sp6C = NULL; - best3_sp68 = NULL; + best1_sp70 = 0; + best2_sp6C = 0; + best3_sp68 = 0; int x_sp44 = minX_spA0; do { diff --git a/src/d/d_cc_d.cpp b/src/d/d_cc_d.cpp index cf09711b3e..3c1acd7d5a 100644 --- a/src/d/d_cc_d.cpp +++ b/src/d/d_cc_d.cpp @@ -255,7 +255,7 @@ dCcD_GObjInf* dCcD_GObjInf::GetTgHitGObj() { u8 dCcD_GObjInf::GetTgHitObjSe() { dCcD_GObjInf* objInf = GetTgHitGObj(); if (objInf == NULL) { - return NULL; + return 0; } else { return objInf->GetAtSe(); } diff --git a/src/d/d_event_manager.cpp b/src/d/d_event_manager.cpp index 8b2291b124..84af0a5d51 100644 --- a/src/d/d_event_manager.cpp +++ b/src/d/d_event_manager.cpp @@ -1245,7 +1245,7 @@ void* dEvent_manager_c::getMySubstanceP(int staffId, const char* dataname, int d int dEvent_manager_c::getMySubstanceNum(int staffId, const char* dataname) { dEvDtData_c* data = getMyDataP(staffId, dataname, FALSE); if (data == NULL) { - return NULL; + return 0; } else { return data->getNumber(); } diff --git a/src/d/d_menu_dmap.cpp b/src/d/d_menu_dmap.cpp index f50c0f3c64..db7404534e 100644 --- a/src/d/d_menu_dmap.cpp +++ b/src/d/d_menu_dmap.cpp @@ -1728,7 +1728,7 @@ void dMenu_Dmap_c::_create() { screenInit(); - mpDrawBg->getMapPane()->changeTexture(mMapCtrl->getResTIMGPointer(0), NULL); + mpDrawBg->getMapPane()->changeTexture(mMapCtrl->getResTIMGPointer(0), 0); if (mpDrawBg->getMapPane()->append(mMapCtrl->getResTIMGPointer(1), 1.0f)) { mpDrawBg->getMapPane()->setBlendRatio(1.0f, 0.0f); diff --git a/src/d/d_menu_letter.cpp b/src/d/d_menu_letter.cpp index a9f27feb71..0ac02bdfac 100644 --- a/src/d/d_menu_letter.cpp +++ b/src/d/d_menu_letter.cpp @@ -492,7 +492,7 @@ void dMenu_Letter_c::read_open_init() { } J2DTextBox* text2 = (J2DTextBox*)field_0x2ec[i]->getPanePtr(); mpString->getStringPage(dMenu_Letter::getLetterText(idx), field_0x3e3 - 1, LINE_MAX, text2, text1, - NULL, NULL, NULL); + NULL, NULL, 0); } field_0x3e2 = mpString->getPageMax(LINE_MAX); if (field_0x3e2 > 1) { @@ -642,7 +642,7 @@ void dMenu_Letter_c::read_next_fadein_init() { text1 = (J2DTextBox*)field_0x2f4[i]->getPanePtr(); } J2DTextBox* text2 = (J2DTextBox*)field_0x2ec[i]->getPanePtr(); - mpString->getStringPage(dMenu_Letter::getLetterText(idx), field_0x3e3 - 1, LINE_MAX, text2, text1, NULL, NULL, NULL); + mpString->getStringPage(dMenu_Letter::getLetterText(idx), field_0x3e3 - 1, LINE_MAX, text2, text1, NULL, NULL, 0); } char acStack_30[10]; sprintf(acStack_30, "%d/%d", field_0x3e3, field_0x3e2); diff --git a/src/d/d_meter2_draw.cpp b/src/d/d_meter2_draw.cpp index 5d945fa5fc..302ef5e06a 100644 --- a/src/d/d_meter2_draw.cpp +++ b/src/d/d_meter2_draw.cpp @@ -1173,7 +1173,7 @@ void dMeter2Draw_c::initButton() { for (int i = 0; i < 2; i++) { for (int j = 0; j < 2; j++) { - field_0x524[i][j] = NULL; + field_0x524[i][j] = 0; } } diff --git a/src/d/d_msg_scrn_staff.cpp b/src/d/d_msg_scrn_staff.cpp index d0cd861250..1f92124146 100644 --- a/src/d/d_msg_scrn_staff.cpp +++ b/src/d/d_msg_scrn_staff.cpp @@ -30,7 +30,7 @@ dMsgScrnStaff_c::dMsgScrnStaff_c(u8 unused) { mpScreen->search(MULTI_CHAR('right_n'))->hide(); for (int i = 0; i < 6; i++) { - mpTm_c[i] = new CPaneMgr(mpScreen, t_tag[i], NULL, NULL); + mpTm_c[i] = new CPaneMgr(mpScreen, t_tag[i], 0, NULL); ((J2DTextBox*)mpTm_c[i]->getPanePtr())->setFont(mDoExt_getMesgFont()); ((J2DTextBox*)mpTm_c[i]->getPanePtr())->setString(0x200, ""); } diff --git a/src/d/d_s_logo.cpp b/src/d/d_s_logo.cpp index 0504084f32..a7821acfe4 100644 --- a/src/d/d_s_logo.cpp +++ b/src/d/d_s_logo.cpp @@ -974,5 +974,5 @@ scene_process_profile_definition g_profile_LOGO_SCENE = { 0, &g_fopScn_Method.base, &l_dScnLogo_Method, - NULL, + 0, }; diff --git a/src/d/d_s_name.cpp b/src/d/d_s_name.cpp index a59d7d2d06..4bdbfd21ac 100644 --- a/src/d/d_s_name.cpp +++ b/src/d/d_s_name.cpp @@ -339,7 +339,7 @@ scene_process_profile_definition g_profile_NAME_SCENE = { 0, &g_fopScn_Method.base, &l_dScnName_Method, - NULL, + 0, }; scene_process_profile_definition g_profile_NAMEEX_SCENE = { @@ -353,5 +353,5 @@ scene_process_profile_definition g_profile_NAMEEX_SCENE = { 0, &g_fopScn_Method.base, &l_dScnName_Method, - NULL, + 0, }; diff --git a/src/d/d_stage.cpp b/src/d/d_stage.cpp index 22e7b00c64..4fdbd71a44 100644 --- a/src/d/d_stage.cpp +++ b/src/d/d_stage.cpp @@ -2456,10 +2456,10 @@ static int dStage_elstInfoInit(dStage_dt_c* i_stage, void* i_data, int param_2, } static void dKankyo_create() { - fopKyM_fastCreate(PROC_KANKYO, NULL, NULL, NULL, NULL); - fopKyM_fastCreate(PROC_KYEFF, NULL, NULL, NULL, NULL); - fopKyM_fastCreate(PROC_KYEFF2, NULL, NULL, NULL, NULL); - fopKyM_fastCreate(PROC_ENVSE, NULL, NULL, NULL, NULL); + fopKyM_fastCreate(PROC_KANKYO, 0, NULL, NULL, NULL); + fopKyM_fastCreate(PROC_KYEFF, 0, NULL, NULL, NULL); + fopKyM_fastCreate(PROC_KYEFF2, 0, NULL, NULL, NULL); + fopKyM_fastCreate(PROC_ENVSE, 0, NULL, NULL, NULL); } static void layerMemoryInfoLoader(void* i_data, dStage_dt_c* i_stage, int param_2) { @@ -2710,7 +2710,7 @@ void dStage_Create() { JUT_ASSERT(4517, status); } - *dStage_roomControl_c::getDemoArcName() = NULL; + *dStage_roomControl_c::getDemoArcName() = 0; dKankyo_create(); if (dComIfG_getStageRes("vrbox_sora.bmd")) {