diff --git a/makefile.gaz b/makefile.gaz index d4b47a9dc..ff6074768 100644 --- a/makefile.gaz +++ b/makefile.gaz @@ -128,7 +128,8 @@ platform_src := platform \ pbaloon \ ptrpdoor \ pconveyr \ - pplayer + pplayer \ + pcbubble hazard_src := hazard \ hfalling \ diff --git a/source/platform/pcbubble.h b/source/platform/pcbubble.h index bbd06557f..998b3cc1a 100644 --- a/source/platform/pcbubble.h +++ b/source/platform/pcbubble.h @@ -20,6 +20,19 @@ class CNpcCollapsingBubblePlatform : public CNpcPlatform { +public: + virtual void render(); + virtual void postInit(); +protected: + virtual void processLifetime( int _frames ); + virtual int checkCollisionAgainst(CThing *_thisThing, int _frames); + u8 m_pop; +}; + +class CNpcCollapsingAcridPlatform : public CNpcCollapsingBubblePlatform +{ +public: + virtual void render(); }; #endif \ No newline at end of file diff --git a/source/platform/platdata.cpp b/source/platform/platdata.cpp index 794dc91f0..619f3a9aa 100644 --- a/source/platform/platdata.cpp +++ b/source/platform/platdata.cpp @@ -454,6 +454,18 @@ CNpcPlatform::NPC_PLATFORM_DATA CNpcPlatform::m_data[NPC_PLATFORM_TYPE_MAX] = 0, NPC_PLATFORM_TIMER_NONE, }, + + { // NPC_COLLAPSING_ACRID_PLATFORM + 3, + 128, + true, + DAMAGE__NONE, + 0, + 2, + NPC_PLATFORM_INFINITE_LIFE_COLLAPSIBLE, + 0, + NPC_PLATFORM_TIMER_NONE, + }, }; CNpcPlatform::NPC_PLATFORM_UNIT_TYPE CNpcPlatform::mapEditConvertTable[NPC_PLATFORM_TYPE_MAX] = @@ -489,6 +501,7 @@ CNpcPlatform::NPC_PLATFORM_UNIT_TYPE CNpcPlatform::mapEditConvertTable[NPC_PLATF NPC_BALLOON_BRIDGE_PLATFORM, NPC_TRAPDOOR_PLATFORM, NPC_CONVEYOR_GENERATOR, + NPC_COLLAPSING_ACRID_PLATFORM, NPC_CONVEYOR_PLATFORM, NPC_PLAYER_BUBBLE_PLATFORM, NPC_CLAM_PLATFORM, diff --git a/source/platform/platform.cpp b/source/platform/platform.cpp index 70d8871e2..bd2376c0c 100644 --- a/source/platform/platform.cpp +++ b/source/platform/platform.cpp @@ -209,6 +209,12 @@ CNpcPlatform *CNpcPlatform::Create(int Type) break; } + case NPC_COLLAPSING_ACRID_PLATFORM: + { + platform = new ("collapsing bubble platform") CNpcCollapsingAcridPlatform; + break; + } + case NPC_FISH_HOOK_PLATFORM: { platform = new ("fish hook platform") CNpcFishHookPlatform; diff --git a/source/platform/platform.h b/source/platform/platform.h index b77810c40..fcb81c610 100644 --- a/source/platform/platform.h +++ b/source/platform/platform.h @@ -88,6 +88,7 @@ public: NPC_CONVEYOR_PLATFORM, NPC_PLAYER_BUBBLE_PLATFORM, NPC_CLAM_PLATFORM, + NPC_COLLAPSING_ACRID_PLATFORM, NPC_PLATFORM_TYPE_MAX, }; enum diff --git a/tools/Data/bin/MkLevel.ini b/tools/Data/bin/MkLevel.ini index 41cd7a008..246aa453e 100644 --- a/tools/Data/bin/MkLevel.ini +++ b/tools/Data/bin/MkLevel.ini @@ -118,7 +118,7 @@ TrapdoorRight=29 SinkingCrate=8 ConveyorCrateGenerator=30 DualGreenPlatform=16 -AcridBubble=4 +AcridBubble=31 LeafRaft=19 OilRigPlatform=1 diff --git a/users/paul/spongebob project/spongebob project.dsp b/users/paul/spongebob project/spongebob project.dsp index d277e58be..dda102e77 100644 --- a/users/paul/spongebob project/spongebob project.dsp +++ b/users/paul/spongebob project/spongebob project.dsp @@ -1317,6 +1317,10 @@ SOURCE=..\..\..\source\platform\pcart.h # End Source File # Begin Source File +SOURCE=..\..\..\source\platform\pcbubble.cpp +# End Source File +# Begin Source File + SOURCE=..\..\..\source\platform\pcbubble.h # End Source File # Begin Source File