From 3a35fd1db8decf3deefaa561d84e7f01ec744f0d Mon Sep 17 00:00:00 2001 From: Berkeley <65060738+tariq-nasheed@users.noreply.github.com> Date: Fri, 12 Apr 2024 02:39:11 -0500 Subject: [PATCH] complete overhaul of directory structure --- CMakeLists.txt | 9 +- src/STRUCTURE | 4 + src/hypermania/All.c | 58 +++ src/hypermania/HyperManiaVariables.h | 4 +- src/hypermania/Mania/All.h | 351 +++++++++++++++++- src/hypermania/Mania/BSS/BSS_Setup.c | 3 - src/hypermania/Mania/BSS/BSS_Setup.h | 17 +- src/hypermania/Mania/CPZ/AmoebaDroid.h | 41 +- src/hypermania/Mania/CPZ/Bubbler.h | 27 +- src/hypermania/Mania/CPZ/CPZSetup.h | 17 +- src/hypermania/Mania/CPZ/CaterkillerJr.h | 22 +- src/hypermania/Mania/CPZ/Grabber.h | 22 +- src/hypermania/Mania/CPZ/Spiny.h | 27 +- .../Mania/Common/CollapsingPlatform.c | 3 - .../Mania/Common/CollapsingPlatform.h | 17 +- src/hypermania/Mania/Cutscene/FXFade.c | 5 - src/hypermania/Mania/Cutscene/FXFade.h | 22 +- src/hypermania/Mania/ERZ/ERZStart.h | 17 +- src/hypermania/Mania/ERZ/PhantomEgg.h | 46 +-- src/hypermania/Mania/ERZ/PhantomMystic.h | 29 +- src/hypermania/Mania/ERZ/PhantomShinobi.h | 35 +- src/hypermania/Mania/FBZ/BigSqueeze.h | 29 +- src/hypermania/Mania/FBZ/Blaster.h | 29 +- src/hypermania/Mania/FBZ/Clucker.h | 28 +- src/hypermania/Mania/FBZ/FBZTrash.h | 25 +- src/hypermania/Mania/FBZ/Technosqueek.h | 22 +- src/hypermania/Mania/FarPlane.h | 31 -- src/hypermania/Mania/GHZ/Batbrain.h | 22 +- src/hypermania/Mania/GHZ/BuzzBomber.h | 29 +- src/hypermania/Mania/GHZ/Chopper.h | 25 +- src/hypermania/Mania/GHZ/Crabmeat.h | 25 +- src/hypermania/Mania/GHZ/DDWrecker.h | 31 +- src/hypermania/Mania/GHZ/DERobot.h | 31 +- src/hypermania/Mania/GHZ/Motobug.h | 25 +- src/hypermania/Mania/GHZ/Newtron.h | 29 +- src/hypermania/Mania/GHZ/Splats.h | 33 +- src/hypermania/Mania/Global/Animals.h | 17 +- src/hypermania/Mania/Global/Camera.h | 24 +- src/hypermania/Mania/Global/Debris.h | 16 + src/hypermania/Mania/Global/Explosion.h | 17 +- src/hypermania/Mania/Global/HUD.h | 65 ++++ src/hypermania/Mania/Global/ImageTrail.h | 30 ++ src/hypermania/Mania/Global/InvincibleStars.h | 17 +- src/hypermania/Mania/Global/ItemBox.h | 20 +- src/hypermania/Mania/Global/Music.h | 29 +- src/hypermania/Mania/Global/PauseMenu.h | 20 +- src/hypermania/Mania/{ => Global}/Player.h | 17 +- src/hypermania/Mania/Global/Ring.h | 33 +- src/hypermania/Mania/Global/SaveGame.h | 14 +- src/hypermania/Mania/Global/ScoreBonus.h | 15 +- src/hypermania/Mania/Global/SpecialRing.h | 28 ++ src/hypermania/Mania/Global/Zone.h | 20 +- src/hypermania/Mania/HCZ/Blastoid.h | 25 +- src/hypermania/Mania/HCZ/Buggernaut.h | 22 +- src/hypermania/Mania/HCZ/HCZSetup.h | 17 +- src/hypermania/Mania/HCZ/Jawz.h | 25 +- src/hypermania/Mania/HCZ/Jellygnite.h | 25 +- src/hypermania/Mania/HCZ/LaundroMobile.h | 44 +-- src/hypermania/Mania/HCZ/MegaChopper.h | 27 +- src/hypermania/Mania/HCZ/Pointdexter.h | 22 +- src/hypermania/Mania/HCZ/TurboSpiker.h | 27 +- src/hypermania/Mania/LRZ/Drillerdroid.h | 45 +-- src/hypermania/Mania/LRZ/DrillerdroidO.h | 49 +-- src/hypermania/Mania/LRZ/Fireworm.h | 25 +- src/hypermania/Mania/LRZ/HPZEmerald.h | 23 ++ src/hypermania/Mania/LRZ/HeavyKing.h | 49 +-- src/hypermania/Mania/LRZ/HeavyRider.h | 29 +- src/hypermania/Mania/LRZ/Rexon.h | 31 +- src/hypermania/Mania/LRZ/RockDrill.h | 25 +- src/hypermania/Mania/LRZ/Toxomister.h | 25 +- src/hypermania/Mania/MMZ/EggPistonsMKII.h | 31 +- src/hypermania/Mania/MMZ/FarPlane.h | 43 ++- src/hypermania/Mania/MMZ/Gachapandora.h | 33 +- src/hypermania/Mania/MMZ/MechaBu.h | 29 +- src/hypermania/Mania/MMZ/PlaneSeeSaw.h | 18 + src/hypermania/Mania/MMZ/PohBee.h | 22 +- src/hypermania/Mania/MMZ/Scarab.h | 25 +- src/hypermania/Mania/MSZ/Armadiloid.h | 24 +- src/hypermania/Mania/MSZ/Bumpalo.h | 22 +- src/hypermania/Mania/MSZ/Cactula.h | 22 +- src/hypermania/Mania/MSZ/DBTower.h | 27 +- src/hypermania/Mania/MSZ/Hatterkiller.h | 22 +- src/hypermania/Mania/MSZ/HeavyMystic.h | 50 +-- src/hypermania/Mania/MSZ/Rattlekiller.h | 22 +- src/hypermania/Mania/MSZ/RollerMKII.h | 27 +- src/hypermania/Mania/MSZ/UberCaterkiller.h | 31 +- src/hypermania/Mania/MSZ/Vultron.h | 22 +- .../{Objects => Mania/Menu}/LevelSelect.h | 29 +- src/hypermania/Mania/Menu/UISaveSlot.h | 68 ++++ src/hypermania/Mania/OOZ/Aquis.h | 25 +- src/hypermania/Mania/OOZ/MegaOctus.h | 44 +-- src/hypermania/Mania/OOZ/MeterDroid.h | 35 +- src/hypermania/Mania/OOZ/OOZSetup.h | 17 +- src/hypermania/Mania/OOZ/Octus.h | 25 +- src/hypermania/Mania/OOZ/Sol.h | 31 +- src/hypermania/Mania/PGZ/Dragonfly.h | 25 +- src/hypermania/Mania/PGZ/HeavyShinobi.h | 32 +- src/hypermania/Mania/PGZ/IceBomba.h | 29 +- src/hypermania/Mania/PGZ/JuggleSaw.h | 27 +- src/hypermania/Mania/PGZ/Shiversaw.h | 31 +- src/hypermania/Mania/PGZ/Woodrow.h | 29 +- src/hypermania/Mania/SPZ/Canista.h | 27 +- src/hypermania/Mania/SPZ/MicDrop.h | 22 +- src/hypermania/Mania/SPZ/Shutterbug.h | 22 +- src/hypermania/Mania/SPZ/Tubinaut.h | 25 +- src/hypermania/Mania/SPZ/WeatherMobile.h | 33 +- src/hypermania/Mania/SSZ/Dango.h | 37 +- src/hypermania/Mania/SSZ/GigaMetal.h | 31 +- src/hypermania/Mania/SSZ/Hotaru.h | 22 +- src/hypermania/Mania/SSZ/HotaruHiWatt.h | 55 +-- src/hypermania/Mania/SSZ/HotaruMKII.h | 27 +- src/hypermania/Mania/SSZ/Kabasira.h | 25 +- src/hypermania/Mania/SSZ/Kanabun.h | 22 +- src/hypermania/Mania/SSZ/MetalSonic.h | 34 +- src/hypermania/Mania/TMZ/BallHog.h | 25 +- src/hypermania/Mania/TMZ/CrimsonEye.h | 31 +- src/hypermania/Mania/TMZ/FlasherMKII.h | 22 +- src/hypermania/Mania/TMZ/SentryBug.h | 35 +- src/hypermania/Mania/TMZ/TurboTurtle.h | 22 +- src/hypermania/Mania/UFO/SpecialClear.h | 79 ++++ src/hypermania/Mania/UFO/UFO_Player.h | 56 +++ src/hypermania/Mania/UFO/UFO_Setup.h | 33 ++ src/hypermania/ModFunctions.h | 32 +- src/hypermania/Objects/All.c | 64 ---- src/hypermania/Objects/Debris.h | 36 -- src/hypermania/Objects/Enemy.c | 85 ----- src/hypermania/Objects/Enemy.h | 176 --------- src/hypermania/Objects/HPZ/HPZEmerald.h | 36 -- src/hypermania/Objects/HUD.h | 82 ---- src/hypermania/Objects/PlaneSeeSaw.h | 35 -- src/hypermania/Objects/UFO_Player.h | 69 ---- src/hypermania/Objects/UFO_Setup.h | 65 ---- src/hypermania/dllmain.c | 64 +--- src/hypermania/link/All.h | 22 ++ src/hypermania/link/BSS/BSS_Setup.c | 3 + src/hypermania/link/BSS/BSS_Setup.h | 3 + .../{Mania => link}/CPZ/AmoebaDroid.c | 0 src/hypermania/link/CPZ/AmoebaDroid.h | 27 ++ src/hypermania/{Mania => link}/CPZ/Bubbler.c | 0 src/hypermania/link/CPZ/Bubbler.h | 13 + src/hypermania/{Mania => link}/CPZ/CPZSetup.c | 0 src/hypermania/link/CPZ/CPZSetup.h | 3 + .../{Mania => link}/CPZ/CaterkillerJr.c | 0 src/hypermania/link/CPZ/CaterkillerJr.h | 8 + src/hypermania/{Mania => link}/CPZ/Grabber.c | 0 src/hypermania/link/CPZ/Grabber.h | 8 + src/hypermania/{Mania => link}/CPZ/Spiny.c | 0 src/hypermania/link/CPZ/Spiny.h | 13 + .../link/Common/CollapsingPlatform.c | 3 + .../link/Common/CollapsingPlatform.h | 3 + src/hypermania/link/Cutscene/FXFade.c | 5 + src/hypermania/link/Cutscene/FXFade.h | 5 + src/hypermania/{Mania => link}/ERZ/ERZStart.c | 0 src/hypermania/link/ERZ/ERZStart.h | 3 + .../{Mania => link}/ERZ/PhantomEgg.c | 0 src/hypermania/link/ERZ/PhantomEgg.h | 23 ++ .../{Mania => link}/ERZ/PhantomMystic.c | 0 src/hypermania/link/ERZ/PhantomMystic.h | 15 + .../{Mania => link}/ERZ/PhantomShinobi.c | 0 src/hypermania/link/ERZ/PhantomShinobi.h | 21 ++ src/hypermania/link/Enemy.c | 85 +++++ src/hypermania/link/Enemy.h | 174 +++++++++ .../{Mania => link}/FBZ/BigSqueeze.c | 0 src/hypermania/link/FBZ/BigSqueeze.h | 15 + src/hypermania/{Mania => link}/FBZ/Blaster.c | 0 src/hypermania/link/FBZ/Blaster.h | 15 + src/hypermania/{Mania => link}/FBZ/Clucker.c | 0 src/hypermania/link/FBZ/Clucker.h | 13 + src/hypermania/{Mania => link}/FBZ/FBZTrash.c | 0 src/hypermania/link/FBZ/FBZTrash.h | 11 + .../{Mania => link}/FBZ/Technosqueek.c | 0 src/hypermania/link/FBZ/Technosqueek.h | 8 + src/hypermania/{Mania => link}/GHZ/Batbrain.c | 0 src/hypermania/link/GHZ/Batbrain.h | 11 + .../{Mania => link}/GHZ/BuzzBomber.c | 0 src/hypermania/link/GHZ/BuzzBomber.h | 18 + src/hypermania/{Mania => link}/GHZ/Chopper.c | 0 src/hypermania/link/GHZ/Chopper.h | 14 + src/hypermania/{Mania => link}/GHZ/Crabmeat.c | 0 src/hypermania/link/GHZ/Crabmeat.h | 14 + .../{Mania => link}/GHZ/DDWrecker.c | 0 src/hypermania/link/GHZ/DDWrecker.h | 17 + src/hypermania/{Mania => link}/GHZ/DERobot.c | 0 src/hypermania/link/GHZ/DERobot.h | 17 + src/hypermania/{Mania => link}/GHZ/Motobug.c | 0 src/hypermania/link/GHZ/Motobug.h | 14 + src/hypermania/{Mania => link}/GHZ/Newtron.c | 0 src/hypermania/link/GHZ/Newtron.h | 15 + src/hypermania/{Mania => link}/GHZ/Splats.c | 0 src/hypermania/link/GHZ/Splats.h | 19 + .../{Mania => link}/Global/Animals.c | 0 src/hypermania/link/Global/Animals.h | 3 + .../{Mania => link}/Global/Camera.c | 0 src/hypermania/link/Global/Camera.h | 10 + .../{Mania => link}/Global/Explosion.c | 0 src/hypermania/link/Global/Explosion.h | 3 + .../{Mania => link}/Global/InvincibleStars.c | 0 src/hypermania/link/Global/InvincibleStars.h | 3 + .../{Mania => link}/Global/ItemBox.c | 2 +- src/hypermania/link/Global/ItemBox.h | 8 + src/hypermania/{Mania => link}/Global/Music.c | 0 src/hypermania/link/Global/Music.h | 15 + .../{Mania => link}/Global/PauseMenu.c | 0 src/hypermania/link/Global/PauseMenu.h | 6 + src/hypermania/{Mania => link}/Global/Ring.c | 0 src/hypermania/link/Global/Ring.h | 18 + .../{Mania => link}/Global/SaveGame.c | 0 src/hypermania/link/Global/SaveGame.h | 10 + .../{Mania => link}/Global/ScoreBonus.c | 0 src/hypermania/link/Global/ScoreBonus.h | 3 + src/hypermania/{Mania => link}/Global/Zone.c | 0 src/hypermania/link/Global/Zone.h | 6 + src/hypermania/{Mania => link}/HCZ/Blastoid.c | 0 src/hypermania/link/HCZ/Blastoid.h | 11 + .../{Mania => link}/HCZ/Buggernaut.c | 0 src/hypermania/link/HCZ/Buggernaut.h | 8 + src/hypermania/{Mania => link}/HCZ/HCZSetup.c | 0 src/hypermania/link/HCZ/HCZSetup.h | 3 + src/hypermania/{Mania => link}/HCZ/Jawz.c | 0 src/hypermania/link/HCZ/Jawz.h | 11 + .../{Mania => link}/HCZ/Jellygnite.c | 0 src/hypermania/link/HCZ/Jellygnite.h | 11 + .../{Mania => link}/HCZ/LaundroMobile.c | 0 src/hypermania/link/HCZ/LaundroMobile.h | 21 ++ .../{Mania => link}/HCZ/MegaChopper.c | 0 src/hypermania/link/HCZ/MegaChopper.h | 13 + .../{Mania => link}/HCZ/Pointdexter.c | 0 src/hypermania/link/HCZ/Pointdexter.h | 8 + .../{Mania => link}/HCZ/TurboSpiker.c | 0 src/hypermania/link/HCZ/TurboSpiker.h | 13 + .../{Mania => link}/LRZ/Drillerdroid.c | 0 src/hypermania/link/LRZ/Drillerdroid.h | 31 ++ .../{Mania => link}/LRZ/DrillerdroidO.c | 0 src/hypermania/link/LRZ/DrillerdroidO.h | 35 ++ src/hypermania/{Mania => link}/LRZ/Fireworm.c | 0 src/hypermania/link/LRZ/Fireworm.h | 11 + .../{Mania => link}/LRZ/HeavyKing.c | 0 src/hypermania/link/LRZ/HeavyKing.h | 15 + .../{Mania => link}/LRZ/HeavyRider.c | 0 src/hypermania/link/LRZ/HeavyRider.h | 35 ++ src/hypermania/{Mania => link}/LRZ/Rexon.c | 0 src/hypermania/link/LRZ/Rexon.h | 17 + .../{Mania => link}/LRZ/RockDrill.c | 0 src/hypermania/link/LRZ/RockDrill.h | 11 + .../{Mania => link}/LRZ/Toxomister.c | 0 src/hypermania/link/LRZ/Toxomister.h | 9 + .../{Mania => link}/MMZ/EggPistonsMKII.c | 0 src/hypermania/link/MMZ/EggPistonsMKII.h | 17 + src/hypermania/{Mania => link}/MMZ/FarPlane.c | 4 - src/hypermania/link/MMZ/FarPlane.h | 16 + .../{Mania => link}/MMZ/Gachapandora.c | 0 src/hypermania/link/MMZ/Gachapandora.h | 19 + src/hypermania/{Mania => link}/MMZ/MechaBu.c | 0 src/hypermania/link/MMZ/MechaBu.h | 15 + src/hypermania/{Mania => link}/MMZ/PohBee.c | 0 src/hypermania/link/MMZ/PohBee.h | 8 + src/hypermania/{Mania => link}/MMZ/Scarab.c | 0 src/hypermania/link/MMZ/Scarab.h | 11 + .../{Mania => link}/MSZ/Armadiloid.c | 0 src/hypermania/link/MSZ/Armadiloid.h | 10 + src/hypermania/{Mania => link}/MSZ/Bumpalo.c | 0 src/hypermania/link/MSZ/Bumpalo.h | 8 + src/hypermania/{Mania => link}/MSZ/Cactula.c | 0 src/hypermania/link/MSZ/Cactula.h | 8 + src/hypermania/{Mania => link}/MSZ/DBTower.c | 0 src/hypermania/link/MSZ/DBTower.h | 13 + .../{Mania => link}/MSZ/Hatterkiller.c | 0 src/hypermania/link/MSZ/Hatterkiller.h | 8 + .../{Mania => link}/MSZ/HeavyMystic.c | 0 src/hypermania/link/MSZ/HeavyMystic.h | 36 ++ .../{Mania => link}/MSZ/Rattlekiller.c | 0 src/hypermania/link/MSZ/Rattlekiller.h | 8 + .../{Mania => link}/MSZ/RollerMKII.c | 0 src/hypermania/link/MSZ/RollerMKII.h | 13 + .../{Mania => link}/MSZ/UberCaterkiller.c | 0 src/hypermania/link/MSZ/UberCaterkiller.h | 17 + src/hypermania/{Mania => link}/MSZ/Vultron.c | 0 src/hypermania/link/MSZ/Vultron.h | 8 + src/hypermania/{Mania => link}/OOZ/Aquis.c | 0 src/hypermania/link/OOZ/Aquis.h | 11 + .../{Mania => link}/OOZ/MegaOctus.c | 0 src/hypermania/link/OOZ/MegaOctus.h | 30 ++ .../{Mania => link}/OOZ/MeterDroid.c | 0 src/hypermania/link/OOZ/MeterDroid.h | 21 ++ src/hypermania/{Mania => link}/OOZ/OOZSetup.c | 0 src/hypermania/link/OOZ/OOZSetup.h | 3 + src/hypermania/{Mania => link}/OOZ/Octus.c | 0 src/hypermania/link/OOZ/Octus.h | 11 + src/hypermania/{Mania => link}/OOZ/Sol.c | 0 src/hypermania/link/OOZ/Sol.h | 17 + .../{Mania => link}/PGZ/Dragonfly.c | 0 src/hypermania/link/PGZ/Dragonfly.h | 11 + .../{Mania => link}/PGZ/HeavyShinobi.c | 0 src/hypermania/link/PGZ/HeavyShinobi.h | 18 + src/hypermania/{Mania => link}/PGZ/IceBomba.c | 0 src/hypermania/link/PGZ/IceBomba.h | 15 + .../{Mania => link}/PGZ/JuggleSaw.c | 0 src/hypermania/link/PGZ/JuggleSaw.h | 13 + .../{Mania => link}/PGZ/Shiversaw.c | 0 src/hypermania/link/PGZ/Shiversaw.h | 17 + src/hypermania/{Mania => link}/PGZ/Woodrow.c | 0 src/hypermania/link/PGZ/Woodrow.h | 15 + src/hypermania/{Mania => link}/SPZ/Canista.c | 0 src/hypermania/link/SPZ/Canista.h | 13 + src/hypermania/{Mania => link}/SPZ/MicDrop.c | 0 src/hypermania/link/SPZ/MicDrop.h | 8 + .../{Mania => link}/SPZ/Shutterbug.c | 0 src/hypermania/link/SPZ/Shutterbug.h | 8 + src/hypermania/{Mania => link}/SPZ/Tubinaut.c | 0 src/hypermania/link/SPZ/Tubinaut.h | 11 + .../{Mania => link}/SPZ/WeatherMobile.c | 0 src/hypermania/link/SPZ/WeatherMobile.h | 19 + src/hypermania/{Mania => link}/SSZ/Dango.c | 0 src/hypermania/link/SSZ/Dango.h | 23 ++ .../{Mania => link}/SSZ/GigaMetal.c | 0 src/hypermania/link/SSZ/GigaMetal.h | 18 + src/hypermania/{Mania => link}/SSZ/Hotaru.c | 0 src/hypermania/link/SSZ/Hotaru.h | 8 + .../{Mania => link}/SSZ/HotaruHiWatt.c | 0 src/hypermania/link/SSZ/HotaruHiWatt.h | 41 ++ .../{Mania => link}/SSZ/HotaruMKII.c | 0 src/hypermania/link/SSZ/HotaruMKII.h | 13 + src/hypermania/{Mania => link}/SSZ/Kabasira.c | 0 src/hypermania/link/SSZ/Kabasira.h | 11 + src/hypermania/{Mania => link}/SSZ/Kanabun.c | 0 src/hypermania/link/SSZ/Kanabun.h | 8 + .../{Mania => link}/SSZ/MetalSonic.c | 0 src/hypermania/link/SSZ/MetalSonic.h | 20 + src/hypermania/{Mania => link}/TMZ/BallHog.c | 0 src/hypermania/link/TMZ/BallHog.h | 11 + .../{Mania => link}/TMZ/CrimsonEye.c | 0 src/hypermania/link/TMZ/CrimsonEye.h | 17 + .../{Mania => link}/TMZ/FlasherMKII.c | 0 src/hypermania/link/TMZ/FlasherMKII.h | 8 + .../{Mania => link}/TMZ/SentryBug.c | 0 src/hypermania/link/TMZ/SentryBug.h | 21 ++ .../{Mania => link}/TMZ/TurboTurtle.c | 0 src/hypermania/link/TMZ/TurboTurtle.h | 8 + src/hypermania/mod/All.h | 32 ++ .../{Objects => mod/Global}/Debris.c | 0 src/hypermania/mod/Global/Debris.h | 11 + src/hypermania/{Objects => mod/Global}/HUD.c | 0 src/hypermania/mod/Global/HUD.h | 13 + .../{Objects => mod/Global}/ImageTrail.c | 2 - .../{Objects => mod/Global}/ImageTrail.h | 38 +- .../{Objects => mod/Global}/Player.c | 16 - .../{Objects => mod/Global}/Player.h | 6 +- .../{Objects => mod/Global}/SpecialRing.c | 2 - .../{Objects => mod/Global}/SpecialRing.h | 34 +- .../{Objects/HPZ => mod/LRZ}/HPZEmerald.c | 2 +- src/hypermania/mod/LRZ/HPZEmerald.h | 9 + .../{Objects => mod/MMZ}/PlaneSeeSaw.c | 1 - src/hypermania/mod/MMZ/PlaneSeeSaw.h | 11 + .../{Objects => mod/Menu}/LevelSelect.c | 0 src/hypermania/mod/Menu/LevelSelect.h | 15 + .../{Objects => mod/Menu}/UISaveSlot.c | 0 .../{Objects => mod/Menu}/UISaveSlot.h | 74 +--- .../{Objects => mod/UFO}/SpecialClear.c | 0 .../{Objects => mod/UFO}/SpecialClear.h | 85 +---- .../{Objects => mod/UFO}/UFO_Player.c | 0 src/hypermania/mod/UFO/UFO_Player.h | 9 + .../{Objects => mod/UFO}/UFO_Setup.c | 3 - src/hypermania/mod/UFO/UFO_Setup.h | 28 ++ src/hypermania/new/All.h | 8 + .../{Objects => new/Global}/HyperStars.c | 2 - .../{Objects => new/Global}/HyperStars.h | 9 +- .../{Objects => new/Global}/JetGlideEffect.c | 0 .../{Objects => new/Global}/JetGlideEffect.h | 9 +- .../{Objects => new/Global}/SuperFlicky.c | 8 - .../{Objects => new/Global}/SuperFlicky.h | 7 +- src/hypermania/{Objects => new}/HPZ/HPZBeam.c | 2 - src/hypermania/{Objects => new}/HPZ/HPZBeam.h | 9 +- .../{Objects => new}/HPZ/HPZIntro.c | 2 - .../{Objects => new}/HPZ/HPZIntro.h | 9 +- .../{Objects => new}/HPZ/HPZSetup.c | 1 - .../{Objects => new}/HPZ/HPZSetup.h | 7 +- 376 files changed, 3181 insertions(+), 3391 deletions(-) create mode 100644 src/STRUCTURE create mode 100644 src/hypermania/All.c delete mode 100644 src/hypermania/Mania/BSS/BSS_Setup.c delete mode 100644 src/hypermania/Mania/Common/CollapsingPlatform.c delete mode 100644 src/hypermania/Mania/Cutscene/FXFade.c delete mode 100644 src/hypermania/Mania/FarPlane.h create mode 100644 src/hypermania/Mania/Global/Debris.h create mode 100644 src/hypermania/Mania/Global/HUD.h create mode 100644 src/hypermania/Mania/Global/ImageTrail.h rename src/hypermania/Mania/{ => Global}/Player.h (99%) create mode 100644 src/hypermania/Mania/Global/SpecialRing.h create mode 100644 src/hypermania/Mania/LRZ/HPZEmerald.h create mode 100644 src/hypermania/Mania/MMZ/PlaneSeeSaw.h rename src/hypermania/{Objects => Mania/Menu}/LevelSelect.h (72%) create mode 100644 src/hypermania/Mania/Menu/UISaveSlot.h create mode 100644 src/hypermania/Mania/UFO/SpecialClear.h create mode 100644 src/hypermania/Mania/UFO/UFO_Player.h create mode 100644 src/hypermania/Mania/UFO/UFO_Setup.h delete mode 100644 src/hypermania/Objects/All.c delete mode 100644 src/hypermania/Objects/Debris.h delete mode 100644 src/hypermania/Objects/Enemy.c delete mode 100644 src/hypermania/Objects/Enemy.h delete mode 100644 src/hypermania/Objects/HPZ/HPZEmerald.h delete mode 100644 src/hypermania/Objects/HUD.h delete mode 100644 src/hypermania/Objects/PlaneSeeSaw.h delete mode 100644 src/hypermania/Objects/UFO_Player.h delete mode 100644 src/hypermania/Objects/UFO_Setup.h create mode 100644 src/hypermania/link/All.h create mode 100644 src/hypermania/link/BSS/BSS_Setup.c create mode 100644 src/hypermania/link/BSS/BSS_Setup.h rename src/hypermania/{Mania => link}/CPZ/AmoebaDroid.c (100%) create mode 100644 src/hypermania/link/CPZ/AmoebaDroid.h rename src/hypermania/{Mania => link}/CPZ/Bubbler.c (100%) create mode 100644 src/hypermania/link/CPZ/Bubbler.h rename src/hypermania/{Mania => link}/CPZ/CPZSetup.c (100%) create mode 100644 src/hypermania/link/CPZ/CPZSetup.h rename src/hypermania/{Mania => link}/CPZ/CaterkillerJr.c (100%) create mode 100644 src/hypermania/link/CPZ/CaterkillerJr.h rename src/hypermania/{Mania => link}/CPZ/Grabber.c (100%) create mode 100644 src/hypermania/link/CPZ/Grabber.h rename src/hypermania/{Mania => link}/CPZ/Spiny.c (100%) create mode 100644 src/hypermania/link/CPZ/Spiny.h create mode 100644 src/hypermania/link/Common/CollapsingPlatform.c create mode 100644 src/hypermania/link/Common/CollapsingPlatform.h create mode 100644 src/hypermania/link/Cutscene/FXFade.c create mode 100644 src/hypermania/link/Cutscene/FXFade.h rename src/hypermania/{Mania => link}/ERZ/ERZStart.c (100%) create mode 100644 src/hypermania/link/ERZ/ERZStart.h rename src/hypermania/{Mania => link}/ERZ/PhantomEgg.c (100%) create mode 100644 src/hypermania/link/ERZ/PhantomEgg.h rename src/hypermania/{Mania => link}/ERZ/PhantomMystic.c (100%) create mode 100644 src/hypermania/link/ERZ/PhantomMystic.h rename src/hypermania/{Mania => link}/ERZ/PhantomShinobi.c (100%) create mode 100644 src/hypermania/link/ERZ/PhantomShinobi.h create mode 100644 src/hypermania/link/Enemy.c create mode 100644 src/hypermania/link/Enemy.h rename src/hypermania/{Mania => link}/FBZ/BigSqueeze.c (100%) create mode 100644 src/hypermania/link/FBZ/BigSqueeze.h rename src/hypermania/{Mania => link}/FBZ/Blaster.c (100%) create mode 100644 src/hypermania/link/FBZ/Blaster.h rename src/hypermania/{Mania => link}/FBZ/Clucker.c (100%) create mode 100644 src/hypermania/link/FBZ/Clucker.h rename src/hypermania/{Mania => link}/FBZ/FBZTrash.c (100%) create mode 100644 src/hypermania/link/FBZ/FBZTrash.h rename src/hypermania/{Mania => link}/FBZ/Technosqueek.c (100%) create mode 100644 src/hypermania/link/FBZ/Technosqueek.h rename src/hypermania/{Mania => link}/GHZ/Batbrain.c (100%) create mode 100644 src/hypermania/link/GHZ/Batbrain.h rename src/hypermania/{Mania => link}/GHZ/BuzzBomber.c (100%) create mode 100644 src/hypermania/link/GHZ/BuzzBomber.h rename src/hypermania/{Mania => link}/GHZ/Chopper.c (100%) create mode 100644 src/hypermania/link/GHZ/Chopper.h rename src/hypermania/{Mania => link}/GHZ/Crabmeat.c (100%) create mode 100644 src/hypermania/link/GHZ/Crabmeat.h rename src/hypermania/{Mania => link}/GHZ/DDWrecker.c (100%) create mode 100644 src/hypermania/link/GHZ/DDWrecker.h rename src/hypermania/{Mania => link}/GHZ/DERobot.c (100%) create mode 100644 src/hypermania/link/GHZ/DERobot.h rename src/hypermania/{Mania => link}/GHZ/Motobug.c (100%) create mode 100644 src/hypermania/link/GHZ/Motobug.h rename src/hypermania/{Mania => link}/GHZ/Newtron.c (100%) create mode 100644 src/hypermania/link/GHZ/Newtron.h rename src/hypermania/{Mania => link}/GHZ/Splats.c (100%) create mode 100644 src/hypermania/link/GHZ/Splats.h rename src/hypermania/{Mania => link}/Global/Animals.c (100%) create mode 100644 src/hypermania/link/Global/Animals.h rename src/hypermania/{Mania => link}/Global/Camera.c (100%) create mode 100644 src/hypermania/link/Global/Camera.h rename src/hypermania/{Mania => link}/Global/Explosion.c (100%) create mode 100644 src/hypermania/link/Global/Explosion.h rename src/hypermania/{Mania => link}/Global/InvincibleStars.c (100%) create mode 100644 src/hypermania/link/Global/InvincibleStars.h rename src/hypermania/{Mania => link}/Global/ItemBox.c (54%) create mode 100644 src/hypermania/link/Global/ItemBox.h rename src/hypermania/{Mania => link}/Global/Music.c (100%) create mode 100644 src/hypermania/link/Global/Music.h rename src/hypermania/{Mania => link}/Global/PauseMenu.c (100%) create mode 100644 src/hypermania/link/Global/PauseMenu.h rename src/hypermania/{Mania => link}/Global/Ring.c (100%) create mode 100644 src/hypermania/link/Global/Ring.h rename src/hypermania/{Mania => link}/Global/SaveGame.c (100%) create mode 100644 src/hypermania/link/Global/SaveGame.h rename src/hypermania/{Mania => link}/Global/ScoreBonus.c (100%) create mode 100644 src/hypermania/link/Global/ScoreBonus.h rename src/hypermania/{Mania => link}/Global/Zone.c (100%) create mode 100644 src/hypermania/link/Global/Zone.h rename src/hypermania/{Mania => link}/HCZ/Blastoid.c (100%) create mode 100644 src/hypermania/link/HCZ/Blastoid.h rename src/hypermania/{Mania => link}/HCZ/Buggernaut.c (100%) create mode 100644 src/hypermania/link/HCZ/Buggernaut.h rename src/hypermania/{Mania => link}/HCZ/HCZSetup.c (100%) create mode 100644 src/hypermania/link/HCZ/HCZSetup.h rename src/hypermania/{Mania => link}/HCZ/Jawz.c (100%) create mode 100644 src/hypermania/link/HCZ/Jawz.h rename src/hypermania/{Mania => link}/HCZ/Jellygnite.c (100%) create mode 100644 src/hypermania/link/HCZ/Jellygnite.h rename src/hypermania/{Mania => link}/HCZ/LaundroMobile.c (100%) create mode 100644 src/hypermania/link/HCZ/LaundroMobile.h rename src/hypermania/{Mania => link}/HCZ/MegaChopper.c (100%) create mode 100644 src/hypermania/link/HCZ/MegaChopper.h rename src/hypermania/{Mania => link}/HCZ/Pointdexter.c (100%) create mode 100644 src/hypermania/link/HCZ/Pointdexter.h rename src/hypermania/{Mania => link}/HCZ/TurboSpiker.c (100%) create mode 100644 src/hypermania/link/HCZ/TurboSpiker.h rename src/hypermania/{Mania => link}/LRZ/Drillerdroid.c (100%) create mode 100644 src/hypermania/link/LRZ/Drillerdroid.h rename src/hypermania/{Mania => link}/LRZ/DrillerdroidO.c (100%) create mode 100644 src/hypermania/link/LRZ/DrillerdroidO.h rename src/hypermania/{Mania => link}/LRZ/Fireworm.c (100%) create mode 100644 src/hypermania/link/LRZ/Fireworm.h rename src/hypermania/{Mania => link}/LRZ/HeavyKing.c (100%) create mode 100644 src/hypermania/link/LRZ/HeavyKing.h rename src/hypermania/{Mania => link}/LRZ/HeavyRider.c (100%) create mode 100644 src/hypermania/link/LRZ/HeavyRider.h rename src/hypermania/{Mania => link}/LRZ/Rexon.c (100%) create mode 100644 src/hypermania/link/LRZ/Rexon.h rename src/hypermania/{Mania => link}/LRZ/RockDrill.c (100%) create mode 100644 src/hypermania/link/LRZ/RockDrill.h rename src/hypermania/{Mania => link}/LRZ/Toxomister.c (100%) create mode 100644 src/hypermania/link/LRZ/Toxomister.h rename src/hypermania/{Mania => link}/MMZ/EggPistonsMKII.c (100%) create mode 100644 src/hypermania/link/MMZ/EggPistonsMKII.h rename src/hypermania/{Mania => link}/MMZ/FarPlane.c (98%) create mode 100644 src/hypermania/link/MMZ/FarPlane.h rename src/hypermania/{Mania => link}/MMZ/Gachapandora.c (100%) create mode 100644 src/hypermania/link/MMZ/Gachapandora.h rename src/hypermania/{Mania => link}/MMZ/MechaBu.c (100%) create mode 100644 src/hypermania/link/MMZ/MechaBu.h rename src/hypermania/{Mania => link}/MMZ/PohBee.c (100%) create mode 100644 src/hypermania/link/MMZ/PohBee.h rename src/hypermania/{Mania => link}/MMZ/Scarab.c (100%) create mode 100644 src/hypermania/link/MMZ/Scarab.h rename src/hypermania/{Mania => link}/MSZ/Armadiloid.c (100%) create mode 100644 src/hypermania/link/MSZ/Armadiloid.h rename src/hypermania/{Mania => link}/MSZ/Bumpalo.c (100%) create mode 100644 src/hypermania/link/MSZ/Bumpalo.h rename src/hypermania/{Mania => link}/MSZ/Cactula.c (100%) create mode 100644 src/hypermania/link/MSZ/Cactula.h rename src/hypermania/{Mania => link}/MSZ/DBTower.c (100%) create mode 100644 src/hypermania/link/MSZ/DBTower.h rename src/hypermania/{Mania => link}/MSZ/Hatterkiller.c (100%) create mode 100644 src/hypermania/link/MSZ/Hatterkiller.h rename src/hypermania/{Mania => link}/MSZ/HeavyMystic.c (100%) create mode 100644 src/hypermania/link/MSZ/HeavyMystic.h rename src/hypermania/{Mania => link}/MSZ/Rattlekiller.c (100%) create mode 100644 src/hypermania/link/MSZ/Rattlekiller.h rename src/hypermania/{Mania => link}/MSZ/RollerMKII.c (100%) create mode 100644 src/hypermania/link/MSZ/RollerMKII.h rename src/hypermania/{Mania => link}/MSZ/UberCaterkiller.c (100%) create mode 100644 src/hypermania/link/MSZ/UberCaterkiller.h rename src/hypermania/{Mania => link}/MSZ/Vultron.c (100%) create mode 100644 src/hypermania/link/MSZ/Vultron.h rename src/hypermania/{Mania => link}/OOZ/Aquis.c (100%) create mode 100644 src/hypermania/link/OOZ/Aquis.h rename src/hypermania/{Mania => link}/OOZ/MegaOctus.c (100%) create mode 100644 src/hypermania/link/OOZ/MegaOctus.h rename src/hypermania/{Mania => link}/OOZ/MeterDroid.c (100%) create mode 100644 src/hypermania/link/OOZ/MeterDroid.h rename src/hypermania/{Mania => link}/OOZ/OOZSetup.c (100%) create mode 100644 src/hypermania/link/OOZ/OOZSetup.h rename src/hypermania/{Mania => link}/OOZ/Octus.c (100%) create mode 100644 src/hypermania/link/OOZ/Octus.h rename src/hypermania/{Mania => link}/OOZ/Sol.c (100%) create mode 100644 src/hypermania/link/OOZ/Sol.h rename src/hypermania/{Mania => link}/PGZ/Dragonfly.c (100%) create mode 100644 src/hypermania/link/PGZ/Dragonfly.h rename src/hypermania/{Mania => link}/PGZ/HeavyShinobi.c (100%) create mode 100644 src/hypermania/link/PGZ/HeavyShinobi.h rename src/hypermania/{Mania => link}/PGZ/IceBomba.c (100%) create mode 100644 src/hypermania/link/PGZ/IceBomba.h rename src/hypermania/{Mania => link}/PGZ/JuggleSaw.c (100%) create mode 100644 src/hypermania/link/PGZ/JuggleSaw.h rename src/hypermania/{Mania => link}/PGZ/Shiversaw.c (100%) create mode 100644 src/hypermania/link/PGZ/Shiversaw.h rename src/hypermania/{Mania => link}/PGZ/Woodrow.c (100%) create mode 100644 src/hypermania/link/PGZ/Woodrow.h rename src/hypermania/{Mania => link}/SPZ/Canista.c (100%) create mode 100644 src/hypermania/link/SPZ/Canista.h rename src/hypermania/{Mania => link}/SPZ/MicDrop.c (100%) create mode 100644 src/hypermania/link/SPZ/MicDrop.h rename src/hypermania/{Mania => link}/SPZ/Shutterbug.c (100%) create mode 100644 src/hypermania/link/SPZ/Shutterbug.h rename src/hypermania/{Mania => link}/SPZ/Tubinaut.c (100%) create mode 100644 src/hypermania/link/SPZ/Tubinaut.h rename src/hypermania/{Mania => link}/SPZ/WeatherMobile.c (100%) create mode 100644 src/hypermania/link/SPZ/WeatherMobile.h rename src/hypermania/{Mania => link}/SSZ/Dango.c (100%) create mode 100644 src/hypermania/link/SSZ/Dango.h rename src/hypermania/{Mania => link}/SSZ/GigaMetal.c (100%) create mode 100644 src/hypermania/link/SSZ/GigaMetal.h rename src/hypermania/{Mania => link}/SSZ/Hotaru.c (100%) create mode 100644 src/hypermania/link/SSZ/Hotaru.h rename src/hypermania/{Mania => link}/SSZ/HotaruHiWatt.c (100%) create mode 100644 src/hypermania/link/SSZ/HotaruHiWatt.h rename src/hypermania/{Mania => link}/SSZ/HotaruMKII.c (100%) create mode 100644 src/hypermania/link/SSZ/HotaruMKII.h rename src/hypermania/{Mania => link}/SSZ/Kabasira.c (100%) create mode 100644 src/hypermania/link/SSZ/Kabasira.h rename src/hypermania/{Mania => link}/SSZ/Kanabun.c (100%) create mode 100644 src/hypermania/link/SSZ/Kanabun.h rename src/hypermania/{Mania => link}/SSZ/MetalSonic.c (100%) create mode 100644 src/hypermania/link/SSZ/MetalSonic.h rename src/hypermania/{Mania => link}/TMZ/BallHog.c (100%) create mode 100644 src/hypermania/link/TMZ/BallHog.h rename src/hypermania/{Mania => link}/TMZ/CrimsonEye.c (100%) create mode 100644 src/hypermania/link/TMZ/CrimsonEye.h rename src/hypermania/{Mania => link}/TMZ/FlasherMKII.c (100%) create mode 100644 src/hypermania/link/TMZ/FlasherMKII.h rename src/hypermania/{Mania => link}/TMZ/SentryBug.c (100%) create mode 100644 src/hypermania/link/TMZ/SentryBug.h rename src/hypermania/{Mania => link}/TMZ/TurboTurtle.c (100%) create mode 100644 src/hypermania/link/TMZ/TurboTurtle.h create mode 100644 src/hypermania/mod/All.h rename src/hypermania/{Objects => mod/Global}/Debris.c (100%) create mode 100644 src/hypermania/mod/Global/Debris.h rename src/hypermania/{Objects => mod/Global}/HUD.c (100%) create mode 100644 src/hypermania/mod/Global/HUD.h rename src/hypermania/{Objects => mod/Global}/ImageTrail.c (98%) rename src/hypermania/{Objects => mod/Global}/ImageTrail.h (55%) rename src/hypermania/{Objects => mod/Global}/Player.c (98%) rename src/hypermania/{Objects => mod/Global}/Player.h (97%) rename src/hypermania/{Objects => mod/Global}/SpecialRing.c (99%) rename src/hypermania/{Objects => mod/Global}/SpecialRing.h (67%) rename src/hypermania/{Objects/HPZ => mod/LRZ}/HPZEmerald.c (99%) create mode 100644 src/hypermania/mod/LRZ/HPZEmerald.h rename src/hypermania/{Objects => mod/MMZ}/PlaneSeeSaw.c (98%) create mode 100644 src/hypermania/mod/MMZ/PlaneSeeSaw.h rename src/hypermania/{Objects => mod/Menu}/LevelSelect.c (100%) create mode 100644 src/hypermania/mod/Menu/LevelSelect.h rename src/hypermania/{Objects => mod/Menu}/UISaveSlot.c (100%) rename src/hypermania/{Objects => mod/Menu}/UISaveSlot.h (55%) rename src/hypermania/{Objects => mod/UFO}/SpecialClear.c (100%) rename src/hypermania/{Objects => mod/UFO}/SpecialClear.h (60%) rename src/hypermania/{Objects => mod/UFO}/UFO_Player.c (100%) create mode 100644 src/hypermania/mod/UFO/UFO_Player.h rename src/hypermania/{Objects => mod/UFO}/UFO_Setup.c (95%) create mode 100644 src/hypermania/mod/UFO/UFO_Setup.h create mode 100644 src/hypermania/new/All.h rename src/hypermania/{Objects => new/Global}/HyperStars.c (98%) rename src/hypermania/{Objects => new/Global}/HyperStars.h (84%) rename src/hypermania/{Objects => new/Global}/JetGlideEffect.c (100%) rename src/hypermania/{Objects => new/Global}/JetGlideEffect.h (81%) rename src/hypermania/{Objects => new/Global}/SuperFlicky.c (98%) rename src/hypermania/{Objects => new/Global}/SuperFlicky.h (91%) rename src/hypermania/{Objects => new}/HPZ/HPZBeam.c (98%) rename src/hypermania/{Objects => new}/HPZ/HPZBeam.h (83%) rename src/hypermania/{Objects => new}/HPZ/HPZIntro.c (99%) rename src/hypermania/{Objects => new}/HPZ/HPZIntro.h (87%) rename src/hypermania/{Objects => new}/HPZ/HPZSetup.c (97%) rename src/hypermania/{Objects => new}/HPZ/HPZSetup.h (82%) diff --git a/CMakeLists.txt b/CMakeLists.txt index 2b05028..9efb2c7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -39,16 +39,11 @@ set(MOD_NAME hypermania CACHE STRING "Used as root directory for mod source + lo add_library(hypermania SHARED src/GameAPI/C/GameAPI/Game.c src/${MOD_NAME}/dllmain.c - src/${MOD_NAME}/Objects/All.c - src/${MOD_NAME}/HyperManiaVariables.c - src/${MOD_NAME}/ModFunctions.c ) target_include_directories(hypermania PRIVATE - src/${MOD_NAME}/ - src/${MOD_NAME}/Objects - src/${MOD_NAME}/Mania - src/GameAPI/C/ + src/GameAPI/C + src/${MOD_NAME} ) if(ANDROID) diff --git a/src/STRUCTURE b/src/STRUCTURE new file mode 100644 index 0000000..48093b5 --- /dev/null +++ b/src/STRUCTURE @@ -0,0 +1,4 @@ +Mania -- class definitions copied from mania decomp +link -- import macros + compatibility functions for mania classes +mod -- import macros + new functions and data for preexisting mania classes +new -- new classes diff --git a/src/hypermania/All.c b/src/hypermania/All.c new file mode 100644 index 0000000..8762512 --- /dev/null +++ b/src/hypermania/All.c @@ -0,0 +1,58 @@ +#include "HyperManiaVariables.c" +#include "ModFunctions.c" + +// ============================================================================= + +// Import macros + compatibility functions for mania classes ------------------- + +// ============================================================================= +#include "link/Enemy.c" +#include "link/BSS/BSS_Setup.c" +#include "link/Common/CollapsingPlatform.c" +#include "link/CPZ/CPZSetup.c" +#include "link/Cutscene/FXFade.c" +#include "link/ERZ/ERZStart.c" +#include "link/Global/Animals.c" +#include "link/Global/Camera.c" +#include "link/Global/Explosion.c" +#include "link/Global/InvincibleStars.c" +#include "link/Global/ItemBox.c" +#include "link/Global/Music.c" +#include "link/Global/PauseMenu.c" +#include "link/Global/Ring.c" +#include "link/Global/SaveGame.c" +#include "link/Global/ScoreBonus.c" +#include "link/Global/Zone.c" +#include "link/HCZ/HCZSetup.c" +#include "link/MMZ/FarPlane.c" +#include "link/OOZ/OOZSetup.c" + +// ============================================================================= + +// Import macros + new functions and data for preexisting mania classes -------- + +// ============================================================================= +#include "mod/Global/Debris.c" +#include "mod/Global/HUD.c" +#include "mod/Global/ImageTrail.c" +#include "mod/Global/Player.c" +#include "mod/Global/SpecialRing.c" +#include "mod/LRZ/HPZEmerald.c" +#include "mod/Menu/LevelSelect.c" +#include "mod/Menu/UISaveSlot.c" +#include "mod/MMZ/PlaneSeeSaw.c" +#include "mod/UFO/SpecialClear.c" +#include "mod/UFO/UFO_Player.c" +#include "mod/UFO/UFO_Setup.c" + +// ============================================================================= + +// New classes used in HyperMania ---------------------------------------------- + +// ============================================================================= +#include "new/Global/HyperStars.c" +#include "new/Global/JetGlideEffect.c" +#include "new/Global/SuperFlicky.c" +#include "new/HPZ/HPZBeam.c" +#include "new/HPZ/HPZIntro.c" +#include "new/HPZ/HPZSetup.c" \ No newline at end of file diff --git a/src/hypermania/HyperManiaVariables.h b/src/hypermania/HyperManiaVariables.h index f9067e7..21d9769 100644 --- a/src/hypermania/HyperManiaVariables.h +++ b/src/hypermania/HyperManiaVariables.h @@ -1,8 +1,8 @@ #ifndef HYPERMANIAVARIABLES_H #define HYPERMANIAVARIABLES_H -#include "Mania/All.h" #include "GameAPI/Game.h" +#include "Mania/All.h" // ============================================================================= @@ -30,6 +30,7 @@ } #define HOOK_IMPORTED_STATE(name, priority) Mod.RegisterStateHook(name, name##_HOOK, priority) + // ============================================================================= // Attackable Classes ---------------------------------------------------------- @@ -52,6 +53,7 @@ typedef struct { uint8 flags; } attackinfo_t; + // ============================================================================= // Misc. + Globals ------------------------------------------------------------- diff --git a/src/hypermania/Mania/All.h b/src/hypermania/Mania/All.h index 6c99f00..fd2915f 100644 --- a/src/hypermania/Mania/All.h +++ b/src/hypermania/Mania/All.h @@ -1,8 +1,347 @@ -#ifndef MANIA_ALL_H -#define MANIA_ALL_H +#pragma once -#include "../GameAPI/C/GameAPI/Game.h" -#include "Player.h" -#include "FarPlane.h" +// Foward Declarations --------------------------------------------------------- +typedef struct ObjectBSS_Setup ObjectBSS_Setup; +typedef struct EntityBSS_Setup EntityBSS_Setup; +typedef struct ObjectAmoebaDroid ObjectAmoebaDroid; +typedef struct EntityAmoebaDroid EntityAmoebaDroid; +typedef struct ObjectBubbler ObjectBubbler; +typedef struct EntityBubbler EntityBubbler; +typedef struct ObjectCPZSetup ObjectCPZSetup; +typedef struct EntityCPZSetup EntityCPZSetup; +typedef struct ObjectCaterkillerJr ObjectCaterkillerJr; +typedef struct EntityCaterkillerJr EntityCaterkillerJr; +typedef struct ObjectGrabber ObjectGrabber; +typedef struct EntityGrabber EntityGrabber; +typedef struct ObjectSpiny ObjectSpiny; +typedef struct EntitySpiny EntitySpiny; +typedef struct ObjectERZStart ObjectERZStart; +typedef struct EntityERZStart EntityERZStart; +typedef struct ObjectPhantomShield ObjectPhantomShield; +typedef struct EntityPhantomShield EntityPhantomShield; +typedef struct ObjectPhantomEgg ObjectPhantomEgg; +typedef struct EntityPhantomEgg EntityPhantomEgg; +typedef struct ObjectPhantomShinobi ObjectPhantomShinobi; +typedef struct EntityPhantomShinobi EntityPhantomShinobi; +typedef struct ObjectPhantomMystic ObjectPhantomMystic; +typedef struct EntityPhantomMystic EntityPhantomMystic; +typedef struct ObjectBigSqueeze ObjectBigSqueeze; +typedef struct EntityBigSqueeze EntityBigSqueeze; +typedef struct ObjectBlaster ObjectBlaster; +typedef struct EntityBlaster EntityBlaster; +typedef struct ObjectClucker ObjectClucker; +typedef struct EntityClucker EntityClucker; +typedef struct ObjectFBZTrash ObjectFBZTrash; +typedef struct EntityFBZTrash EntityFBZTrash; +typedef struct ObjectTechnosqueek ObjectTechnosqueek; +typedef struct EntityTechnosqueek EntityTechnosqueek; +typedef struct ObjectBatbrain ObjectBatbrain; +typedef struct EntityBatbrain EntityBatbrain; +typedef struct ObjectBuzzBomber ObjectBuzzBomber; +typedef struct EntityBuzzBomber EntityBuzzBomber; +typedef struct ObjectChopper ObjectChopper; +typedef struct EntityChopper EntityChopper; +typedef struct ObjectCrabmeat ObjectCrabmeat; +typedef struct EntityCrabmeat EntityCrabmeat; +typedef struct ObjectDDWrecker ObjectDDWrecker; +typedef struct EntityDDWrecker EntityDDWrecker; +typedef struct ObjectDERobot ObjectDERobot; +typedef struct EntityDERobot EntityDERobot; +typedef struct ObjectMotobug ObjectMotobug; +typedef struct EntityMotobug EntityMotobug; +typedef struct ObjectNewtron ObjectNewtron; +typedef struct EntityNewtron EntityNewtron; +typedef struct ObjectSplats ObjectSplats; +typedef struct EntitySplats EntitySplats; +typedef struct ObjectPauseMenu ObjectPauseMenu; +typedef struct EntityPauseMenu EntityPauseMenu; +typedef struct ObjectInvincibleStars ObjectInvincibleStars; +typedef struct EntityInvincibleStars EntityInvincibleStars; +typedef struct ObjectCamera ObjectCamera; +typedef struct EntityCamera EntityCamera; +typedef struct ObjectMusic ObjectMusic; +typedef struct EntityMusic EntityMusic; +typedef struct ObjectRing ObjectRing; +typedef struct EntityRing EntityRing; +typedef struct ObjectZone ObjectZone; +typedef struct EntityZone EntityZone; +typedef struct ObjectAnimals ObjectAnimals; +typedef struct EntityAnimals EntityAnimals; +typedef struct ObjectItemBox ObjectItemBox; +typedef struct EntityItemBox EntityItemBox; +typedef struct ObjectExplosion ObjectExplosion; +typedef struct EntityExplosion EntityExplosion; +typedef struct ObjectScoreBonus ObjectScoreBonus; +typedef struct EntityScoreBonus EntityScoreBonus; +typedef struct ObjectPlayer ObjectPlayer; +typedef struct ObjectPlayer ObjectPlayer; +typedef struct EntityPlayer EntityPlayer; +typedef struct ObjectDebris ObjectDebris; +typedef struct EntityDebris EntityDebris; +typedef struct ObjectHUD ObjectHUD; +typedef struct EntityHUD EntityHUD; +typedef struct ObjectImageTrail ObjectImageTrail; +typedef struct EntityImageTrail EntityImageTrail; +typedef struct ObjectSpecialRing ObjectSpecialRing; +typedef struct EntitySpecialRing EntitySpecialRing; +typedef struct ObjectBlastoid ObjectBlastoid; +typedef struct EntityBlastoid EntityBlastoid; +typedef struct ObjectBuggernaut ObjectBuggernaut; +typedef struct EntityBuggernaut EntityBuggernaut; +typedef struct ObjectHCZSetup ObjectHCZSetup; +typedef struct EntityHCZSetup EntityHCZSetup; +typedef struct ObjectJawz ObjectJawz; +typedef struct EntityJawz EntityJawz; +typedef struct ObjectJellygnite ObjectJellygnite; +typedef struct EntityJellygnite EntityJellygnite; +typedef struct ObjectMegaChopper ObjectMegaChopper; +typedef struct EntityMegaChopper EntityMegaChopper; +typedef struct ObjectPointdexter ObjectPointdexter; +typedef struct EntityPointdexter EntityPointdexter; +typedef struct ObjectTurboSpiker ObjectTurboSpiker; +typedef struct EntityTurboSpiker EntityTurboSpiker; +typedef struct ObjectWhirlpool ObjectWhirlpool; +typedef struct EntityWhirlpool EntityWhirlpool; +typedef struct ObjectLaundroMobile ObjectLaundroMobile; +typedef struct EntityLaundroMobile EntityLaundroMobile; +typedef struct ObjectFireworm ObjectFireworm; +typedef struct EntityFireworm EntityFireworm; +typedef struct ObjectRexon ObjectRexon; +typedef struct EntityRexon EntityRexon; +typedef struct ObjectToxomister ObjectToxomister; +typedef struct EntityToxomister EntityToxomister; +typedef struct ObjectDrillerdroid ObjectDrillerdroid; +typedef struct EntityDrillerdroid EntityDrillerdroid; +typedef struct ObjectDrillerdroidO ObjectDrillerdroidO; +typedef struct EntityDrillerdroidO EntityDrillerdroidO; +typedef struct ObjectHeavyRider ObjectHeavyRider; +typedef struct EntityHeavyRider EntityHeavyRider; +typedef struct ObjectHeavyKing ObjectHeavyKing; +typedef struct EntityHeavyKing EntityHeavyKing; +typedef struct ObjectRockDrill ObjectRockDrill; +typedef struct EntityRockDrill EntityRockDrill; +typedef struct ObjectHPZEmerald ObjectHPZEmerald; +typedef struct EntityHPZEmerald EntityHPZEmerald; +typedef struct ObjectFarPlane ObjectFarPlane; +typedef struct EntityFarPlane EntityFarPlane; +typedef struct ObjectMechaBu ObjectMechaBu; +typedef struct EntityMechaBu EntityMechaBu; +typedef struct ObjectPohBee ObjectPohBee; +typedef struct EntityPohBee EntityPohBee; +typedef struct ObjectScarab ObjectScarab; +typedef struct EntityScarab EntityScarab; +typedef struct ObjectEggPistonsMKII ObjectEggPistonsMKII; +typedef struct EntityEggPistonsMKII EntityEggPistonsMKII; +typedef struct ObjectGachapandora ObjectGachapandora; +typedef struct EntityGachapandora EntityGachapandora; +typedef struct ObjectPlaneSeeSaw ObjectPlaneSeeSaw; +typedef struct EntityPlaneSeeSaw EntityPlaneSeeSaw; +typedef struct ObjectArmadiloid ObjectArmadiloid; +typedef struct EntityArmadiloid EntityArmadiloid; +typedef struct ObjectBumpalo ObjectBumpalo; +typedef struct EntityBumpalo EntityBumpalo; +typedef struct ObjectCactula ObjectCactula; +typedef struct EntityCactula EntityCactula; +typedef struct ObjectHatterkiller ObjectHatterkiller; +typedef struct EntityHatterkiller EntityHatterkiller; +typedef struct ObjectRattlekiller ObjectRattlekiller; +typedef struct EntityRattlekiller EntityRattlekiller; +typedef struct ObjectRollerMKII ObjectRollerMKII; +typedef struct EntityRollerMKII EntityRollerMKII; +typedef struct ObjectVultron ObjectVultron; +typedef struct EntityVultron EntityVultron; +typedef struct ObjectUberCaterkiller ObjectUberCaterkiller; +typedef struct EntityUberCaterkiller EntityUberCaterkiller; +typedef struct ObjectDBTower ObjectDBTower; +typedef struct EntityDBTower EntityDBTower; +typedef struct ObjectHeavyMystic ObjectHeavyMystic; +typedef struct EntityHeavyMystic EntityHeavyMystic; +typedef struct ObjectAquis ObjectAquis; +typedef struct EntityAquis EntityAquis; +typedef struct ObjectOOZSetup ObjectOOZSetup; +typedef struct EntityOOZSetup EntityOOZSetup; +typedef struct ObjectOctus ObjectOctus; +typedef struct EntityOctus EntityOctus; +typedef struct ObjectSol ObjectSol; +typedef struct EntitySol EntitySol; +typedef struct ObjectMeterDroid ObjectMeterDroid; +typedef struct EntityMeterDroid EntityMeterDroid; +typedef struct ObjectMegaOctus ObjectMegaOctus; +typedef struct EntityMegaOctus EntityMegaOctus; +typedef struct ObjectDragonfly ObjectDragonfly; +typedef struct EntityDragonfly EntityDragonfly; +typedef struct ObjectIceBomba ObjectIceBomba; +typedef struct EntityIceBomba EntityIceBomba; +typedef struct ObjectJuggleSaw ObjectJuggleSaw; +typedef struct EntityJuggleSaw EntityJuggleSaw; +typedef struct ObjectWoodrow ObjectWoodrow; +typedef struct EntityWoodrow EntityWoodrow; +typedef struct ObjectShiversaw ObjectShiversaw; +typedef struct EntityShiversaw EntityShiversaw; +typedef struct ObjectHeavyShinobi ObjectHeavyShinobi; +typedef struct EntityHeavyShinobi EntityHeavyShinobi; +typedef struct ObjectCanista ObjectCanista; +typedef struct EntityCanista EntityCanista; +typedef struct ObjectMicDrop ObjectMicDrop; +typedef struct EntityMicDrop EntityMicDrop; +typedef struct ObjectShutterbug ObjectShutterbug; +typedef struct EntityShutterbug EntityShutterbug; +typedef struct ObjectTubinaut ObjectTubinaut; +typedef struct EntityTubinaut EntityTubinaut; +typedef struct ObjectWeatherMobile ObjectWeatherMobile; +typedef struct EntityWeatherMobile EntityWeatherMobile; +typedef struct ObjectDango ObjectDango; +typedef struct EntityDango EntityDango; +typedef struct ObjectHotaru ObjectHotaru; +typedef struct EntityHotaru EntityHotaru; +typedef struct ObjectHotaruMKII ObjectHotaruMKII; +typedef struct EntityHotaruMKII EntityHotaruMKII; +typedef struct ObjectKabasira ObjectKabasira; +typedef struct EntityKabasira EntityKabasira; +typedef struct ObjectKanabun ObjectKanabun; +typedef struct EntityKanabun EntityKanabun; +typedef struct ObjectHotaruHiWatt ObjectHotaruHiWatt; +typedef struct EntityHotaruHiWatt EntityHotaruHiWatt; +typedef struct ObjectMetalSonic ObjectMetalSonic; +typedef struct EntityMetalSonic EntityMetalSonic; +typedef struct ObjectGigaMetal ObjectGigaMetal; +typedef struct EntityGigaMetal EntityGigaMetal; +typedef struct ObjectBallHog ObjectBallHog; +typedef struct EntityBallHog EntityBallHog; +typedef struct ObjectFlasherMKII ObjectFlasherMKII; +typedef struct EntityFlasherMKII EntityFlasherMKII; +typedef struct ObjectSentryBug ObjectSentryBug; +typedef struct EntitySentryBug EntitySentryBug; +typedef struct ObjectTurboTurtle ObjectTurboTurtle; +typedef struct EntityTurboTurtle EntityTurboTurtle; +typedef struct ObjectCrimsonEye ObjectCrimsonEye; +typedef struct EntityCrimsonEye EntityCrimsonEye; +typedef struct ObjectFXFade ObjectFXFade; +typedef struct EntityFXFade EntityFXFade; +typedef struct ObjectCollapsingPlatform ObjectCollapsingPlatform; +typedef struct EntityCollapsingPlatform EntityCollapsingPlatform; +typedef struct ObjectUFO_Player ObjectUFO_Player; +typedef struct EntityUFO_Player EntityUFO_Player; +typedef struct ObjectUFO_Setup ObjectUFO_Setup; +typedef struct EntityUFO_Setup EntityUFO_Setup; +typedef struct ObjectSpecialClear ObjectSpecialClear; +typedef struct EntitySpecialClear EntitySpecialClear; +typedef struct ObjectUISaveSlot ObjectUISaveSlot; +typedef struct EntityUISaveSlot EntityUISaveSlot; +typedef struct ObjectLevelSelect ObjectLevelSelect; +typedef struct EntityLevelSelect EntityLevelSelect; -#endif //! MANIA_ALL_H \ No newline at end of file +// Includes -------------------------------------------------------------------- +#include "BSS/BSS_Setup.h" +#include "CPZ/AmoebaDroid.h" +#include "CPZ/Bubbler.h" +#include "CPZ/CPZSetup.h" +#include "CPZ/CaterkillerJr.h" +#include "CPZ/Grabber.h" +#include "CPZ/Spiny.h" +#include "Common/CollapsingPlatform.h" +#include "Cutscene/FXFade.h" +#include "ERZ/ERZStart.h" +#include "ERZ/PhantomEgg.h" +#include "ERZ/PhantomMystic.h" +#include "ERZ/PhantomShinobi.h" +#include "FBZ/BigSqueeze.h" +#include "FBZ/Blaster.h" +#include "FBZ/Clucker.h" +#include "FBZ/FBZTrash.h" +#include "FBZ/Technosqueek.h" +#include "GHZ/Batbrain.h" +#include "GHZ/BuzzBomber.h" +#include "GHZ/Chopper.h" +#include "GHZ/Crabmeat.h" +#include "GHZ/DDWrecker.h" +#include "GHZ/DERobot.h" +#include "GHZ/Motobug.h" +#include "GHZ/Newtron.h" +#include "GHZ/Splats.h" +#include "Global/Animals.h" +#include "Global/Camera.h" +#include "Global/Debris.h" +#include "Global/Explosion.h" +#include "Global/HUD.h" +#include "Global/ImageTrail.h" +#include "Global/InvincibleStars.h" +#include "Global/ItemBox.h" +#include "Global/Music.h" +#include "Global/PauseMenu.h" +#include "Global/Player.h" +#include "Global/Ring.h" +#include "Global/SaveGame.h" +#include "Global/ScoreBonus.h" +#include "Global/SpecialRing.h" +#include "Global/Zone.h" +#include "HCZ/Blastoid.h" +#include "HCZ/Buggernaut.h" +#include "HCZ/HCZSetup.h" +#include "HCZ/Jawz.h" +#include "HCZ/Jellygnite.h" +#include "HCZ/LaundroMobile.h" +#include "HCZ/MegaChopper.h" +#include "HCZ/Pointdexter.h" +#include "HCZ/TurboSpiker.h" +#include "LRZ/Drillerdroid.h" +#include "LRZ/DrillerdroidO.h" +#include "LRZ/Fireworm.h" +#include "LRZ/HPZEmerald.h" +#include "LRZ/HeavyKing.h" +#include "LRZ/HeavyRider.h" +#include "LRZ/Rexon.h" +#include "LRZ/RockDrill.h" +#include "LRZ/Toxomister.h" +#include "MMZ/EggPistonsMKII.h" +#include "MMZ/FarPlane.h" +#include "MMZ/Gachapandora.h" +#include "MMZ/MechaBu.h" +#include "MMZ/PlaneSeeSaw.h" +#include "MMZ/PohBee.h" +#include "MMZ/Scarab.h" +#include "MSZ/Armadiloid.h" +#include "MSZ/Bumpalo.h" +#include "MSZ/Cactula.h" +#include "MSZ/DBTower.h" +#include "MSZ/Hatterkiller.h" +#include "MSZ/HeavyMystic.h" +#include "MSZ/Rattlekiller.h" +#include "MSZ/RollerMKII.h" +#include "MSZ/UberCaterkiller.h" +#include "MSZ/Vultron.h" +#include "Menu/LevelSelect.h" +#include "Menu/UISaveSlot.h" +#include "OOZ/Aquis.h" +#include "OOZ/MegaOctus.h" +#include "OOZ/MeterDroid.h" +#include "OOZ/OOZSetup.h" +#include "OOZ/Octus.h" +#include "OOZ/Sol.h" +#include "PGZ/Dragonfly.h" +#include "PGZ/HeavyShinobi.h" +#include "PGZ/IceBomba.h" +#include "PGZ/JuggleSaw.h" +#include "PGZ/Shiversaw.h" +#include "PGZ/Woodrow.h" +#include "SPZ/Canista.h" +#include "SPZ/MicDrop.h" +#include "SPZ/Shutterbug.h" +#include "SPZ/Tubinaut.h" +#include "SPZ/WeatherMobile.h" +#include "SSZ/Dango.h" +#include "SSZ/GigaMetal.h" +#include "SSZ/Hotaru.h" +#include "SSZ/HotaruHiWatt.h" +#include "SSZ/HotaruMKII.h" +#include "SSZ/Kabasira.h" +#include "SSZ/Kanabun.h" +#include "SSZ/MetalSonic.h" +#include "TMZ/BallHog.h" +#include "TMZ/CrimsonEye.h" +#include "TMZ/FlasherMKII.h" +#include "TMZ/SentryBug.h" +#include "TMZ/TurboTurtle.h" +#include "UFO/SpecialClear.h" +#include "UFO/UFO_Player.h" +#include "UFO/UFO_Setup.h" \ No newline at end of file diff --git a/src/hypermania/Mania/BSS/BSS_Setup.c b/src/hypermania/Mania/BSS/BSS_Setup.c deleted file mode 100644 index fb5422f..0000000 --- a/src/hypermania/Mania/BSS/BSS_Setup.c +++ /dev/null @@ -1,3 +0,0 @@ -#include "BSS_Setup.h" - -ObjectBSS_Setup *BSS_Setup; diff --git a/src/hypermania/Mania/BSS/BSS_Setup.h b/src/hypermania/Mania/BSS/BSS_Setup.h index ee88ee1..0b9e7fa 100644 --- a/src/hypermania/Mania/BSS/BSS_Setup.h +++ b/src/hypermania/Mania/BSS/BSS_Setup.h @@ -1,9 +1,6 @@ -#ifndef OBJ_BSS_SETUP_H -#define OBJ_BSS_SETUP_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectBSS_Setup { RSDK_OBJECT uint8 randomNumbers[4]; // used to calculate the map (& colours) for Random BSS mode int32 sphereCount; @@ -64,9 +61,9 @@ typedef struct { uint16 sfxMedal; uint16 sfxMedalCaught; uint16 sfxTeleport; -} ObjectBSS_Setup; +}; -typedef struct { +struct EntityBSS_Setup { RSDK_ENTITY StateMachine(state); int32 spinTimer; @@ -96,8 +93,4 @@ typedef struct { int32 stopMovement; Animator globeSpinAnimator; Animator shadowAnimator; -} EntityBSS_Setup; - -extern ObjectBSS_Setup *BSS_Setup; - -#endif //! OBJ_BSS_SETUP_H +}; diff --git a/src/hypermania/Mania/CPZ/AmoebaDroid.h b/src/hypermania/Mania/CPZ/AmoebaDroid.h index b3ba994..92cbfae 100644 --- a/src/hypermania/Mania/CPZ/AmoebaDroid.h +++ b/src/hypermania/Mania/CPZ/AmoebaDroid.h @@ -1,11 +1,8 @@ -#ifndef OBJ_AMOEBADROID_H -#define OBJ_AMOEBADROID_H - -#include "GameAPI/Game.h" +#pragma once #define AMOEBADROID_BLOB_COUNT (8) -typedef struct { +struct ObjectAmoebaDroid { RSDK_OBJECT TABLE(int32 debrisInfo1[17], { 4, 0, 0, -0x20000, -0x28000, 1, 0, 0x20000, -0x28000, 2, 0, -0x28000, -0x20000, 3, 0, 0x28000, -0x20000 }); TABLE(int32 debrisInfo2[13], { 3, 4, 0, 0, -0x20000, 5, 0, -0x28000, -0x20000, 5, 1, 0x28000, -0x20000 }); @@ -21,9 +18,9 @@ typedef struct { uint16 sfxRelease; uint16 aniFrames; uint16 waterFrames; -} ObjectAmoebaDroid; +}; -typedef struct { +struct EntityAmoebaDroid { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -42,32 +39,4 @@ typedef struct { Animator attractorTopAnimator; Animator attractorSideAnimator; Hitbox hitbox; -} EntityAmoebaDroid; - -extern ObjectAmoebaDroid* AmoebaDroid; - -extern void (*AmoebaDroid_State_DropIn)(); -extern void (*AmoebaDroid_State_DropIntoPool)(); -extern void (*AmoebaDroid_State_SurfaceFromPool)(); -extern void (*AmoebaDroid_State_ChooseAttack)(); -extern void (*AmoebaDroid_State_ExitPool)(); -extern void (*AmoebaDroid_State_BounceAttack)(); -extern void (*AmoebaDroid_State_GatherBlobs)(); -extern void (*AmoebaDroid_State_SpinBlobs)(); -extern void (*AmoebaDroid_Hit)(); - -void AmoebaDroid_EnemyInfoHook(); - -#define OBJ_AMOEBADROID_SETUP \ - IMPORT_PUBLIC_FUNC(AmoebaDroid_State_DropIn); \ - IMPORT_PUBLIC_FUNC(AmoebaDroid_State_DropIntoPool); \ - IMPORT_PUBLIC_FUNC(AmoebaDroid_State_SurfaceFromPool); \ - IMPORT_PUBLIC_FUNC(AmoebaDroid_State_ChooseAttack); \ - IMPORT_PUBLIC_FUNC(AmoebaDroid_State_ExitPool); \ - IMPORT_PUBLIC_FUNC(AmoebaDroid_State_BounceAttack); \ - IMPORT_PUBLIC_FUNC(AmoebaDroid_State_GatherBlobs); \ - IMPORT_PUBLIC_FUNC(AmoebaDroid_State_SpinBlobs); \ - IMPORT_PUBLIC_FUNC(AmoebaDroid_Hit); \ - REGISTER_ENEMY(AmoebaDroid) - -#endif //! OBJ_AMOEBADROID_H +}; diff --git a/src/hypermania/Mania/CPZ/Bubbler.h b/src/hypermania/Mania/CPZ/Bubbler.h index 8507e6f..00c6070 100644 --- a/src/hypermania/Mania/CPZ/Bubbler.h +++ b/src/hypermania/Mania/CPZ/Bubbler.h @@ -1,17 +1,14 @@ -#ifndef OBJ_BUBBLER_H -#define OBJ_BUBBLER_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectBubbler { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxRange; Hitbox hitboxProjectile; uint16 aniFrames; -} ObjectBubbler; +}; -typedef struct { +struct EntityBubbler { RSDK_ENTITY StateMachine(state); int16 timer; @@ -20,18 +17,4 @@ typedef struct { uint8 startDir; Animator bodyHitbox; Animator flameAnimator; -} EntityBubbler; - -extern ObjectBubbler* Bubbler; - -extern void (*Bubbler_StateProjectile_Seed)(); -extern void (*Bubbler_StateProjectile_Bubbler)(); - -void Bubbler_EnemyInfoHook(); - -#define OBJ_BUBBLER_SETUP \ - IMPORT_PUBLIC_FUNC(Bubbler_StateProjectile_Seed); \ - IMPORT_PUBLIC_FUNC(Bubbler_StateProjectile_Bubbler); \ - REGISTER_ENEMY(Bubbler) - -#endif //! OBJ_BUBBLER_H +}; diff --git a/src/hypermania/Mania/CPZ/CPZSetup.h b/src/hypermania/Mania/CPZ/CPZSetup.h index dc211c2..3b4dbd5 100644 --- a/src/hypermania/Mania/CPZ/CPZSetup.h +++ b/src/hypermania/Mania/CPZ/CPZSetup.h @@ -1,9 +1,6 @@ -#ifndef OBJ_CPZSETUP_H -#define OBJ_CPZSETUP_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectCPZSetup { RSDK_OBJECT uint16 aniTiles; TileLayer *background; @@ -16,12 +13,8 @@ typedef struct { int32 chemLiquidPalIndex3; uint16 aniTileFrame; Entity *outro; -} ObjectCPZSetup; +}; -typedef struct { +struct EntityCPZSetup { RSDK_ENTITY -} EntityCPZSetup; - -extern ObjectCPZSetup *CPZSetup; - -#endif //! OBJ_CPZSETUP_H +}; diff --git a/src/hypermania/Mania/CPZ/CaterkillerJr.h b/src/hypermania/Mania/CPZ/CaterkillerJr.h index 957c244..3f58cd2 100644 --- a/src/hypermania/Mania/CPZ/CaterkillerJr.h +++ b/src/hypermania/Mania/CPZ/CaterkillerJr.h @@ -1,17 +1,14 @@ -#ifndef OBJ_CATERKILLERJR_H -#define OBJ_CATERKILLERJR_H - -#include "GameAPI/Game.h" +#pragma once #define CATERKILLERJR_SEGMENT_COUNT (7) -typedef struct { +struct ObjectCaterkillerJr { RSDK_OBJECT Hitbox hitbox; uint16 aniFrames; -} ObjectCaterkillerJr; +}; -typedef struct { +struct EntityCaterkillerJr { RSDK_ENTITY StateMachine(state); int32 timer; @@ -24,13 +21,4 @@ typedef struct { int32 boundsR; Animator bodyAnimators[CATERKILLERJR_SEGMENT_COUNT]; Animator smokePuffAnimators[3]; -} EntityCaterkillerJr; - -extern ObjectCaterkillerJr* CaterkillerJr; - -void CaterkillerJr_EnemyInfoHook(); - -#define OBJ_CATERKILLERJR_SETUP \ - REGISTER_ENEMY(CaterkillerJr) - -#endif //! OBJ_CATERKILLERJR_H +}; diff --git a/src/hypermania/Mania/CPZ/Grabber.h b/src/hypermania/Mania/CPZ/Grabber.h index 03a1fee..21fae2b 100644 --- a/src/hypermania/Mania/CPZ/Grabber.h +++ b/src/hypermania/Mania/CPZ/Grabber.h @@ -1,9 +1,6 @@ -#ifndef OBJ_GRABBER_H -#define OBJ_GRABBER_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectGrabber { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxGrab; @@ -11,9 +8,9 @@ typedef struct { uint16 aniFrames; uint16 sfxGrab; uint16 sfxDestroy; -} ObjectGrabber; +}; -typedef struct { +struct EntityGrabber { RSDK_ENTITY StateMachine(state); Animator bodyAnimator; @@ -28,13 +25,4 @@ typedef struct { uint8 startDir; int32 turnTimer; int32 timer; -} EntityGrabber; - -extern ObjectGrabber* Grabber; - -void Grabber_EnemyInfoHook(); - -#define OBJ_GRABBER_SETUP \ - REGISTER_ENEMY(Grabber) - -#endif //! OBJ_GRABBER_H +}; diff --git a/src/hypermania/Mania/CPZ/Spiny.h b/src/hypermania/Mania/CPZ/Spiny.h index 5e2004e..8039f34 100644 --- a/src/hypermania/Mania/CPZ/Spiny.h +++ b/src/hypermania/Mania/CPZ/Spiny.h @@ -1,18 +1,15 @@ -#ifndef OBJ_SPINY_H -#define OBJ_SPINY_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectSpiny { RSDK_OBJECT Hitbox hitboxSpiny; Hitbox hitboxRange; Hitbox hitboxShot; uint16 aniFrames; uint16 sfxShot; -} ObjectSpiny; +}; -typedef struct { +struct EntitySpiny { RSDK_ENTITY StateMachine(state); Animator animator; @@ -23,18 +20,4 @@ typedef struct { int32 shotVelocity; int32 dirChangeTimer; int32 moveTimer; -} EntitySpiny; - -extern ObjectSpiny* Spiny; - -extern void (*Spiny_State_Shot)(); -extern void (*Spiny_State_ShotDisappear)(); - -void Spiny_EnemyInfoHook(); - -#define OBJ_SPINY_SETUP \ - IMPORT_PUBLIC_FUNC(Spiny_State_Shot); \ - IMPORT_PUBLIC_FUNC(Spiny_State_ShotDisappear); \ - REGISTER_ENEMY(Spiny) - -#endif //! OBJ_SPINY_H +}; diff --git a/src/hypermania/Mania/Common/CollapsingPlatform.c b/src/hypermania/Mania/Common/CollapsingPlatform.c deleted file mode 100644 index d74539a..0000000 --- a/src/hypermania/Mania/Common/CollapsingPlatform.c +++ /dev/null @@ -1,3 +0,0 @@ -#include "CollapsingPlatform.h" - -ObjectCollapsingPlatform *CollapsingPlatform; diff --git a/src/hypermania/Mania/Common/CollapsingPlatform.h b/src/hypermania/Mania/Common/CollapsingPlatform.h index 5516d00..e134efa 100644 --- a/src/hypermania/Mania/Common/CollapsingPlatform.h +++ b/src/hypermania/Mania/Common/CollapsingPlatform.h @@ -1,17 +1,14 @@ -#ifndef OBJ_COLLAPSINGPLATFORM_H -#define OBJ_COLLAPSINGPLATFORM_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectCollapsingPlatform { RSDK_OBJECT uint8 shift; Animator animator; uint16 aniFrames; uint16 sfxCrumble; -} ObjectCollapsingPlatform; +}; -typedef struct { +struct EntityCollapsingPlatform { RSDK_ENTITY StateMachine(state); Vector2 size; @@ -26,8 +23,4 @@ typedef struct { uint16 storedTiles[256]; Hitbox hitboxTrigger; Vector2 stoodPos; -} EntityCollapsingPlatform; - -extern ObjectCollapsingPlatform *CollapsingPlatform; - -#endif //! OBJ_COLLAPSINGPLATFORM_H +}; diff --git a/src/hypermania/Mania/Cutscene/FXFade.c b/src/hypermania/Mania/Cutscene/FXFade.c deleted file mode 100644 index 45acd5b..0000000 --- a/src/hypermania/Mania/Cutscene/FXFade.c +++ /dev/null @@ -1,5 +0,0 @@ -#include "FXFade.h" - -ObjectFXFade *FXFade; -void (*FXFade_State_FadeIn)(void); -void (*FXFade_State_FadeOut)(void); \ No newline at end of file diff --git a/src/hypermania/Mania/Cutscene/FXFade.h b/src/hypermania/Mania/Cutscene/FXFade.h index 07ecb03..ae2971e 100644 --- a/src/hypermania/Mania/Cutscene/FXFade.h +++ b/src/hypermania/Mania/Cutscene/FXFade.h @@ -1,15 +1,12 @@ -#ifndef OBJ_FXFADE_H -#define OBJ_FXFADE_H - -#include "GameAPI/Game.h" +#pragma once // Object Class -typedef struct { +struct ObjectFXFade { RSDK_OBJECT -} ObjectFXFade; +}; // Entity Class -typedef struct { +struct EntityFXFade { RSDK_ENTITY StateMachine(state); int32 timer; @@ -24,13 +21,4 @@ typedef struct { #if MANIA_USE_PLUS bool32 transitionScene; #endif -} EntityFXFade; - -// Object Struct -extern ObjectFXFade* FXFade; - -// Imported Functions -extern void (*FXFade_State_FadeIn)(void); -extern void (*FXFade_State_FadeOut)(void); - -#endif //! OBJ_FXFADE_H \ No newline at end of file +}; diff --git a/src/hypermania/Mania/ERZ/ERZStart.h b/src/hypermania/Mania/ERZ/ERZStart.h index 83313eb..2f8b8fd 100644 --- a/src/hypermania/Mania/ERZ/ERZStart.h +++ b/src/hypermania/Mania/ERZ/ERZStart.h @@ -1,9 +1,6 @@ -#ifndef OBJ_ERZSTART_H -#define OBJ_ERZSTART_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectERZStart { RSDK_OBJECT int32 timer; int32 unused1; @@ -18,13 +15,9 @@ typedef struct { void *emeralds[7]; void *king; void *eggman; -} ObjectERZStart; +}; -typedef struct { +struct EntityERZStart { MANIA_CUTSCENE_BASE int32 timer; -} EntityERZStart; - -extern ObjectERZStart *ERZStart; - -#endif //! OBJ_ERZSTART_H +}; diff --git a/src/hypermania/Mania/ERZ/PhantomEgg.h b/src/hypermania/Mania/ERZ/PhantomEgg.h index bed12d0..ceeeb4c 100644 --- a/src/hypermania/Mania/ERZ/PhantomEgg.h +++ b/src/hypermania/Mania/ERZ/PhantomEgg.h @@ -1,15 +1,12 @@ -#ifndef OBJ_PHANTOMEGG_H -#define OBJ_PHANTOMEGG_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectPhantomShield { RSDK_OBJECT Hitbox hitbox; uint16 aniFrames; -} ObjectPhantomShield; +}; -typedef struct { +struct EntityPhantomShield { RSDK_ENTITY StateMachine(state); bool32 shieldActive; @@ -17,9 +14,7 @@ typedef struct { int32 playerTimer[PLAYER_COUNT]; Entity* parent; Animator animator; -} EntityPhantomShield; - -extern ObjectPhantomShield* PhantomShield; +}; typedef enum { PHANTOMEGG_EGGMAN, @@ -33,7 +28,7 @@ typedef enum { PHANTOMEGG_ATTACK_WARP, } PhantomEggAttackIDs; -typedef struct { +struct ObjectPhantomEgg { RSDK_OBJECT TABLE(int32 debrisInfo[29], { 4, 0, 0, -0x20000, -0x28000, 1, 0, -0x20000, -0x28000, 2, 0, 0x20000, -0x20000, 3, 0, 0x28000, -0x20000, 4, 0, -0x10000, -0x10000, 5, 0, 0x10000, -0x10000, 6, 0, -0x8000, -0x10000 }); @@ -66,9 +61,9 @@ typedef struct { uint16 sfxMissile; uint16 aniFrames; bool32 disableSuperForm; -} ObjectPhantomEgg; +}; -typedef struct { +struct EntityPhantomEgg { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -92,27 +87,4 @@ typedef struct { Animator eggmanAnimator; Animator rubyAnimator; Hitbox hitbox; -} EntityPhantomEgg; - -extern ObjectPhantomEgg* PhantomEgg; - -extern void (*PhantomEgg_State_MoveAround)(); -extern void (*PhantomEgg_State_Attack_Jumped)(); -extern void (*PhantomEgg_State_Attack_JumpLand)(); -extern void (*PhantomEgg_State_Attack_JumpAttack)(); -extern void (*PhantomEgg_State_Attack_CableShock)(); -extern void (*PhantomEgg_Hit)(); - -void PhantomEgg_EnemyInfoHook(); - -#define OBJ_PHANTOMEGG_SETUP \ - MOD_REGISTER_OBJECT_HOOK(PhantomShield); \ - IMPORT_PUBLIC_FUNC(PhantomEgg_State_MoveAround); \ - IMPORT_PUBLIC_FUNC(PhantomEgg_State_Attack_Jumped); \ - IMPORT_PUBLIC_FUNC(PhantomEgg_State_Attack_JumpLand); \ - IMPORT_PUBLIC_FUNC(PhantomEgg_State_Attack_JumpAttack); \ - IMPORT_PUBLIC_FUNC(PhantomEgg_State_Attack_CableShock); \ - IMPORT_PUBLIC_FUNC(PhantomEgg_Hit); \ - REGISTER_ENEMY(PhantomEgg) - -#endif //! OBJ_PHANTOMEGG_H +}; diff --git a/src/hypermania/Mania/ERZ/PhantomMystic.h b/src/hypermania/Mania/ERZ/PhantomMystic.h index 8398ac8..d8573bd 100644 --- a/src/hypermania/Mania/ERZ/PhantomMystic.h +++ b/src/hypermania/Mania/ERZ/PhantomMystic.h @@ -1,17 +1,14 @@ -#ifndef OBJ_PHANTOMMYSTIC_H -#define OBJ_PHANTOMMYSTIC_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectPhantomMystic { RSDK_OBJECT uint16 aniFrames; uint16 sfxCupSwap; uint16 sfxBigLaser; uint16 sfxImpact; -} ObjectPhantomMystic; +}; -typedef struct { +struct EntityPhantomMystic { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -39,20 +36,4 @@ typedef struct { Animator cupSpikeAnimator; // Not actually ever drawn... Animator cupBlastAnimator; Hitbox hitbox; -} EntityPhantomMystic; - -extern ObjectPhantomMystic* PhantomMystic; - -extern void (*PhantomMystic_State_CupBlast)(); -extern void (*PhantomMystic_State_MoveCupsToMystic)(); -extern void (*PhantomMystic_Hit)(); - -void PhantomMystic_EnemyInfoHook(); - -#define OBJ_PHANTOMMYSTIC_SETUP \ - IMPORT_PUBLIC_FUNC(PhantomMystic_State_CupBlast); \ - IMPORT_PUBLIC_FUNC(PhantomMystic_State_MoveCupsToMystic); \ - IMPORT_PUBLIC_FUNC(PhantomMystic_Hit); \ - REGISTER_ENEMY(PhantomMystic) - -#endif //! OBJ_PHANTOMMYSTIC_H +}; diff --git a/src/hypermania/Mania/ERZ/PhantomShinobi.h b/src/hypermania/Mania/ERZ/PhantomShinobi.h index 5032e96..4c5b9bb 100644 --- a/src/hypermania/Mania/ERZ/PhantomShinobi.h +++ b/src/hypermania/Mania/ERZ/PhantomShinobi.h @@ -1,17 +1,14 @@ -#ifndef OBJ_PHANTOMSHINOBI_H -#define OBJ_PHANTOMSHINOBI_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectPhantomShinobi { RSDK_OBJECT Hitbox hitbox; uint16 aniFrames; uint16 sfxBlade; uint16 sfxHit; -} ObjectPhantomShinobi; +}; -typedef struct { +struct EntityPhantomShinobi { RSDK_ENTITY StateMachine(state); Vector2 startPos; @@ -29,26 +26,4 @@ typedef struct { Animator bodyAnimator; Animator armAnimator; Animator finAnimator; -} EntityPhantomShinobi; - -extern ObjectPhantomShinobi* PhantomShinobi; - -extern void (*PhantomShinobi_State_SetupAttack)(); -extern void (*PhantomShinobi_State_Moving)(); -extern void (*PhantomShinobi_State_PrepareFinAttack)(); -extern void (*PhantomShinobi_State_ExtendFins)(); -extern void (*PhantomShinobi_State_RetractFins)(); -extern void (*PhantomShinobi_Hit)(); - -void PhantomShinobi_EnemyInfoHook(); - -#define OBJ_PHANTOMSHINOBI_SETUP \ - IMPORT_PUBLIC_FUNC(PhantomShinobi_State_SetupAttack); \ - IMPORT_PUBLIC_FUNC(PhantomShinobi_State_Moving); \ - IMPORT_PUBLIC_FUNC(PhantomShinobi_State_PrepareFinAttack); \ - IMPORT_PUBLIC_FUNC(PhantomShinobi_State_ExtendFins); \ - IMPORT_PUBLIC_FUNC(PhantomShinobi_State_RetractFins); \ - IMPORT_PUBLIC_FUNC(PhantomShinobi_Hit); \ - REGISTER_ENEMY(PhantomShinobi) - -#endif //! OBJ_PHANTOMSHINOBI_H +}; diff --git a/src/hypermania/Mania/FBZ/BigSqueeze.h b/src/hypermania/Mania/FBZ/BigSqueeze.h index 0ea3e15..ef3d493 100644 --- a/src/hypermania/Mania/FBZ/BigSqueeze.h +++ b/src/hypermania/Mania/FBZ/BigSqueeze.h @@ -1,7 +1,4 @@ -#ifndef OBJ_BIGSQUEEZE_H -#define OBJ_BIGSQUEEZE_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { BIGSQUEEZE_MANAGER, @@ -10,7 +7,7 @@ typedef enum { BIGSQUEEZE_CRUSHER_R, } BigSqueezeTypes; -typedef struct { +struct ObjectBigSqueeze { RSDK_OBJECT TABLE(int32 prongDebrisInfo[10], { 3, 12, -0x20000, -0x10000, 13, 0, -0x10000, 14, 0x20000, -0x10000 }); TABLE(int32 domeDebrisInfo[13], { 4, 8, -0x20000, -0x10000, 9, -0x10000, -0x10000, 10, 0x10000, -0x10000, 11, 0x20000, -0x10000 }); @@ -25,9 +22,9 @@ typedef struct { uint16 sfxMagnet; uint16 sfxOrbinaut; uint16 aniFrames; -} ObjectBigSqueeze; +}; -typedef struct { +struct EntityBigSqueeze { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -43,20 +40,4 @@ typedef struct { Animator wheelAnimator; Animator electricAnimator; Hitbox hitbox; -} EntityBigSqueeze; - -extern ObjectBigSqueeze* BigSqueeze; - -extern void (*BigSqueeze_StateBoss_Idle)(); -extern void (*BigSqueeze_StateBoss_Electrified)(); -extern void (*BigSqueeze_Hit)(); - -void BigSqueeze_EnemyInfoHook(); - -#define OBJ_BIGSQUEEZE_SETUP \ - IMPORT_PUBLIC_FUNC(BigSqueeze_StateBoss_Idle); \ - IMPORT_PUBLIC_FUNC(BigSqueeze_StateBoss_Electrified); \ - IMPORT_PUBLIC_FUNC(BigSqueeze_Hit); \ - REGISTER_ENEMY(BigSqueeze) - -#endif //! OBJ_BIGSQUEEZE_H +}; diff --git a/src/hypermania/Mania/FBZ/Blaster.h b/src/hypermania/Mania/FBZ/Blaster.h index fa14450..52fdcbc 100644 --- a/src/hypermania/Mania/FBZ/Blaster.h +++ b/src/hypermania/Mania/FBZ/Blaster.h @@ -1,17 +1,14 @@ -#ifndef OBJ_BLASTER_H -#define OBJ_BLASTER_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectBlaster { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxRange; Hitbox hitboxProjectile; uint16 aniFrames; -} ObjectBlaster; +}; -typedef struct { +struct EntityBlaster { RSDK_ENTITY StateMachine(state); uint16 unused1; @@ -20,20 +17,4 @@ typedef struct { Vector2 startPos; uint8 startDir; Animator animator; -} EntityBlaster; - -extern ObjectBlaster* Blaster; - -extern void (*Blaster_State_BeginShot)(); -extern void (*Blaster_State_Shot)(); -extern void (*Blaster_State_Shell)(); - -void Blaster_EnemyInfoHook(); - -#define OBJ_BLASTER_SETUP \ - IMPORT_PUBLIC_FUNC(Blaster_State_BeginShot); \ - IMPORT_PUBLIC_FUNC(Blaster_State_Shot); \ - IMPORT_PUBLIC_FUNC(Blaster_State_Shell); \ - REGISTER_ENEMY(Blaster) - -#endif //! OBJ_BLASTER_H +}; diff --git a/src/hypermania/Mania/FBZ/Clucker.h b/src/hypermania/Mania/FBZ/Clucker.h index c54c475..71d65f0 100644 --- a/src/hypermania/Mania/FBZ/Clucker.h +++ b/src/hypermania/Mania/FBZ/Clucker.h @@ -1,10 +1,6 @@ +#pragma once -#ifndef OBJ_CLUCKER_H -#define OBJ_CLUCKER_H - -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectClucker { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxRange; @@ -12,9 +8,9 @@ typedef struct { Hitbox hitboxEgg; uint16 aniFrames; uint16 sfxShot; -} ObjectClucker; +}; -typedef struct { +struct EntityClucker { RSDK_ENTITY StateMachine(state); int32 yOffset; @@ -23,18 +19,4 @@ typedef struct { uint16 delay; bool32 hasParent; Animator animator; -} EntityClucker; - -extern ObjectClucker* Clucker; - -extern void (*Clucker_State_Destroyed)(); -extern void (*Clucker_State_Egg)(); - -void Clucker_EnemyInfoHook(); - -#define OBJ_CLUCKER_SETUP \ - IMPORT_PUBLIC_FUNC(Clucker_State_Destroyed); \ - IMPORT_PUBLIC_FUNC(Clucker_State_Egg); \ - REGISTER_ENEMY(Clucker) - -#endif //! OBJ_CLUCKER_H +}; diff --git a/src/hypermania/Mania/FBZ/FBZTrash.h b/src/hypermania/Mania/FBZ/FBZTrash.h index 6bfe4f3..f9a63e0 100644 --- a/src/hypermania/Mania/FBZ/FBZTrash.h +++ b/src/hypermania/Mania/FBZ/FBZTrash.h @@ -1,7 +1,4 @@ -#ifndef OBJ_FBZTRASH_H -#define OBJ_FBZTRASH_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { FBZTRASH_TRASH, @@ -10,12 +7,12 @@ typedef enum { FBZTRASH_ORBINAUT, } FBZTrashTypes; -typedef struct { +struct ObjectFBZTrash { RSDK_OBJECT uint16 aniFrames; -} ObjectFBZTrash; +}; -typedef struct { +struct EntityFBZTrash { RSDK_ENTITY StateMachine(state); FBZTrashTypes type; @@ -28,16 +25,4 @@ typedef struct { void* parent; Hitbox hitbox; Animator animator; -} EntityFBZTrash; - -extern ObjectFBZTrash* FBZTrash; - -extern void (*FBZTrash_State_OrbinautMove)(); - -void FBZTrash_EnemyInfoHook(); - -#define OBJ_FBZTRASH_SETUP \ - IMPORT_PUBLIC_FUNC(FBZTrash_State_OrbinautMove); \ - REGISTER_ENEMY(FBZTrash) - -#endif //! OBJ_FBZTRASH_H +}; diff --git a/src/hypermania/Mania/FBZ/Technosqueek.h b/src/hypermania/Mania/FBZ/Technosqueek.h index 4b9bc9e..2d835fd 100644 --- a/src/hypermania/Mania/FBZ/Technosqueek.h +++ b/src/hypermania/Mania/FBZ/Technosqueek.h @@ -1,15 +1,12 @@ -#ifndef OBJ_TECHNOSQUEEK_H -#define OBJ_TECHNOSQUEEK_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectTechnosqueek { RSDK_OBJECT Hitbox hitboxBadnik; uint16 aniFrames; -} ObjectTechnosqueek; +}; -typedef struct { +struct EntityTechnosqueek { RSDK_ENTITY StateMachine(state); uint8 type; @@ -24,13 +21,4 @@ typedef struct { uint8 startDir; Animator animator; Animator tailAnimator; -} EntityTechnosqueek; - -extern ObjectTechnosqueek* Technosqueek; - -void Technosqueek_EnemyInfoHook(); - -#define OBJ_TECHNOSQUEEK_SETUP \ - REGISTER_ENEMY(Technosqueek) - -#endif //! OBJ_TECHNOSQUEEK_H +}; diff --git a/src/hypermania/Mania/FarPlane.h b/src/hypermania/Mania/FarPlane.h deleted file mode 100644 index 51d224d..0000000 --- a/src/hypermania/Mania/FarPlane.h +++ /dev/null @@ -1,31 +0,0 @@ -#ifndef MANIA_FARPLANE_H -#define MANIA_FARPLANE_H - -#define FARPLANE_ENTITY_COUNT (256) - -typedef struct { - RSDK_OBJECT - uint32 aniFrames; - Vector2 screenPos; - Vector2 worldPos; - Vector2 originPos; - Vector2 position; - Vector2 positionList[0x200]; - int32 unused1; - int32 unused2; - int32 unused3; - int32 unused4; - int32 unused5; - uint16 layerID; -} ObjectFarPlane; - -typedef struct { - RSDK_ENTITY - Vector2 size; - Vector2 origin; - uint16 entitySlots[FARPLANE_ENTITY_COUNT]; - int32 entityCount; - Animator animator; -} EntityFarPlane; - -#endif //! MANIA_FARPLANE_H \ No newline at end of file diff --git a/src/hypermania/Mania/GHZ/Batbrain.h b/src/hypermania/Mania/GHZ/Batbrain.h index b8ed370..be4be09 100644 --- a/src/hypermania/Mania/GHZ/Batbrain.h +++ b/src/hypermania/Mania/GHZ/Batbrain.h @@ -1,29 +1,17 @@ -#ifndef OBJ_BATBRAIN_H -#define OBJ_BATBRAIN_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectBatbrain { RSDK_OBJECT Hitbox hitboxBadnik; uint16 aniFrames; uint16 sfxFlap; -} ObjectBatbrain; +}; -typedef struct { +struct EntityBatbrain { RSDK_ENTITY StateMachine(state); int32 targetY; EntityPlayer* target; Vector2 startPos; Animator animator; -} EntityBatbrain; - -extern ObjectBatbrain* Batbrain; - -void Batbrain_EnemyInfoHook(); - -#define OBJ_BATBRAIN_SETUP \ - REGISTER_ENEMY(Batbrain) - -#endif //! OBJ_BATBRAIN_H +}; diff --git a/src/hypermania/Mania/GHZ/BuzzBomber.h b/src/hypermania/Mania/GHZ/BuzzBomber.h index 89d570e..1371915 100644 --- a/src/hypermania/Mania/GHZ/BuzzBomber.h +++ b/src/hypermania/Mania/GHZ/BuzzBomber.h @@ -1,16 +1,13 @@ -#ifndef OBJ_BUZZBOMBER_H -#define OBJ_BUZZBOMBER_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectBuzzBomber { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxProjectile; uint16 aniFrames; -} ObjectBuzzBomber; +}; -typedef struct { +struct EntityBuzzBomber { RSDK_ENTITY StateMachine(state); uint8 shotRange; @@ -23,20 +20,4 @@ typedef struct { Animator wingAnimator; Animator thrustAnimator; Hitbox hitboxRange; -} EntityBuzzBomber; - -extern ObjectBuzzBomber* BuzzBomber; - -extern void (*BuzzBomber_State_Flying)(); -extern void (*BuzzBomber_State_Idle)(); -extern void (*BuzzBomber_State_DetectedPlayer)(); - -void BuzzBomber_EnemyInfoHook(); - -#define OBJ_BUZZBOMBER_SETUP \ - IMPORT_PUBLIC_FUNC(BuzzBomber_State_Flying); \ - IMPORT_PUBLIC_FUNC(BuzzBomber_State_Idle); \ - IMPORT_PUBLIC_FUNC(BuzzBomber_State_DetectedPlayer); \ - REGISTER_ENEMY(BuzzBomber) - -#endif //! OBJ_BUZZBOMBER_H +}; diff --git a/src/hypermania/Mania/GHZ/Chopper.h b/src/hypermania/Mania/GHZ/Chopper.h index bfbbfc3..7dac0d7 100644 --- a/src/hypermania/Mania/GHZ/Chopper.h +++ b/src/hypermania/Mania/GHZ/Chopper.h @@ -1,18 +1,15 @@ -#ifndef OBJ_CHOPPER_H -#define OBJ_CHOPPER_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectChopper { RSDK_OBJECT Hitbox hitboxJump; Hitbox hitboxSwim; Hitbox hitboxRange; Hitbox hitboxWater; uint16 aniFrames; -} ObjectChopper; +}; -typedef struct { +struct EntityChopper { RSDK_ENTITY StateMachine(state); uint8 type; @@ -21,16 +18,4 @@ typedef struct { Vector2 startPos; uint8 startDir; Animator animator; -} EntityChopper; - -extern ObjectChopper* Chopper; - -extern void (*Chopper_State_Jump)(); - -void Chopper_EnemyInfoHook(); - -#define OBJ_CHOPPER_SETUP \ - IMPORT_PUBLIC_FUNC(Chopper_State_Jump); \ - REGISTER_ENEMY(Chopper) - -#endif //! OBJ_CHOPPER_H +}; diff --git a/src/hypermania/Mania/GHZ/Crabmeat.h b/src/hypermania/Mania/GHZ/Crabmeat.h index 874cfff..4f4e7db 100644 --- a/src/hypermania/Mania/GHZ/Crabmeat.h +++ b/src/hypermania/Mania/GHZ/Crabmeat.h @@ -1,16 +1,13 @@ -#ifndef OBJ_CRABMEAT_H -#define OBJ_CRABMEAT_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectCrabmeat { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxProjectile; uint16 aniFrames; -} ObjectCrabmeat; +}; -typedef struct { +struct EntityCrabmeat { RSDK_ENTITY StateMachine(state); int32 timer; @@ -18,16 +15,4 @@ typedef struct { Vector2 startPos; int32 startDir; Animator animator; -} EntityCrabmeat; - -extern ObjectCrabmeat* Crabmeat; - -extern void (*Crabmeat_State_Projectile)(); - -void Crabmeat_EnemyInfoHook(); - -#define OBJ_CRABMEAT_SETUP \ - IMPORT_PUBLIC_FUNC(Crabmeat_State_Projectile); \ - REGISTER_ENEMY(Crabmeat) - -#endif //! OBJ_CRABMEAT_H +}; diff --git a/src/hypermania/Mania/GHZ/DDWrecker.h b/src/hypermania/Mania/GHZ/DDWrecker.h index 6ab44b8..3995055 100644 --- a/src/hypermania/Mania/GHZ/DDWrecker.h +++ b/src/hypermania/Mania/GHZ/DDWrecker.h @@ -1,7 +1,4 @@ -#ifndef OBJ_DDWRECKER_H -#define OBJ_DDWRECKER_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { DDWRECKER_SETUP, @@ -11,7 +8,7 @@ typedef enum { DDWRECKER_CORE, } DDWreckerTypes; -typedef struct { +struct ObjectDDWrecker { RSDK_OBJECT int32 camBoundL; int32 camBoundR; @@ -29,9 +26,9 @@ typedef struct { uint16 sfxAssemble; uint16 sfxRotate; uint16 sfxSharp; -} ObjectDDWrecker; +}; -typedef struct { +struct EntityDDWrecker { RSDK_ENTITY StateMachine(state); StateMachine(stateBall); @@ -55,22 +52,4 @@ typedef struct { int32 blendAmount; Animator animator; Hitbox hitbox; -} EntityDDWrecker; - -extern ObjectDDWrecker* DDWrecker; - -extern void (*DDWrecker_StateBall_Vulnerable)(); -extern void (*DDWrecker_StateBall_Spiked)(); -extern void (*DDWrecker_StateBall_Partnerless)(); -extern void (*DDWrecker_Hit)(); - -void DDWrecker_EnemyInfoHook(); - -#define OBJ_DDWRECKER_SETUP \ - IMPORT_PUBLIC_FUNC(DDWrecker_StateBall_Vulnerable); \ - IMPORT_PUBLIC_FUNC(DDWrecker_StateBall_Spiked); \ - IMPORT_PUBLIC_FUNC(DDWrecker_StateBall_Partnerless); \ - IMPORT_PUBLIC_FUNC(DDWrecker_Hit); \ - REGISTER_ENEMY(DDWrecker) - -#endif //! OBJ_DDWRECKER_H +}; diff --git a/src/hypermania/Mania/GHZ/DERobot.h b/src/hypermania/Mania/GHZ/DERobot.h index 02550b4..eb022f5 100644 --- a/src/hypermania/Mania/GHZ/DERobot.h +++ b/src/hypermania/Mania/GHZ/DERobot.h @@ -1,9 +1,6 @@ -#ifndef OBJ_DEROBOT_H -#define OBJ_DEROBOT_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectDERobot { RSDK_OBJECT uint16 aniFrames; Hitbox hitboxHand; @@ -21,9 +18,9 @@ typedef struct { uint16 sfxDrop; uint16 sfxButton2; uint16 sfxHullClose; -} ObjectDERobot; +}; -typedef struct { +struct EntityDERobot { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -56,22 +53,4 @@ typedef struct { Animator armAnimator; int32 aniID; int32 frameID; -} EntityDERobot; - -extern ObjectDERobot* DERobot; - -extern void (*DERobot_State_FallLand)(); -extern void (*DERobot_State_Walk)(); -extern void (*DERobot_State_ArmAttack)(); -extern void (*DERobot_Hit)(); - -void DERobot_EnemyInfoHook(); - -#define OBJ_DEROBOT_SETUP \ - IMPORT_PUBLIC_FUNC(DERobot_State_FallLand); \ - IMPORT_PUBLIC_FUNC(DERobot_State_Walk); \ - IMPORT_PUBLIC_FUNC(DERobot_State_ArmAttack); \ - IMPORT_PUBLIC_FUNC(DERobot_Hit); \ - REGISTER_ENEMY(DERobot) - -#endif //! OBJ_DEROBOT_H +}; diff --git a/src/hypermania/Mania/GHZ/Motobug.h b/src/hypermania/Mania/GHZ/Motobug.h index f2fbda7..ce18089 100644 --- a/src/hypermania/Mania/GHZ/Motobug.h +++ b/src/hypermania/Mania/GHZ/Motobug.h @@ -1,15 +1,12 @@ -#ifndef OBJ_MOTOBUG_H -#define OBJ_MOTOBUG_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectMotobug { RSDK_OBJECT Hitbox hitboxBadnik; uint16 aniFrames; -} ObjectMotobug; +}; -typedef struct { +struct EntityMotobug { RSDK_ENTITY StateMachine(state); int32 turnTimer; @@ -18,16 +15,4 @@ typedef struct { uint8 startDir; bool32 wasTurning; Animator animator; -} EntityMotobug; - -extern ObjectMotobug* Motobug; - -extern void (*Motobug_State_Smoke)(); - -void Motobug_EnemyInfoHook(); - -#define OBJ_MOTOBUG_SETUP \ - IMPORT_PUBLIC_FUNC(Motobug_State_Smoke); \ - REGISTER_ENEMY(Motobug) - -#endif //! OBJ_MOTOBUG_H +}; diff --git a/src/hypermania/Mania/GHZ/Newtron.h b/src/hypermania/Mania/GHZ/Newtron.h index b9d2046..3407e16 100644 --- a/src/hypermania/Mania/GHZ/Newtron.h +++ b/src/hypermania/Mania/GHZ/Newtron.h @@ -1,18 +1,15 @@ -#ifndef OBJ_NEWTRON_H -#define OBJ_NEWTRON_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectNewtron { RSDK_OBJECT Hitbox hitboxShoot; Hitbox hitboxFly; Hitbox hitboxProjectile; Hitbox hitboxRange; uint16 aniFrames; -} ObjectNewtron; +}; -typedef struct { +struct EntityNewtron { RSDK_ENTITY StateMachine(state); uint8 type; @@ -20,20 +17,4 @@ typedef struct { Vector2 startPos; Animator animator; Animator flameAnimator; -} EntityNewtron; - -extern ObjectNewtron* Newtron; - -extern void (*Newtron_State_StartFly)(); -extern void (*Newtron_State_Fly)(); -extern void (*Newtron_State_Shoot)(); - -void Newtron_EnemyInfoHook(); - -#define OBJ_NEWTRON_SETUP \ - IMPORT_PUBLIC_FUNC(Newtron_State_StartFly); \ - IMPORT_PUBLIC_FUNC(Newtron_State_Fly); \ - IMPORT_PUBLIC_FUNC(Newtron_State_Shoot); \ - REGISTER_ENEMY(Newtron) - -#endif //! OBJ_NEWTRON_H +}; diff --git a/src/hypermania/Mania/GHZ/Splats.h b/src/hypermania/Mania/GHZ/Splats.h index 5958ef3..e0e074a 100644 --- a/src/hypermania/Mania/GHZ/Splats.h +++ b/src/hypermania/Mania/GHZ/Splats.h @@ -1,9 +1,6 @@ -#ifndef OBJ_SPLATS_H -#define OBJ_SPLATS_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectSplats { RSDK_OBJECT StateMachine(initialState); Hitbox hitboxBadnikGHZ; @@ -12,9 +9,9 @@ typedef struct { uint16 aniFrames; uint16 sfxSplatsSpawn; uint16 sfxSplatsLand; -} ObjectSplats; +}; -typedef struct { +struct EntitySplats { RSDK_ENTITY StateMachine(state); uint8 bounceCount; @@ -28,24 +25,4 @@ typedef struct { int32 startDir; Animator mainAnimator; Animator splashAnimator; -} EntitySplats; - -extern ObjectSplats* Splats; - -extern void (*Splats_State_BounceAround)(); -extern void (*Splats_State_JumpOutOfJar)(); -extern void (*Splats_State_HandleBouncing)(); -extern void (*Splats_State_HandleLanding)(); -extern void (*Splats_State_NoMoreJumps)(); - -void Splats_EnemyInfoHook(); - -#define OBJ_SPLATS_SETUP \ - IMPORT_PUBLIC_FUNC(Splats_State_BounceAround); \ - IMPORT_PUBLIC_FUNC(Splats_State_JumpOutOfJar); \ - IMPORT_PUBLIC_FUNC(Splats_State_HandleBouncing); \ - IMPORT_PUBLIC_FUNC(Splats_State_HandleLanding); \ - IMPORT_PUBLIC_FUNC(Splats_State_NoMoreJumps); \ - REGISTER_ENEMY(Splats) - -#endif //! OBJ_SPLATS_H +}; diff --git a/src/hypermania/Mania/Global/Animals.h b/src/hypermania/Mania/Global/Animals.h index cc871f9..689fc66 100644 --- a/src/hypermania/Mania/Global/Animals.h +++ b/src/hypermania/Mania/Global/Animals.h @@ -1,7 +1,4 @@ -#ifndef OBJ_ANIMALS_H -#define OBJ_ANIMALS_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { ANIMAL_FLICKY, @@ -24,7 +21,7 @@ typedef enum { ANIMAL_BEHAVE_FIXED, } AnimalBehaviours; -typedef struct { +struct ObjectAnimals { RSDK_OBJECT TABLE(int32 hitboxes[12], { 0x70000, 0x70000, 0xC0000, 0xA0000, 0x80000, 0x80000, 0x80000, 0x80000, 0x70000, 0x50000, 0x70000, 0x60000 }); TABLE(int32 gravityStrength[12], { 0x1800, 0x3800, 0x3800, 0x3800, 0x3800, 0x3800, 0x3800, 0x3800, 0x1800, 0x3800, 0x3800, 0x3800 }); @@ -36,9 +33,9 @@ typedef struct { int32 animalTypes[2]; bool32 hasPlatform; bool32 hasBridge; -} ObjectAnimals; +}; -typedef struct { +struct EntityAnimals { RSDK_ENTITY StateMachine(state); int32 timer; @@ -46,8 +43,4 @@ typedef struct { AnimalBehaviours behaviour; Animator animator; Hitbox hitboxAnimal; -} EntityAnimals; - -extern ObjectAnimals *Animals; - -#endif //! OBJ_ANIMALS_H +}; diff --git a/src/hypermania/Mania/Global/Camera.h b/src/hypermania/Mania/Global/Camera.h index 2d0b5dc..8e95cd2 100644 --- a/src/hypermania/Mania/Global/Camera.h +++ b/src/hypermania/Mania/Global/Camera.h @@ -1,7 +1,4 @@ -#ifndef OBJ_CAMERA_H -#define OBJ_CAMERA_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { CAMERA_LERP_NORMAL, @@ -11,13 +8,13 @@ typedef enum { } CameraLerpType; // Object Class -typedef struct { +struct ObjectCamera { RSDK_OBJECT Vector2 centerBounds; -} ObjectCamera; +}; // Entity Class -typedef struct { +struct EntityCamera { RSDK_ENTITY StateMachine(state); Entity *target; @@ -41,15 +38,4 @@ typedef struct { int32 boundsR; int32 boundsT; int32 boundsB; -} EntityCamera; - -// Object Struct -extern ObjectCamera *Camera; - -// Imported Functions -extern void (*Camera_State_FollowXY)(); -extern void (*Camera_State_FollowY)(); -extern void (*Camera_ShakeScreen)(int32 screen, int32 shakeX, int32 shakeY); -extern void (*Camera_SetupLerp)(int32 type, int32 screen, int32 x, int32 y, int32 speed); - -#endif //! OBJ_CAMERA_H +}; diff --git a/src/hypermania/Mania/Global/Debris.h b/src/hypermania/Mania/Global/Debris.h new file mode 100644 index 0000000..8e3ba54 --- /dev/null +++ b/src/hypermania/Mania/Global/Debris.h @@ -0,0 +1,16 @@ +#pragma once + +struct ObjectDebris { + RSDK_OBJECT +}; + +struct EntityDebris { + RSDK_ENTITY + StateMachine(state); + int32 timer; + int32 gravityStrength; + int32 rotSpeed; + Vector2 scaleSpeed; + int32 delay; + Animator animator; +}; \ No newline at end of file diff --git a/src/hypermania/Mania/Global/Explosion.h b/src/hypermania/Mania/Global/Explosion.h index 6b20918..6b4e443 100644 --- a/src/hypermania/Mania/Global/Explosion.h +++ b/src/hypermania/Mania/Global/Explosion.h @@ -1,7 +1,4 @@ -#ifndef OBJ_EXPLOSION_H -#define OBJ_EXPLOSION_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { EXPLOSION_ITEMBOX, @@ -10,18 +7,14 @@ typedef enum { EXPLOSION_BOSSPUFF, } ExplosionTypes; -typedef struct { +struct ObjectExplosion { RSDK_OBJECT uint16 aniFrames; uint16 sfxDestroy; -} ObjectExplosion; +}; -typedef struct { +struct EntityExplosion { RSDK_ENTITY Animator animator; int32 planeFilter; -} EntityExplosion; - -extern ObjectExplosion *Explosion; - -#endif //! OBJ_EXPLOSION_H +}; diff --git a/src/hypermania/Mania/Global/HUD.h b/src/hypermania/Mania/Global/HUD.h new file mode 100644 index 0000000..2cf7770 --- /dev/null +++ b/src/hypermania/Mania/Global/HUD.h @@ -0,0 +1,65 @@ +#pragma once + +struct ObjectHUD { + RSDK_OBJECT + uint16 aniFrames; +#if GAME_VERSION != VER_100 + uint16 superButtonFrames; +#endif +#if MANIA_USE_PLUS + uint16 sfxClick; + uint16 sfxStarpost; + bool32 showTAPrompt; + bool32 replaySaveEnabled; + int32 screenBorderType[PLAYER_COUNT]; + int32 swapCooldown; + int32 stockFlashTimers[PLAYER_COUNT]; +#endif +}; + +struct EntityHUD { + RSDK_ENTITY + StateMachine(state); + Vector2 scorePos; + Vector2 timePos; + Vector2 ringsPos; + Vector2 lifePos; +#if MANIA_USE_PLUS + int32 lifeFrameIDs[PLAYER_COUNT]; + int32 lives[PLAYER_COUNT]; +#endif + int32 targetPos; +#if GAME_VERSION != VER_100 + int32 actionPromptPos; +#endif +#if MANIA_USE_PLUS + StateMachine(vsStates[PLAYER_COUNT]); + Vector2 vsScorePos[PLAYER_COUNT]; + Vector2 vsTimePos[PLAYER_COUNT]; + Vector2 vsRingsPos[PLAYER_COUNT]; + Vector2 vsLifePos[PLAYER_COUNT]; + int32 vsTargetPos[PLAYER_COUNT]; + int32 screenID; +#endif +#if GAME_VERSION != VER_100 + int32 timeFlashFrame; +#endif + int32 ringFlashFrame; + bool32 enableTimeFlash; + bool32 enableRingFlash; + Animator hudElementsAnimator; + Animator numbersAnimator; + Animator hyperNumbersAnimator; + Animator lifeIconAnimator; + Animator playerIDAnimator; +#if GAME_VERSION != VER_100 + Animator superIconAnimator; + Animator superButtonAnimator; +#endif +#if MANIA_USE_PLUS + Animator thumbsUpIconAnimator; + Animator thumbsUpButtonAnimator; + Animator replayClapAnimator; + Animator saveReplayButtonAnimator; +#endif +}; \ No newline at end of file diff --git a/src/hypermania/Mania/Global/ImageTrail.h b/src/hypermania/Mania/Global/ImageTrail.h new file mode 100644 index 0000000..77f3e46 --- /dev/null +++ b/src/hypermania/Mania/Global/ImageTrail.h @@ -0,0 +1,30 @@ +#pragma once + +// Constants +#define IMAGETRAIL_TRACK_COUNT (7) + +// Object Class +struct ObjectImageTrail { + RSDK_OBJECT +}; + +// Entity Class +struct EntityImageTrail { + RSDK_ENTITY + EntityPlayer *player; + int32 playerClassID; + Vector2 currentPos; + Vector2 statePos[IMAGETRAIL_TRACK_COUNT]; + int32 currentRotation; + int32 stateRotation[IMAGETRAIL_TRACK_COUNT]; + uint8 currentDirection; + uint8 stateDirection[IMAGETRAIL_TRACK_COUNT]; + uint8 currentVisible; + uint8 stateVisible[IMAGETRAIL_TRACK_COUNT]; + int32 currentScale; + int32 stateScale[IMAGETRAIL_TRACK_COUNT]; + Animator currentAnimator; + Animator stateAnimator[IMAGETRAIL_TRACK_COUNT]; + int32 baseAlpha; + int32 fadeoutTimer; +}; \ No newline at end of file diff --git a/src/hypermania/Mania/Global/InvincibleStars.h b/src/hypermania/Mania/Global/InvincibleStars.h index a487cc4..7611045 100644 --- a/src/hypermania/Mania/Global/InvincibleStars.h +++ b/src/hypermania/Mania/Global/InvincibleStars.h @@ -1,16 +1,13 @@ -#ifndef OBJ_INVINCIBLESTARS_H -#define OBJ_INVINCIBLESTARS_H - -#include "GameAPI/Game.h" +#pragma once // Object Class -typedef struct { +struct ObjectInvincibleStars { RSDK_OBJECT uint16 aniFrames; -} ObjectInvincibleStars; +}; // Entity Class -typedef struct { +struct EntityInvincibleStars { RSDK_ENTITY EntityPlayer* player; Vector2 starPos[8]; @@ -18,8 +15,4 @@ typedef struct { int32 starFrame[2]; int32 starOffset; Animator starAnimator[4]; -} EntityInvincibleStars; - -extern ObjectInvincibleStars* InvincibleStars; - -#endif //! OBJ_INVINCIBLESTARS_H \ No newline at end of file +}; diff --git a/src/hypermania/Mania/Global/ItemBox.h b/src/hypermania/Mania/Global/ItemBox.h index f57acf6..64ef1db 100644 --- a/src/hypermania/Mania/Global/ItemBox.h +++ b/src/hypermania/Mania/Global/ItemBox.h @@ -1,5 +1,4 @@ -#ifndef MANIA_ITEMBOX_H -#define MANIA_ITEMBOX_H +#pragma once typedef enum { ITEMBOX_RING, @@ -26,7 +25,7 @@ typedef enum { } ItemBoxTypes; // Object Class -typedef struct { +struct ObjectItemBox { RSDK_OBJECT Hitbox hitboxItemBox; Hitbox hitboxHidden; @@ -39,10 +38,10 @@ typedef struct { uint16 sfxPowerDown; uint16 sfxRecovery; #endif -} ObjectItemBox; +}; // Entity Class -typedef struct { +struct EntityItemBox { RSDK_ENTITY StateMachine(state); ItemBoxTypes type; @@ -63,13 +62,4 @@ typedef struct { #if MANIA_USE_PLUS Entity *parent; #endif -} EntityItemBox; - -// Object Struct -extern ObjectItemBox* ItemBox; - -// Imported Functions -extern void (*ItemBox_State_Broken)(); -extern void (*ItemBox_Break)(EntityBase* itemBox, EntityBase* player); - -#endif //! MANIA_ITEMBOX_H \ No newline at end of file +}; diff --git a/src/hypermania/Mania/Global/Music.h b/src/hypermania/Mania/Global/Music.h index 89d3975..0729bce 100644 --- a/src/hypermania/Mania/Global/Music.h +++ b/src/hypermania/Mania/Global/Music.h @@ -1,7 +1,4 @@ -#ifndef OBJ_MUSIC_H -#define OBJ_MUSIC_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { TRACK_NONE = -1, @@ -32,7 +29,7 @@ typedef enum { TRACK_ERZBOSS = TRACK_SUPER, } MusicTracks; -typedef struct { +struct ObjectMusic { RSDK_OBJECT char trackNames[16][32]; uint32 trackLoops[16]; @@ -51,9 +48,9 @@ typedef struct { bool32 playing1UPTrack; #endif uint16 aniFrames; -} ObjectMusic; +}; -typedef struct { +struct EntityMusic { RSDK_ENTITY StateMachine(state); String trackFile; @@ -68,20 +65,4 @@ typedef struct { float volume; float fadeSpeed; Animator animator; -} EntityMusic; - -extern ObjectMusic *Music; - -extern void (*Music_PlayTrack)(uint8 trackID); -extern void (*Music_SetMusicTrack)(const char* path, uint8 track, uint32 loopPoint); -extern void (*Music_FadeOut)(float fadeSpeed); -extern void (*Music_PlayJingle)(uint8 trackID); - -#define OBJ_MUSIC_SETUP \ - IMPORT_PUBLIC_FUNC(Music_PlayTrack); \ - IMPORT_PUBLIC_FUNC(Music_SetMusicTrack); \ - IMPORT_PUBLIC_FUNC(Music_FadeOut); \ - IMPORT_PUBLIC_FUNC(Music_PlayJingle); \ - MOD_REGISTER_OBJECT_HOOK(Music) - -#endif //! OBJ_MUSIC_H +}; diff --git a/src/hypermania/Mania/Global/PauseMenu.h b/src/hypermania/Mania/Global/PauseMenu.h index ef4d1d4..2f1df5d 100644 --- a/src/hypermania/Mania/Global/PauseMenu.h +++ b/src/hypermania/Mania/Global/PauseMenu.h @@ -1,11 +1,8 @@ -#ifndef OBJ_PAUSEMENU_H -#define OBJ_PAUSEMENU_H - -#include "GameAPI/Game.h" +#pragma once #define PAUSEMENU_BUTTON_COUNT (3) -typedef struct { +struct ObjectPauseMenu { RSDK_OBJECT uint16 sfxBleep; uint16 sfxAccept; @@ -20,9 +17,9 @@ typedef struct { #if MANIA_USE_PLUS uint16 tintLookupTable[0x10000]; #endif -} ObjectPauseMenu; +}; -typedef struct { +struct EntityPauseMenu { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -45,11 +42,4 @@ typedef struct { void (*fadeoutCB)(void); int32 unused1; int32 unused2; // these may possibly be leftover or editor things -} EntityPauseMenu; - -extern ObjectPauseMenu *PauseMenu; - -#define OBJ_PAUSEMENU_SETUP \ - MOD_REGISTER_OBJECT_HOOK(PauseMenu) - -#endif //! OBJ_PAUSEMENU_H +}; diff --git a/src/hypermania/Mania/Player.h b/src/hypermania/Mania/Global/Player.h similarity index 99% rename from src/hypermania/Mania/Player.h rename to src/hypermania/Mania/Global/Player.h index df8fc18..39e5485 100644 --- a/src/hypermania/Mania/Player.h +++ b/src/hypermania/Mania/Global/Player.h @@ -1,5 +1,4 @@ -#ifndef MANIA_PLAYER_H -#define MANIA_PLAYER_H +#pragma once // Helper Enums typedef enum { @@ -107,7 +106,7 @@ typedef enum { // Object Class #if MANIA_USE_PLUS -typedef struct { +struct ObjectPlayer { RSDK_OBJECT TABLE(int32 sonicPhysicsTable[64], { 0x60000, 0xC00, 0x1800, 0x600, 0x8000, 0x600, 0x68000, -0x40000, 0x30000, 0x600, 0xC00, 0x300, 0x4000, 0x300, 0x38000, -0x20000, @@ -225,9 +224,9 @@ typedef struct { StateMachine(configureGhostCB); bool32 (*canSuperCB)(bool32 isHUD); int32 superDashCooldown; -} ObjectPlayer; +}; #else -typedef struct { +struct ObjectPlayer { RSDK_OBJECT int32 playerCount; TABLE(int32 sonicPhysicsTable[64], @@ -309,11 +308,11 @@ typedef struct { uint16 sfxOuttahere; uint16 sfxTransform2; bool32 gotHit[PLAYER_COUNT]; -} ObjectPlayer; +}; #endif // Entity Class -typedef struct { +struct EntityPlayer { RSDK_ENTITY StateMachine(state); StateMachine(nextAirState); @@ -410,6 +409,4 @@ typedef struct { #if MANIA_USE_PLUS int32 uncurlTimer; #endif -} EntityPlayer; - -#endif //! MANIA_PLAYER_H \ No newline at end of file +}; diff --git a/src/hypermania/Mania/Global/Ring.h b/src/hypermania/Mania/Global/Ring.h index cb42793..382e1f3 100644 --- a/src/hypermania/Mania/Global/Ring.h +++ b/src/hypermania/Mania/Global/Ring.h @@ -1,8 +1,4 @@ -#ifndef OBJ_RING_H -#define OBJ_RING_H - -#include "GameAPI/Game.h" -#include "Player.h" +#pragma once typedef enum { RING_TYPE_NORMAL, @@ -20,15 +16,15 @@ typedef enum { RING_MOVE_PATH, } RingMoveTypes; -typedef struct { +struct ObjectRing { RSDK_OBJECT Hitbox hitbox; int32 pan; uint16 aniFrames; uint16 sfxRing; -} ObjectRing; +}; -typedef struct { +struct EntityRing { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -44,23 +40,4 @@ typedef struct { int32 speed; Vector2 drawPos; Animator animator; -} EntityRing; - -extern ObjectRing *Ring; - -// Imported Functions -extern void (*Ring_State_Lost)(void); -extern void (*Ring_Draw_Normal)(void); -extern void (*Ring_State_Sparkle)(void); -extern void (*Ring_Draw_Sparkle)(void); -extern void (*Ring_Collect)(void); - -#define OBJ_RING_SETUP \ - IMPORT_PUBLIC_FUNC(Ring_State_Lost); \ - IMPORT_PUBLIC_FUNC(Ring_State_Lost); \ - IMPORT_PUBLIC_FUNC(Ring_State_Sparkle); \ - IMPORT_PUBLIC_FUNC(Ring_Draw_Sparkle); \ - IMPORT_PUBLIC_FUNC(Ring_Collect); \ - MOD_REGISTER_OBJECT_HOOK(Ring) - -#endif //! OBJ_RING_H +}; diff --git a/src/hypermania/Mania/Global/SaveGame.h b/src/hypermania/Mania/Global/SaveGame.h index 2c01cc6..ce147ef 100644 --- a/src/hypermania/Mania/Global/SaveGame.h +++ b/src/hypermania/Mania/Global/SaveGame.h @@ -1,5 +1,4 @@ -#ifndef MANIA_SAVEGAME_H -#define MANIA_SAVEGAME_H +#pragma once typedef struct { uint8 padding[0x58]; @@ -34,14 +33,3 @@ typedef enum { SAVERECALL_DISABLED, SAVERECALL_BROKENITEMBOX, } SaveRecallStates; - -extern SaveRAM* (*SaveGame_GetSaveRAM)(void); -extern void (*SaveGame_SaveGameState)(void); -extern int32* (*SaveGame_GetDataPtr)(int32 slot, bool32 encore); - -#define OBJ_SAVE_SETUP \ - IMPORT_PUBLIC_FUNC(SaveGame_GetSaveRAM); \ - IMPORT_PUBLIC_FUNC(SaveGame_SaveGameState); \ - IMPORT_PUBLIC_FUNC(SaveGame_GetDataPtr) - -#endif //! MANIA_SAVEGAME_H \ No newline at end of file diff --git a/src/hypermania/Mania/Global/ScoreBonus.h b/src/hypermania/Mania/Global/ScoreBonus.h index 7e9c22c..d3ec107 100644 --- a/src/hypermania/Mania/Global/ScoreBonus.h +++ b/src/hypermania/Mania/Global/ScoreBonus.h @@ -1,17 +1,12 @@ -#ifndef MANIA_SCOREBONUS_H -#define MANIA_SCOREBONUS_H +#pragma once -typedef struct { +struct ObjectScoreBonus { RSDK_OBJECT uint16 aniFrames; -} ObjectScoreBonus; +}; -typedef struct { +struct EntityScoreBonus { RSDK_ENTITY int32 timer; Animator animator; -} EntityScoreBonus; - -extern ObjectScoreBonus* ScoreBonus; - -#endif //! MANIA_SCOREBONUS_H \ No newline at end of file +}; diff --git a/src/hypermania/Mania/Global/SpecialRing.h b/src/hypermania/Mania/Global/SpecialRing.h new file mode 100644 index 0000000..a078514 --- /dev/null +++ b/src/hypermania/Mania/Global/SpecialRing.h @@ -0,0 +1,28 @@ +#pragma once + +struct ObjectSpecialRing { + RSDK_OBJECT + uint16 aniFrames; + Hitbox hitbox; + uint16 sfxSpecialRing; + uint16 sfxSpecialWarp; + uint16 modelIndex; + uint16 sceneIndex; +}; + +struct EntitySpecialRing { + RSDK_ENTITY + StateMachine(state); + int32 id; + int32 planeFilter; + int32 warpTimer; + int32 sparkleRadius; + Animator warpAnimator; + int32 angleZ; + int32 angleY; + bool32 enabled; + Matrix matTempRot; + Matrix matTransform; + Matrix matWorld; + Matrix matNormal; +}; \ No newline at end of file diff --git a/src/hypermania/Mania/Global/Zone.h b/src/hypermania/Mania/Global/Zone.h index 1c9960e..c7308a0 100644 --- a/src/hypermania/Mania/Global/Zone.h +++ b/src/hypermania/Mania/Global/Zone.h @@ -1,5 +1,4 @@ -#ifndef MANIA_ZONE_H -#define MANIA_ZONE_H +#pragma once typedef enum { ZONE_INVALID = -1, @@ -25,7 +24,7 @@ typedef enum { ZONE_COUNT_SAVEFILE = ZONE_ERZ + 1, } ZoneIDs; -typedef struct { +struct ObjectZone { RSDK_OBJECT int32 actID; StateMachine(stageFinishCallback); @@ -71,7 +70,7 @@ typedef struct { #endif uint16 fgLayerMask[2]; // { lowPriority, highPriority } uint16 moveLayerMask; - uint8 fgDrawGroup[2]; // { lowPriority, highPriority } + uint8 fgDrawGroup[2]; // { lowPriority, highPriority } uint8 objectDrawGroup[2]; // { lowPriority, highPriority } uint8 playerDrawGroup[2]; // { lowPriority, highPriority } uint8 hudDrawGroup; @@ -84,9 +83,9 @@ typedef struct { bool32 teleportActionActive; int32 randSeed; #endif -} ObjectZone; +}; -typedef struct { +struct EntityZone { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -94,11 +93,4 @@ typedef struct { int32 timer; int32 fadeSpeed; int32 fadeColor; -} EntityZone; - -extern ObjectZone* Zone; -extern int32 (*Zone_GetZoneID)(); -extern void (*Zone_StartFadeIn)(int32, int32); -extern void (*Zone_StartFadeOut)(int32, int32); - -#endif //! MANIA_ZONE_H \ No newline at end of file +}; diff --git a/src/hypermania/Mania/HCZ/Blastoid.h b/src/hypermania/Mania/HCZ/Blastoid.h index c22e7a5..186e9e3 100644 --- a/src/hypermania/Mania/HCZ/Blastoid.h +++ b/src/hypermania/Mania/HCZ/Blastoid.h @@ -1,31 +1,16 @@ -#ifndef OBJ_BLASTOID_H -#define OBJ_BLASTOID_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectBlastoid { RSDK_OBJECT Hitbox hitboxBody; Hitbox hitboxProjectile; uint16 aniFrames; uint16 sfxShot; -} ObjectBlastoid; +}; -typedef struct { +struct EntityBlastoid { RSDK_ENTITY StateMachine(state); uint8 timer; Animator animator; -} EntityBlastoid; - -extern ObjectBlastoid* Blastoid; - -extern void (*Blastoid_State_Projectile)(); - -void Blastoid_EnemyInfoHook(); - -#define OBJ_BLASTOID_SETUP \ - IMPORT_PUBLIC_FUNC(Blastoid_State_Projectile); \ - REGISTER_ENEMY(Blastoid) - -#endif //! OBJ_BLASTOID_H +}; diff --git a/src/hypermania/Mania/HCZ/Buggernaut.h b/src/hypermania/Mania/HCZ/Buggernaut.h index 4695d3d..b30f430 100644 --- a/src/hypermania/Mania/HCZ/Buggernaut.h +++ b/src/hypermania/Mania/HCZ/Buggernaut.h @@ -1,16 +1,13 @@ -#ifndef OBJ_BUGGERNAUT_H -#define OBJ_BUGGERNAUT_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectBuggernaut { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxParentRange; uint16 aniFrames; -} ObjectBuggernaut; +}; -typedef struct { +struct EntityBuggernaut { RSDK_ENTITY StateMachine(state); bool32 passThrough; @@ -20,13 +17,4 @@ typedef struct { Entity* parent; Animator bodyAnimator; Animator wingAnimator; -} EntityBuggernaut; - -extern ObjectBuggernaut* Buggernaut; - -void Buggernaut_EnemyInfoHook(); - -#define OBJ_BUGGERNAUT_SETUP \ - REGISTER_ENEMY(Buggernaut) - -#endif //! OBJ_BUGGERNAUT_H +}; diff --git a/src/hypermania/Mania/HCZ/HCZSetup.h b/src/hypermania/Mania/HCZ/HCZSetup.h index a53a703..47303e7 100644 --- a/src/hypermania/Mania/HCZ/HCZSetup.h +++ b/src/hypermania/Mania/HCZ/HCZSetup.h @@ -1,9 +1,6 @@ -#ifndef OBJ_HCZSETUP_H -#define OBJ_HCZSETUP_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectHCZSetup { RSDK_OBJECT TABLE(int32 pendulumAniTileDurations[14], { 4, 3, 2, 2, 2, 3, 3, 4, 3, 2, 2, 2, 3, 3 }); int32 unused1; @@ -21,12 +18,8 @@ typedef struct { uint16 sfxWaterfall; uint16 sfxWaterfallLoop; #endif -} ObjectHCZSetup; +}; -typedef struct { +struct EntityHCZSetup { RSDK_ENTITY -} EntityHCZSetup; - -extern ObjectHCZSetup *HCZSetup; - -#endif //! OBJ_HCZSETUP_H +}; diff --git a/src/hypermania/Mania/HCZ/Jawz.h b/src/hypermania/Mania/HCZ/Jawz.h index 224d8bb..dfc6049 100644 --- a/src/hypermania/Mania/HCZ/Jawz.h +++ b/src/hypermania/Mania/HCZ/Jawz.h @@ -1,30 +1,15 @@ -#ifndef OBJ_JAWZ_H -#define OBJ_JAWZ_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectJawz { RSDK_OBJECT Hitbox hitboxBadnik; uint16 aniFrames; -} ObjectJawz; +}; -typedef struct { +struct EntityJawz { RSDK_ENTITY uint8 triggerDir; StateMachine(state); Vector2 startPos; Animator animator; -} EntityJawz; - -extern ObjectJawz* Jawz; - -extern void (*Jawz_State_Triggered)(); - -void Jawz_EnemyInfoHook(); - -#define OBJ_JAWZ_SETUP \ - IMPORT_PUBLIC_FUNC(Jawz_State_Triggered); \ - REGISTER_ENEMY(Jawz) - -#endif //! OBJ_JAWZ_H +}; diff --git a/src/hypermania/Mania/HCZ/Jellygnite.h b/src/hypermania/Mania/HCZ/Jellygnite.h index e3aac4c..de1b25b 100644 --- a/src/hypermania/Mania/HCZ/Jellygnite.h +++ b/src/hypermania/Mania/HCZ/Jellygnite.h @@ -1,18 +1,15 @@ -#ifndef OBJ_JELLYGNITE_H -#define OBJ_JELLYGNITE_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectJellygnite { RSDK_OBJECT Hitbox hitbox; Hitbox hitboxUnused; uint16 aniFrames; uint16 sfxGrab; uint16 sfxElectrify; -} ObjectJellygnite; +}; -typedef struct { +struct EntityJellygnite { RSDK_ENTITY StateMachine(state); Vector2 startPos; @@ -29,16 +26,4 @@ typedef struct { Animator bodyAnimator; Animator frontTentacleAnimator; Animator backTentacleAnimator; -} EntityJellygnite; - -extern ObjectJellygnite* Jellygnite; - -extern void (*Jellygnite_State_Init)(); - -void Jellygnite_EnemyInfoHook(); - -#define OBJ_JELLYGNITE_SETUP \ - IMPORT_PUBLIC_FUNC(Jellygnite_State_Init); \ - REGISTER_ENEMY(Jellygnite) - -#endif //! OBJ_JELLYGNITE_H +}; diff --git a/src/hypermania/Mania/HCZ/LaundroMobile.h b/src/hypermania/Mania/HCZ/LaundroMobile.h index 67a9d97..f8f4816 100644 --- a/src/hypermania/Mania/HCZ/LaundroMobile.h +++ b/src/hypermania/Mania/HCZ/LaundroMobile.h @@ -1,18 +1,15 @@ -#ifndef OBJ_LAUNDROMOBILE_H -#define OBJ_LAUNDROMOBILE_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectWhirlpool { RSDK_OBJECT uint16 aniFrames; uint16 sfxWhirlpool; bool32 playingWhirlpoolSfx; int32 sfxChannel; int32 timer; -} ObjectWhirlpool; +}; -typedef struct { +struct EntityWhirlpool { RSDK_ENTITY int32 angVel; int32 yVel; @@ -25,9 +22,7 @@ typedef struct { int32 playerAmplitude[PLAYER_COUNT]; Hitbox hitbox; Animator animator; -} EntityWhirlpool; - -extern ObjectWhirlpool* Whirlpool; +}; typedef enum { LAUNDROMOBILE_BOSS, @@ -39,7 +34,7 @@ typedef enum { LAUNDROMOBILE_DELAYEDSPLASH, } LaundroMobileTypes; -typedef struct { +struct ObjectLaundroMobile { RSDK_OBJECT uint8 health; uint8 invincibilityTimer; @@ -92,9 +87,9 @@ typedef struct { uint16 sfxRumble; uint16 sfxImpact; #endif -} ObjectLaundroMobile; +}; -typedef struct { +struct EntityLaundroMobile { RSDK_ENTITY uint8 type; StateMachine(state); @@ -108,25 +103,4 @@ typedef struct { Animator propellerAnimator; Animator eggmanAnimator; Animator flameAnimator; -} EntityLaundroMobile; - -extern ObjectLaundroMobile* LaundroMobile; - -extern void (*LaundroMobile_StateBoss_AwaitPlayer_Phase1)(); -extern void (*LaundroMobile_StateBoss_SetupArena_Phase1)(); -extern void (*LaundroMobile_StateBoss_Destroyed_Phase1)(); -extern void (*LaundroMobile_StateBoss_Destroyed_Phase2)(); -extern void (*LaundroMobile_StateBoss_Explode_Phase2)(); - -void LaundroMobile_EnemyInfoHook(); - -#define OBJ_LAUNDROMOBILE_SETUP \ - MOD_REGISTER_OBJECT_HOOK(Whirlpool); \ - IMPORT_PUBLIC_FUNC(LaundroMobile_StateBoss_AwaitPlayer_Phase1); \ - IMPORT_PUBLIC_FUNC(LaundroMobile_StateBoss_SetupArena_Phase1); \ - IMPORT_PUBLIC_FUNC(LaundroMobile_StateBoss_Destroyed_Phase1); \ - IMPORT_PUBLIC_FUNC(LaundroMobile_StateBoss_Destroyed_Phase2); \ - IMPORT_PUBLIC_FUNC(LaundroMobile_StateBoss_Explode_Phase2); \ - REGISTER_ENEMY(LaundroMobile) - -#endif //! OBJ_LAUNDROMOBILE_H +}; diff --git a/src/hypermania/Mania/HCZ/MegaChopper.h b/src/hypermania/Mania/HCZ/MegaChopper.h index c64bada..df30b15 100644 --- a/src/hypermania/Mania/HCZ/MegaChopper.h +++ b/src/hypermania/Mania/HCZ/MegaChopper.h @@ -1,16 +1,13 @@ -#ifndef OBJ_MEGACHOPPER_H -#define OBJ_MEGACHOPPER_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectMegaChopper { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxChop; uint16 aniFrames; -} ObjectMegaChopper; +}; -typedef struct { +struct EntityMegaChopper { RSDK_ENTITY StateMachine(state); Vector2 startPos; @@ -22,18 +19,4 @@ typedef struct { uint16 lastShakeFlags; uint8 nibbleTimer; Animator animator; -} EntityMegaChopper; - -extern ObjectMegaChopper* MegaChopper; - -extern void (*MegaChopper_State_InWater)(); -extern void (*MegaChopper_State_OutOfWater)(); - -void MegaChopper_EnemyInfoHook(); - -#define OBJ_MEGACHOPPER_SETUP \ - IMPORT_PUBLIC_FUNC(MegaChopper_State_InWater); \ - IMPORT_PUBLIC_FUNC(MegaChopper_State_OutOfWater); \ - REGISTER_ENEMY(MegaChopper) - -#endif //! OBJ_MEGACHOPPER_H +}; diff --git a/src/hypermania/Mania/HCZ/Pointdexter.h b/src/hypermania/Mania/HCZ/Pointdexter.h index 7724686..8a19564 100644 --- a/src/hypermania/Mania/HCZ/Pointdexter.h +++ b/src/hypermania/Mania/HCZ/Pointdexter.h @@ -1,28 +1,16 @@ -#ifndef OBJ_POINTDEXTER_H -#define OBJ_POINTDEXTER_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectPointdexter { RSDK_OBJECT Hitbox hitbox; uint16 aniFrames; -} ObjectPointdexter; +}; -typedef struct { +struct EntityPointdexter { RSDK_ENTITY StateMachine(state); uint8 timer; Vector2 startPos; uint8 startDir; Animator animator; -} EntityPointdexter; - -extern ObjectPointdexter* Pointdexter; - -void Pointdexter_EnemyInfoHook(); - -#define OBJ_POINTDEXTER_SETUP \ - REGISTER_ENEMY(Pointdexter) - -#endif //! OBJ_POINTDEXTER_H +}; diff --git a/src/hypermania/Mania/HCZ/TurboSpiker.h b/src/hypermania/Mania/HCZ/TurboSpiker.h index d15af2c..91191f6 100644 --- a/src/hypermania/Mania/HCZ/TurboSpiker.h +++ b/src/hypermania/Mania/HCZ/TurboSpiker.h @@ -1,9 +1,6 @@ -#ifndef OBJ_TURBOSPIKER_H -#define OBJ_TURBOSPIKER_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectTurboSpiker { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxSpike; @@ -11,9 +8,9 @@ typedef struct { uint16 aniFrames; uint16 sfxLaunch; uint16 sfxSplash; -} ObjectTurboSpiker; +}; -typedef struct { +struct EntityTurboSpiker { RSDK_ENTITY StateMachine(state); uint32 type; @@ -25,18 +22,4 @@ typedef struct { Animator shellAnimator; Animator animator; bool32 playedLaunchSfx; -} EntityTurboSpiker; - -extern ObjectTurboSpiker* TurboSpiker; - -extern void (*TurboSpiker_State_Spike)(); -extern void (*TurboSpiker_State_Ember)(); - -void TurboSpiker_EnemyInfoHook(); - -#define OBJ_TURBOSPIKER_SETUP \ - IMPORT_PUBLIC_FUNC(TurboSpiker_State_Spike); \ - IMPORT_PUBLIC_FUNC(TurboSpiker_State_Ember); \ - REGISTER_ENEMY(TurboSpiker) - -#endif //! OBJ_TURBOSPIKER_H +}; diff --git a/src/hypermania/Mania/LRZ/Drillerdroid.h b/src/hypermania/Mania/LRZ/Drillerdroid.h index ce6e98c..d436b90 100644 --- a/src/hypermania/Mania/LRZ/Drillerdroid.h +++ b/src/hypermania/Mania/LRZ/Drillerdroid.h @@ -1,7 +1,4 @@ -#ifndef OBJ_DRILLERDROID_H -#define OBJ_DRILLERDROID_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { DRILLERDROID_MAIN, @@ -9,7 +6,7 @@ typedef enum { DRILLERDROID_UNUSED, } DrillerdroidTypes; -typedef struct { +struct ObjectDrillerdroid { RSDK_OBJECT Hitbox hitboxCore; Hitbox hitboxPistonL; @@ -44,9 +41,9 @@ typedef struct { uint16 sfxDrop; uint16 sfxFail; uint16 sfxClang; -} ObjectDrillerdroid; +}; -typedef struct { +struct EntityDrillerdroid { RSDK_ENTITY uint8 type; StateMachine(state); @@ -60,36 +57,4 @@ typedef struct { int32 timer; uint8 invincibilityTimer; int8 health; -} EntityDrillerdroid; - -extern ObjectDrillerdroid* Drillerdroid; - -extern void (*Drillerdroid_State_SetupArena)(); -extern void (*Drillerdroid_State_AwaitPlayer)(); -extern void (*Drillerdroid_State_FinishDrilling)(); -extern void (*Drillerdroid_State_JumpTargeting)(); -extern void (*Drillerdroid_State_DecidingDropPos)(); -extern void (*Drillerdroid_State_DropFailReset)(); -extern void (*Drillerdroid_State_Destroyed)(); -extern void (*Drillerdroid_State_Finish)(); -extern void (*Drillerdroid_State_DropSignPost)(); -extern void (*Drillerdroid_State_Target)(); -extern void (*Drillerdroid_Hit)(); - -void Drillerdroid_EnemyInfoHook(); - -#define OBJ_DRILLERDROID_SETUP \ - IMPORT_PUBLIC_FUNC(Drillerdroid_State_SetupArena); \ - IMPORT_PUBLIC_FUNC(Drillerdroid_State_AwaitPlayer); \ - IMPORT_PUBLIC_FUNC(Drillerdroid_State_FinishDrilling); \ - IMPORT_PUBLIC_FUNC(Drillerdroid_State_JumpTargeting); \ - IMPORT_PUBLIC_FUNC(Drillerdroid_State_DecidingDropPos); \ - IMPORT_PUBLIC_FUNC(Drillerdroid_State_DropFailReset); \ - IMPORT_PUBLIC_FUNC(Drillerdroid_State_Destroyed); \ - IMPORT_PUBLIC_FUNC(Drillerdroid_State_Finish); \ - IMPORT_PUBLIC_FUNC(Drillerdroid_State_DropSignPost); \ - IMPORT_PUBLIC_FUNC(Drillerdroid_State_Target); \ - IMPORT_PUBLIC_FUNC(Drillerdroid_Hit); \ - REGISTER_ENEMY(Drillerdroid) - -#endif //! OBJ_DRILLERDROID_H +}; diff --git a/src/hypermania/Mania/LRZ/DrillerdroidO.h b/src/hypermania/Mania/LRZ/DrillerdroidO.h index a5c304e..90e24cc 100644 --- a/src/hypermania/Mania/LRZ/DrillerdroidO.h +++ b/src/hypermania/Mania/LRZ/DrillerdroidO.h @@ -1,7 +1,4 @@ -#ifndef OBJ_DRILLERDROIDO_H -#define OBJ_DRILLERDROIDO_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { DRILLERDROIDO_MAIN, @@ -11,7 +8,7 @@ typedef enum { DRILLERDROIDO_UNUSED2, } DrillerdroidOTypes; -typedef struct { +struct ObjectDrillerdroidO { RSDK_OBJECT Hitbox hitboxCore; Hitbox hitboxPistonL; @@ -44,10 +41,10 @@ typedef struct { uint16 sfxJump; uint16 sfxTargeting; uint16 sfxSizzle; -} ObjectDrillerdroidO; +}; // Entity Class -typedef struct { +struct EntityDrillerdroidO { RSDK_ENTITY uint8 type; StateMachine(state); @@ -61,40 +58,4 @@ typedef struct { int32 timer; uint8 invincibilityTimer; int8 health; -} EntityDrillerdroidO; - -extern ObjectDrillerdroidO* DrillerdroidO; - -extern void (*DrillerdroidO_State_Dropping)(); -extern void (*DrillerdroidO_State_Landed)(); -extern void (*DrillerdroidO_State_LandRecoil)(); -extern void (*DrillerdroidO_State_BeginDrilling)(); -extern void (*DrillerdroidO_State_Drilling)(); -extern void (*DrillerdroidO_State_FinishDrilling)(); -extern void (*DrillerdroidO_State_Overheat)(); -extern void (*DrillerdroidO_State_OverheatRecoil)(); -extern void (*DrillerdroidO_State_JumpTargetDelay)(); -extern void (*DrillerdroidO_State_OverheatRecoil_DestroyedSegment)(); -extern void (*DrillerdroidO_State_Cooldown)(); -extern void (*DrillerdroidO_State_ResetFromCooldown)(); -extern void (*DrillerdroidO_State_Destroyed)(); - -void DrillerdroidO_EnemyInfoHook(); - -#define OBJ_DRILLERDROIDO_SETUP \ - IMPORT_PUBLIC_FUNC(DrillerdroidO_State_Dropping); \ - IMPORT_PUBLIC_FUNC(DrillerdroidO_State_Landed); \ - IMPORT_PUBLIC_FUNC(DrillerdroidO_State_LandRecoil); \ - IMPORT_PUBLIC_FUNC(DrillerdroidO_State_BeginDrilling); \ - IMPORT_PUBLIC_FUNC(DrillerdroidO_State_Drilling); \ - IMPORT_PUBLIC_FUNC(DrillerdroidO_State_FinishDrilling); \ - IMPORT_PUBLIC_FUNC(DrillerdroidO_State_Overheat); \ - IMPORT_PUBLIC_FUNC(DrillerdroidO_State_OverheatRecoil); \ - IMPORT_PUBLIC_FUNC(DrillerdroidO_State_JumpTargetDelay); \ - IMPORT_PUBLIC_FUNC(DrillerdroidO_State_OverheatRecoil_DestroyedSegment); \ - IMPORT_PUBLIC_FUNC(DrillerdroidO_State_Cooldown); \ - IMPORT_PUBLIC_FUNC(DrillerdroidO_State_ResetFromCooldown); \ - IMPORT_PUBLIC_FUNC(DrillerdroidO_State_Destroyed); \ - REGISTER_ENEMY(DrillerdroidO) - -#endif //! OBJ_DRILLERDROIDO_H +}; diff --git a/src/hypermania/Mania/LRZ/Fireworm.h b/src/hypermania/Mania/LRZ/Fireworm.h index 19a33b3..5c02c71 100644 --- a/src/hypermania/Mania/LRZ/Fireworm.h +++ b/src/hypermania/Mania/LRZ/Fireworm.h @@ -1,19 +1,16 @@ -#ifndef OBJ_FIREWORM_H -#define OBJ_FIREWORM_H - -#include "GameAPI/Game.h" +#pragma once #define FIREWORM_SEGMENT_COUNT (1 + 4) -typedef struct { +struct ObjectFireworm { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxRange; Animator holeAnimator; uint16 aniFrames; -} ObjectFireworm; +}; -typedef struct { +struct EntityFireworm { RSDK_ENTITY StateMachine(state); Vector2 startPos; @@ -30,16 +27,4 @@ typedef struct { int32 boundsR; Animator bodyAnimators[FIREWORM_SEGMENT_COUNT]; Animator flameAnimators[FIREWORM_SEGMENT_COUNT]; -} EntityFireworm; - -extern ObjectFireworm* Fireworm; - -extern void (*Fireworm_State_FlyAround)(); - -void Fireworm_EnemyInfoHook(); - -#define OBJ_FIREWORM_SETUP \ - IMPORT_PUBLIC_FUNC(Fireworm_State_FlyAround); \ - REGISTER_ENEMY(Fireworm) - -#endif //! OBJ_FIREWORM_H +}; diff --git a/src/hypermania/Mania/LRZ/HPZEmerald.h b/src/hypermania/Mania/LRZ/HPZEmerald.h new file mode 100644 index 0000000..42b576f --- /dev/null +++ b/src/hypermania/Mania/LRZ/HPZEmerald.h @@ -0,0 +1,23 @@ +#pragma once + +typedef enum { + HPZEMERALD_MASTER, + HPZEMERALD_EMERALD_LOW, + HPZEMERALD_EMERALD_HIGH, +} HPZEmeraldTypes; + +struct ObjectHPZEmerald { + RSDK_OBJECT + uint16 aniFrames; +}; + +struct EntityHPZEmerald { + RSDK_ENTITY + StateMachine(state); // unused + uint8 type; + bool32 solid; + Vector2 startPos; + Hitbox *hitbox; + Animator emeraldAnimator; + Animator overlayAnimator; +}; diff --git a/src/hypermania/Mania/LRZ/HeavyKing.h b/src/hypermania/Mania/LRZ/HeavyKing.h index e646ff8..914f0d4 100644 --- a/src/hypermania/Mania/LRZ/HeavyKing.h +++ b/src/hypermania/Mania/LRZ/HeavyKing.h @@ -1,9 +1,6 @@ -#ifndef OBJ_HEAVYKING_H -#define OBJ_HEAVYKING_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectHeavyKing { RSDK_OBJECT TABLE(int32 attackPattern[32], { 0, 0, 1, 0, 2, 2, 1, 0, 0, 1, 1, 2, 0, 2, 0, 0, 2, 1, 1, 2, 1, 0, 1, 0, 2, 2, 0, 1, 0, 0, 2, 1 }); int32 attackPatternPos; @@ -28,9 +25,9 @@ typedef struct { uint16 sfxImpact6; uint16 aniFrames; uint16 cutsceneFrames; -} ObjectHeavyKing; +}; -typedef struct { +struct EntityHeavyKing { RSDK_ENTITY StateMachine(state); StateMachine(stateStore); @@ -48,40 +45,4 @@ typedef struct { Animator electricityAnimator; Animator storedBodyAnimator; Animator storedScepterAnimator; -} EntityHeavyKing; - -extern ObjectHeavyKing* HeavyKing; - -extern void (*HeavyKing_State_JumpToTargetEmerald)(); -extern void (*HeavyKing_State_Leaping)(); -extern void (*HeavyKing_State_LeapToMasterEmerald)(); -extern void (*HeavyKing_State_LandedOnMasterEmerald)(); -extern void (*HeavyKing_State_ChargeStart)(); -extern void (*HeavyKing_State_ChargeStop)(); -extern void (*HeavyKing_State_PrepareHover)(); -extern void (*HeavyKing_State_StartHovering)(); -extern void (*HeavyKing_State_Hovering)(); -extern void (*HeavyKing_State_LaserAttack)(); -extern void (*HeavyKing_State_ExpandRingAttack)(); -extern void (*HeavyKing_State_TwinChargeAttack)(); -extern void (*HeavyKing_Hit)(); - -void HeavyKing_EnemyInfoHook(); - -#define OBJ_HEAVYKING_SETUP \ - IMPORT_PUBLIC_FUNC(HeavyKing_State_JumpToTargetEmerald); \ - IMPORT_PUBLIC_FUNC(HeavyKing_State_Leaping); \ - IMPORT_PUBLIC_FUNC(HeavyKing_State_LeapToMasterEmerald); \ - IMPORT_PUBLIC_FUNC(HeavyKing_State_LandedOnMasterEmerald); \ - IMPORT_PUBLIC_FUNC(HeavyKing_State_ChargeStart); \ - IMPORT_PUBLIC_FUNC(HeavyKing_State_ChargeStop); \ - IMPORT_PUBLIC_FUNC(HeavyKing_State_PrepareHover); \ - IMPORT_PUBLIC_FUNC(HeavyKing_State_StartHovering); \ - IMPORT_PUBLIC_FUNC(HeavyKing_State_Hovering); \ - IMPORT_PUBLIC_FUNC(HeavyKing_State_LaserAttack); \ - IMPORT_PUBLIC_FUNC(HeavyKing_State_ExpandRingAttack); \ - IMPORT_PUBLIC_FUNC(HeavyKing_State_TwinChargeAttack); \ - IMPORT_PUBLIC_FUNC(HeavyKing_Hit); \ - REGISTER_ENEMY(HeavyKing) - -#endif //! OBJ_HEAVYKING_H +}; diff --git a/src/hypermania/Mania/LRZ/HeavyRider.h b/src/hypermania/Mania/LRZ/HeavyRider.h index 95b59a3..a0a4765 100644 --- a/src/hypermania/Mania/LRZ/HeavyRider.h +++ b/src/hypermania/Mania/LRZ/HeavyRider.h @@ -1,7 +1,4 @@ -#ifndef OBJ_HEAVYRIDER_H -#define OBJ_HEAVYRIDER_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { HEAVYRIDER_RIDER, @@ -40,7 +37,7 @@ typedef enum { HEAVYRIDER_WHEEL_RETRACTING, } HeavyRiderWheelStates; -typedef struct { +struct ObjectHeavyRider { RSDK_OBJECT uint8 curAttack; uint8 spikeBallState; @@ -75,9 +72,9 @@ typedef struct { uint16 sfxJump; uint16 sfxCheer; uint16 sfxBumper; -} ObjectHeavyRider; +}; -typedef struct { +struct EntityHeavyRider { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -91,20 +88,4 @@ typedef struct { Animator spikeBallAnimator; Animator fireballAnimator; Animator wheelieAnimator; -} EntityHeavyRider; - -extern ObjectHeavyRider* HeavyRider; - -extern void (*HeavyRider_State_Moving)(); -extern void (*HeavyRider_State_Turning)(); -extern void (*HeavyRider_Hit)(); - -void HeavyRider_EnemyInfoHook(); - -#define OBJ_HEAVYRIDER_SETUP \ - IMPORT_PUBLIC_FUNC(HeavyRider_State_Moving); \ - IMPORT_PUBLIC_FUNC(HeavyRider_State_Turning); \ - IMPORT_PUBLIC_FUNC(HeavyRider_Hit); \ - REGISTER_ENEMY(HeavyRider) - -#endif //! OBJ_HEAVYRIDER_H +}; diff --git a/src/hypermania/Mania/LRZ/Rexon.h b/src/hypermania/Mania/LRZ/Rexon.h index 1f6301e..56646f7 100644 --- a/src/hypermania/Mania/LRZ/Rexon.h +++ b/src/hypermania/Mania/LRZ/Rexon.h @@ -1,7 +1,4 @@ -#ifndef OBJ_REXON_H -#define OBJ_REXON_H - -#include "GameAPI/Game.h" +#pragma once #define REXON_SEGMENT_COUNT (5) @@ -11,7 +8,7 @@ typedef enum { REXON_SHOT, } RexonTypes; -typedef struct { +struct ObjectRexon { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxShell; @@ -20,9 +17,9 @@ typedef struct { uint16 aniFrames; uint16 sfxShot; uint16 sfxExplosion; -} ObjectRexon; +}; -typedef struct { +struct EntityRexon { RSDK_ENTITY StateMachine(state); bool32 noMove; @@ -39,22 +36,4 @@ typedef struct { Animator bodyAnimator; Animator neckAnimator; Animator headAnimator; -} EntityRexon; - -extern ObjectRexon* Rexon; - -extern void (*Rexon_State_Hidden)(); -extern void (*Rexon_State_Rising)(); -extern void (*Rexon_State_Shooting)(); -extern void (*Rexon_State_Destroyed)(); - -void Rexon_EnemyInfoHook(); - -#define OBJ_REXON_SETUP \ - IMPORT_PUBLIC_FUNC(Rexon_State_Hidden); \ - IMPORT_PUBLIC_FUNC(Rexon_State_Rising); \ - IMPORT_PUBLIC_FUNC(Rexon_State_Shooting); \ - IMPORT_PUBLIC_FUNC(Rexon_State_Destroyed); \ - REGISTER_ENEMY(Rexon) - -#endif //! OBJ_REXON_H +}; diff --git a/src/hypermania/Mania/LRZ/RockDrill.h b/src/hypermania/Mania/LRZ/RockDrill.h index c724012..e99f223 100644 --- a/src/hypermania/Mania/LRZ/RockDrill.h +++ b/src/hypermania/Mania/LRZ/RockDrill.h @@ -1,9 +1,6 @@ -#ifndef OBJ_ROCKDRILL_H -#define OBJ_ROCKDRILL_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectRockDrill { RSDK_OBJECT Hitbox hitboxBody; Hitbox hitboxPistonL; @@ -15,9 +12,9 @@ typedef struct { uint16 sfxHit; uint16 sfxExplosion; uint16 sfxDrill; -} ObjectRockDrill; +}; -typedef struct { +struct EntityRockDrill { RSDK_ENTITY StateMachine(state); Animator animator; @@ -34,16 +31,4 @@ typedef struct { int32 pistonMoveDir[2]; int32 drillMoveDir[2]; uint8 invincibilityTimer; -} EntityRockDrill; - -extern ObjectRockDrill* RockDrill; - -extern void (*RockDrill_State_Drilling)(); - -void RockDrill_EnemyInfoHook(); - -#define OBJ_ROCKDRILL_SETUP \ - IMPORT_PUBLIC_FUNC(RockDrill_State_Drilling); \ - REGISTER_ENEMY(RockDrill) - -#endif //! OBJ_ROCKDRILL_H +}; diff --git a/src/hypermania/Mania/LRZ/Toxomister.h b/src/hypermania/Mania/LRZ/Toxomister.h index 9292539..ed81aae 100644 --- a/src/hypermania/Mania/LRZ/Toxomister.h +++ b/src/hypermania/Mania/LRZ/Toxomister.h @@ -1,16 +1,13 @@ -#ifndef OBJ_TOXOMISTER_H -#define OBJ_TOXOMISTER_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectToxomister { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxCloud; uint16 aniFrames; -} ObjectToxomister; +}; -typedef struct { +struct EntityToxomister { RSDK_ENTITY StateMachine(state); Vector2 startPos; @@ -22,16 +19,4 @@ typedef struct { uint16 shakeCount; uint16 prevShakeFlags; Animator animator; -} EntityToxomister; - -extern ObjectToxomister* Toxomister; - -extern void (*Toxomister_State_CreateClouds)(); - -void Toxomister_EnemyInfoHook(); - -#define OBJ_TOXOMISTER_SETUP \ - IMPORT_PUBLIC_FUNC(Toxomister_State_CreateClouds); \ - REGISTER_ENEMY(Toxomister) - -#endif //! OBJ_TOXOMISTER_H +}; diff --git a/src/hypermania/Mania/MMZ/EggPistonsMKII.h b/src/hypermania/Mania/MMZ/EggPistonsMKII.h index f696cff..70c2449 100644 --- a/src/hypermania/Mania/MMZ/EggPistonsMKII.h +++ b/src/hypermania/Mania/MMZ/EggPistonsMKII.h @@ -1,7 +1,4 @@ -#ifndef OBJ_EGGPISTONSMKII_H -#define OBJ_EGGPISTONSMKII_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { EGGPISTON_PISTON, @@ -12,7 +9,7 @@ typedef enum { EGGPISTON_ALARM, } EggPistonMKIITypes; -typedef struct { +struct ObjectEggPistonsMKII { RSDK_OBJECT int32 invincibilityTimer; int32 health; @@ -30,9 +27,9 @@ typedef struct { uint16 sfxElectrify; uint16 sfxExplosion; uint16 sfxAlarm; -} ObjectEggPistonsMKII; +}; -typedef struct { +struct EntityEggPistonsMKII { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -43,22 +40,4 @@ typedef struct { Animator mainAnimator; Animator altAnimator; Hitbox hitbox; -} EntityEggPistonsMKII; - -extern ObjectEggPistonsMKII* EggPistonsMKII; - -extern void (*EggPistonsMKII_State_ClassicMode)(); -extern void (*EggPistonsMKII_State_PinchMode)(); -extern void (*EggPistonsMKII_State_Destroyed)(); -extern void (*EggPistonsMKII_Hit)(); - -void EggPistonsMKII_EnemyInfoHook(); - -#define OBJ_EGGPISTONSMKII_SETUP \ - IMPORT_PUBLIC_FUNC(EggPistonsMKII_State_ClassicMode); \ - IMPORT_PUBLIC_FUNC(EggPistonsMKII_State_PinchMode); \ - IMPORT_PUBLIC_FUNC(EggPistonsMKII_State_Destroyed); \ - IMPORT_PUBLIC_FUNC(EggPistonsMKII_Hit); \ - REGISTER_ENEMY(EggPistonsMKII) - -#endif //! OBJ_EGGPISTONSMKII_H +}; diff --git a/src/hypermania/Mania/MMZ/FarPlane.h b/src/hypermania/Mania/MMZ/FarPlane.h index a1c3321..9cdc71a 100644 --- a/src/hypermania/Mania/MMZ/FarPlane.h +++ b/src/hypermania/Mania/MMZ/FarPlane.h @@ -1,21 +1,28 @@ -#ifndef OBJ_FARPLANE_H -#define OBJ_FARPLANE_H +#pragma once -#include "GameAPI/Game.h" +#define FARPLANE_ENTITY_COUNT (256) -extern ObjectFarPlane* FarPlane; +struct ObjectFarPlane { + RSDK_OBJECT + uint32 aniFrames; + Vector2 screenPos; + Vector2 worldPos; + Vector2 originPos; + Vector2 position; + Vector2 positionList[0x200]; + int32 unused1; + int32 unused2; + int32 unused3; + int32 unused4; + int32 unused5; + uint16 layerID; +}; -extern void (*FarPlane_SetupEntities)(); -extern void (*FarPlane_SetEntityActivities)(uint8 active); - -void FarPlane_LateUpdate_OVERLOAD(); - -void FarPlane_DrawHook_ApplyFarPlane(); -void FarPlane_DrawHook_RemoveFarPlane(); - -#define OBJ_FARPLANE_SETUP \ - IMPORT_PUBLIC_FUNC(FarPlane_SetupEntities); \ - IMPORT_PUBLIC_FUNC(FarPlane_SetEntityActivities); \ - MOD_REGISTER_OBJ_OVERLOAD(FarPlane, NULL, FarPlane_LateUpdate_OVERLOAD, NULL, NULL, NULL, NULL, NULL, NULL, NULL) - -#endif //! OBJ_FARPLANE_H +struct EntityFarPlane { + RSDK_ENTITY + Vector2 size; + Vector2 origin; + uint16 entitySlots[FARPLANE_ENTITY_COUNT]; + int32 entityCount; + Animator animator; +}; diff --git a/src/hypermania/Mania/MMZ/Gachapandora.h b/src/hypermania/Mania/MMZ/Gachapandora.h index 9bc32f8..1e5686a 100644 --- a/src/hypermania/Mania/MMZ/Gachapandora.h +++ b/src/hypermania/Mania/MMZ/Gachapandora.h @@ -1,7 +1,4 @@ -#ifndef OBJ_GACHAPANDORA_H -#define OBJ_GACHAPANDORA_H - -#include "GameAPI/Game.h" +#pragma once #define GACHAPANDORA_CAPSULE_COUNT (4) @@ -17,7 +14,7 @@ typedef enum { GACHAPANDORA_SPARK, } GachapandoraTypes; -typedef struct { +struct ObjectGachapandora { RSDK_OBJECT TABLE(int32 capsuleOffsets[56], { 37, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 49, 50, 50, 50, 51, 51, 51, 51, 52, 52, 52, 52, 53, 53, 53, 53, @@ -63,9 +60,9 @@ typedef struct { uint16 sfxPon; uint16 sfxFireball; uint16 sfxGiggle; -} ObjectGachapandora; +}; -typedef struct { +struct EntityGachapandora { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -85,24 +82,4 @@ typedef struct { Animator handleAnimator; Animator capsuleAnimator; Hitbox hitbox; -} EntityGachapandora; - -extern ObjectGachapandora* Gachapandora; - -extern void (*Gachapandora_StatePrize_DrillerMove)(); -extern void (*Gachapandora_StatePrize_FireDropperMove)(); -extern void (*Gachapandora_StatePrize_AmyWalk)(); -extern void (*Gachapandora_StatePrize_AmyIdle)(); -extern void (*Gachapandora_StatePrize_Destroyed)(); - -void Gachapandora_EnemyInfoHook(); - -#define OBJ_GACHAPANDORA_SETUP \ - IMPORT_PUBLIC_FUNC(Gachapandora_StatePrize_DrillerMove); \ - IMPORT_PUBLIC_FUNC(Gachapandora_StatePrize_FireDropperMove); \ - IMPORT_PUBLIC_FUNC(Gachapandora_StatePrize_AmyWalk); \ - IMPORT_PUBLIC_FUNC(Gachapandora_StatePrize_AmyIdle); \ - IMPORT_PUBLIC_FUNC(Gachapandora_StatePrize_Destroyed); \ - REGISTER_ENEMY(Gachapandora) - -#endif //! OBJ_GACHAPANDORA_H +}; diff --git a/src/hypermania/Mania/MMZ/MechaBu.h b/src/hypermania/Mania/MMZ/MechaBu.h index f078337..0256b67 100644 --- a/src/hypermania/Mania/MMZ/MechaBu.h +++ b/src/hypermania/Mania/MMZ/MechaBu.h @@ -1,9 +1,6 @@ -#ifndef OBJ_MECHABU_H -#define OBJ_MECHABU_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectMechaBu { RSDK_OBJECT TABLE(int32 sawOffsets[10], { -0x150000, -0xF0000, -0x170000, -0xE0000, -0x190000, -0xA0000, -0x1A0000, -0x50000, -0x1A0000, -0x40000 }); Hitbox hitboxSaw; @@ -11,9 +8,9 @@ typedef struct { uint16 aniFrames; uint16 sfxSawUp; uint16 sfxSawDown; -} ObjectMechaBu; +}; -typedef struct { +struct EntityMechaBu { RSDK_ENTITY StateMachine(state); ManiaPlaneFilterTypes planeFilter; @@ -25,20 +22,4 @@ typedef struct { Animator badnikAnimator; Animator hornAnimator; Animator sawAnimator; -} EntityMechaBu; - -extern ObjectMechaBu* MechaBu; - -extern void (*MechaBu_State_Moving)(); -extern void (*MechaBu_State_Stopped)(); -extern void (*MechaBu_State_Falling)(); - -void MechaBu_EnemyInfoHook(); - -#define OBJ_MECHABU_SETUP \ - IMPORT_PUBLIC_FUNC(MechaBu_State_Moving); \ - IMPORT_PUBLIC_FUNC(MechaBu_State_Stopped); \ - IMPORT_PUBLIC_FUNC(MechaBu_State_Falling); \ - REGISTER_ENEMY(MechaBu) - -#endif //! OBJ_MECHABU_H +}; diff --git a/src/hypermania/Mania/MMZ/PlaneSeeSaw.h b/src/hypermania/Mania/MMZ/PlaneSeeSaw.h new file mode 100644 index 0000000..087e7a8 --- /dev/null +++ b/src/hypermania/Mania/MMZ/PlaneSeeSaw.h @@ -0,0 +1,18 @@ +#pragma once + +struct ObjectPlaneSeeSaw { + RSDK_OBJECT + uint16 aniFrames; + uint16 sfxSpring; + uint16 sfxFlipper; +}; + +struct EntityPlaneSeeSaw { + RSDK_ENTITY + StateMachine(state); + int32 unused; + int32 seeSawPos; + Animator platformAnimator; + Animator swingAnimator; + Animator weightAnimator; +}; \ No newline at end of file diff --git a/src/hypermania/Mania/MMZ/PohBee.h b/src/hypermania/Mania/MMZ/PohBee.h index ed55495..5522d2a 100644 --- a/src/hypermania/Mania/MMZ/PohBee.h +++ b/src/hypermania/Mania/MMZ/PohBee.h @@ -1,15 +1,12 @@ -#ifndef OBJ_POHBEE_H -#define OBJ_POHBEE_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectPohBee { RSDK_OBJECT Hitbox hitbox; uint16 aniFrames; -} ObjectPohBee; +}; -typedef struct { +struct EntityPohBee { RSDK_ENTITY StateMachine(state); Vector2 startPos; @@ -26,13 +23,4 @@ typedef struct { uint8 spikeCount; Vector2 amplitude; ManiaPlaneFilterTypes planeFilter; -} EntityPohBee; - -extern ObjectPohBee* PohBee; - -void PohBee_EnemyInfoHook(); - -#define OBJ_POHBEE_SETUP \ - REGISTER_ENEMY(PohBee) - -#endif //! OBJ_POHBEE_H +}; diff --git a/src/hypermania/Mania/MMZ/Scarab.h b/src/hypermania/Mania/MMZ/Scarab.h index de924ad..1f29fad 100644 --- a/src/hypermania/Mania/MMZ/Scarab.h +++ b/src/hypermania/Mania/MMZ/Scarab.h @@ -1,16 +1,13 @@ -#ifndef OBJ_SCARAB_H -#define OBJ_SCARAB_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectScarab { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxGrab; uint16 aniFrames; -} ObjectScarab; +}; -typedef struct { +struct EntityScarab { RSDK_ENTITY StateMachine(state); Vector2 startPos; @@ -29,16 +26,4 @@ typedef struct { uint8 pullCount; int8 moveDir; uint8 grabbedPlayers; -} EntityScarab; - -extern ObjectScarab* Scarab; - -extern void (*Scarab_HandlePlayerRelease)(); - -void Scarab_EnemyInfoHook(); - -#define OBJ_SCARAB_SETUP \ - IMPORT_PUBLIC_FUNC(Scarab_HandlePlayerRelease); \ - REGISTER_ENEMY(Scarab) - -#endif //! OBJ_SCARAB_H +}; diff --git a/src/hypermania/Mania/MSZ/Armadiloid.h b/src/hypermania/Mania/MSZ/Armadiloid.h index e11da38..b09c831 100644 --- a/src/hypermania/Mania/MSZ/Armadiloid.h +++ b/src/hypermania/Mania/MSZ/Armadiloid.h @@ -1,15 +1,12 @@ -#ifndef OBJ_ARMADILOID_H -#define OBJ_ARMADILOID_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectArmadiloid { RSDK_OBJECT uint16 aniFrames; uint16 sfxShot; -} ObjectArmadiloid; +}; -typedef struct { +struct EntityArmadiloid { RSDK_ENTITY StateMachine(state); int32 type; @@ -21,15 +18,4 @@ typedef struct { Animator bodyAnimator; Animator headAnimator; Animator boosterAnimator; -} EntityArmadiloid; - -extern ObjectArmadiloid* Armadiloid; - -void Armadiloid_EnemyInfoHook(); -extern void (*Armadiloid_State_Rider)(); - -#define OBJ_ARMADILOID_SETUP \ - IMPORT_PUBLIC_FUNC(Armadiloid_State_Rider); \ - REGISTER_ENEMY(Armadiloid) - -#endif //! OBJ_ARMADILOID_H +}; diff --git a/src/hypermania/Mania/MSZ/Bumpalo.h b/src/hypermania/Mania/MSZ/Bumpalo.h index ce1b63b..e1011d4 100644 --- a/src/hypermania/Mania/MSZ/Bumpalo.h +++ b/src/hypermania/Mania/MSZ/Bumpalo.h @@ -1,9 +1,6 @@ -#ifndef OBJ_BUMPALO_H -#define OBJ_BUMPALO_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectBumpalo { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxBumper; @@ -15,9 +12,9 @@ typedef struct { uint16 sfxHuff; uint16 sfxClack; uint16 sfxImpact; -} ObjectBumpalo; +}; -typedef struct { +struct EntityBumpalo { RSDK_ENTITY StateMachine(state); Vector2 startPos; @@ -28,13 +25,4 @@ typedef struct { Animator badnikAnimator; Animator huffAnimator; Animator dustAnimator; -} EntityBumpalo; - -extern ObjectBumpalo* Bumpalo; - -void Bumpalo_EnemyInfoHook(); - -#define OBJ_BUMPALO_SETUP \ - REGISTER_ENEMY(Bumpalo) - -#endif //! OBJ_BUMPALO_H +}; diff --git a/src/hypermania/Mania/MSZ/Cactula.h b/src/hypermania/Mania/MSZ/Cactula.h index 51fc6b9..a6a6796 100644 --- a/src/hypermania/Mania/MSZ/Cactula.h +++ b/src/hypermania/Mania/MSZ/Cactula.h @@ -1,16 +1,13 @@ -#ifndef OBJ_CACTULA_H -#define OBJ_CACTULA_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectCactula { RSDK_OBJECT Hitbox hitboxBadnik; uint16 aniFrames; uint16 sfxCactDrop; -} ObjectCactula; +}; -typedef struct { +struct EntityCactula { RSDK_ENTITY StateMachine(state); int32 unused; @@ -19,13 +16,4 @@ typedef struct { Animator bodyTopAnimator; Animator bodyBottomAnimator; Animator propellerAnimator; -} EntityCactula; - -extern ObjectCactula* Cactula; - -void Cactula_EnemyInfoHook(); - -#define OBJ_CACTULA_SETUP \ - REGISTER_ENEMY(Cactula) - -#endif //! OBJ_CACTULA_H +}; diff --git a/src/hypermania/Mania/MSZ/DBTower.h b/src/hypermania/Mania/MSZ/DBTower.h index 7fef0aa..0b77026 100644 --- a/src/hypermania/Mania/MSZ/DBTower.h +++ b/src/hypermania/Mania/MSZ/DBTower.h @@ -1,11 +1,8 @@ -#ifndef OBJ_DBTOWER_H -#define OBJ_DBTOWER_H - -#include "GameAPI/Game.h" +#pragma once #define DBTOWER_SEGMENT_COUNT (4) -typedef struct { +struct ObjectDBTower { RSDK_OBJECT Hitbox hitboxSegment; bool32 defeated; @@ -18,9 +15,9 @@ typedef struct { uint16 sfxRocketJet2; uint16 sfxRockemSockem; uint16 aniFrames; -} ObjectDBTower; +}; -typedef struct { +struct EntityDBTower { RSDK_ENTITY StateMachine(state); int32 timer; @@ -41,18 +38,4 @@ typedef struct { uint8 playerTimers[PLAYER_COUNT]; Animator headAnimator; Animator bodyAnimator; -} EntityDBTower; - -extern ObjectDBTower* DBTower; - -extern void (*DBTower_State_HandleBoss)(); -extern void (*DBTower_State_Destroyed)(); - -void DBTower_EnemyInfoHook(); - -#define OBJ_DBTOWER_SETUP \ - IMPORT_PUBLIC_FUNC(DBTower_State_HandleBoss); \ - IMPORT_PUBLIC_FUNC(DBTower_State_Destroyed); \ - REGISTER_ENEMY(DBTower) - -#endif //! OBJ_DBTOWER_H +}; diff --git a/src/hypermania/Mania/MSZ/Hatterkiller.h b/src/hypermania/Mania/MSZ/Hatterkiller.h index ce79988..912d372 100644 --- a/src/hypermania/Mania/MSZ/Hatterkiller.h +++ b/src/hypermania/Mania/MSZ/Hatterkiller.h @@ -1,20 +1,17 @@ -#ifndef OBJ_HATTERKILLER_H -#define OBJ_HATTERKILLER_H - -#include "GameAPI/Game.h" +#pragma once #define HATTERKILLER_SEGMENT_COUNT (10) -typedef struct { +struct ObjectHatterkiller { RSDK_OBJECT Hitbox hitboxSegment; uint16 sfxRocketJet; uint16 sfxTransform2; uint16 sfxPowerup; uint16 aniFrames; -} ObjectHatterkiller; +}; -typedef struct { +struct EntityHatterkiller { RSDK_ENTITY int32 timer; Vector2 bodyPositions[HATTERKILLER_SEGMENT_COUNT]; @@ -24,13 +21,4 @@ typedef struct { Animator headAnimator; Animator bodyAnimator; Animator tailAnimator; -} EntityHatterkiller; - -extern ObjectHatterkiller* Hatterkiller; - -void Hatterkiller_EnemyInfoHook(); - -#define OBJ_HATTERKILLER_SETUP \ - REGISTER_ENEMY(Hatterkiller) - -#endif //! OBJ_HATTERKILLER_H +}; diff --git a/src/hypermania/Mania/MSZ/HeavyMystic.h b/src/hypermania/Mania/MSZ/HeavyMystic.h index 082582e..5258f8d 100644 --- a/src/hypermania/Mania/MSZ/HeavyMystic.h +++ b/src/hypermania/Mania/MSZ/HeavyMystic.h @@ -1,7 +1,4 @@ -#ifndef OBJ_HEAVYMYSTIC_H -#define OBJ_HEAVYMYSTIC_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { MYSTIC_MISCHIEF, @@ -12,7 +9,7 @@ typedef enum { MYSTIC_DEBRIS, } HeavyMysticTypes; -typedef struct { +struct ObjectHeavyMystic { RSDK_OBJECT int32 boundsL; int32 boundsR; @@ -39,9 +36,9 @@ typedef struct { uint16 sfxAppear1; uint16 aniFrames; uint16 rouguesFrames; -} ObjectHeavyMystic; +}; -typedef struct { +struct EntityHeavyMystic { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -57,41 +54,4 @@ typedef struct { Vector2 targetPos; Animator animator; Hitbox hitbox; -} EntityHeavyMystic; - -extern ObjectHeavyMystic* HeavyMystic; - -extern void (*HeavyMystic_Hit)(); -extern void (*HeavyMystic_StateBoss_RougeHit)(); -extern void (*HeavyMystic_StateBoss_MysticReveal)(); -extern void (*HeavyMystic_StateBoss_FangIdle)(); -extern void (*HeavyMystic_StateBoss_FangTell)(); -extern void (*HeavyMystic_StateBoss_FangHop)(); -extern void (*HeavyMystic_StateBoss_BarkIdle)(); -extern void (*HeavyMystic_StateBoss_BarkPounding)(); -extern void (*HeavyMystic_StateBoss_BarkJump)(); -extern void (*HeavyMystic_StateBoss_BeanIdle)(); -extern void (*HeavyMystic_StateBoss_BeanBomb1Throw)(); -extern void (*HeavyMystic_StateBoss_BeanBomb2Throw)(); -extern void (*HeavyMystic_StateBoss_BeanJump)(); - -void HeavyMystic_EnemyInfoHook(); - -#define OBJ_HEAVYMYSTIC_SETUP \ - IMPORT_PUBLIC_FUNC(HeavyMystic_Hit); \ - HeavyMystic_StateBoss_RougeHit = Mod.GetPublicFunction(NULL, "HeavyMystic_StateBoss_RougeHit"); \ - if (!HeavyMystic_StateBoss_RougeHit) HeavyMystic_StateBoss_RougeHit = Mod.GetPublicFunction(NULL, "HeavyMystic_StateBoss_RogueHit"); \ - IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_MysticReveal); \ - IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_FangIdle); \ - IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_FangTell); \ - IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_FangHop); \ - IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_BarkIdle); \ - IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_BarkPounding); \ - IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_BarkJump); \ - IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_BeanIdle); \ - IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_BeanBomb1Throw); \ - IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_BeanBomb2Throw); \ - IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_BeanJump); \ - REGISTER_ENEMY(HeavyMystic) - -#endif //! OBJ_HEAVYMYSTIC_H +}; diff --git a/src/hypermania/Mania/MSZ/Rattlekiller.h b/src/hypermania/Mania/MSZ/Rattlekiller.h index aa1dbe5..7de32ce 100644 --- a/src/hypermania/Mania/MSZ/Rattlekiller.h +++ b/src/hypermania/Mania/MSZ/Rattlekiller.h @@ -1,18 +1,15 @@ -#ifndef OBJ_RATTLEKILLER_H -#define OBJ_RATTLEKILLER_H - -#include "GameAPI/Game.h" +#pragma once #define RATTLEKILLER_SEGMENT_COUNT (10) -typedef struct { +struct ObjectRattlekiller { RSDK_OBJECT Hitbox hitboxSegment; uint16 sfxRocketJet; uint16 aniFrames; -} ObjectRattlekiller; +}; -typedef struct { +struct EntityRattlekiller { RSDK_ENTITY StateMachine(state); // Unused StateMachine(stateDraw); // Unused @@ -33,13 +30,4 @@ typedef struct { Animator headAnimator; Animator bodyAnimator; Animator tailAnimator; -} EntityRattlekiller; - -extern ObjectRattlekiller* Rattlekiller; - -void Rattlekiller_EnemyInfoHook(); - -#define OBJ_RATTLEKILLER_SETUP \ - REGISTER_ENEMY(Rattlekiller) - -#endif //! OBJ_RATTLEKILLER_H +}; diff --git a/src/hypermania/Mania/MSZ/RollerMKII.h b/src/hypermania/Mania/MSZ/RollerMKII.h index 4b0486e..7670adc 100644 --- a/src/hypermania/Mania/MSZ/RollerMKII.h +++ b/src/hypermania/Mania/MSZ/RollerMKII.h @@ -1,9 +1,6 @@ -#ifndef OBJ_ROLLERMKII_H -#define OBJ_ROLLERMKII_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectRollerMKII { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxObject; @@ -17,9 +14,9 @@ typedef struct { uint16 sfxDropDash; uint16 sfxRelease; uint16 sfxSkidding; -} ObjectRollerMKII; +}; -typedef struct { +struct EntityRollerMKII { RSDK_ENTITY StateMachine(state); Vector2 startPos; @@ -28,18 +25,4 @@ typedef struct { bool32 touchedGround; EntityPlayer* playerPtr; Animator animator; -} EntityRollerMKII; - -extern ObjectRollerMKII* RollerMKII; - -extern void (*RollerMKII_State_Idle)(); -extern void (*RollerMKII_State_SpinUp)(); - -void RollerMKII_EnemyInfoHook(); - -#define OBJ_ROLLERMKII_SETUP \ - IMPORT_PUBLIC_FUNC(RollerMKII_State_Idle); \ - IMPORT_PUBLIC_FUNC(RollerMKII_State_SpinUp); \ - REGISTER_ENEMY(RollerMKII) - -#endif //! OBJ_ROLLERMKII_H +}; diff --git a/src/hypermania/Mania/MSZ/UberCaterkiller.h b/src/hypermania/Mania/MSZ/UberCaterkiller.h index aab9be5..dd6d978 100644 --- a/src/hypermania/Mania/MSZ/UberCaterkiller.h +++ b/src/hypermania/Mania/MSZ/UberCaterkiller.h @@ -1,11 +1,8 @@ -#ifndef OBJ_UBERCATERKILLER_H -#define OBJ_UBERCATERKILLER_H - -#include "GameAPI/Game.h" +#pragma once #define UBERCATERKILLER_SEGMENT_COUNT (10) -typedef struct { +struct ObjectUberCaterkiller { RSDK_OBJECT Hitbox hitboxSegment; bool32 defeated; @@ -17,9 +14,9 @@ typedef struct { uint16 sfxBumper3; uint16 sfxCaterJump; uint16 aniFrames; -} ObjectUberCaterkiller; +}; -typedef struct { +struct EntityUberCaterkiller { RSDK_ENTITY StateMachine(state); int32 timer; @@ -39,22 +36,4 @@ typedef struct { uint8 playerTimers[PLAYER_COUNT]; Animator headAnimator; Animator bodyAnimator; -} EntityUberCaterkiller; - -extern ObjectUberCaterkiller* UberCaterkiller; - -extern void (*UberCaterkiller_State_HorizontalJump)(); -extern void (*UberCaterkiller_State_FirstJump)(); -extern void (*UberCaterkiller_State_RepeatedJumps)(); -extern void (*UberCaterkiller_Hit)(); - -void UberCaterkiller_EnemyInfoHook(); - -#define OBJ_UBERCATERKILLER_SETUP \ - IMPORT_PUBLIC_FUNC(UberCaterkiller_State_HorizontalJump); \ - IMPORT_PUBLIC_FUNC(UberCaterkiller_State_FirstJump); \ - IMPORT_PUBLIC_FUNC(UberCaterkiller_State_RepeatedJumps); \ - IMPORT_PUBLIC_FUNC(UberCaterkiller_Hit); \ - REGISTER_ENEMY(UberCaterkiller) - -#endif //! OBJ_UBERCATERKILLER_H +}; diff --git a/src/hypermania/Mania/MSZ/Vultron.h b/src/hypermania/Mania/MSZ/Vultron.h index 6fde996..aaeb9ec 100644 --- a/src/hypermania/Mania/MSZ/Vultron.h +++ b/src/hypermania/Mania/MSZ/Vultron.h @@ -1,16 +1,13 @@ -#ifndef OBJ_VULTRON_H -#define OBJ_VULTRON_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectVultron { RSDK_OBJECT Hitbox hitboxRange; uint16 aniFrames; uint16 sfxVultron; -} ObjectVultron; +}; -typedef struct { +struct EntityVultron { RSDK_ENTITY StateMachine(state); uint8 type; @@ -22,13 +19,4 @@ typedef struct { Hitbox hitboxBadnik; Animator bodyAnimator; Animator flameAnimator; -} EntityVultron; - -extern ObjectVultron* Vultron; - -void Vultron_EnemyInfoHook(); - -#define OBJ_VULTRON_SETUP \ - REGISTER_ENEMY(Vultron) - -#endif //! OBJ_VULTRON_H +}; diff --git a/src/hypermania/Objects/LevelSelect.h b/src/hypermania/Mania/Menu/LevelSelect.h similarity index 72% rename from src/hypermania/Objects/LevelSelect.h rename to src/hypermania/Mania/Menu/LevelSelect.h index 10a1250..01533a7 100644 --- a/src/hypermania/Objects/LevelSelect.h +++ b/src/hypermania/Mania/Menu/LevelSelect.h @@ -1,7 +1,4 @@ -#ifndef OBJ_LEVELSELECT_H -#define OBJ_LEVELSELECT_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { LSELECT_PLAYER_NONE, @@ -14,7 +11,7 @@ typedef enum { #endif } LevelSelectPlayerIDs; -typedef struct { +struct ObjectLevelSelect { RSDK_OBJECT #if MANIA_USE_PLUS STATIC(int32 bgAniDuration, 240); @@ -46,9 +43,9 @@ typedef struct { int32 soundTestMax; uint16 sfxFail; #endif -} ObjectLevelSelect; +}; -typedef struct { +struct EntityLevelSelect { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -76,20 +73,4 @@ typedef struct { int32 unused3; int32 unused4; #endif -} EntityLevelSelect; - -extern ObjectLevelSelect* LevelSelect; - -// ============================================================================= - -// Functions ------------------------------------------------------------------- - -// ============================================================================= -void LevelSelect_StageLoad_OVERLOAD(); - -#define OBJ_LEVELSELECT_SETUP \ - MOD_REGISTER_OBJ_OVERLOAD(LevelSelect, NULL, NULL, NULL, NULL, NULL, LevelSelect_StageLoad_OVERLOAD, NULL, NULL, NULL) - -void LevelSelect_Cheat_AllEmeralds(); - -#endif //! OBJ_LEVELSELECT_H +}; diff --git a/src/hypermania/Mania/Menu/UISaveSlot.h b/src/hypermania/Mania/Menu/UISaveSlot.h new file mode 100644 index 0000000..02f8d36 --- /dev/null +++ b/src/hypermania/Mania/Menu/UISaveSlot.h @@ -0,0 +1,68 @@ +#pragma once + +typedef enum { + UISAVESLOT_REGULAR, + UISAVESLOT_NOSAVE, +} UISaveSlotTypes; + +struct ObjectUISaveSlot { + RSDK_OBJECT + uint16 aniFrames; +}; + +struct EntityUISaveSlot { + MANIA_UI_ITEM_BASE + bool32 isNewSave; +#if MANIA_USE_PLUS + StateMachine(stateInput); +#endif + int32 listID; + int32 frameID; + int32 saveZoneID; + int32 saveLives; +#if MANIA_USE_PLUS + int32 saveContinues; +#endif + int32 saveEmeralds; +#if MANIA_USE_PLUS + uint8 saveEncorePlayer; + uint8 saveEncoreBuddy; + uint8 saveEncoreFriends[3]; +#endif + UISaveSlotTypes type; + int32 slotID; +#if MANIA_USE_PLUS + bool32 encoreMode; +#endif + bool32 currentlySelected; + int32 zoneIconSprX; + int32 textBounceOffset; + int32 buttonBounceOffset; + int32 textBouncePos; + int32 buttonBouncePos; + int32 fxRadius; +#if MANIA_USE_PLUS + void *fxRuby; + bool32 debugEncoreDraw; + uint8 dCharPoint; + uint8 dCharPartner; + uint8 dCharStock1; + uint8 dCharStock2; + uint8 dCharStock3; +#endif + Animator uiAnimator; + Animator playersAnimator; + Animator shadowsAnimator; + Animator livesAnimator; +#if MANIA_USE_PLUS + Animator continuesAnimator; +#endif + Animator emeraldsAnimator; + Animator zoneIconAnimator; + Animator zoneNameAnimator; + Animator fuzzAnimator; + Animator iconBGAnimator; + Animator saveStatusAnimator; + Animator numbersAnimator; + uint16 textFrames; +}; diff --git a/src/hypermania/Mania/OOZ/Aquis.h b/src/hypermania/Mania/OOZ/Aquis.h index 4aff87d..a9e4238 100644 --- a/src/hypermania/Mania/OOZ/Aquis.h +++ b/src/hypermania/Mania/OOZ/Aquis.h @@ -1,18 +1,15 @@ -#ifndef OBJ_AQUIS_H -#define OBJ_AQUIS_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectAquis { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxRange; Hitbox hitboxProjectile; uint16 aniFrames; uint16 sfxShot; -} ObjectAquis; +}; -typedef struct { +struct EntityAquis { RSDK_ENTITY StateMachine(state); int32 timer; @@ -22,16 +19,4 @@ typedef struct { uint8 startDir; Animator mainAnimator; Animator wingAnimator; -} EntityAquis; - -extern ObjectAquis* Aquis; - -extern void (*Aquis_State_Shot)(); - -void Aquis_EnemyInfoHook(); - -#define OBJ_AQUIS_SETUP \ - IMPORT_PUBLIC_FUNC(Aquis_State_Shot); \ - REGISTER_ENEMY(Aquis) - -#endif //! OBJ_AQUIS_H +}; diff --git a/src/hypermania/Mania/OOZ/MegaOctus.h b/src/hypermania/Mania/OOZ/MegaOctus.h index 85bd90b..909ba33 100644 --- a/src/hypermania/Mania/OOZ/MegaOctus.h +++ b/src/hypermania/Mania/OOZ/MegaOctus.h @@ -1,7 +1,4 @@ -#ifndef OBJ_MEGAOCTUS_H -#define OBJ_MEGAOCTUS_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { MEGAOCTUS_BODY, @@ -16,7 +13,7 @@ typedef enum { MEGAOCTUS_LASERFIRE, } MegaOctusTypes; -typedef struct { +struct ObjectMegaOctus { RSDK_OBJECT Entity* bossEntity; Animator noseAnimator; @@ -43,9 +40,9 @@ typedef struct { uint16 sfxHarpoon; uint16 sfxSurface; uint16 sfxLaserSplash; -} ObjectMegaOctus; +}; -typedef struct { +struct EntityMegaOctus { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -66,35 +63,4 @@ typedef struct { Animator animator; Animator altAnimator; Hitbox hitbox; -} EntityMegaOctus; - -extern ObjectMegaOctus* MegaOctus; - -extern void (*MegaOctus_State_EnterMegaOctus)(); -extern void (*MegaOctus_State_OpenHatchAndLaugh)(); -extern void (*MegaOctus_State_CloseHatch)(); -extern void (*MegaOctus_State_DiveIntoOil)(); -extern void (*MegaOctus_State_SpawnWeapons)(); -extern void (*MegaOctus_State_CannonThenSpawnOrbs)(); -extern void (*MegaOctus_StateOrb_Wait)(); -extern void (*MegaOctus_StateOrb_FireShot)(); -extern void (*MegaOctus_StateOrb_Idle)(); -extern void (*MegaOctus_StateOrb_Destroyed)(); -extern void (*MegaOctus_Hit)(); - -void MegaOctus_EnemyInfoHook(); - -#define OBJ_MEGAOCTUS_SETUP \ - IMPORT_PUBLIC_FUNC(MegaOctus_Hit); \ - IMPORT_PUBLIC_FUNC(MegaOctus_State_OpenHatchAndLaugh); \ - IMPORT_PUBLIC_FUNC(MegaOctus_State_CloseHatch); \ - IMPORT_PUBLIC_FUNC(MegaOctus_State_DiveIntoOil); \ - IMPORT_PUBLIC_FUNC(MegaOctus_State_SpawnWeapons); \ - IMPORT_PUBLIC_FUNC(MegaOctus_State_CannonThenSpawnOrbs); \ - IMPORT_PUBLIC_FUNC(MegaOctus_StateOrb_Wait); \ - IMPORT_PUBLIC_FUNC(MegaOctus_StateOrb_FireShot); \ - IMPORT_PUBLIC_FUNC(MegaOctus_StateOrb_Idle); \ - IMPORT_PUBLIC_FUNC(MegaOctus_StateOrb_Destroyed); \ - REGISTER_ENEMY(MegaOctus) - -#endif //! OBJ_MEGAOCTUS_H +}; diff --git a/src/hypermania/Mania/OOZ/MeterDroid.h b/src/hypermania/Mania/OOZ/MeterDroid.h index c6968d3..e1efffc 100644 --- a/src/hypermania/Mania/OOZ/MeterDroid.h +++ b/src/hypermania/Mania/OOZ/MeterDroid.h @@ -1,9 +1,6 @@ -#ifndef OBJ_METERDROID_H -#define OBJ_METERDROID_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectMeterDroid { RSDK_OBJECT TABLE(int32 debrisSpeeds[21], { 5, 0, 0, -0x20000, -0x28000, 1, 0, 0x20000, -0x20000, 2, 0, -0x28000, -0x10000, 3, 0, 0x28000, -0x10000, 4, 0, 0x10000, 0x10000 }); @@ -23,9 +20,9 @@ typedef struct { uint16 sfxValve; uint16 sfxWrench; uint16 aniFrames; -} ObjectMeterDroid; +}; -typedef struct { +struct EntityMeterDroid { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -45,26 +42,4 @@ typedef struct { Animator propellorAnimator; Animator armAnimator; Animator wrenchAnimator; -} EntityMeterDroid; - -extern ObjectMeterDroid* MeterDroid; - -extern void (*MeterDroid_State_TurningValve)(); -extern void (*MeterDroid_State_StopTurningValve)(); -extern void (*MeterDroid_State_WatchPlatformsPopUp)(); -extern void (*MeterDroid_State_Destroyed)(); -extern void (*MeterDroid_State_FinishAct)(); -extern void (*MeterDroid_Hit)(); - -void MeterDroid_EnemyInfoHook(); - -#define OBJ_METERDROID_SETUP \ - IMPORT_PUBLIC_FUNC(MeterDroid_State_TurningValve); \ - IMPORT_PUBLIC_FUNC(MeterDroid_State_StopTurningValve); \ - IMPORT_PUBLIC_FUNC(MeterDroid_State_WatchPlatformsPopUp); \ - IMPORT_PUBLIC_FUNC(MeterDroid_State_Destroyed); \ - IMPORT_PUBLIC_FUNC(MeterDroid_State_FinishAct); \ - IMPORT_PUBLIC_FUNC(MeterDroid_Hit); \ - REGISTER_ENEMY(MeterDroid) - -#endif //! OBJ_METERDROID_H +}; diff --git a/src/hypermania/Mania/OOZ/OOZSetup.h b/src/hypermania/Mania/OOZ/OOZSetup.h index f4ed656..245edf7 100644 --- a/src/hypermania/Mania/OOZ/OOZSetup.h +++ b/src/hypermania/Mania/OOZ/OOZSetup.h @@ -1,9 +1,6 @@ -#ifndef OBJ_OOZSETUP_H -#define OBJ_OOZSETUP_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectOOZSetup { RSDK_OBJECT int32 palTimer; uint16 aniTiles; @@ -33,13 +30,9 @@ typedef struct { #endif bool32 hasAchievement; Entity *cutscenePtr; -} ObjectOOZSetup; +}; -typedef struct { +struct EntityOOZSetup { RSDK_ENTITY uint8 type; -} EntityOOZSetup; - -extern ObjectOOZSetup *OOZSetup; - -#endif //! OBJ_OOZSETUP_H +}; diff --git a/src/hypermania/Mania/OOZ/Octus.h b/src/hypermania/Mania/OOZ/Octus.h index 790be86..33b8f96 100644 --- a/src/hypermania/Mania/OOZ/Octus.h +++ b/src/hypermania/Mania/OOZ/Octus.h @@ -1,18 +1,15 @@ -#ifndef OBJ_OCTUS_H -#define OBJ_OCTUS_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectOctus { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxProjectile; Hitbox hitboxRange; uint16 aniFrames; uint16 sfxShot; -} ObjectOctus; +}; -typedef struct { +struct EntityOctus { RSDK_ENTITY StateMachine(state); int32 timer; @@ -21,16 +18,4 @@ typedef struct { uint8 startDir; int32 unused2; Animator animator; -} EntityOctus; - -extern ObjectOctus* Octus; - -extern void (*Octus_State_Shot)(); - -void Octus_EnemyInfoHook(); - -#define OBJ_OCTUS_SETUP \ - IMPORT_PUBLIC_FUNC(Octus_State_Shot); \ - REGISTER_ENEMY(Octus) - -#endif //! OBJ_OCTUS_H +}; diff --git a/src/hypermania/Mania/OOZ/Sol.h b/src/hypermania/Mania/OOZ/Sol.h index ffa552b..c281eba 100644 --- a/src/hypermania/Mania/OOZ/Sol.h +++ b/src/hypermania/Mania/OOZ/Sol.h @@ -1,18 +1,15 @@ -#ifndef OBJ_SOL_H -#define OBJ_SOL_H - -#include "GameAPI/Game.h" +#pragma once #define SOL_FLAMEORB_COUNT (4) -typedef struct { +struct ObjectSol { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxOrb; uint16 aniFrames; -} ObjectSol; +}; -typedef struct { +struct EntitySol { RSDK_ENTITY StateMachine(state); Vector2 startPos; @@ -24,22 +21,4 @@ typedef struct { bool32 fireOrbs; Animator mainAnimator; Animator ballAnimator; -} EntitySol; - -extern ObjectSol* Sol; - -extern void (*Sol_State_Moving)(); -extern void (*Sol_State_ShootingOrbs)(); -extern void (*Sol_State_NoOrbs)(); -extern void (*Sol_State_ActiveFireball)(); - -void Sol_EnemyInfoHook(); - -#define OBJ_SOL_SETUP \ - IMPORT_PUBLIC_FUNC(Sol_State_Moving); \ - IMPORT_PUBLIC_FUNC(Sol_State_ShootingOrbs); \ - IMPORT_PUBLIC_FUNC(Sol_State_NoOrbs); \ - IMPORT_PUBLIC_FUNC(Sol_State_ActiveFireball); \ - REGISTER_ENEMY(Sol) - -#endif //! OBJ_SOL_H +}; diff --git a/src/hypermania/Mania/PGZ/Dragonfly.h b/src/hypermania/Mania/PGZ/Dragonfly.h index af064b1..5669fe4 100644 --- a/src/hypermania/Mania/PGZ/Dragonfly.h +++ b/src/hypermania/Mania/PGZ/Dragonfly.h @@ -1,18 +1,15 @@ -#ifndef OBJ_DRAGONFLY_H -#define OBJ_DRAGONFLY_H - -#include "GameAPI/Game.h" +#pragma once #define DRAGONFLY_SPINE_COUNT (6) -typedef struct { +struct ObjectDragonfly { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxSpine; uint16 aniFrames; -} ObjectDragonfly; +}; -typedef struct { +struct EntityDragonfly { RSDK_ENTITY StateMachine(state); uint8 dir; @@ -24,16 +21,4 @@ typedef struct { Animator animator; Animator wingAnimator; Animator bodyAnimator; -} EntityDragonfly; - -extern ObjectDragonfly* Dragonfly; - -extern void (*Dragonfly_State_Move)(); - -void Dragonfly_EnemyInfoHook(); - -#define OBJ_DRAGONFLY_SETUP \ - IMPORT_PUBLIC_FUNC(Dragonfly_State_Move); \ - REGISTER_ENEMY(Dragonfly) - -#endif //! OBJ_DRAGONFLY_H +}; diff --git a/src/hypermania/Mania/PGZ/HeavyShinobi.h b/src/hypermania/Mania/PGZ/HeavyShinobi.h index 86bb95d..c9120f9 100644 --- a/src/hypermania/Mania/PGZ/HeavyShinobi.h +++ b/src/hypermania/Mania/PGZ/HeavyShinobi.h @@ -1,9 +1,6 @@ -#ifndef OBJ_HEAVYSHINOBI_H -#define OBJ_HEAVYSHINOBI_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectHeavyShinobi { RSDK_OBJECT int8 health; uint8 invincibilityTimer; @@ -32,9 +29,9 @@ typedef struct { uint16 sfxSlash; uint16 sfxStick; uint16 sfxThrow; -} ObjectHeavyShinobi; +}; -typedef struct { +struct EntityHeavyShinobi { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -45,23 +42,4 @@ typedef struct { Vector2 playerDistance; Animator mainAnimator; Animator fxAnimator; -} EntityHeavyShinobi; - -extern ObjectHeavyShinobi* HeavyShinobi; - -void HeavyShinobi_EnemyInfoHook(void); -extern void (*HeavyShinobi_State_Idle)(); -extern void (*HeavyShinobi_State_Slash)(); -extern void (*HeavyShinobi_State_Jump)(); -extern void (*HeavyShinobi_State_Glitched)(); -extern void (*HeavyShinobi_State_Destroyed)(); - -#define OBJ_HEAVYSHINOBI_SETUP \ - IMPORT_PUBLIC_FUNC(HeavyShinobi_State_Idle); \ - IMPORT_PUBLIC_FUNC(HeavyShinobi_State_Slash); \ - IMPORT_PUBLIC_FUNC(HeavyShinobi_State_Jump); \ - IMPORT_PUBLIC_FUNC(HeavyShinobi_State_Glitched); \ - IMPORT_PUBLIC_FUNC(HeavyShinobi_State_Destroyed); \ - REGISTER_ENEMY(HeavyShinobi) - -#endif //! OBJ_HEAVYSHINOBI_H \ No newline at end of file +}; diff --git a/src/hypermania/Mania/PGZ/IceBomba.h b/src/hypermania/Mania/PGZ/IceBomba.h index dbb71f0..2d84449 100644 --- a/src/hypermania/Mania/PGZ/IceBomba.h +++ b/src/hypermania/Mania/PGZ/IceBomba.h @@ -1,9 +1,6 @@ -#ifndef OBJ_ICEBOMBA_H -#define OBJ_ICEBOMBA_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectIceBomba { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxBomb; @@ -11,9 +8,9 @@ typedef struct { uint16 aniFrames; uint16 sfxExplosion; uint16 sfxFreeze; -} ObjectIceBomba; +}; -typedef struct { +struct EntityIceBomba { RSDK_ENTITY StateMachine(state); uint8 dir; @@ -25,20 +22,4 @@ typedef struct { Animator bodyAnimator; Animator wingAnimator; Animator bombAnimator; -} EntityIceBomba; - -extern ObjectIceBomba* IceBomba; - -extern void (*IceBomba_State_Flying)(); -extern void (*IceBomba_State_Turning)(); -extern void (*IceBomba_State_FlyAway)(); - -void IceBomba_EnemyInfoHook(); - -#define OBJ_ICEBOMBA_SETUP \ - IMPORT_PUBLIC_FUNC(IceBomba_State_Flying); \ - IMPORT_PUBLIC_FUNC(IceBomba_State_Turning); \ - IMPORT_PUBLIC_FUNC(IceBomba_State_FlyAway); \ - REGISTER_ENEMY(IceBomba) - -#endif //! OBJ_ICEBOMBA_H +}; diff --git a/src/hypermania/Mania/PGZ/JuggleSaw.h b/src/hypermania/Mania/PGZ/JuggleSaw.h index 6027b13..1444ddf 100644 --- a/src/hypermania/Mania/PGZ/JuggleSaw.h +++ b/src/hypermania/Mania/PGZ/JuggleSaw.h @@ -1,13 +1,10 @@ -#ifndef OBJ_JUGGLESAW_H -#define OBJ_JUGGLESAW_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { JUGGLESAW_NO_SAW = 0, JUGGLESAW_HAS_SAW = 1, JUGGLESAW_AWAITING_SAW = 2 } JuggleSawMode; #define JUGGLESAW_MAX_FRIENDS (8) -typedef struct { +struct ObjectJuggleSaw { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxFriendRange; @@ -18,9 +15,9 @@ typedef struct { uint16 sfxExplode; uint16 sfxJuggle; uint16 sfxThrow; -} ObjectJuggleSaw; +}; -typedef struct { +struct EntityJuggleSaw { RSDK_ENTITY StateMachine(state); uint16 sawDelay; @@ -33,18 +30,4 @@ typedef struct { Vector2 startPos; uint8 startDir; Animator animator; -} EntityJuggleSaw; - -extern ObjectJuggleSaw* JuggleSaw; - -extern void (*JuggleSaw_StateCrab_Handle)(); -extern void (*JuggleSaw_StateCrab_ThrowSaw)(); - -void JuggleSaw_EnemyInfoHook(); - -#define OBJ_JUGGLESAW_SETUP \ - IMPORT_PUBLIC_FUNC(JuggleSaw_StateCrab_Handle); \ - IMPORT_PUBLIC_FUNC(JuggleSaw_StateCrab_ThrowSaw); \ - REGISTER_ENEMY(JuggleSaw) - -#endif //! OBJ_JUGGLESAW_H +}; diff --git a/src/hypermania/Mania/PGZ/Shiversaw.h b/src/hypermania/Mania/PGZ/Shiversaw.h index c848f5d..b78364d 100644 --- a/src/hypermania/Mania/PGZ/Shiversaw.h +++ b/src/hypermania/Mania/PGZ/Shiversaw.h @@ -1,11 +1,8 @@ -#ifndef OBJ_SHIVERSAW_H -#define OBJ_SHIVERSAW_H - -#include "GameAPI/Game.h" +#pragma once #define SHIVERSAW_SAW_COUNT (2) -typedef struct { +struct ObjectShiversaw { RSDK_OBJECT uint8 health; uint8 invincibilityTimer; @@ -26,9 +23,9 @@ typedef struct { uint16 sfxTargeting; uint16 sfxRocketJet; uint16 sfxExplosion3; -} ObjectShiversaw; +}; -typedef struct { +struct EntityShiversaw { RSDK_ENTITY StateMachine(state); StateMachine(stateSaw[SHIVERSAW_SAW_COUNT]); @@ -52,22 +49,4 @@ typedef struct { Animator armAnimator; Animator spinnerAnimator; Animator sawAnimator[SHIVERSAW_SAW_COUNT]; -} EntityShiversaw; - -extern ObjectShiversaw* Shiversaw; - -extern void (*Shiversaw_State_Idle)(); -extern void (*Shiversaw_State_MoveToPlayer)(); -extern void (*Shiversaw_State_HitRecoil)(); -extern void (*Shiversaw_Hit)(); - -void Shiversaw_EnemyInfoHook(); - -#define OBJ_SHIVERSAW_SETUP \ - IMPORT_PUBLIC_FUNC(Shiversaw_State_Idle); \ - IMPORT_PUBLIC_FUNC(Shiversaw_State_MoveToPlayer); \ - IMPORT_PUBLIC_FUNC(Shiversaw_State_HitRecoil); \ - IMPORT_PUBLIC_FUNC(Shiversaw_Hit); \ - REGISTER_ENEMY(Shiversaw) - -#endif //! OBJ_SHIVERSAW_H \ No newline at end of file +}; diff --git a/src/hypermania/Mania/PGZ/Woodrow.h b/src/hypermania/Mania/PGZ/Woodrow.h index 7188de9..9385bfc 100644 --- a/src/hypermania/Mania/PGZ/Woodrow.h +++ b/src/hypermania/Mania/PGZ/Woodrow.h @@ -1,9 +1,6 @@ -#ifndef OBJ_WOODROW_H -#define OBJ_WOODROW_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectWoodrow { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxFullRange; @@ -12,9 +9,9 @@ typedef struct { uint16 aniFrames; uint16 sfxExplosion; uint16 sfxPeck; -} ObjectWoodrow; +}; -typedef struct { +struct EntityWoodrow { RSDK_ENTITY StateMachine(state); uint8 type; @@ -29,20 +26,4 @@ typedef struct { uint8 startDir; void* parent; Animator animator; -} EntityWoodrow; - -extern ObjectWoodrow* Woodrow; - -extern void (*Woodrow_State_Idle)(); -extern void (*Woodrow_State_MoveUp)(); -extern void (*Woodrow_State_MoveDown)(); - -void Woodrow_EnemyInfoHook(); - -#define OBJ_WOODROW_SETUP \ - IMPORT_PUBLIC_FUNC(Woodrow_State_Idle); \ - IMPORT_PUBLIC_FUNC(Woodrow_State_MoveUp); \ - IMPORT_PUBLIC_FUNC(Woodrow_State_MoveDown); \ - REGISTER_ENEMY(Woodrow) - -#endif //! OBJ_WOODROW_H +}; diff --git a/src/hypermania/Mania/SPZ/Canista.h b/src/hypermania/Mania/SPZ/Canista.h index 71ff108..062c1ea 100644 --- a/src/hypermania/Mania/SPZ/Canista.h +++ b/src/hypermania/Mania/SPZ/Canista.h @@ -1,9 +1,6 @@ -#ifndef OBJ_CANISTA_H -#define OBJ_CANISTA_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectCanista { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxRange; @@ -11,9 +8,9 @@ typedef struct { Hitbox hitboxProjectile; uint16 aniFrames; uint16 sfxPon; -} ObjectCanista; +}; -typedef struct { +struct EntityCanista { RSDK_ENTITY StateMachine(state); uint8 triggerMode; @@ -34,18 +31,4 @@ typedef struct { Animator mainAnimator; Animator tapeAnimator; Animator cannonAnimator; -} EntityCanista; - -extern ObjectCanista* Canista; - -extern void (*Canista_State_Moving)(); -extern void (*Canista_State_Idle)(); - -void Canista_EnemyInfoHook(); - -#define OBJ_CANISTA_SETUP \ - IMPORT_PUBLIC_FUNC(Canista_State_Moving); \ - IMPORT_PUBLIC_FUNC(Canista_State_Idle); \ - REGISTER_ENEMY(Canista) - -#endif //! OBJ_CANISTA_H +}; diff --git a/src/hypermania/Mania/SPZ/MicDrop.h b/src/hypermania/Mania/SPZ/MicDrop.h index 9e54604..a7ebe2a 100644 --- a/src/hypermania/Mania/SPZ/MicDrop.h +++ b/src/hypermania/Mania/SPZ/MicDrop.h @@ -1,17 +1,14 @@ -#ifndef OBJ_MICDROP_H -#define OBJ_MICDROP_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectMicDrop { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxRange; uint16 aniFrames; uint16 sfxElectrify; -} ObjectMicDrop; +}; -typedef struct { +struct EntityMicDrop { RSDK_ENTITY StateMachine(state); Animator bodyAnimator; @@ -23,13 +20,4 @@ typedef struct { int32 swingVel; int32 radius; int32 swingPos; -} EntityMicDrop; - -extern ObjectMicDrop* MicDrop; - -void MicDrop_EnemyInfoHook(); - -#define OBJ_MICDROP_SETUP \ - REGISTER_ENEMY(MicDrop) - -#endif //! OBJ_MICDROP_H +}; diff --git a/src/hypermania/Mania/SPZ/Shutterbug.h b/src/hypermania/Mania/SPZ/Shutterbug.h index 05a6da4..72c170f 100644 --- a/src/hypermania/Mania/SPZ/Shutterbug.h +++ b/src/hypermania/Mania/SPZ/Shutterbug.h @@ -1,18 +1,15 @@ -#ifndef OBJ_SHUTTERBUG_H -#define OBJ_SHUTTERBUG_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectShutterbug { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxAchievement; uint32 pictureCount; uint16 aniFrames; uint16 snapSfx; -} ObjectShutterbug; +}; -typedef struct { +struct EntityShutterbug { RSDK_ENTITY StateMachine(state); uint8 snaps; @@ -29,13 +26,4 @@ typedef struct { Hitbox hitboxRange; Animator animator; Animator overlayAnimator; -} EntityShutterbug; - -extern ObjectShutterbug* Shutterbug; - -void Shutterbug_EnemyInfoHook(); - -#define OBJ_SHUTTERBUG_SETUP \ - REGISTER_ENEMY(Shutterbug) - -#endif //! OBJ_SHUTTERBUG_H +}; diff --git a/src/hypermania/Mania/SPZ/Tubinaut.h b/src/hypermania/Mania/SPZ/Tubinaut.h index 5070d0b..c349bb9 100644 --- a/src/hypermania/Mania/SPZ/Tubinaut.h +++ b/src/hypermania/Mania/SPZ/Tubinaut.h @@ -1,11 +1,8 @@ -#ifndef OBJ_TUBINAUT_H -#define OBJ_TUBINAUT_H - -#include "GameAPI/Game.h" +#pragma once #define TUBINAUT_ORB_COUNT (3) -typedef struct { +struct ObjectTubinaut { RSDK_OBJECT Hitbox hitboxFace; Hitbox hitboxOrb; @@ -13,9 +10,9 @@ typedef struct { uint16 aniFrames; uint16 sfxPowerdown; uint16 sfxRepel; -} ObjectTubinaut; +}; -typedef struct { +struct EntityTubinaut { RSDK_ENTITY StateMachine(state); StateMachine(orbState); @@ -34,16 +31,4 @@ typedef struct { int32 timer; uint16 distanceRemain; uint16 distance; -} EntityTubinaut; - -extern ObjectTubinaut* Tubinaut; - -extern void (*Tubinaut_State_Move)(); - -void Tubinaut_EnemyInfoHook(); - -#define OBJ_TUBINAUT_SETUP \ - IMPORT_PUBLIC_FUNC(Tubinaut_State_Move); \ - REGISTER_ENEMY(Tubinaut) - -#endif //! OBJ_TUBINAUT_H +}; diff --git a/src/hypermania/Mania/SPZ/WeatherMobile.h b/src/hypermania/Mania/SPZ/WeatherMobile.h index dff0bbd..7401536 100644 --- a/src/hypermania/Mania/SPZ/WeatherMobile.h +++ b/src/hypermania/Mania/SPZ/WeatherMobile.h @@ -1,7 +1,4 @@ -#ifndef OBJ_WEATHERMOBILE_H -#define OBJ_WEATHERMOBILE_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { WEATHERMOBILE_EGGMAN, @@ -13,7 +10,7 @@ typedef enum { WEATHERMOBILE_CLOUD, } WeatherMobileTypes; -typedef struct { +struct ObjectWeatherMobile { RSDK_OBJECT TABLE(int32 debrisInfo[29], { 4, 0, 0, -0x20000, -0x28000, 1, 0, -0x20000, -0x28000, 2, 0, 0x20000, -0x20000, 3, 0, 0x28000, -0x20000, 4, 0, -0x10000, -0x10000, 5, 0, 0x10000, -0x10000, 6, 0, -0x8000, -0x10000 }); @@ -36,9 +33,9 @@ typedef struct { bool32 playingRainSfx; uint16 aniFrames; uint16 eggmanFrames; -} ObjectWeatherMobile; +}; -typedef struct { +struct EntityWeatherMobile { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -58,24 +55,4 @@ typedef struct { Animator radarDishLAnimator; Animator radarDishRAnimator; Hitbox hitbox; -} EntityWeatherMobile; - -extern ObjectWeatherMobile* WeatherMobile; - -extern void (*WeatherMobile_State_EnterEggman)(); -extern void (*WeatherMobile_State_HandleMovement)(); -extern void (*WeatherMobile_State_WindAttack)(); -extern void (*WeatherMobile_State_SunAttack)(); -extern void (*WeatherMobile_Hit)(); - -void WeatherMobile_EnemyInfoHook(); - -#define OBJ_WEATHERMOBILE_SETUP \ - IMPORT_PUBLIC_FUNC(WeatherMobile_State_EnterEggman); \ - IMPORT_PUBLIC_FUNC(WeatherMobile_State_HandleMovement); \ - IMPORT_PUBLIC_FUNC(WeatherMobile_State_WindAttack); \ - IMPORT_PUBLIC_FUNC(WeatherMobile_State_SunAttack); \ - IMPORT_PUBLIC_FUNC(WeatherMobile_Hit); \ - REGISTER_ENEMY(WeatherMobile) - -#endif //! OBJ_WEATHERMOBILE_H +}; diff --git a/src/hypermania/Mania/SSZ/Dango.h b/src/hypermania/Mania/SSZ/Dango.h index 24f17da..9edac6f 100644 --- a/src/hypermania/Mania/SSZ/Dango.h +++ b/src/hypermania/Mania/SSZ/Dango.h @@ -1,17 +1,14 @@ -#ifndef OBJ_DANGO_H -#define OBJ_DANGO_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectDango { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxCurlRange; uint16 aniFrames; uint16 sfxBumper; -} ObjectDango; +}; -typedef struct { +struct EntityDango { RSDK_ENTITY StateMachine(state); int32 timer; @@ -20,28 +17,4 @@ typedef struct { Vector2 startPos; uint8 startDir; Animator animator; -} EntityDango; - -extern ObjectDango* Dango; - -extern void (*Dango_State_Walking)(); -extern void (*Dango_State_Turning)(); -extern void (*Dango_State_Falling_Uncurled)(); -extern void (*Dango_State_Curling)(); -extern void (*Dango_State_Rolling)(); -extern void (*Dango_State_Falling_Curled)(); -extern void (*Dango_State_Uncurling)(); - -void Dango_EnemyInfoHook(); - -#define OBJ_DANGO_SETUP \ - IMPORT_PUBLIC_FUNC(Dango_State_Walking); \ - IMPORT_PUBLIC_FUNC(Dango_State_Turning); \ - IMPORT_PUBLIC_FUNC(Dango_State_Falling_Uncurled); \ - IMPORT_PUBLIC_FUNC(Dango_State_Curling); \ - IMPORT_PUBLIC_FUNC(Dango_State_Rolling); \ - IMPORT_PUBLIC_FUNC(Dango_State_Falling_Curled); \ - IMPORT_PUBLIC_FUNC(Dango_State_Uncurling); \ - REGISTER_ENEMY(Dango) - -#endif //! OBJ_DANGO_H +}; diff --git a/src/hypermania/Mania/SSZ/GigaMetal.h b/src/hypermania/Mania/SSZ/GigaMetal.h index b81f350..ef7e68d 100644 --- a/src/hypermania/Mania/SSZ/GigaMetal.h +++ b/src/hypermania/Mania/SSZ/GigaMetal.h @@ -1,7 +1,4 @@ -#ifndef OBJ_GIGAMETAL_H -#define OBJ_GIGAMETAL_H - -#include "GameAPI/Game.h" +#pragma once #if MANIA_USE_PLUS @@ -19,7 +16,7 @@ typedef enum { GIGAMETAL_SHARD, } GigaMetalAniIDs; -typedef struct { +struct ObjectGigaMetal { RSDK_OBJECT int32 invincibleTimer; int32 explodeTimer; @@ -33,9 +30,9 @@ typedef struct { Hitbox hitboxHand; Hitbox hitboxCore; Hitbox hitboxHead; -} ObjectGigaMetal; +}; -typedef struct { +struct EntityGigaMetal { RSDK_ENTITY StateMachine(state); StateMachine(stateDraw); @@ -60,24 +57,6 @@ typedef struct { uint8 frameID; int32 rotationAngles[3]; int32 laserSize; -} EntityGigaMetal; - -extern ObjectGigaMetal* GigaMetal; - -extern void (*GigaMetal_StateBody_Marching)(); -extern void (*GigaMetal_Hit)(); - -void GigaMetal_EnemyInfoHook(); - -#define OBJ_GIGAMETAL_SETUP \ - IMPORT_PUBLIC_FUNC(GigaMetal_StateBody_Marching); \ - IMPORT_PUBLIC_FUNC(GigaMetal_Hit); \ - REGISTER_ENEMY(GigaMetal) - -#else - -#define OBJ_GIGAMETAL_SETUP +}; #endif - -#endif //! OBJ_GIGAMETAL_H diff --git a/src/hypermania/Mania/SSZ/Hotaru.h b/src/hypermania/Mania/SSZ/Hotaru.h index 502ad8c..bff6cc9 100644 --- a/src/hypermania/Mania/SSZ/Hotaru.h +++ b/src/hypermania/Mania/SSZ/Hotaru.h @@ -1,7 +1,4 @@ -#ifndef OBJ_HOTARU_H -#define OBJ_HOTARU_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { HOTARU_ATTACK_IDLE, @@ -9,7 +6,7 @@ typedef enum { HOTARU_ATTACK_ATTACKING, } HotaruAttackStates; -typedef struct { +struct ObjectHotaru { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxTrigger; @@ -17,9 +14,9 @@ typedef struct { int32 unused2; Hitbox hitboxElectricity; uint16 aniFrames; -} ObjectHotaru; +}; -typedef struct { +struct EntityHotaru { RSDK_ENTITY StateMachine(state); uint8 quality; @@ -44,13 +41,4 @@ typedef struct { Animator mainAnimator; Animator bulbAnimator; Animator electricityAnimator; -} EntityHotaru; - -extern ObjectHotaru* Hotaru; - -void Hotaru_EnemyInfoHook(); - -#define OBJ_HOTARU_SETUP \ - REGISTER_ENEMY(Hotaru) - -#endif //! OBJ_HOTARU_H +}; diff --git a/src/hypermania/Mania/SSZ/HotaruHiWatt.h b/src/hypermania/Mania/SSZ/HotaruHiWatt.h index a216224..3a413b0 100644 --- a/src/hypermania/Mania/SSZ/HotaruHiWatt.h +++ b/src/hypermania/Mania/SSZ/HotaruHiWatt.h @@ -1,7 +1,4 @@ -#ifndef OBJ_HOTARUHIWATT_H -#define OBJ_HOTARUHIWATT_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { HHW_BOSS, @@ -15,7 +12,7 @@ typedef enum { HHW_ELECTRICORB, } HHWTypes; -typedef struct { +struct ObjectHotaruHiWatt { RSDK_OBJECT TABLE(int32 debrisInfo[33], { 8, 0, 0, -0x20000, -0x28000, 1, 0, 0x20000, -0x28000, 2, 0, -0x28000, -0x20000, 3, 0, 0x28000, -0x20000, @@ -38,9 +35,9 @@ typedef struct { uint16 sfxCharge; uint16 aniFrames; uint16 hotaruFrames; -} ObjectHotaruHiWatt; +}; -typedef struct { +struct EntityHotaruHiWatt { RSDK_ENTITY StateMachine(state); StateMachine(nextState); @@ -63,46 +60,4 @@ typedef struct { Animator bulbFlashAnimator; Animator laserImpactAnimator; Hitbox hitbox; -} EntityHotaruHiWatt; - -extern ObjectHotaruHiWatt* HotaruHiWatt; - -extern void (*HotaruHiWatt_StateBoss_Appear)(); -extern void (*HotaruHiWatt_StateBoss_FlyUp)(); -extern void (*HotaruHiWatt_StateBoss_LaserAttackDelay)(); -extern void (*HotaruHiWatt_StateBoss_ChargingLaser)(); -extern void (*HotaruHiWatt_StateBoss_FinishedLaserAttack)(); -extern void (*HotaruHiWatt_StateBoss_LaserAttack_Left)(); -extern void (*HotaruHiWatt_StateBoss_LaserAttack_Right)(); -extern void (*HotaruHiWatt_StateHotaru_Charging)(); -extern void (*HotaruHiWatt_StateHotaru_Attacking)(); -extern void (*HotaruHiWatt_StateHotaru_FinishedAttack)(); -extern void (*HotaruHiWatt_StateHotaru_EndAttackSequence)(); -extern void (*HotaruHiWatt_StateHotaruPair_AttackMovingDown)(); -extern void (*HotaruHiWatt_StateHotaruPair_AttackMovingUp)(); -extern void (*HotaruHiWatt_SetupHHWReappear)(); -extern void (*HotaruHiWatt_SpawnPairHotarus)(); -extern void (*HotaruHiWatt_Hit)(); - -void HotaruHiWatt_EnemyInfoHook(); - -#define OBJ_HOTARUHIWATT_SETUP \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateBoss_Appear); \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateBoss_FlyUp); \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateBoss_LaserAttackDelay); \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateBoss_LaserAttack_Left); \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateBoss_LaserAttack_Right); \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateBoss_ChargingLaser); \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateBoss_FinishedLaserAttack); \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateHotaru_Charging); \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateHotaru_Attacking); \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateHotaru_FinishedAttack); \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateHotaru_EndAttackSequence); \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateHotaruPair_AttackMovingDown); \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateHotaruPair_AttackMovingUp); \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_SetupHHWReappear); \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_SpawnPairHotarus); \ - IMPORT_PUBLIC_FUNC(HotaruHiWatt_Hit); \ - REGISTER_ENEMY(HotaruHiWatt) - -#endif //! OBJ_HOTARUHIWATT_H +}; diff --git a/src/hypermania/Mania/SSZ/HotaruMKII.h b/src/hypermania/Mania/SSZ/HotaruMKII.h index 25d609c..3947d43 100644 --- a/src/hypermania/Mania/SSZ/HotaruMKII.h +++ b/src/hypermania/Mania/SSZ/HotaruMKII.h @@ -1,9 +1,6 @@ -#ifndef OBJ_HOTARUMKII_H -#define OBJ_HOTARUMKII_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectHotaruMKII { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxLaser; @@ -12,9 +9,9 @@ typedef struct { uint16 sfxLaser; uint16 sfxFly; uint16 sfxCharge; -} ObjectHotaruMKII; +}; -typedef struct { +struct EntityHotaruMKII { RSDK_ENTITY StateMachine(state); Vector2 startPos; @@ -37,18 +34,4 @@ typedef struct { Animator mainAnimator; Animator flashAnimator; Animator unusedAnimator; -} EntityHotaruMKII; - -extern ObjectHotaruMKII* HotaruMKII; - -extern void (*HotaruMKII_State_Charging)(); -extern void (*HotaruMKII_State_LaserAttack)(); - -void HotaruMKII_EnemyInfoHook(); - -#define OBJ_HOTARUMKII_SETUP \ - IMPORT_PUBLIC_FUNC(HotaruMKII_State_Charging); \ - IMPORT_PUBLIC_FUNC(HotaruMKII_State_LaserAttack); \ - REGISTER_ENEMY(HotaruMKII) - -#endif //! OBJ_HOTARUMKII_H +}; diff --git a/src/hypermania/Mania/SSZ/Kabasira.h b/src/hypermania/Mania/SSZ/Kabasira.h index 0d01605..2e674fd 100644 --- a/src/hypermania/Mania/SSZ/Kabasira.h +++ b/src/hypermania/Mania/SSZ/Kabasira.h @@ -1,18 +1,15 @@ -#ifndef OBJ_KABASIRA_H -#define OBJ_KABASIRA_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectKabasira { RSDK_OBJECT Hitbox hitboxBadnik; Vector2 onScreenRange; uint16 aniFrames; uint16 sfxPon; uint16 sfxExplosion2; -} ObjectKabasira; +}; -typedef struct { +struct EntityKabasira { RSDK_ENTITY StateMachine(state); int32 unused1; @@ -23,16 +20,4 @@ typedef struct { Animator bodyAnimator; Animator wingsAnimator; int32 unused3; -} EntityKabasira; - -extern ObjectKabasira* Kabasira; - -extern void (*Kabasira_State_Moving)(); - -void Kabasira_EnemyInfoHook(); - -#define OBJ_KABASIRA_SETUP \ - IMPORT_PUBLIC_FUNC(Kabasira_State_Moving); \ - REGISTER_ENEMY(Kabasira) - -#endif //! OBJ_KABASIRA_H +}; diff --git a/src/hypermania/Mania/SSZ/Kanabun.h b/src/hypermania/Mania/SSZ/Kanabun.h index 3826888..5ea2479 100644 --- a/src/hypermania/Mania/SSZ/Kanabun.h +++ b/src/hypermania/Mania/SSZ/Kanabun.h @@ -1,15 +1,12 @@ -#ifndef OBJ_KANABUN_H -#define OBJ_KANABUN_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectKanabun { RSDK_OBJECT Hitbox hitboxBadnik; uint16 aniFrames; -} ObjectKanabun; +}; -typedef struct { +struct EntityKanabun { RSDK_ENTITY StateMachine(state); int32 unused; @@ -20,13 +17,4 @@ typedef struct { uint8 bobDist; uint8 angleVel; Animator animator; -} EntityKanabun; - -extern ObjectKanabun* Kanabun; - -void Kanabun_EnemyInfoHook(); - -#define OBJ_KANABUN_SETUP \ - REGISTER_ENEMY(Kanabun) - -#endif //! OBJ_KANABUN_H +}; diff --git a/src/hypermania/Mania/SSZ/MetalSonic.h b/src/hypermania/Mania/SSZ/MetalSonic.h index 8bda0d6..e1be6d3 100644 --- a/src/hypermania/Mania/SSZ/MetalSonic.h +++ b/src/hypermania/Mania/SSZ/MetalSonic.h @@ -1,7 +1,4 @@ -#ifndef OBJ_METALSONIC_H -#define OBJ_METALSONIC_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { MS_ANI_IDLE, @@ -26,7 +23,7 @@ typedef enum { MS_ATTACK_BALL, } MetalSonicAttackIDs; -typedef struct { +struct ObjectMetalSonic { RSDK_OBJECT int32 unused; int32 invincibilityTimerPanel; @@ -52,9 +49,9 @@ typedef struct { Hitbox hitboxHover; Hitbox hitboxDash; uint16 aniFrames; -} ObjectMetalSonic; +}; -typedef struct { +struct EntityMetalSonic { RSDK_ENTITY StateMachine(state); Vector2 targetPos; @@ -77,25 +74,4 @@ typedef struct { Hitbox* innerBox; Animator metalSonicAnimator; Animator boosterAnimator; -} EntityMetalSonic; - -extern ObjectMetalSonic* MetalSonic; - -// hopefully this works because i dont feel like compiling a pre-mania Game.so to test it lol -#if !MANIA_USE_PLUS - extern void (*MetalSonic_State_Hover_Phase2)(); - extern void (*MetalSonic_State_FinishAttack_Phase2)(); - extern void (*MetalSonic_Hit)(); - - void MetalSonic_EnemyInfoHook(); - - #define OBJ_METALSONIC_SETUP \ - IMPORT_PUBLIC_FUNC(MetalSonic_State_Hover_Phase2); \ - IMPORT_PUBLIC_FUNC(MetalSonic_State_FinishAttack_Phase2); \ - IMPORT_PUBLIC_FUNC(MetalSonic_Hit); \ - REGISTER_ENEMY(MetalSonic) -#else - #define OBJ_METALSONIC_SETUP -#endif - -#endif //! OBJ_METALSONIC_H +}; diff --git a/src/hypermania/Mania/TMZ/BallHog.h b/src/hypermania/Mania/TMZ/BallHog.h index e5f45c2..4595712 100644 --- a/src/hypermania/Mania/TMZ/BallHog.h +++ b/src/hypermania/Mania/TMZ/BallHog.h @@ -1,9 +1,6 @@ -#ifndef OBJ_BALLHOG_H -#define OBJ_BALLHOG_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectBallHog { RSDK_OBJECT Hitbox hitboxBadnik; Hitbox hitboxBomb; @@ -12,9 +9,9 @@ typedef struct { uint16 sfxArrowHit; uint16 sfxDrop; uint16 sfxJump; -} ObjectBallHog; +}; -typedef struct { +struct EntityBallHog { RSDK_ENTITY StateMachine(state); uint8 numJumps; @@ -24,16 +21,4 @@ typedef struct { Vector2 startPos; uint8 startDir; Animator animator; -} EntityBallHog; - -extern ObjectBallHog *BallHog; - -extern void (*BallHog_State_Bomb)(); - -void BallHog_EnemyInfoHook(); - -#define OBJ_BALLHOG_SETUP \ - IMPORT_PUBLIC_FUNC(BallHog_State_Bomb); \ - REGISTER_ENEMY(BallHog) - -#endif //! OBJ_BALLHOG_H +}; diff --git a/src/hypermania/Mania/TMZ/CrimsonEye.h b/src/hypermania/Mania/TMZ/CrimsonEye.h index ca644f1..feae843 100644 --- a/src/hypermania/Mania/TMZ/CrimsonEye.h +++ b/src/hypermania/Mania/TMZ/CrimsonEye.h @@ -1,7 +1,4 @@ -#ifndef OBJ_CRIMSONEYE_H -#define OBJ_CRIMSONEYE_H - -#include "GameAPI/Game.h" +#pragma once typedef enum { CRIMSONEYE_CONTAINER, @@ -18,7 +15,7 @@ typedef enum { CE_ARROW_OFF = 0xFF, } CrimsonEyeArrowTypes; -typedef struct { +struct ObjectCrimsonEye { RSDK_OBJECT TABLE(int32 debrisInfo[97], { 24, 0, 0, -0x28000, -0x28000, 1, 0, -0x14000, -0x28000, 2, 0, 0x14000, -0x26000, 3, 0, 0x28000, -0x26000, 4, 0, -0x26000, @@ -63,9 +60,9 @@ typedef struct { uint16 sfxImpact; TileLayer* liftBackground; TileLayer* bg2Layer; -} ObjectCrimsonEye; +}; -typedef struct { +struct EntityCrimsonEye { RSDK_ENTITY StateMachine(state); StateMachine(stateEye); @@ -76,22 +73,4 @@ typedef struct { int32 ballRadiusTimer; Vector2 originPos; Animator animator; -} EntityCrimsonEye; - -extern ObjectCrimsonEye* CrimsonEye; - -extern void (*CrimsonEye_StateCore_ContainerActive)(); -extern void (*CrimsonEye_StateCore_Hovering)(); -extern void (*CrimsonEye_StateCore_ImpactLift)(); -extern void (*CrimsonEye_Hit)(); - -void CrimsonEye_EnemyInfoHook(); - -#define OBJ_CRIMSONEYE_SETUP \ - IMPORT_PUBLIC_FUNC(CrimsonEye_StateCore_ContainerActive); \ - IMPORT_PUBLIC_FUNC(CrimsonEye_StateCore_Hovering); \ - IMPORT_PUBLIC_FUNC(CrimsonEye_StateCore_ImpactLift); \ - IMPORT_PUBLIC_FUNC(CrimsonEye_Hit); \ - REGISTER_ENEMY(CrimsonEye) - -#endif //! OBJ_CRIMSONEYE_H +}; diff --git a/src/hypermania/Mania/TMZ/FlasherMKII.h b/src/hypermania/Mania/TMZ/FlasherMKII.h index f289a6b..df12911 100644 --- a/src/hypermania/Mania/TMZ/FlasherMKII.h +++ b/src/hypermania/Mania/TMZ/FlasherMKII.h @@ -1,16 +1,13 @@ -#ifndef OBJ_FLASHERMKII_H -#define OBJ_FLASHERMKII_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectFlasherMKII { RSDK_OBJECT uint16 aniFrames; uint16 sfxFlop; uint16 sfxZap; -} ObjectFlasherMKII; +}; -typedef struct { +struct EntityFlasherMKII { RSDK_ENTITY StateMachine(state); uint8 orientation; @@ -18,13 +15,4 @@ typedef struct { int32 timer; Vector2 startPos; Animator animator; -} EntityFlasherMKII; - -extern ObjectFlasherMKII* FlasherMKII; - -void FlasherMKII_EnemyInfoHook(); - -#define OBJ_FLASHERMKII_SETUP \ - REGISTER_ENEMY(FlasherMKII) - -#endif //! OBJ_FLASHERMKII_H +}; diff --git a/src/hypermania/Mania/TMZ/SentryBug.h b/src/hypermania/Mania/TMZ/SentryBug.h index 79296ea..68ad00b 100644 --- a/src/hypermania/Mania/TMZ/SentryBug.h +++ b/src/hypermania/Mania/TMZ/SentryBug.h @@ -1,9 +1,6 @@ -#ifndef OBJ_SENTRYBUG_H -#define OBJ_SENTRYBUG_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectSentryBug { RSDK_OBJECT TABLE(int32 orbOffsets_Attatched[84], { -0x50000, 0x30000, -0x90000, 0xA0000, -0x70000, 0x100000, 0x70000, 0x30000, 0x30000, 0xA0000, -0x30000, 0x100000, -0x70000, 0x30000, -0xB0000, 0xA0000, -0x80000, 0x100000, 0x90000, 0x30000, @@ -22,9 +19,9 @@ typedef struct { uint16 aniFrames; uint16 sfxPon; uint16 sfxSwarm; -} ObjectSentryBug; +}; -typedef struct { +struct EntitySentryBug { RSDK_ENTITY StateMachine(state); StateMachine(stateOrbs); @@ -48,26 +45,4 @@ typedef struct { Matrix matWorld; Animator bugAnimator; Animator orbAnimator; -} EntitySentryBug; - -extern ObjectSentryBug* SentryBug; - -extern void (*SentryBug_State_AwaitPlayer)(); -extern void (*SentryBug_State_DropOrbs)(); -extern void (*SentryBug_State_NetAppear)(); -extern void (*SentryBug_State_NetShrink)(); -extern void (*SentryBug_State_NetFlash)(); -extern void (*SentryBug_State_ReturnToSlots)(); - -void SentryBug_EnemyInfoHook(); - -#define OBJ_SENTRYBUG_SETUP \ - IMPORT_PUBLIC_FUNC(SentryBug_State_AwaitPlayer); \ - IMPORT_PUBLIC_FUNC(SentryBug_State_DropOrbs); \ - IMPORT_PUBLIC_FUNC(SentryBug_State_NetAppear); \ - IMPORT_PUBLIC_FUNC(SentryBug_State_NetShrink); \ - IMPORT_PUBLIC_FUNC(SentryBug_State_NetFlash); \ - IMPORT_PUBLIC_FUNC(SentryBug_State_ReturnToSlots); \ - REGISTER_ENEMY(SentryBug) - -#endif //! OBJ_SENTRYBUG_H +}; diff --git a/src/hypermania/Mania/TMZ/TurboTurtle.h b/src/hypermania/Mania/TMZ/TurboTurtle.h index 413e1e2..6b2a912 100644 --- a/src/hypermania/Mania/TMZ/TurboTurtle.h +++ b/src/hypermania/Mania/TMZ/TurboTurtle.h @@ -1,17 +1,14 @@ -#ifndef OBJ_TURBOTURTLE_H -#define OBJ_TURBOTURTLE_H +#pragma once -#include "GameAPI/Game.h" - -typedef struct { +struct ObjectTurboTurtle { RSDK_OBJECT Hitbox hitboxBadnik; uint16 aniFrames; uint16 sfxWalk; uint16 sfxWalk2; -} ObjectTurboTurtle; +}; -typedef struct { +struct EntityTurboTurtle { RSDK_ENTITY StateMachine(state); Vector2 startPos; @@ -37,13 +34,4 @@ typedef struct { int32 rightFanDuration; int32 rightFanStrength; int32 rightFanLength; -} EntityTurboTurtle; - -extern ObjectTurboTurtle* TurboTurtle; - -void TurboTurtle_EnemyInfoHook(); - -#define OBJ_TURBOTURTLE_SETUP \ - REGISTER_ENEMY(TurboTurtle) - -#endif //! OBJ_TURBOTURTLE_H +}; diff --git a/src/hypermania/Mania/UFO/SpecialClear.h b/src/hypermania/Mania/UFO/SpecialClear.h new file mode 100644 index 0000000..fc5d836 --- /dev/null +++ b/src/hypermania/Mania/UFO/SpecialClear.h @@ -0,0 +1,79 @@ +#pragma once + +typedef enum { + SC_MSG_SPECIALCLEAR, + SC_MSG_GOTEMERALD, + SC_MSG_ALLEMERALDS, + SC_MSG_SUPER, +} SpecialClearTypes; + +typedef enum { + SC_ANI_SONIC, + SC_ANI_TAILS, + SC_ANI_KNUX, +#if MANIA_USE_PLUS + SC_ANI_MIGHTY, + SC_ANI_RAY, +#endif + SC_ANI_BONUS, + SC_ANI_NUMBERS, + SC_ANI_EMERALDS, +#if MANIA_USE_PLUS + SC_ANI_CONTINUE, +#endif +} SpecialClearAniIDs; + +struct ObjectSpecialClear { + RSDK_OBJECT + uint16 aniFrames; +#if !MANIA_USE_PLUS + uint16 continueFrames; +#endif + uint16 sfxScoreAdd; + uint16 sfxScoreTotal; + uint16 sfxEvent; + uint16 sfxSpecialWarp; + uint16 sfxContinue; + uint16 sfxEmerald; +}; + +struct EntitySpecialClear { + RSDK_ENTITY + StateMachine(state); + bool32 isBSS; + int32 messageType; + int32 timer; + bool32 showFade; + bool32 continueIconVisible; + bool32 hasContinues; + int32 fillColor; + int32 score; + int32 score1UP; + int32 lives; + int32 ringBonus; + int32 perfectBonus; + int32 machBonus; + Vector2 messagePos1; + Vector2 messagePos2; + Vector2 scoreBonusPos; + Vector2 ringBonusPos; + Vector2 perfectBonusPos; + Vector2 machBonusPos; + Vector2 continuePos; + int32 emeraldPositions[7]; + int32 emeraldSpeeds[7]; + int32 unused1; + int32 unused2; + int32 unused3; + int32 unused4; + int32 unused5; + int32 unused6; + int32 unused7; + int32 unused8; + bool32 saveInProgress; + Animator playerNameAnimator; + Animator bonusAnimator; + Animator numbersAnimator; + Animator emeraldsAnimator; + Animator continueAnimator; +}; \ No newline at end of file diff --git a/src/hypermania/Mania/UFO/UFO_Player.h b/src/hypermania/Mania/UFO/UFO_Player.h new file mode 100644 index 0000000..bda8bcd --- /dev/null +++ b/src/hypermania/Mania/UFO/UFO_Player.h @@ -0,0 +1,56 @@ +#pragma once + +struct ObjectUFO_Player { + RSDK_OBJECT + int32 maxSpeed; + uint16 aniFrames; // unused + uint16 sfxJump; + uint16 sfxCharge; + uint16 sfxRelease; + uint16 sfxLoseRings; + uint16 sfxDrop; + uint16 sfxBumper; + uint16 sfxSpring; + uint16 sfxSkid; + uint16 sfxGrittyGround; + uint16 jogModel; + uint16 dashModel; + uint16 jumpModel; + uint16 ballModel; + uint16 tumbleModel; + uint16 sceneIndex; +}; + +struct EntityUFO_Player { + RSDK_ENTITY + StateMachine(state); + int32 machQuota1; + int32 machQuota2; + int32 machQuota3; + int32 startingRings; + int32 timer; + int32 courseOutTimer; + int32 angleX; + int32 height; + int32 gravityStrength; + int32 angleZ; + int32 velDivisor; + int32 bumperTimer; + int32 angleVel; + int32 skidTimer; + Entity *camera; + Entity *circuitPtr; + Matrix matRotate; + Matrix matTransform; + Matrix matWorld; + Matrix matNormal; + StateMachine(stateInput); + int32 controllerID; + bool32 up; + bool32 down; + bool32 left; + bool32 right; + bool32 jumpPress; + bool32 jumpHold; + Animator animator; +}; diff --git a/src/hypermania/Mania/UFO/UFO_Setup.h b/src/hypermania/Mania/UFO/UFO_Setup.h new file mode 100644 index 0000000..7fa0e82 --- /dev/null +++ b/src/hypermania/Mania/UFO/UFO_Setup.h @@ -0,0 +1,33 @@ +#pragma once + +struct ObjectUFO_Setup { + RSDK_OBJECT + StateMachine(deformCB); + int32 timedOut; +#if MANIA_USE_PLUS + bool32 encoreStage; +#endif + int32 machLevel; + int32 scoreBonus; + int32 machPoints; + int32 rings; + int32 timer; + int32 ringFrame; + int32 ringPan; + int32 spherePan; + int32 specialStageID; + int32 machQuotas[3]; + uint8 playFieldLayer; + uint16 sfxBlueSphere; + uint16 sfxSSExit; + uint16 sfxEmerald; + uint16 sfxEvent; + bool32 resetToTitle; +}; + +struct EntityUFO_Setup { + RSDK_ENTITY + StateMachine(state); + int32 timer; + color fadeColor; +}; diff --git a/src/hypermania/ModFunctions.h b/src/hypermania/ModFunctions.h index 880a3b5..52c38c1 100644 --- a/src/hypermania/ModFunctions.h +++ b/src/hypermania/ModFunctions.h @@ -1,30 +1,10 @@ -#ifndef MODFUNCTIONS_H -#define MODFUNCTIONS_H +#pragma once #include "HyperManiaVariables.h" - -#include "Objects/Player.h" -#include "Mania/Global/SaveGame.h" -#include "Mania/Global/Animals.h" -#include "Mania/Global/Camera.h" -#include "Mania/Common/CollapsingPlatform.h" -#include "Objects/Debris.h" -#include "Mania/Global/Explosion.h" -#include "Mania/Cutscene/FXFade.h" -#include "Mania/Global/ItemBox.h" -#include "Mania/Global/Ring.h" -#include "Mania/Global/ScoreBonus.h" -#include "Mania/Global/Zone.h" -#include "Mania/Global/Music.h" -#include "Mania/Global/PauseMenu.h" -#include "Mania/Global/InvincibleStars.h" - -#include "Mania/CPZ/CPZSetup.h" -#include "Mania/OOZ/OOZSetup.h" -#include "Mania/HCZ/HCZSetup.h" -#include "Mania/MMZ/FarPlane.h" -#include "Mania/ERZ/ERZStart.h" -#include "Mania/BSS/BSS_Setup.h" +#include "Mania/All.h" +#include "mod/All.h" +#include "link/All.h" +#include "new/All.h" extern bool32 HPZ_SuperSpecialStage; // bad hack variable for testing purposes, will be removed later, please understand @@ -104,5 +84,3 @@ void HMAPI_ScreenFlash(EntityPlayer* player, float intensity); void HMAPI_BadnikScreenClear(EntityPlayer* player); void HMAPI_ItemBoxScreenClear(EntityPlayer* player, bool32 force); void AddAPIFunctions(); - -#endif //MODFUNCTIONS_H \ No newline at end of file diff --git a/src/hypermania/Objects/All.c b/src/hypermania/Objects/All.c deleted file mode 100644 index 0b74352..0000000 --- a/src/hypermania/Objects/All.c +++ /dev/null @@ -1,64 +0,0 @@ -#include "ModFunctions.h" - -#include "Mania/Global/SaveGame.c" -#include "Mania/Global/Animals.c" -#include "Mania/Global/Camera.c" -#include "Mania/Common/CollapsingPlatform.c" -#include "Mania/Global/Explosion.c" -#include "Mania/Cutscene/FXFade.c" -#include "Mania/Global/Ring.c" -#include "Mania/Global/ScoreBonus.c" -#include "Mania/Global/ItemBox.c" -#include "Mania/Global/Zone.c" -#include "Mania/Global/Music.c" -#include "Mania/Global/PauseMenu.c" -#include "Mania/Global/InvincibleStars.c" - -#include "Mania/CPZ/CPZSetup.c" -#include "Mania/OOZ/OOZSetup.c" -#include "Mania/HCZ/HCZSetup.c" -#include "Mania/MMZ/FarPlane.c" -#include "Mania/ERZ/ERZStart.c" -#include "Mania/BSS/BSS_Setup.c" - -// im sorry jesus -typedef struct { - int32 type; // -1 means untransformed - Animator animator; -} HPZEmeraldExt; - -// left to right ordering converted to a centered origin that fans out with a left-leaning bias -uint32 super_emerald_lookup[7] = { 5, 3, 1, 0, 2, 4, 6 }; // linear order -> super emerald order -uint32 super_emerald_revlookup[7] = { 3, 2, 4, 1, 5, 0, 6 }; // super emerald order -> linear order - -// Sonic 3's emerald order is identical to Mania's with the exceptions being blue/purple and cyan/red are flipped -uint32 sonic3_emerald_lookup[7] = { 0, 1, 3, 2, 4, 6, 5 }; - - -#include "Player.c" -#include "ImageTrail.c" -#include "SpecialRing.c" -#include "UFO_Setup.c" -#include "UFO_Player.c" -#include "HUD.c" -#include "UISaveSlot.c" -#include "LevelSelect.c" -#include "PlaneSeeSaw.c" -#include "Debris.c" - -#include "SuperFlicky.c" -#include "HyperStars.c" -#include "JetGlideEffect.c" - -struct { - uint16 aniFrames; - uint16 sfxSpecialWarp; -} HPZEmeraldStaticExt; - -#include "HPZ/HPZSetup.c" -#include "HPZ/HPZIntro.c" -#include "HPZ/HPZBeam.c" -#include "HPZ/HPZEmerald.c" -#include "SpecialClear.c" - -#include "Enemy.c" diff --git a/src/hypermania/Objects/Debris.h b/src/hypermania/Objects/Debris.h deleted file mode 100644 index 10893ad..0000000 --- a/src/hypermania/Objects/Debris.h +++ /dev/null @@ -1,36 +0,0 @@ -#ifndef OBJ_DEBRIS_H -#define OBJ_DEBRIS_H - -#include "GameAPI/Game.h" - -typedef struct { - RSDK_OBJECT -} ObjectDebris; - -typedef struct { - RSDK_ENTITY - StateMachine(state); - int32 timer; - int32 gravityStrength; - int32 rotSpeed; - Vector2 scaleSpeed; - int32 delay; - Animator animator; -} EntityDebris; - -extern ObjectDebris* Debris; - -// ============================================================================= - -// Functions ------------------------------------------------------------------- - -// ============================================================================= -extern void (*Debris_State_Move)(); -extern void (*Debris_State_FallAndFlicker)(); - -void Debris_Draw_OVERLOAD(); - -#define OBJ_DEBRIS_SETUP \ - MOD_REGISTER_OBJ_OVERLOAD(Debris, NULL, NULL, NULL, Debris_Draw_OVERLOAD, NULL, NULL, NULL, NULL, NULL) - -#endif //! OBJ_DEBRIS_H diff --git a/src/hypermania/Objects/Enemy.c b/src/hypermania/Objects/Enemy.c deleted file mode 100644 index f84173b..0000000 --- a/src/hypermania/Objects/Enemy.c +++ /dev/null @@ -1,85 +0,0 @@ -#include "Enemy.h" - -#include "Mania/ERZ/PhantomMystic.c" -#include "Mania/ERZ/PhantomShinobi.c" -#include "Mania/ERZ/PhantomEgg.c" -#include "Mania/TMZ/CrimsonEye.c" -#include "Mania/MMZ/Gachapandora.c" -#include "Mania/MMZ/EggPistonsMKII.c" -#include "Mania/LRZ/RockDrill.c" -#include "Mania/LRZ/HeavyKing.c" -#include "Mania/LRZ/HeavyRider.c" -#include "Mania/LRZ/DrillerdroidO.c" -#include "Mania/LRZ/Drillerdroid.c" -#include "Mania/OOZ/MegaOctus.c" -#include "Mania/OOZ/MeterDroid.c" -#include "Mania/MSZ/HeavyMystic.c" -#include "Mania/MSZ/DBTower.c" -#include "Mania/MSZ/UberCaterkiller.c" -#include "Mania/HCZ/LaundroMobile.c" -#include "Mania/SSZ/GigaMetal.c" -#include "Mania/SSZ/MetalSonic.c" -#include "Mania/SSZ/HotaruHiWatt.c" -#include "Mania/PGZ/HeavyShinobi.c" -#include "Mania/PGZ/Shiversaw.c" -#include "Mania/FBZ/BigSqueeze.c" -#include "Mania/SPZ/WeatherMobile.c" -#include "Mania/CPZ/AmoebaDroid.c" -#include "Mania/GHZ/DERobot.c" -#include "Mania/GHZ/DDWrecker.c" - -#include "Mania/TMZ/FlasherMKII.c" -#include "Mania/TMZ/TurboTurtle.c" -#include "Mania/TMZ/SentryBug.c" -#include "Mania/TMZ/BallHog.c" -#include "Mania/MMZ/PohBee.c" -#include "Mania/MMZ/Scarab.c" -#include "Mania/MMZ/MechaBu.c" -#include "Mania/LRZ/Fireworm.c" -#include "Mania/LRZ/Rexon.c" -#include "Mania/LRZ/Toxomister.c" -#include "Mania/OOZ/Octus.c" -#include "Mania/OOZ/Sol.c" -#include "Mania/OOZ/Aquis.c" -#include "Mania/MSZ/Rattlekiller.c" -#include "Mania/MSZ/RollerMKII.c" -#include "Mania/MSZ/Vultron.c" -#include "Mania/MSZ/Bumpalo.c" -#include "Mania/MSZ/Armadiloid.c" -#include "Mania/MSZ/Cactula.c" -#include "Mania/MSZ/Hatterkiller.c" -#include "Mania/HCZ/TurboSpiker.c" -#include "Mania/HCZ/Buggernaut.c" -#include "Mania/HCZ/MegaChopper.c" -#include "Mania/HCZ/Jawz.c" -#include "Mania/HCZ/Jellygnite.c" -#include "Mania/HCZ/Blastoid.c" -#include "Mania/HCZ/Pointdexter.c" -#include "Mania/SSZ/Kabasira.c" -#include "Mania/SSZ/Dango.c" -#include "Mania/SSZ/Kanabun.c" -#include "Mania/SSZ/HotaruMKII.c" -#include "Mania/SSZ/Hotaru.c" -#include "Mania/PGZ/Woodrow.c" -#include "Mania/PGZ/Dragonfly.c" -#include "Mania/PGZ/IceBomba.c" -#include "Mania/PGZ/JuggleSaw.c" -#include "Mania/FBZ/FBZTrash.c" -#include "Mania/FBZ/Technosqueek.c" -#include "Mania/FBZ/Clucker.c" -#include "Mania/FBZ/Blaster.c" -#include "Mania/SPZ/Shutterbug.c" -#include "Mania/SPZ/Canista.c" -#include "Mania/SPZ/Tubinaut.c" -#include "Mania/SPZ/MicDrop.c" -#include "Mania/CPZ/Grabber.c" -#include "Mania/CPZ/Spiny.c" -#include "Mania/CPZ/CaterkillerJr.c" -#include "Mania/CPZ/Bubbler.c" -#include "Mania/GHZ/Splats.c" -#include "Mania/GHZ/Newtron.c" -#include "Mania/GHZ/Chopper.c" -#include "Mania/GHZ/Crabmeat.c" -#include "Mania/GHZ/Batbrain.c" -#include "Mania/GHZ/Motobug.c" -#include "Mania/GHZ/BuzzBomber.c" \ No newline at end of file diff --git a/src/hypermania/Objects/Enemy.h b/src/hypermania/Objects/Enemy.h deleted file mode 100644 index a29e7f0..0000000 --- a/src/hypermania/Objects/Enemy.h +++ /dev/null @@ -1,176 +0,0 @@ -#include "GameAPI/Game.h" - -#include "Mania/ERZ/PhantomMystic.h" -#include "Mania/ERZ/PhantomShinobi.h" -#include "Mania/ERZ/PhantomEgg.h" -#include "Mania/TMZ/CrimsonEye.h" -#include "Mania/MMZ/Gachapandora.h" -#include "Mania/MMZ/EggPistonsMKII.h" -#include "Mania/LRZ/RockDrill.h" -#include "Mania/LRZ/HeavyKing.h" -#include "Mania/LRZ/HeavyRider.h" -#include "Mania/LRZ/DrillerdroidO.h" -#include "Mania/LRZ/Drillerdroid.h" -#include "Mania/OOZ/MegaOctus.h" -#include "Mania/OOZ/MeterDroid.h" -#include "Mania/MSZ/HeavyMystic.h" -#include "Mania/MSZ/DBTower.h" -#include "Mania/MSZ/UberCaterkiller.h" -#include "Mania/HCZ/LaundroMobile.h" -#include "Mania/SSZ/GigaMetal.h" -#include "Mania/SSZ/MetalSonic.h" -#include "Mania/SSZ/HotaruHiWatt.h" -#include "Mania/PGZ/HeavyShinobi.h" -#include "Mania/PGZ/Shiversaw.h" -#include "Mania/FBZ/BigSqueeze.h" -#include "Mania/SPZ/WeatherMobile.h" -#include "Mania/CPZ/AmoebaDroid.h" -#include "Mania/GHZ/DERobot.h" -#include "Mania/GHZ/DDWrecker.h" - -#include "Mania/TMZ/FlasherMKII.h" -#include "Mania/TMZ/TurboTurtle.h" -#include "Mania/TMZ/SentryBug.h" -#include "Mania/TMZ/BallHog.h" -#include "Mania/MMZ/PohBee.h" -#include "Mania/MMZ/Scarab.h" -#include "Mania/MMZ/MechaBu.h" -#include "Mania/LRZ/Fireworm.h" -#include "Mania/LRZ/Rexon.h" -#include "Mania/LRZ/Toxomister.h" -#include "Mania/OOZ/Octus.h" -#include "Mania/OOZ/Sol.h" -#include "Mania/OOZ/Aquis.h" -#include "Mania/MSZ/Rattlekiller.h" -#include "Mania/MSZ/RollerMKII.h" -#include "Mania/MSZ/Vultron.h" -#include "Mania/MSZ/Bumpalo.h" -#include "Mania/MSZ/Armadiloid.h" -#include "Mania/MSZ/Cactula.h" -#include "Mania/MSZ/Hatterkiller.h" -#include "Mania/HCZ/TurboSpiker.h" -#include "Mania/HCZ/Buggernaut.h" -#include "Mania/HCZ/MegaChopper.h" -#include "Mania/HCZ/Jawz.h" -#include "Mania/HCZ/Jellygnite.h" -#include "Mania/HCZ/Blastoid.h" -#include "Mania/HCZ/Pointdexter.h" -#include "Mania/SSZ/Kabasira.h" -#include "Mania/SSZ/Dango.h" -#include "Mania/SSZ/Kanabun.h" -#include "Mania/SSZ/HotaruMKII.h" -#include "Mania/SSZ/Hotaru.h" -#include "Mania/PGZ/Woodrow.h" -#include "Mania/PGZ/Dragonfly.h" -#include "Mania/PGZ/IceBomba.h" -#include "Mania/PGZ/JuggleSaw.h" -#include "Mania/FBZ/FBZTrash.h" -#include "Mania/FBZ/Technosqueek.h" -#include "Mania/FBZ/Clucker.h" -#include "Mania/FBZ/Blaster.h" -#include "Mania/SPZ/Shutterbug.h" -#include "Mania/SPZ/Canista.h" -#include "Mania/SPZ/Tubinaut.h" -#include "Mania/SPZ/MicDrop.h" -#include "Mania/CPZ/Grabber.h" -#include "Mania/CPZ/Spiny.h" -#include "Mania/CPZ/CaterkillerJr.h" -#include "Mania/CPZ/Bubbler.h" -#include "Mania/GHZ/Splats.h" -#include "Mania/GHZ/Newtron.h" -#include "Mania/GHZ/Chopper.h" -#include "Mania/GHZ/Crabmeat.h" -#include "Mania/GHZ/Batbrain.h" -#include "Mania/GHZ/Motobug.h" -#include "Mania/GHZ/BuzzBomber.h" - - -#define REGISTER_ENEMY(name) MOD_REGISTER_OBJ_OVERLOAD(name, NULL, NULL, NULL, NULL, NULL, name##_EnemyInfoHook, NULL, NULL, NULL) - -#define HOOK_ENEMY_OBJECTS \ - IMPORT_PUBLIC_FUNC(APICallback_TrackEnemyDefeat); \ - IMPORT_PUBLIC_FUNC(TimeAttackData_TrackEnemyDefeat); \ - \ - OBJ_PHANTOMMYSTIC_SETUP; \ - OBJ_PHANTOMSHINOBI_SETUP; \ - OBJ_PHANTOMEGG_SETUP; \ - OBJ_CRIMSONEYE_SETUP; \ - OBJ_GACHAPANDORA_SETUP; \ - OBJ_EGGPISTONSMKII_SETUP; \ - OBJ_ROCKDRILL_SETUP; \ - OBJ_HEAVYKING_SETUP; \ - OBJ_HEAVYRIDER_SETUP; \ - OBJ_DRILLERDROIDO_SETUP; \ - OBJ_DRILLERDROID_SETUP; \ - OBJ_MEGAOCTUS_SETUP; \ - OBJ_METERDROID_SETUP; \ - OBJ_HEAVYMYSTIC_SETUP; \ - OBJ_DBTOWER_SETUP; \ - OBJ_UBERCATERKILLER_SETUP; \ - OBJ_LAUNDROMOBILE_SETUP; \ - OBJ_METALSONIC_SETUP; \ - OBJ_GIGAMETAL_SETUP; \ - OBJ_HOTARUHIWATT_SETUP; \ - OBJ_HEAVYSHINOBI_SETUP; \ - OBJ_SHIVERSAW_SETUP; \ - OBJ_BIGSQUEEZE_SETUP; \ - OBJ_WEATHERMOBILE_SETUP; \ - OBJ_AMOEBADROID_SETUP; \ - OBJ_DEROBOT_SETUP; \ - OBJ_DDWRECKER_SETUP; \ - \ - OBJ_FLASHERMKII_SETUP; \ - OBJ_TURBOTURTLE_SETUP; \ - OBJ_SENTRYBUG_SETUP; \ - OBJ_BALLHOG_SETUP; \ - OBJ_POHBEE_SETUP; \ - OBJ_SCARAB_SETUP; \ - OBJ_MECHABU_SETUP; \ - OBJ_FIREWORM_SETUP; \ - OBJ_REXON_SETUP; \ - OBJ_TOXOMISTER_SETUP; \ - OBJ_OCTUS_SETUP; \ - OBJ_SOL_SETUP; \ - OBJ_AQUIS_SETUP; \ - OBJ_RATTLEKILLER_SETUP; \ - OBJ_ROLLERMKII_SETUP; \ - OBJ_VULTRON_SETUP; \ - OBJ_BUMPALO_SETUP; \ - OBJ_ARMADILOID_SETUP; \ - OBJ_CACTULA_SETUP; \ - OBJ_HATTERKILLER_SETUP; \ - OBJ_TURBOSPIKER_SETUP; \ - OBJ_BUGGERNAUT_SETUP; \ - OBJ_MEGACHOPPER_SETUP; \ - OBJ_JAWZ_SETUP; \ - OBJ_JELLYGNITE_SETUP; \ - OBJ_BLASTOID_SETUP; \ - OBJ_POINTDEXTER_SETUP; \ - OBJ_KABASIRA_SETUP; \ - OBJ_DANGO_SETUP; \ - OBJ_KANABUN_SETUP; \ - OBJ_HOTARUMKII_SETUP; \ - OBJ_HOTARU_SETUP; \ - OBJ_WOODROW_SETUP; \ - OBJ_DRAGONFLY_SETUP; \ - OBJ_ICEBOMBA_SETUP; \ - OBJ_JUGGLESAW_SETUP; \ - OBJ_FBZTRASH_SETUP; \ - OBJ_TECHNOSQUEEK_SETUP; \ - OBJ_CLUCKER_SETUP; \ - OBJ_BLASTER_SETUP; \ - OBJ_CANISTA_SETUP; \ - OBJ_TUBINAUT_SETUP; \ - OBJ_SHUTTERBUG_SETUP; \ - OBJ_MICDROP_SETUP; \ - OBJ_SPINY_SETUP; \ - OBJ_GRABBER_SETUP; \ - OBJ_CATERKILLERJR_SETUP; \ - OBJ_BUBBLER_SETUP; \ - OBJ_SPLATS_SETUP; \ - OBJ_NEWTRON_SETUP; \ - OBJ_CHOPPER_SETUP; \ - OBJ_CRABMEAT_SETUP; \ - OBJ_BATBRAIN_SETUP; \ - OBJ_MOTOBUG_SETUP; \ - OBJ_BUZZBOMBER_SETUP diff --git a/src/hypermania/Objects/HPZ/HPZEmerald.h b/src/hypermania/Objects/HPZ/HPZEmerald.h deleted file mode 100644 index ca61121..0000000 --- a/src/hypermania/Objects/HPZ/HPZEmerald.h +++ /dev/null @@ -1,36 +0,0 @@ -#ifndef OBJ_HPZEMERALD_H -#define OBJ_HPZEMERALD_H - -#include "GameAPI/Game.h" - -typedef enum { - HPZEMERALD_MASTER, - HPZEMERALD_EMERALD_LOW, - HPZEMERALD_EMERALD_HIGH, -} HPZEmeraldTypes; - -typedef struct { - RSDK_OBJECT - uint16 aniFrames; -} ObjectHPZEmerald; - -typedef struct { - RSDK_ENTITY - StateMachine(state); // unused - uint8 type; - bool32 solid; - Vector2 startPos; - Hitbox *hitbox; - Animator emeraldAnimator; - Animator overlayAnimator; -} EntityHPZEmerald; - -extern ObjectHPZEmerald *HPZEmerald; - -// Overload Functions -void HPZEmerald_Update_Hook(void); -void HPZEmerald_Draw_Hook(void); -void HPZEmerald_Create_Hook(void* data); -void HPZEmerald_StageLoad_Hook(void); - -#endif //! OBJ_HPZEMERALD_H diff --git a/src/hypermania/Objects/HUD.h b/src/hypermania/Objects/HUD.h deleted file mode 100644 index 05113f9..0000000 --- a/src/hypermania/Objects/HUD.h +++ /dev/null @@ -1,82 +0,0 @@ -#ifndef OBJ_HUD_H -#define OBJ_HUD_H - -#include "GameAPI/Game.h" - -typedef struct { - RSDK_OBJECT - uint16 aniFrames; -#if GAME_VERSION != VER_100 - uint16 superButtonFrames; -#endif -#if MANIA_USE_PLUS - uint16 sfxClick; - uint16 sfxStarpost; - bool32 showTAPrompt; - bool32 replaySaveEnabled; - int32 screenBorderType[PLAYER_COUNT]; - int32 swapCooldown; - int32 stockFlashTimers[PLAYER_COUNT]; -#endif -} ObjectHUD; - -typedef struct { - RSDK_ENTITY - StateMachine(state); - Vector2 scorePos; - Vector2 timePos; - Vector2 ringsPos; - Vector2 lifePos; -#if MANIA_USE_PLUS - int32 lifeFrameIDs[PLAYER_COUNT]; - int32 lives[PLAYER_COUNT]; -#endif - int32 targetPos; -#if GAME_VERSION != VER_100 - int32 actionPromptPos; -#endif -#if MANIA_USE_PLUS - StateMachine(vsStates[PLAYER_COUNT]); - Vector2 vsScorePos[PLAYER_COUNT]; - Vector2 vsTimePos[PLAYER_COUNT]; - Vector2 vsRingsPos[PLAYER_COUNT]; - Vector2 vsLifePos[PLAYER_COUNT]; - int32 vsTargetPos[PLAYER_COUNT]; - int32 screenID; -#endif -#if GAME_VERSION != VER_100 - int32 timeFlashFrame; -#endif - int32 ringFlashFrame; - bool32 enableTimeFlash; - bool32 enableRingFlash; - Animator hudElementsAnimator; - Animator numbersAnimator; - Animator hyperNumbersAnimator; - Animator lifeIconAnimator; - Animator playerIDAnimator; -#if GAME_VERSION != VER_100 - Animator superIconAnimator; - Animator superButtonAnimator; -#endif -#if MANIA_USE_PLUS - Animator thumbsUpIconAnimator; - Animator thumbsUpButtonAnimator; - Animator replayClapAnimator; - Animator saveReplayButtonAnimator; -#endif -} EntityHUD; - -extern ObjectHUD *HUD; - -// ============================================================================= - -// Functions ------------------------------------------------------------------- - -// ============================================================================= -void HUD_LateUpdate_OVERLOAD(); - -#define OBJ_HUD_SETUP \ - MOD_REGISTER_OBJ_OVERLOAD(HUD, NULL, HUD_LateUpdate_OVERLOAD, NULL, NULL, NULL, NULL, NULL, NULL, NULL) - -#endif //! OBJ_HUD_H diff --git a/src/hypermania/Objects/PlaneSeeSaw.h b/src/hypermania/Objects/PlaneSeeSaw.h deleted file mode 100644 index 5a65fb1..0000000 --- a/src/hypermania/Objects/PlaneSeeSaw.h +++ /dev/null @@ -1,35 +0,0 @@ -#ifndef OBJ_PLANESEESAW_H -#define OBJ_PLANESEESAW_H - -#include "GameAPI/Game.h" - -// Object Class -typedef struct { - RSDK_OBJECT - uint16 aniFrames; - uint16 sfxSpring; - uint16 sfxFlipper; -} ObjectPlaneSeeSaw; - -// Entity Class -typedef struct { - RSDK_ENTITY - StateMachine(state); - int32 unused; - int32 seeSawPos; - Animator platformAnimator; - Animator swingAnimator; - Animator weightAnimator; -} EntityPlaneSeeSaw; - -extern ObjectPlaneSeeSaw* PlaneSeeSaw; - -bool32 PlaneSeeSaw_State_Launch_HOOK(bool32 skippedState); -bool32 PlaneSeeSaw_PlayerState_ToBG_HOOK(bool32 skippedState); - -#define OBJ_PLANESEESAW_SETUP \ - HOOK_STATE(PlaneSeeSaw_State_Launch, 1); \ - HOOK_STATE(PlaneSeeSaw_PlayerState_ToBG, 0); \ - MOD_REGISTER_OBJ_OVERLOAD(PlaneSeeSaw, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL) - -#endif //! OBJ_PLANESEESAW_H diff --git a/src/hypermania/Objects/UFO_Player.h b/src/hypermania/Objects/UFO_Player.h deleted file mode 100644 index eeca753..0000000 --- a/src/hypermania/Objects/UFO_Player.h +++ /dev/null @@ -1,69 +0,0 @@ -#ifndef OBJ_UFO_PLAYER_H -#define OBJ_UFO_PLAYER_H - -#include "GameAPI/Game.h" - -typedef struct { - RSDK_OBJECT - int32 maxSpeed; - uint16 aniFrames; // unused - uint16 sfxJump; - uint16 sfxCharge; - uint16 sfxRelease; - uint16 sfxLoseRings; - uint16 sfxDrop; - uint16 sfxBumper; - uint16 sfxSpring; - uint16 sfxSkid; - uint16 sfxGrittyGround; - uint16 jogModel; - uint16 dashModel; - uint16 jumpModel; - uint16 ballModel; - uint16 tumbleModel; - uint16 sceneIndex; -} ObjectUFO_Player; - -typedef struct { - RSDK_ENTITY - StateMachine(state); - int32 machQuota1; - int32 machQuota2; - int32 machQuota3; - int32 startingRings; - int32 timer; - int32 courseOutTimer; - int32 angleX; - int32 height; - int32 gravityStrength; - int32 angleZ; - int32 velDivisor; - int32 bumperTimer; - int32 angleVel; - int32 skidTimer; - Entity *camera; - Entity *circuitPtr; - Matrix matRotate; - Matrix matTransform; - Matrix matWorld; - Matrix matNormal; - StateMachine(stateInput); - int32 controllerID; - bool32 up; - bool32 down; - bool32 left; - bool32 right; - bool32 jumpPress; - bool32 jumpHold; - Animator animator; -} EntityUFO_Player; - -extern ObjectUFO_Player *UFO_Player; - -bool32 UFO_Player_State_UFOCaught_Released_HOOK(bool32); - -#define OBJ_UFO_PLAYER_SETUP \ - HOOK_STATE(UFO_Player_State_UFOCaught_Released, 1); \ - MOD_REGISTER_OBJECT_HOOK(UFO_Player) - -#endif //! OBJ_UFO_PLAYER_H diff --git a/src/hypermania/Objects/UFO_Setup.h b/src/hypermania/Objects/UFO_Setup.h deleted file mode 100644 index 1a19a1c..0000000 --- a/src/hypermania/Objects/UFO_Setup.h +++ /dev/null @@ -1,65 +0,0 @@ -#ifndef OBJ_UFO_SETUP_H -#define OBJ_UFO_SETUP_H - -#include "GameAPI/Game.h" - -typedef struct { - RSDK_OBJECT - StateMachine(deformCB); - int32 timedOut; -#if MANIA_USE_PLUS - bool32 encoreStage; -#endif - int32 machLevel; - int32 scoreBonus; - int32 machPoints; - int32 rings; - int32 timer; - int32 ringFrame; - int32 ringPan; - int32 spherePan; - int32 specialStageID; - int32 machQuotas[3]; - uint8 playFieldLayer; - uint16 sfxBlueSphere; - uint16 sfxSSExit; - uint16 sfxEmerald; - uint16 sfxEvent; - bool32 resetToTitle; -} ObjectUFO_Setup; - -typedef struct { - RSDK_ENTITY - StateMachine(state); - int32 timer; - color fadeColor; -} EntityUFO_Setup; - -extern ObjectUFO_Setup *UFO_Setup; - -typedef struct { - int32 timedOut; - int32 machLevel; - int32 scoreBonus; - int32 rings; - int32 specialStageID; -} UFO_HPZbuffer_t; -extern UFO_HPZbuffer_t UFO_HPZbuffer; - - -bool32 UFO_Setup_State_FinishFadeout_HOOK(bool32); - -extern void (*UFO_Setup_State_FinishFadeout)(); -extern void (*UFO_Setup_Finish_Win)(); - -void SetupHPZResults(void* data); - -// lol -#define OBJ_UFO_SETUP_SETUP \ - Mod.AddModCallback(MODCB_ONUPDATE, SetupHPZResults); \ - IMPORT_PUBLIC_FUNC(UFO_Setup_State_FinishFadeout); \ - IMPORT_PUBLIC_FUNC(UFO_Setup_Finish_Win); \ - HOOK_IMPORTED_STATE(UFO_Setup_State_FinishFadeout, 1); \ - MOD_REGISTER_OBJECT_HOOK(UFO_Setup) - -#endif //! OBJ_UFO_SETUP_H diff --git a/src/hypermania/dllmain.c b/src/hypermania/dllmain.c index bb4ae6c..f3ec8e4 100644 --- a/src/hypermania/dllmain.c +++ b/src/hypermania/dllmain.c @@ -1,53 +1,4 @@ -#include "../GameAPI/C/GameAPI/Game.h" - -#include "ModFunctions.h" - -// game classes litte/no notable modifications -#include "Mania/Global/SaveGame.h" -#include "Mania/Global/Animals.h" -#include "Mania/Global/Camera.h" -#include "Mania/Common/CollapsingPlatform.h" -#include "Mania/Global/Explosion.h" -#include "Mania/Cutscene/FXFade.h" -#include "Mania/Global/ItemBox.h" -#include "Mania/Global/Ring.h" -#include "Mania/Global/ScoreBonus.h" -#include "Mania/Global/Zone.h" -#include "Mania/Global/Music.h" -#include "Mania/Global/PauseMenu.h" -#include "Mania/Global/InvincibleStars.h" - -#include "Mania/CPZ/CPZSetup.h" -#include "Mania/OOZ/OOZSetup.h" -#include "Mania/HCZ/HCZSetup.h" -#include "Mania/MMZ/FarPlane.h" -#include "Mania/ERZ/ERZStart.h" -#include "Mania/BSS/BSS_Setup.h" - -// game classes with notable modifications -#include "Objects/Player.h" -#include "Objects/ImageTrail.h" -#include "Objects/SpecialRing.h" -#include "Objects/UFO_Setup.h" -#include "Objects/UFO_Player.h" -#include "Objects/SpecialClear.h" -#include "Objects/HUD.h" -#include "Objects/UISaveSlot.h" -#include "Objects/LevelSelect.h" -#include "Objects/HPZ/HPZEmerald.h" -#include "Objects/PlaneSeeSaw.h" -#include "Objects/Debris.h" - -// new classes -#include "Objects/SuperFlicky.h" -#include "Objects/HyperStars.h" -#include "Objects/JetGlideEffect.h" -#include "Objects/HPZ/HPZSetup.h" -#include "Objects/HPZ/HPZIntro.h" -#include "Objects/HPZ/HPZBeam.h" - -// enemy checking file -#include "Objects/Enemy.h" +#include "All.c" #if RETRO_USE_MOD_LOADER DLLExport bool32 LinkModLogic(EngineInfo *info, const char *id); @@ -138,17 +89,8 @@ void StageCleanup(void* data) { void InitModAPI() { printf( - "\x1b[93mH" - "\x1b[91mY" - "\x1b[95mP" - "\x1b[96mE" - "\x1b[32mR" - "\x1b[92mM" - "\x1b[37mA" - "\x1b[93mN" - "\x1b[91mI" - "\x1b[95mA" - "\x1b[0m" + "\x1b[93mH\x1b[91mY\x1b[95mP\x1b[96mE\x1b[32mR" + "\x1b[92mM\x1b[37mA\x1b[93mN\x1b[91mI\x1b[95mA\x1b[0m" ); printf(" loaded\n"); diff --git a/src/hypermania/link/All.h b/src/hypermania/link/All.h new file mode 100644 index 0000000..dbb3234 --- /dev/null +++ b/src/hypermania/link/All.h @@ -0,0 +1,22 @@ +#pragma once + +#include "Enemy.h" +#include "BSS/BSS_Setup.h" +#include "Common/CollapsingPlatform.h" +#include "CPZ/CPZSetup.h" +#include "Cutscene/FXFade.h" +#include "ERZ/ERZStart.h" +#include "Global/Animals.h" +#include "Global/Camera.h" +#include "Global/Explosion.h" +#include "Global/InvincibleStars.h" +#include "Global/ItemBox.h" +#include "Global/Music.h" +#include "Global/PauseMenu.h" +#include "Global/Ring.h" +#include "Global/SaveGame.h" +#include "Global/ScoreBonus.h" +#include "Global/Zone.h" +#include "HCZ/HCZSetup.h" +#include "MMZ/FarPlane.h" +#include "OOZ/OOZSetup.h" \ No newline at end of file diff --git a/src/hypermania/link/BSS/BSS_Setup.c b/src/hypermania/link/BSS/BSS_Setup.c new file mode 100644 index 0000000..5a92cdc --- /dev/null +++ b/src/hypermania/link/BSS/BSS_Setup.c @@ -0,0 +1,3 @@ +#include "BSS_Setup.h" + +ObjectBSS_Setup* BSS_Setup; diff --git a/src/hypermania/link/BSS/BSS_Setup.h b/src/hypermania/link/BSS/BSS_Setup.h new file mode 100644 index 0000000..4fbd362 --- /dev/null +++ b/src/hypermania/link/BSS/BSS_Setup.h @@ -0,0 +1,3 @@ +#pragma once + +extern ObjectBSS_Setup* BSS_Setup; \ No newline at end of file diff --git a/src/hypermania/Mania/CPZ/AmoebaDroid.c b/src/hypermania/link/CPZ/AmoebaDroid.c similarity index 100% rename from src/hypermania/Mania/CPZ/AmoebaDroid.c rename to src/hypermania/link/CPZ/AmoebaDroid.c diff --git a/src/hypermania/link/CPZ/AmoebaDroid.h b/src/hypermania/link/CPZ/AmoebaDroid.h new file mode 100644 index 0000000..3ad91ce --- /dev/null +++ b/src/hypermania/link/CPZ/AmoebaDroid.h @@ -0,0 +1,27 @@ +#pragma once + +extern ObjectAmoebaDroid* AmoebaDroid; + +extern void (*AmoebaDroid_State_DropIn)(); +extern void (*AmoebaDroid_State_DropIntoPool)(); +extern void (*AmoebaDroid_State_SurfaceFromPool)(); +extern void (*AmoebaDroid_State_ChooseAttack)(); +extern void (*AmoebaDroid_State_ExitPool)(); +extern void (*AmoebaDroid_State_BounceAttack)(); +extern void (*AmoebaDroid_State_GatherBlobs)(); +extern void (*AmoebaDroid_State_SpinBlobs)(); +extern void (*AmoebaDroid_Hit)(); + +void AmoebaDroid_EnemyInfoHook(); + +#define OBJ_AMOEBADROID_SETUP \ + IMPORT_PUBLIC_FUNC(AmoebaDroid_State_DropIn); \ + IMPORT_PUBLIC_FUNC(AmoebaDroid_State_DropIntoPool); \ + IMPORT_PUBLIC_FUNC(AmoebaDroid_State_SurfaceFromPool); \ + IMPORT_PUBLIC_FUNC(AmoebaDroid_State_ChooseAttack); \ + IMPORT_PUBLIC_FUNC(AmoebaDroid_State_ExitPool); \ + IMPORT_PUBLIC_FUNC(AmoebaDroid_State_BounceAttack); \ + IMPORT_PUBLIC_FUNC(AmoebaDroid_State_GatherBlobs); \ + IMPORT_PUBLIC_FUNC(AmoebaDroid_State_SpinBlobs); \ + IMPORT_PUBLIC_FUNC(AmoebaDroid_Hit); \ + REGISTER_ENEMY(AmoebaDroid) \ No newline at end of file diff --git a/src/hypermania/Mania/CPZ/Bubbler.c b/src/hypermania/link/CPZ/Bubbler.c similarity index 100% rename from src/hypermania/Mania/CPZ/Bubbler.c rename to src/hypermania/link/CPZ/Bubbler.c diff --git a/src/hypermania/link/CPZ/Bubbler.h b/src/hypermania/link/CPZ/Bubbler.h new file mode 100644 index 0000000..42328b4 --- /dev/null +++ b/src/hypermania/link/CPZ/Bubbler.h @@ -0,0 +1,13 @@ +#pragma once + +extern ObjectBubbler* Bubbler; + +extern void (*Bubbler_StateProjectile_Seed)(); +extern void (*Bubbler_StateProjectile_Bubbler)(); + +void Bubbler_EnemyInfoHook(); + +#define OBJ_BUBBLER_SETUP \ + IMPORT_PUBLIC_FUNC(Bubbler_StateProjectile_Seed); \ + IMPORT_PUBLIC_FUNC(Bubbler_StateProjectile_Bubbler); \ + REGISTER_ENEMY(Bubbler) \ No newline at end of file diff --git a/src/hypermania/Mania/CPZ/CPZSetup.c b/src/hypermania/link/CPZ/CPZSetup.c similarity index 100% rename from src/hypermania/Mania/CPZ/CPZSetup.c rename to src/hypermania/link/CPZ/CPZSetup.c diff --git a/src/hypermania/link/CPZ/CPZSetup.h b/src/hypermania/link/CPZ/CPZSetup.h new file mode 100644 index 0000000..cb88b56 --- /dev/null +++ b/src/hypermania/link/CPZ/CPZSetup.h @@ -0,0 +1,3 @@ +#pragma once + +extern ObjectCPZSetup* CPZSetup; \ No newline at end of file diff --git a/src/hypermania/Mania/CPZ/CaterkillerJr.c b/src/hypermania/link/CPZ/CaterkillerJr.c similarity index 100% rename from src/hypermania/Mania/CPZ/CaterkillerJr.c rename to src/hypermania/link/CPZ/CaterkillerJr.c diff --git a/src/hypermania/link/CPZ/CaterkillerJr.h b/src/hypermania/link/CPZ/CaterkillerJr.h new file mode 100644 index 0000000..321feb0 --- /dev/null +++ b/src/hypermania/link/CPZ/CaterkillerJr.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectCaterkillerJr* CaterkillerJr; + +void CaterkillerJr_EnemyInfoHook(); + +#define OBJ_CATERKILLERJR_SETUP \ + REGISTER_ENEMY(CaterkillerJr) \ No newline at end of file diff --git a/src/hypermania/Mania/CPZ/Grabber.c b/src/hypermania/link/CPZ/Grabber.c similarity index 100% rename from src/hypermania/Mania/CPZ/Grabber.c rename to src/hypermania/link/CPZ/Grabber.c diff --git a/src/hypermania/link/CPZ/Grabber.h b/src/hypermania/link/CPZ/Grabber.h new file mode 100644 index 0000000..fe3a24f --- /dev/null +++ b/src/hypermania/link/CPZ/Grabber.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectGrabber* Grabber; + +void Grabber_EnemyInfoHook(); + +#define OBJ_GRABBER_SETUP \ + REGISTER_ENEMY(Grabber) \ No newline at end of file diff --git a/src/hypermania/Mania/CPZ/Spiny.c b/src/hypermania/link/CPZ/Spiny.c similarity index 100% rename from src/hypermania/Mania/CPZ/Spiny.c rename to src/hypermania/link/CPZ/Spiny.c diff --git a/src/hypermania/link/CPZ/Spiny.h b/src/hypermania/link/CPZ/Spiny.h new file mode 100644 index 0000000..0d9f41d --- /dev/null +++ b/src/hypermania/link/CPZ/Spiny.h @@ -0,0 +1,13 @@ +#pragma once + +extern ObjectSpiny* Spiny; + +extern void (*Spiny_State_Shot)(); +extern void (*Spiny_State_ShotDisappear)(); + +void Spiny_EnemyInfoHook(); + +#define OBJ_SPINY_SETUP \ + IMPORT_PUBLIC_FUNC(Spiny_State_Shot); \ + IMPORT_PUBLIC_FUNC(Spiny_State_ShotDisappear); \ + REGISTER_ENEMY(Spiny) \ No newline at end of file diff --git a/src/hypermania/link/Common/CollapsingPlatform.c b/src/hypermania/link/Common/CollapsingPlatform.c new file mode 100644 index 0000000..d8761a6 --- /dev/null +++ b/src/hypermania/link/Common/CollapsingPlatform.c @@ -0,0 +1,3 @@ +#include "CollapsingPlatform.h" + +ObjectCollapsingPlatform* CollapsingPlatform; diff --git a/src/hypermania/link/Common/CollapsingPlatform.h b/src/hypermania/link/Common/CollapsingPlatform.h new file mode 100644 index 0000000..3f413ba --- /dev/null +++ b/src/hypermania/link/Common/CollapsingPlatform.h @@ -0,0 +1,3 @@ +#pragma once + +ObjectCollapsingPlatform* CollapsingPlatform; \ No newline at end of file diff --git a/src/hypermania/link/Cutscene/FXFade.c b/src/hypermania/link/Cutscene/FXFade.c new file mode 100644 index 0000000..49c53cf --- /dev/null +++ b/src/hypermania/link/Cutscene/FXFade.c @@ -0,0 +1,5 @@ +#include "FXFade.h" + +ObjectFXFade* FXFade; +void (*FXFade_State_FadeIn)(); +void (*FXFade_State_FadeOut)(); \ No newline at end of file diff --git a/src/hypermania/link/Cutscene/FXFade.h b/src/hypermania/link/Cutscene/FXFade.h new file mode 100644 index 0000000..bd473d7 --- /dev/null +++ b/src/hypermania/link/Cutscene/FXFade.h @@ -0,0 +1,5 @@ +#pragma once + +extern ObjectFXFade* FXFade; +extern void (*FXFade_State_FadeIn)(); +extern void (*FXFade_State_FadeOut)(); \ No newline at end of file diff --git a/src/hypermania/Mania/ERZ/ERZStart.c b/src/hypermania/link/ERZ/ERZStart.c similarity index 100% rename from src/hypermania/Mania/ERZ/ERZStart.c rename to src/hypermania/link/ERZ/ERZStart.c diff --git a/src/hypermania/link/ERZ/ERZStart.h b/src/hypermania/link/ERZ/ERZStart.h new file mode 100644 index 0000000..302dc37 --- /dev/null +++ b/src/hypermania/link/ERZ/ERZStart.h @@ -0,0 +1,3 @@ +#pragma once + +extern ObjectERZStart* ERZStart; \ No newline at end of file diff --git a/src/hypermania/Mania/ERZ/PhantomEgg.c b/src/hypermania/link/ERZ/PhantomEgg.c similarity index 100% rename from src/hypermania/Mania/ERZ/PhantomEgg.c rename to src/hypermania/link/ERZ/PhantomEgg.c diff --git a/src/hypermania/link/ERZ/PhantomEgg.h b/src/hypermania/link/ERZ/PhantomEgg.h new file mode 100644 index 0000000..b0ac4aa --- /dev/null +++ b/src/hypermania/link/ERZ/PhantomEgg.h @@ -0,0 +1,23 @@ +#pragma once + +extern ObjectPhantomShield* PhantomShield; +extern ObjectPhantomEgg* PhantomEgg; + +extern void (*PhantomEgg_State_MoveAround)(); +extern void (*PhantomEgg_State_Attack_Jumped)(); +extern void (*PhantomEgg_State_Attack_JumpLand)(); +extern void (*PhantomEgg_State_Attack_JumpAttack)(); +extern void (*PhantomEgg_State_Attack_CableShock)(); +extern void (*PhantomEgg_Hit)(); + +void PhantomEgg_EnemyInfoHook(); + +#define OBJ_PHANTOMEGG_SETUP \ + MOD_REGISTER_OBJECT_HOOK(PhantomShield); \ + IMPORT_PUBLIC_FUNC(PhantomEgg_State_MoveAround); \ + IMPORT_PUBLIC_FUNC(PhantomEgg_State_Attack_Jumped); \ + IMPORT_PUBLIC_FUNC(PhantomEgg_State_Attack_JumpLand); \ + IMPORT_PUBLIC_FUNC(PhantomEgg_State_Attack_JumpAttack); \ + IMPORT_PUBLIC_FUNC(PhantomEgg_State_Attack_CableShock); \ + IMPORT_PUBLIC_FUNC(PhantomEgg_Hit); \ + REGISTER_ENEMY(PhantomEgg) \ No newline at end of file diff --git a/src/hypermania/Mania/ERZ/PhantomMystic.c b/src/hypermania/link/ERZ/PhantomMystic.c similarity index 100% rename from src/hypermania/Mania/ERZ/PhantomMystic.c rename to src/hypermania/link/ERZ/PhantomMystic.c diff --git a/src/hypermania/link/ERZ/PhantomMystic.h b/src/hypermania/link/ERZ/PhantomMystic.h new file mode 100644 index 0000000..5213fe2 --- /dev/null +++ b/src/hypermania/link/ERZ/PhantomMystic.h @@ -0,0 +1,15 @@ +#pragma once + +extern ObjectPhantomMystic* PhantomMystic; + +extern void (*PhantomMystic_State_CupBlast)(); +extern void (*PhantomMystic_State_MoveCupsToMystic)(); +extern void (*PhantomMystic_Hit)(); + +void PhantomMystic_EnemyInfoHook(); + +#define OBJ_PHANTOMMYSTIC_SETUP \ + IMPORT_PUBLIC_FUNC(PhantomMystic_State_CupBlast); \ + IMPORT_PUBLIC_FUNC(PhantomMystic_State_MoveCupsToMystic); \ + IMPORT_PUBLIC_FUNC(PhantomMystic_Hit); \ + REGISTER_ENEMY(PhantomMystic) \ No newline at end of file diff --git a/src/hypermania/Mania/ERZ/PhantomShinobi.c b/src/hypermania/link/ERZ/PhantomShinobi.c similarity index 100% rename from src/hypermania/Mania/ERZ/PhantomShinobi.c rename to src/hypermania/link/ERZ/PhantomShinobi.c diff --git a/src/hypermania/link/ERZ/PhantomShinobi.h b/src/hypermania/link/ERZ/PhantomShinobi.h new file mode 100644 index 0000000..f9ce572 --- /dev/null +++ b/src/hypermania/link/ERZ/PhantomShinobi.h @@ -0,0 +1,21 @@ +#pragma once + +extern ObjectPhantomShinobi* PhantomShinobi; + +extern void (*PhantomShinobi_State_SetupAttack)(); +extern void (*PhantomShinobi_State_Moving)(); +extern void (*PhantomShinobi_State_PrepareFinAttack)(); +extern void (*PhantomShinobi_State_ExtendFins)(); +extern void (*PhantomShinobi_State_RetractFins)(); +extern void (*PhantomShinobi_Hit)(); + +void PhantomShinobi_EnemyInfoHook(); + +#define OBJ_PHANTOMSHINOBI_SETUP \ + IMPORT_PUBLIC_FUNC(PhantomShinobi_State_SetupAttack); \ + IMPORT_PUBLIC_FUNC(PhantomShinobi_State_Moving); \ + IMPORT_PUBLIC_FUNC(PhantomShinobi_State_PrepareFinAttack); \ + IMPORT_PUBLIC_FUNC(PhantomShinobi_State_ExtendFins); \ + IMPORT_PUBLIC_FUNC(PhantomShinobi_State_RetractFins); \ + IMPORT_PUBLIC_FUNC(PhantomShinobi_Hit); \ + REGISTER_ENEMY(PhantomShinobi) \ No newline at end of file diff --git a/src/hypermania/link/Enemy.c b/src/hypermania/link/Enemy.c new file mode 100644 index 0000000..019b38f --- /dev/null +++ b/src/hypermania/link/Enemy.c @@ -0,0 +1,85 @@ +#include "Enemy.h" + +#include "link/ERZ/PhantomMystic.c" +#include "link/ERZ/PhantomShinobi.c" +#include "link/ERZ/PhantomEgg.c" +#include "link/TMZ/CrimsonEye.c" +#include "link/MMZ/Gachapandora.c" +#include "link/MMZ/EggPistonsMKII.c" +#include "link/LRZ/RockDrill.c" +#include "link/LRZ/HeavyKing.c" +#include "link/LRZ/HeavyRider.c" +#include "link/LRZ/DrillerdroidO.c" +#include "link/LRZ/Drillerdroid.c" +#include "link/OOZ/MegaOctus.c" +#include "link/OOZ/MeterDroid.c" +#include "link/MSZ/HeavyMystic.c" +#include "link/MSZ/DBTower.c" +#include "link/MSZ/UberCaterkiller.c" +#include "link/HCZ/LaundroMobile.c" +#include "link/SSZ/GigaMetal.c" +#include "link/SSZ/MetalSonic.c" +#include "link/SSZ/HotaruHiWatt.c" +#include "link/PGZ/HeavyShinobi.c" +#include "link/PGZ/Shiversaw.c" +#include "link/FBZ/BigSqueeze.c" +#include "link/SPZ/WeatherMobile.c" +#include "link/CPZ/AmoebaDroid.c" +#include "link/GHZ/DERobot.c" +#include "link/GHZ/DDWrecker.c" + +#include "link/TMZ/FlasherMKII.c" +#include "link/TMZ/TurboTurtle.c" +#include "link/TMZ/SentryBug.c" +#include "link/TMZ/BallHog.c" +#include "link/MMZ/PohBee.c" +#include "link/MMZ/Scarab.c" +#include "link/MMZ/MechaBu.c" +#include "link/LRZ/Fireworm.c" +#include "link/LRZ/Rexon.c" +#include "link/LRZ/Toxomister.c" +#include "link/OOZ/Octus.c" +#include "link/OOZ/Sol.c" +#include "link/OOZ/Aquis.c" +#include "link/MSZ/Rattlekiller.c" +#include "link/MSZ/RollerMKII.c" +#include "link/MSZ/Vultron.c" +#include "link/MSZ/Bumpalo.c" +#include "link/MSZ/Armadiloid.c" +#include "link/MSZ/Cactula.c" +#include "link/MSZ/Hatterkiller.c" +#include "link/HCZ/TurboSpiker.c" +#include "link/HCZ/Buggernaut.c" +#include "link/HCZ/MegaChopper.c" +#include "link/HCZ/Jawz.c" +#include "link/HCZ/Jellygnite.c" +#include "link/HCZ/Blastoid.c" +#include "link/HCZ/Pointdexter.c" +#include "link/SSZ/Kabasira.c" +#include "link/SSZ/Dango.c" +#include "link/SSZ/Kanabun.c" +#include "link/SSZ/HotaruMKII.c" +#include "link/SSZ/Hotaru.c" +#include "link/PGZ/Woodrow.c" +#include "link/PGZ/Dragonfly.c" +#include "link/PGZ/IceBomba.c" +#include "link/PGZ/JuggleSaw.c" +#include "link/FBZ/FBZTrash.c" +#include "link/FBZ/Technosqueek.c" +#include "link/FBZ/Clucker.c" +#include "link/FBZ/Blaster.c" +#include "link/SPZ/Shutterbug.c" +#include "link/SPZ/Canista.c" +#include "link/SPZ/Tubinaut.c" +#include "link/SPZ/MicDrop.c" +#include "link/CPZ/Grabber.c" +#include "link/CPZ/Spiny.c" +#include "link/CPZ/CaterkillerJr.c" +#include "link/CPZ/Bubbler.c" +#include "link/GHZ/Splats.c" +#include "link/GHZ/Newtron.c" +#include "link/GHZ/Chopper.c" +#include "link/GHZ/Crabmeat.c" +#include "link/GHZ/Batbrain.c" +#include "link/GHZ/Motobug.c" +#include "link/GHZ/BuzzBomber.c" \ No newline at end of file diff --git a/src/hypermania/link/Enemy.h b/src/hypermania/link/Enemy.h new file mode 100644 index 0000000..d868e5b --- /dev/null +++ b/src/hypermania/link/Enemy.h @@ -0,0 +1,174 @@ +#include "link/ERZ/PhantomMystic.h" +#include "link/ERZ/PhantomShinobi.h" +#include "link/ERZ/PhantomEgg.h" +#include "link/TMZ/CrimsonEye.h" +#include "link/MMZ/Gachapandora.h" +#include "link/MMZ/EggPistonsMKII.h" +#include "link/LRZ/RockDrill.h" +#include "link/LRZ/HeavyKing.h" +#include "link/LRZ/HeavyRider.h" +#include "link/LRZ/DrillerdroidO.h" +#include "link/LRZ/Drillerdroid.h" +#include "link/OOZ/MegaOctus.h" +#include "link/OOZ/MeterDroid.h" +#include "link/MSZ/HeavyMystic.h" +#include "link/MSZ/DBTower.h" +#include "link/MSZ/UberCaterkiller.h" +#include "link/HCZ/LaundroMobile.h" +#include "link/SSZ/GigaMetal.h" +#include "link/SSZ/MetalSonic.h" +#include "link/SSZ/HotaruHiWatt.h" +#include "link/PGZ/HeavyShinobi.h" +#include "link/PGZ/Shiversaw.h" +#include "link/FBZ/BigSqueeze.h" +#include "link/SPZ/WeatherMobile.h" +#include "link/CPZ/AmoebaDroid.h" +#include "link/GHZ/DERobot.h" +#include "link/GHZ/DDWrecker.h" + +#include "link/TMZ/FlasherMKII.h" +#include "link/TMZ/TurboTurtle.h" +#include "link/TMZ/SentryBug.h" +#include "link/TMZ/BallHog.h" +#include "link/MMZ/PohBee.h" +#include "link/MMZ/Scarab.h" +#include "link/MMZ/MechaBu.h" +#include "link/LRZ/Fireworm.h" +#include "link/LRZ/Rexon.h" +#include "link/LRZ/Toxomister.h" +#include "link/OOZ/Octus.h" +#include "link/OOZ/Sol.h" +#include "link/OOZ/Aquis.h" +#include "link/MSZ/Rattlekiller.h" +#include "link/MSZ/RollerMKII.h" +#include "link/MSZ/Vultron.h" +#include "link/MSZ/Bumpalo.h" +#include "link/MSZ/Armadiloid.h" +#include "link/MSZ/Cactula.h" +#include "link/MSZ/Hatterkiller.h" +#include "link/HCZ/TurboSpiker.h" +#include "link/HCZ/Buggernaut.h" +#include "link/HCZ/MegaChopper.h" +#include "link/HCZ/Jawz.h" +#include "link/HCZ/Jellygnite.h" +#include "link/HCZ/Blastoid.h" +#include "link/HCZ/Pointdexter.h" +#include "link/SSZ/Kabasira.h" +#include "link/SSZ/Dango.h" +#include "link/SSZ/Kanabun.h" +#include "link/SSZ/HotaruMKII.h" +#include "link/SSZ/Hotaru.h" +#include "link/PGZ/Woodrow.h" +#include "link/PGZ/Dragonfly.h" +#include "link/PGZ/IceBomba.h" +#include "link/PGZ/JuggleSaw.h" +#include "link/FBZ/FBZTrash.h" +#include "link/FBZ/Technosqueek.h" +#include "link/FBZ/Clucker.h" +#include "link/FBZ/Blaster.h" +#include "link/SPZ/Shutterbug.h" +#include "link/SPZ/Canista.h" +#include "link/SPZ/Tubinaut.h" +#include "link/SPZ/MicDrop.h" +#include "link/CPZ/Grabber.h" +#include "link/CPZ/Spiny.h" +#include "link/CPZ/CaterkillerJr.h" +#include "link/CPZ/Bubbler.h" +#include "link/GHZ/Splats.h" +#include "link/GHZ/Newtron.h" +#include "link/GHZ/Chopper.h" +#include "link/GHZ/Crabmeat.h" +#include "link/GHZ/Batbrain.h" +#include "link/GHZ/Motobug.h" +#include "link/GHZ/BuzzBomber.h" + + +#define REGISTER_ENEMY(name) MOD_REGISTER_OBJ_OVERLOAD(name, NULL, NULL, NULL, NULL, NULL, name##_EnemyInfoHook, NULL, NULL, NULL) + +#define HOOK_ENEMY_OBJECTS \ + IMPORT_PUBLIC_FUNC(APICallback_TrackEnemyDefeat); \ + IMPORT_PUBLIC_FUNC(TimeAttackData_TrackEnemyDefeat); \ + \ + OBJ_PHANTOMMYSTIC_SETUP; \ + OBJ_PHANTOMSHINOBI_SETUP; \ + OBJ_PHANTOMEGG_SETUP; \ + OBJ_CRIMSONEYE_SETUP; \ + OBJ_GACHAPANDORA_SETUP; \ + OBJ_EGGPISTONSMKII_SETUP; \ + OBJ_ROCKDRILL_SETUP; \ + OBJ_HEAVYKING_SETUP; \ + OBJ_HEAVYRIDER_SETUP; \ + OBJ_DRILLERDROIDO_SETUP; \ + OBJ_DRILLERDROID_SETUP; \ + OBJ_MEGAOCTUS_SETUP; \ + OBJ_METERDROID_SETUP; \ + OBJ_HEAVYMYSTIC_SETUP; \ + OBJ_DBTOWER_SETUP; \ + OBJ_UBERCATERKILLER_SETUP; \ + OBJ_LAUNDROMOBILE_SETUP; \ + OBJ_METALSONIC_SETUP; \ + OBJ_GIGAMETAL_SETUP; \ + OBJ_HOTARUHIWATT_SETUP; \ + OBJ_HEAVYSHINOBI_SETUP; \ + OBJ_SHIVERSAW_SETUP; \ + OBJ_BIGSQUEEZE_SETUP; \ + OBJ_WEATHERMOBILE_SETUP; \ + OBJ_AMOEBADROID_SETUP; \ + OBJ_DEROBOT_SETUP; \ + OBJ_DDWRECKER_SETUP; \ + \ + OBJ_FLASHERMKII_SETUP; \ + OBJ_TURBOTURTLE_SETUP; \ + OBJ_SENTRYBUG_SETUP; \ + OBJ_BALLHOG_SETUP; \ + OBJ_POHBEE_SETUP; \ + OBJ_SCARAB_SETUP; \ + OBJ_MECHABU_SETUP; \ + OBJ_FIREWORM_SETUP; \ + OBJ_REXON_SETUP; \ + OBJ_TOXOMISTER_SETUP; \ + OBJ_OCTUS_SETUP; \ + OBJ_SOL_SETUP; \ + OBJ_AQUIS_SETUP; \ + OBJ_RATTLEKILLER_SETUP; \ + OBJ_ROLLERMKII_SETUP; \ + OBJ_VULTRON_SETUP; \ + OBJ_BUMPALO_SETUP; \ + OBJ_ARMADILOID_SETUP; \ + OBJ_CACTULA_SETUP; \ + OBJ_HATTERKILLER_SETUP; \ + OBJ_TURBOSPIKER_SETUP; \ + OBJ_BUGGERNAUT_SETUP; \ + OBJ_MEGACHOPPER_SETUP; \ + OBJ_JAWZ_SETUP; \ + OBJ_JELLYGNITE_SETUP; \ + OBJ_BLASTOID_SETUP; \ + OBJ_POINTDEXTER_SETUP; \ + OBJ_KABASIRA_SETUP; \ + OBJ_DANGO_SETUP; \ + OBJ_KANABUN_SETUP; \ + OBJ_HOTARUMKII_SETUP; \ + OBJ_HOTARU_SETUP; \ + OBJ_WOODROW_SETUP; \ + OBJ_DRAGONFLY_SETUP; \ + OBJ_ICEBOMBA_SETUP; \ + OBJ_JUGGLESAW_SETUP; \ + OBJ_FBZTRASH_SETUP; \ + OBJ_TECHNOSQUEEK_SETUP; \ + OBJ_CLUCKER_SETUP; \ + OBJ_BLASTER_SETUP; \ + OBJ_CANISTA_SETUP; \ + OBJ_TUBINAUT_SETUP; \ + OBJ_SHUTTERBUG_SETUP; \ + OBJ_MICDROP_SETUP; \ + OBJ_SPINY_SETUP; \ + OBJ_GRABBER_SETUP; \ + OBJ_CATERKILLERJR_SETUP; \ + OBJ_BUBBLER_SETUP; \ + OBJ_SPLATS_SETUP; \ + OBJ_NEWTRON_SETUP; \ + OBJ_CHOPPER_SETUP; \ + OBJ_CRABMEAT_SETUP; \ + OBJ_BATBRAIN_SETUP; \ + OBJ_MOTOBUG_SETUP; \ + OBJ_BUZZBOMBER_SETUP diff --git a/src/hypermania/Mania/FBZ/BigSqueeze.c b/src/hypermania/link/FBZ/BigSqueeze.c similarity index 100% rename from src/hypermania/Mania/FBZ/BigSqueeze.c rename to src/hypermania/link/FBZ/BigSqueeze.c diff --git a/src/hypermania/link/FBZ/BigSqueeze.h b/src/hypermania/link/FBZ/BigSqueeze.h new file mode 100644 index 0000000..04fc64e --- /dev/null +++ b/src/hypermania/link/FBZ/BigSqueeze.h @@ -0,0 +1,15 @@ +#pragma once + +extern ObjectBigSqueeze* BigSqueeze; + +extern void (*BigSqueeze_StateBoss_Idle)(); +extern void (*BigSqueeze_StateBoss_Electrified)(); +extern void (*BigSqueeze_Hit)(); + +void BigSqueeze_EnemyInfoHook(); + +#define OBJ_BIGSQUEEZE_SETUP \ + IMPORT_PUBLIC_FUNC(BigSqueeze_StateBoss_Idle); \ + IMPORT_PUBLIC_FUNC(BigSqueeze_StateBoss_Electrified); \ + IMPORT_PUBLIC_FUNC(BigSqueeze_Hit); \ + REGISTER_ENEMY(BigSqueeze) \ No newline at end of file diff --git a/src/hypermania/Mania/FBZ/Blaster.c b/src/hypermania/link/FBZ/Blaster.c similarity index 100% rename from src/hypermania/Mania/FBZ/Blaster.c rename to src/hypermania/link/FBZ/Blaster.c diff --git a/src/hypermania/link/FBZ/Blaster.h b/src/hypermania/link/FBZ/Blaster.h new file mode 100644 index 0000000..88720d1 --- /dev/null +++ b/src/hypermania/link/FBZ/Blaster.h @@ -0,0 +1,15 @@ +#pragma once + +extern ObjectBlaster* Blaster; + +extern void (*Blaster_State_BeginShot)(); +extern void (*Blaster_State_Shot)(); +extern void (*Blaster_State_Shell)(); + +void Blaster_EnemyInfoHook(); + +#define OBJ_BLASTER_SETUP \ + IMPORT_PUBLIC_FUNC(Blaster_State_BeginShot); \ + IMPORT_PUBLIC_FUNC(Blaster_State_Shot); \ + IMPORT_PUBLIC_FUNC(Blaster_State_Shell); \ + REGISTER_ENEMY(Blaster) \ No newline at end of file diff --git a/src/hypermania/Mania/FBZ/Clucker.c b/src/hypermania/link/FBZ/Clucker.c similarity index 100% rename from src/hypermania/Mania/FBZ/Clucker.c rename to src/hypermania/link/FBZ/Clucker.c diff --git a/src/hypermania/link/FBZ/Clucker.h b/src/hypermania/link/FBZ/Clucker.h new file mode 100644 index 0000000..22e02e6 --- /dev/null +++ b/src/hypermania/link/FBZ/Clucker.h @@ -0,0 +1,13 @@ +#pragma once + +extern ObjectClucker* Clucker; + +extern void (*Clucker_State_Destroyed)(); +extern void (*Clucker_State_Egg)(); + +void Clucker_EnemyInfoHook(); + +#define OBJ_CLUCKER_SETUP \ + IMPORT_PUBLIC_FUNC(Clucker_State_Destroyed); \ + IMPORT_PUBLIC_FUNC(Clucker_State_Egg); \ + REGISTER_ENEMY(Clucker) \ No newline at end of file diff --git a/src/hypermania/Mania/FBZ/FBZTrash.c b/src/hypermania/link/FBZ/FBZTrash.c similarity index 100% rename from src/hypermania/Mania/FBZ/FBZTrash.c rename to src/hypermania/link/FBZ/FBZTrash.c diff --git a/src/hypermania/link/FBZ/FBZTrash.h b/src/hypermania/link/FBZ/FBZTrash.h new file mode 100644 index 0000000..95339ab --- /dev/null +++ b/src/hypermania/link/FBZ/FBZTrash.h @@ -0,0 +1,11 @@ +#pragma once + +extern ObjectFBZTrash* FBZTrash; + +extern void (*FBZTrash_State_OrbinautMove)(); + +void FBZTrash_EnemyInfoHook(); + +#define OBJ_FBZTRASH_SETUP \ + IMPORT_PUBLIC_FUNC(FBZTrash_State_OrbinautMove); \ + REGISTER_ENEMY(FBZTrash) \ No newline at end of file diff --git a/src/hypermania/Mania/FBZ/Technosqueek.c b/src/hypermania/link/FBZ/Technosqueek.c similarity index 100% rename from src/hypermania/Mania/FBZ/Technosqueek.c rename to src/hypermania/link/FBZ/Technosqueek.c diff --git a/src/hypermania/link/FBZ/Technosqueek.h b/src/hypermania/link/FBZ/Technosqueek.h new file mode 100644 index 0000000..da6a524 --- /dev/null +++ b/src/hypermania/link/FBZ/Technosqueek.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectTechnosqueek* Technosqueek; + +void Technosqueek_EnemyInfoHook(); + +#define OBJ_TECHNOSQUEEK_SETUP \ + REGISTER_ENEMY(Technosqueek) \ No newline at end of file diff --git a/src/hypermania/Mania/GHZ/Batbrain.c b/src/hypermania/link/GHZ/Batbrain.c similarity index 100% rename from src/hypermania/Mania/GHZ/Batbrain.c rename to src/hypermania/link/GHZ/Batbrain.c diff --git a/src/hypermania/link/GHZ/Batbrain.h b/src/hypermania/link/GHZ/Batbrain.h new file mode 100644 index 0000000..508529f --- /dev/null +++ b/src/hypermania/link/GHZ/Batbrain.h @@ -0,0 +1,11 @@ +#ifndef OBJ_BATBRAIN_LINK_H +#define OBJ_BATBRAIN_LINK_H + +extern ObjectBatbrain* Batbrain; + +void Batbrain_EnemyInfoHook(); + +#define OBJ_BATBRAIN_SETUP \ + REGISTER_ENEMY(Batbrain) + +#endif \ No newline at end of file diff --git a/src/hypermania/Mania/GHZ/BuzzBomber.c b/src/hypermania/link/GHZ/BuzzBomber.c similarity index 100% rename from src/hypermania/Mania/GHZ/BuzzBomber.c rename to src/hypermania/link/GHZ/BuzzBomber.c diff --git a/src/hypermania/link/GHZ/BuzzBomber.h b/src/hypermania/link/GHZ/BuzzBomber.h new file mode 100644 index 0000000..d401b3a --- /dev/null +++ b/src/hypermania/link/GHZ/BuzzBomber.h @@ -0,0 +1,18 @@ +#ifndef OBJ_BUZZBOMBER_LINK_H +#define OBJ_BUZZBOMBER_LINK_H + +extern ObjectBuzzBomber* BuzzBomber; + +extern void (*BuzzBomber_State_Flying)(); +extern void (*BuzzBomber_State_Idle)(); +extern void (*BuzzBomber_State_DetectedPlayer)(); + +void BuzzBomber_EnemyInfoHook(); + +#define OBJ_BUZZBOMBER_SETUP \ + IMPORT_PUBLIC_FUNC(BuzzBomber_State_Flying); \ + IMPORT_PUBLIC_FUNC(BuzzBomber_State_Idle); \ + IMPORT_PUBLIC_FUNC(BuzzBomber_State_DetectedPlayer); \ + REGISTER_ENEMY(BuzzBomber) + +#endif \ No newline at end of file diff --git a/src/hypermania/Mania/GHZ/Chopper.c b/src/hypermania/link/GHZ/Chopper.c similarity index 100% rename from src/hypermania/Mania/GHZ/Chopper.c rename to src/hypermania/link/GHZ/Chopper.c diff --git a/src/hypermania/link/GHZ/Chopper.h b/src/hypermania/link/GHZ/Chopper.h new file mode 100644 index 0000000..4b8d46c --- /dev/null +++ b/src/hypermania/link/GHZ/Chopper.h @@ -0,0 +1,14 @@ +#ifndef OBJ_CHOPPER_LINK_H +#define OBJ_CHOPPER_LINK_H + +extern ObjectChopper* Chopper; + +extern void (*Chopper_State_Jump)(); + +void Chopper_EnemyInfoHook(); + +#define OBJ_CHOPPER_SETUP \ + IMPORT_PUBLIC_FUNC(Chopper_State_Jump); \ + REGISTER_ENEMY(Chopper) + +#endif \ No newline at end of file diff --git a/src/hypermania/Mania/GHZ/Crabmeat.c b/src/hypermania/link/GHZ/Crabmeat.c similarity index 100% rename from src/hypermania/Mania/GHZ/Crabmeat.c rename to src/hypermania/link/GHZ/Crabmeat.c diff --git a/src/hypermania/link/GHZ/Crabmeat.h b/src/hypermania/link/GHZ/Crabmeat.h new file mode 100644 index 0000000..b3f42cb --- /dev/null +++ b/src/hypermania/link/GHZ/Crabmeat.h @@ -0,0 +1,14 @@ +#ifndef OBJ_CRABMEAT_LINK_H +#define OBJ_CRABMEAT_LINK_H + +extern ObjectCrabmeat* Crabmeat; + +extern void (*Crabmeat_State_Projectile)(); + +void Crabmeat_EnemyInfoHook(); + +#define OBJ_CRABMEAT_SETUP \ + IMPORT_PUBLIC_FUNC(Crabmeat_State_Projectile); \ + REGISTER_ENEMY(Crabmeat) + +#endif diff --git a/src/hypermania/Mania/GHZ/DDWrecker.c b/src/hypermania/link/GHZ/DDWrecker.c similarity index 100% rename from src/hypermania/Mania/GHZ/DDWrecker.c rename to src/hypermania/link/GHZ/DDWrecker.c diff --git a/src/hypermania/link/GHZ/DDWrecker.h b/src/hypermania/link/GHZ/DDWrecker.h new file mode 100644 index 0000000..ae3352c --- /dev/null +++ b/src/hypermania/link/GHZ/DDWrecker.h @@ -0,0 +1,17 @@ +#pragma once + +extern ObjectDDWrecker* DDWrecker; + +extern void (*DDWrecker_StateBall_Vulnerable)(); +extern void (*DDWrecker_StateBall_Spiked)(); +extern void (*DDWrecker_StateBall_Partnerless)(); +extern void (*DDWrecker_Hit)(); + +void DDWrecker_EnemyInfoHook(); + +#define OBJ_DDWRECKER_SETUP \ + IMPORT_PUBLIC_FUNC(DDWrecker_StateBall_Vulnerable); \ + IMPORT_PUBLIC_FUNC(DDWrecker_StateBall_Spiked); \ + IMPORT_PUBLIC_FUNC(DDWrecker_StateBall_Partnerless); \ + IMPORT_PUBLIC_FUNC(DDWrecker_Hit); \ + REGISTER_ENEMY(DDWrecker) \ No newline at end of file diff --git a/src/hypermania/Mania/GHZ/DERobot.c b/src/hypermania/link/GHZ/DERobot.c similarity index 100% rename from src/hypermania/Mania/GHZ/DERobot.c rename to src/hypermania/link/GHZ/DERobot.c diff --git a/src/hypermania/link/GHZ/DERobot.h b/src/hypermania/link/GHZ/DERobot.h new file mode 100644 index 0000000..7074d35 --- /dev/null +++ b/src/hypermania/link/GHZ/DERobot.h @@ -0,0 +1,17 @@ +#pragma once + +extern ObjectDERobot* DERobot; + +extern void (*DERobot_State_FallLand)(); +extern void (*DERobot_State_Walk)(); +extern void (*DERobot_State_ArmAttack)(); +extern void (*DERobot_Hit)(); + +void DERobot_EnemyInfoHook(); + +#define OBJ_DEROBOT_SETUP \ + IMPORT_PUBLIC_FUNC(DERobot_State_FallLand); \ + IMPORT_PUBLIC_FUNC(DERobot_State_Walk); \ + IMPORT_PUBLIC_FUNC(DERobot_State_ArmAttack); \ + IMPORT_PUBLIC_FUNC(DERobot_Hit); \ + REGISTER_ENEMY(DERobot) diff --git a/src/hypermania/Mania/GHZ/Motobug.c b/src/hypermania/link/GHZ/Motobug.c similarity index 100% rename from src/hypermania/Mania/GHZ/Motobug.c rename to src/hypermania/link/GHZ/Motobug.c diff --git a/src/hypermania/link/GHZ/Motobug.h b/src/hypermania/link/GHZ/Motobug.h new file mode 100644 index 0000000..6082efd --- /dev/null +++ b/src/hypermania/link/GHZ/Motobug.h @@ -0,0 +1,14 @@ +#ifndef OBJ_MOTOBUG_LINK_H +#define OBJ_MOTOBUG_LINK_H + +extern ObjectMotobug* Motobug; + +extern void (*Motobug_State_Smoke)(); + +void Motobug_EnemyInfoHook(); + +#define OBJ_MOTOBUG_SETUP \ + IMPORT_PUBLIC_FUNC(Motobug_State_Smoke); \ + REGISTER_ENEMY(Motobug) + +#endif \ No newline at end of file diff --git a/src/hypermania/Mania/GHZ/Newtron.c b/src/hypermania/link/GHZ/Newtron.c similarity index 100% rename from src/hypermania/Mania/GHZ/Newtron.c rename to src/hypermania/link/GHZ/Newtron.c diff --git a/src/hypermania/link/GHZ/Newtron.h b/src/hypermania/link/GHZ/Newtron.h new file mode 100644 index 0000000..548023b --- /dev/null +++ b/src/hypermania/link/GHZ/Newtron.h @@ -0,0 +1,15 @@ +#pragma once + +extern ObjectNewtron* Newtron; + +extern void (*Newtron_State_StartFly)(); +extern void (*Newtron_State_Fly)(); +extern void (*Newtron_State_Shoot)(); + +void Newtron_EnemyInfoHook(); + +#define OBJ_NEWTRON_SETUP \ + IMPORT_PUBLIC_FUNC(Newtron_State_StartFly); \ + IMPORT_PUBLIC_FUNC(Newtron_State_Fly); \ + IMPORT_PUBLIC_FUNC(Newtron_State_Shoot); \ + REGISTER_ENEMY(Newtron) \ No newline at end of file diff --git a/src/hypermania/Mania/GHZ/Splats.c b/src/hypermania/link/GHZ/Splats.c similarity index 100% rename from src/hypermania/Mania/GHZ/Splats.c rename to src/hypermania/link/GHZ/Splats.c diff --git a/src/hypermania/link/GHZ/Splats.h b/src/hypermania/link/GHZ/Splats.h new file mode 100644 index 0000000..55585a2 --- /dev/null +++ b/src/hypermania/link/GHZ/Splats.h @@ -0,0 +1,19 @@ +#pragma once + +extern ObjectSplats* Splats; + +extern void (*Splats_State_BounceAround)(); +extern void (*Splats_State_JumpOutOfJar)(); +extern void (*Splats_State_HandleBouncing)(); +extern void (*Splats_State_HandleLanding)(); +extern void (*Splats_State_NoMoreJumps)(); + +void Splats_EnemyInfoHook(); + +#define OBJ_SPLATS_SETUP \ + IMPORT_PUBLIC_FUNC(Splats_State_BounceAround); \ + IMPORT_PUBLIC_FUNC(Splats_State_JumpOutOfJar); \ + IMPORT_PUBLIC_FUNC(Splats_State_HandleBouncing); \ + IMPORT_PUBLIC_FUNC(Splats_State_HandleLanding); \ + IMPORT_PUBLIC_FUNC(Splats_State_NoMoreJumps); \ + REGISTER_ENEMY(Splats) \ No newline at end of file diff --git a/src/hypermania/Mania/Global/Animals.c b/src/hypermania/link/Global/Animals.c similarity index 100% rename from src/hypermania/Mania/Global/Animals.c rename to src/hypermania/link/Global/Animals.c diff --git a/src/hypermania/link/Global/Animals.h b/src/hypermania/link/Global/Animals.h new file mode 100644 index 0000000..6410395 --- /dev/null +++ b/src/hypermania/link/Global/Animals.h @@ -0,0 +1,3 @@ +#pragma once + +extern ObjectAnimals* Animals; \ No newline at end of file diff --git a/src/hypermania/Mania/Global/Camera.c b/src/hypermania/link/Global/Camera.c similarity index 100% rename from src/hypermania/Mania/Global/Camera.c rename to src/hypermania/link/Global/Camera.c diff --git a/src/hypermania/link/Global/Camera.h b/src/hypermania/link/Global/Camera.h new file mode 100644 index 0000000..741005e --- /dev/null +++ b/src/hypermania/link/Global/Camera.h @@ -0,0 +1,10 @@ +#pragma once + +// Object Struct +extern ObjectCamera *Camera; + +// Imported Functions +extern void (*Camera_State_FollowXY)(); +extern void (*Camera_State_FollowY)(); +extern void (*Camera_ShakeScreen)(int32 screen, int32 shakeX, int32 shakeY); +extern void (*Camera_SetupLerp)(int32 type, int32 screen, int32 x, int32 y, int32 speed); \ No newline at end of file diff --git a/src/hypermania/Mania/Global/Explosion.c b/src/hypermania/link/Global/Explosion.c similarity index 100% rename from src/hypermania/Mania/Global/Explosion.c rename to src/hypermania/link/Global/Explosion.c diff --git a/src/hypermania/link/Global/Explosion.h b/src/hypermania/link/Global/Explosion.h new file mode 100644 index 0000000..07b2a0c --- /dev/null +++ b/src/hypermania/link/Global/Explosion.h @@ -0,0 +1,3 @@ +#pragma once + +extern ObjectExplosion *Explosion; \ No newline at end of file diff --git a/src/hypermania/Mania/Global/InvincibleStars.c b/src/hypermania/link/Global/InvincibleStars.c similarity index 100% rename from src/hypermania/Mania/Global/InvincibleStars.c rename to src/hypermania/link/Global/InvincibleStars.c diff --git a/src/hypermania/link/Global/InvincibleStars.h b/src/hypermania/link/Global/InvincibleStars.h new file mode 100644 index 0000000..3e50687 --- /dev/null +++ b/src/hypermania/link/Global/InvincibleStars.h @@ -0,0 +1,3 @@ +#pragma once + +extern ObjectInvincibleStars* InvincibleStars; \ No newline at end of file diff --git a/src/hypermania/Mania/Global/ItemBox.c b/src/hypermania/link/Global/ItemBox.c similarity index 54% rename from src/hypermania/Mania/Global/ItemBox.c rename to src/hypermania/link/Global/ItemBox.c index b1644d5..e27b438 100644 --- a/src/hypermania/Mania/Global/ItemBox.c +++ b/src/hypermania/link/Global/ItemBox.c @@ -2,4 +2,4 @@ ObjectItemBox *ItemBox; void (*ItemBox_State_Broken)(void); -void (*ItemBox_Break)(EntityBase*, EntityBase*); \ No newline at end of file +void (*ItemBox_Break)(EntityItemBox* itemBox, EntityPlayer* player); \ No newline at end of file diff --git a/src/hypermania/link/Global/ItemBox.h b/src/hypermania/link/Global/ItemBox.h new file mode 100644 index 0000000..3b91668 --- /dev/null +++ b/src/hypermania/link/Global/ItemBox.h @@ -0,0 +1,8 @@ +#pragma once + +// Object Struct +extern ObjectItemBox* ItemBox; + +// Imported Functions +extern void (*ItemBox_State_Broken)(); +extern void (*ItemBox_Break)(EntityItemBox* itemBox, EntityPlayer* player); \ No newline at end of file diff --git a/src/hypermania/Mania/Global/Music.c b/src/hypermania/link/Global/Music.c similarity index 100% rename from src/hypermania/Mania/Global/Music.c rename to src/hypermania/link/Global/Music.c diff --git a/src/hypermania/link/Global/Music.h b/src/hypermania/link/Global/Music.h new file mode 100644 index 0000000..0bb3806 --- /dev/null +++ b/src/hypermania/link/Global/Music.h @@ -0,0 +1,15 @@ +#pragma once + +extern ObjectMusic *Music; + +extern void (*Music_PlayTrack)(uint8 trackID); +extern void (*Music_SetMusicTrack)(const char* path, uint8 track, uint32 loopPoint); +extern void (*Music_FadeOut)(float fadeSpeed); +extern void (*Music_PlayJingle)(uint8 trackID); + +#define OBJ_MUSIC_SETUP \ + IMPORT_PUBLIC_FUNC(Music_PlayTrack); \ + IMPORT_PUBLIC_FUNC(Music_SetMusicTrack); \ + IMPORT_PUBLIC_FUNC(Music_FadeOut); \ + IMPORT_PUBLIC_FUNC(Music_PlayJingle); \ + MOD_REGISTER_OBJECT_HOOK(Music) \ No newline at end of file diff --git a/src/hypermania/Mania/Global/PauseMenu.c b/src/hypermania/link/Global/PauseMenu.c similarity index 100% rename from src/hypermania/Mania/Global/PauseMenu.c rename to src/hypermania/link/Global/PauseMenu.c diff --git a/src/hypermania/link/Global/PauseMenu.h b/src/hypermania/link/Global/PauseMenu.h new file mode 100644 index 0000000..d8b2edd --- /dev/null +++ b/src/hypermania/link/Global/PauseMenu.h @@ -0,0 +1,6 @@ +#pragma once + +extern ObjectPauseMenu *PauseMenu; + +#define OBJ_PAUSEMENU_SETUP \ + MOD_REGISTER_OBJECT_HOOK(PauseMenu) \ No newline at end of file diff --git a/src/hypermania/Mania/Global/Ring.c b/src/hypermania/link/Global/Ring.c similarity index 100% rename from src/hypermania/Mania/Global/Ring.c rename to src/hypermania/link/Global/Ring.c diff --git a/src/hypermania/link/Global/Ring.h b/src/hypermania/link/Global/Ring.h new file mode 100644 index 0000000..050e3c4 --- /dev/null +++ b/src/hypermania/link/Global/Ring.h @@ -0,0 +1,18 @@ +#pragma once + +extern ObjectRing *Ring; + +// Imported Functions +extern void (*Ring_State_Lost)(void); +extern void (*Ring_Draw_Normal)(void); +extern void (*Ring_State_Sparkle)(void); +extern void (*Ring_Draw_Sparkle)(void); +extern void (*Ring_Collect)(void); + +#define OBJ_RING_SETUP \ + IMPORT_PUBLIC_FUNC(Ring_State_Lost); \ + IMPORT_PUBLIC_FUNC(Ring_State_Lost); \ + IMPORT_PUBLIC_FUNC(Ring_State_Sparkle); \ + IMPORT_PUBLIC_FUNC(Ring_Draw_Sparkle); \ + IMPORT_PUBLIC_FUNC(Ring_Collect); \ + MOD_REGISTER_OBJECT_HOOK(Ring) \ No newline at end of file diff --git a/src/hypermania/Mania/Global/SaveGame.c b/src/hypermania/link/Global/SaveGame.c similarity index 100% rename from src/hypermania/Mania/Global/SaveGame.c rename to src/hypermania/link/Global/SaveGame.c diff --git a/src/hypermania/link/Global/SaveGame.h b/src/hypermania/link/Global/SaveGame.h new file mode 100644 index 0000000..c8432ec --- /dev/null +++ b/src/hypermania/link/Global/SaveGame.h @@ -0,0 +1,10 @@ +#pragma once + +extern SaveRAM* (*SaveGame_GetSaveRAM)(void); +extern void (*SaveGame_SaveGameState)(void); +extern int32* (*SaveGame_GetDataPtr)(int32 slot, bool32 encore); + +#define OBJ_SAVE_SETUP \ + IMPORT_PUBLIC_FUNC(SaveGame_GetSaveRAM); \ + IMPORT_PUBLIC_FUNC(SaveGame_SaveGameState); \ + IMPORT_PUBLIC_FUNC(SaveGame_GetDataPtr) \ No newline at end of file diff --git a/src/hypermania/Mania/Global/ScoreBonus.c b/src/hypermania/link/Global/ScoreBonus.c similarity index 100% rename from src/hypermania/Mania/Global/ScoreBonus.c rename to src/hypermania/link/Global/ScoreBonus.c diff --git a/src/hypermania/link/Global/ScoreBonus.h b/src/hypermania/link/Global/ScoreBonus.h new file mode 100644 index 0000000..6c15f4f --- /dev/null +++ b/src/hypermania/link/Global/ScoreBonus.h @@ -0,0 +1,3 @@ +#pragma once + +extern ObjectScoreBonus* ScoreBonus; \ No newline at end of file diff --git a/src/hypermania/Mania/Global/Zone.c b/src/hypermania/link/Global/Zone.c similarity index 100% rename from src/hypermania/Mania/Global/Zone.c rename to src/hypermania/link/Global/Zone.c diff --git a/src/hypermania/link/Global/Zone.h b/src/hypermania/link/Global/Zone.h new file mode 100644 index 0000000..93e29ee --- /dev/null +++ b/src/hypermania/link/Global/Zone.h @@ -0,0 +1,6 @@ +#pragma once + +extern ObjectZone* Zone; +extern int32 (*Zone_GetZoneID)(); +extern void (*Zone_StartFadeIn)(int32, int32); +extern void (*Zone_StartFadeOut)(int32, int32); \ No newline at end of file diff --git a/src/hypermania/Mania/HCZ/Blastoid.c b/src/hypermania/link/HCZ/Blastoid.c similarity index 100% rename from src/hypermania/Mania/HCZ/Blastoid.c rename to src/hypermania/link/HCZ/Blastoid.c diff --git a/src/hypermania/link/HCZ/Blastoid.h b/src/hypermania/link/HCZ/Blastoid.h new file mode 100644 index 0000000..bf43b2f --- /dev/null +++ b/src/hypermania/link/HCZ/Blastoid.h @@ -0,0 +1,11 @@ +#pragma once + +extern ObjectBlastoid* Blastoid; + +extern void (*Blastoid_State_Projectile)(); + +void Blastoid_EnemyInfoHook(); + +#define OBJ_BLASTOID_SETUP \ + IMPORT_PUBLIC_FUNC(Blastoid_State_Projectile); \ + REGISTER_ENEMY(Blastoid) \ No newline at end of file diff --git a/src/hypermania/Mania/HCZ/Buggernaut.c b/src/hypermania/link/HCZ/Buggernaut.c similarity index 100% rename from src/hypermania/Mania/HCZ/Buggernaut.c rename to src/hypermania/link/HCZ/Buggernaut.c diff --git a/src/hypermania/link/HCZ/Buggernaut.h b/src/hypermania/link/HCZ/Buggernaut.h new file mode 100644 index 0000000..18887db --- /dev/null +++ b/src/hypermania/link/HCZ/Buggernaut.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectBuggernaut* Buggernaut; + +void Buggernaut_EnemyInfoHook(); + +#define OBJ_BUGGERNAUT_SETUP \ + REGISTER_ENEMY(Buggernaut) \ No newline at end of file diff --git a/src/hypermania/Mania/HCZ/HCZSetup.c b/src/hypermania/link/HCZ/HCZSetup.c similarity index 100% rename from src/hypermania/Mania/HCZ/HCZSetup.c rename to src/hypermania/link/HCZ/HCZSetup.c diff --git a/src/hypermania/link/HCZ/HCZSetup.h b/src/hypermania/link/HCZ/HCZSetup.h new file mode 100644 index 0000000..fa74329 --- /dev/null +++ b/src/hypermania/link/HCZ/HCZSetup.h @@ -0,0 +1,3 @@ +#pragma once + +extern ObjectHCZSetup *HCZSetup; \ No newline at end of file diff --git a/src/hypermania/Mania/HCZ/Jawz.c b/src/hypermania/link/HCZ/Jawz.c similarity index 100% rename from src/hypermania/Mania/HCZ/Jawz.c rename to src/hypermania/link/HCZ/Jawz.c diff --git a/src/hypermania/link/HCZ/Jawz.h b/src/hypermania/link/HCZ/Jawz.h new file mode 100644 index 0000000..6060fd9 --- /dev/null +++ b/src/hypermania/link/HCZ/Jawz.h @@ -0,0 +1,11 @@ +#pragma once + +extern ObjectJawz* Jawz; + +extern void (*Jawz_State_Triggered)(); + +void Jawz_EnemyInfoHook(); + +#define OBJ_JAWZ_SETUP \ + IMPORT_PUBLIC_FUNC(Jawz_State_Triggered); \ + REGISTER_ENEMY(Jawz) \ No newline at end of file diff --git a/src/hypermania/Mania/HCZ/Jellygnite.c b/src/hypermania/link/HCZ/Jellygnite.c similarity index 100% rename from src/hypermania/Mania/HCZ/Jellygnite.c rename to src/hypermania/link/HCZ/Jellygnite.c diff --git a/src/hypermania/link/HCZ/Jellygnite.h b/src/hypermania/link/HCZ/Jellygnite.h new file mode 100644 index 0000000..1799135 --- /dev/null +++ b/src/hypermania/link/HCZ/Jellygnite.h @@ -0,0 +1,11 @@ +#pragma once + +extern ObjectJellygnite* Jellygnite; + +extern void (*Jellygnite_State_Init)(); + +void Jellygnite_EnemyInfoHook(); + +#define OBJ_JELLYGNITE_SETUP \ + IMPORT_PUBLIC_FUNC(Jellygnite_State_Init); \ + REGISTER_ENEMY(Jellygnite) \ No newline at end of file diff --git a/src/hypermania/Mania/HCZ/LaundroMobile.c b/src/hypermania/link/HCZ/LaundroMobile.c similarity index 100% rename from src/hypermania/Mania/HCZ/LaundroMobile.c rename to src/hypermania/link/HCZ/LaundroMobile.c diff --git a/src/hypermania/link/HCZ/LaundroMobile.h b/src/hypermania/link/HCZ/LaundroMobile.h new file mode 100644 index 0000000..3351a64 --- /dev/null +++ b/src/hypermania/link/HCZ/LaundroMobile.h @@ -0,0 +1,21 @@ +#pragma once + +extern ObjectWhirlpool* Whirlpool; +extern ObjectLaundroMobile* LaundroMobile; + +extern void (*LaundroMobile_StateBoss_AwaitPlayer_Phase1)(); +extern void (*LaundroMobile_StateBoss_SetupArena_Phase1)(); +extern void (*LaundroMobile_StateBoss_Destroyed_Phase1)(); +extern void (*LaundroMobile_StateBoss_Destroyed_Phase2)(); +extern void (*LaundroMobile_StateBoss_Explode_Phase2)(); + +void LaundroMobile_EnemyInfoHook(); + +#define OBJ_LAUNDROMOBILE_SETUP \ + MOD_REGISTER_OBJECT_HOOK(Whirlpool); \ + IMPORT_PUBLIC_FUNC(LaundroMobile_StateBoss_AwaitPlayer_Phase1); \ + IMPORT_PUBLIC_FUNC(LaundroMobile_StateBoss_SetupArena_Phase1); \ + IMPORT_PUBLIC_FUNC(LaundroMobile_StateBoss_Destroyed_Phase1); \ + IMPORT_PUBLIC_FUNC(LaundroMobile_StateBoss_Destroyed_Phase2); \ + IMPORT_PUBLIC_FUNC(LaundroMobile_StateBoss_Explode_Phase2); \ + REGISTER_ENEMY(LaundroMobile) \ No newline at end of file diff --git a/src/hypermania/Mania/HCZ/MegaChopper.c b/src/hypermania/link/HCZ/MegaChopper.c similarity index 100% rename from src/hypermania/Mania/HCZ/MegaChopper.c rename to src/hypermania/link/HCZ/MegaChopper.c diff --git a/src/hypermania/link/HCZ/MegaChopper.h b/src/hypermania/link/HCZ/MegaChopper.h new file mode 100644 index 0000000..2c2054b --- /dev/null +++ b/src/hypermania/link/HCZ/MegaChopper.h @@ -0,0 +1,13 @@ +#pragma once + +extern ObjectMegaChopper* MegaChopper; + +extern void (*MegaChopper_State_InWater)(); +extern void (*MegaChopper_State_OutOfWater)(); + +void MegaChopper_EnemyInfoHook(); + +#define OBJ_MEGACHOPPER_SETUP \ + IMPORT_PUBLIC_FUNC(MegaChopper_State_InWater); \ + IMPORT_PUBLIC_FUNC(MegaChopper_State_OutOfWater); \ + REGISTER_ENEMY(MegaChopper) \ No newline at end of file diff --git a/src/hypermania/Mania/HCZ/Pointdexter.c b/src/hypermania/link/HCZ/Pointdexter.c similarity index 100% rename from src/hypermania/Mania/HCZ/Pointdexter.c rename to src/hypermania/link/HCZ/Pointdexter.c diff --git a/src/hypermania/link/HCZ/Pointdexter.h b/src/hypermania/link/HCZ/Pointdexter.h new file mode 100644 index 0000000..95673e2 --- /dev/null +++ b/src/hypermania/link/HCZ/Pointdexter.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectPointdexter* Pointdexter; + +void Pointdexter_EnemyInfoHook(); + +#define OBJ_POINTDEXTER_SETUP \ + REGISTER_ENEMY(Pointdexter) \ No newline at end of file diff --git a/src/hypermania/Mania/HCZ/TurboSpiker.c b/src/hypermania/link/HCZ/TurboSpiker.c similarity index 100% rename from src/hypermania/Mania/HCZ/TurboSpiker.c rename to src/hypermania/link/HCZ/TurboSpiker.c diff --git a/src/hypermania/link/HCZ/TurboSpiker.h b/src/hypermania/link/HCZ/TurboSpiker.h new file mode 100644 index 0000000..f306c7d --- /dev/null +++ b/src/hypermania/link/HCZ/TurboSpiker.h @@ -0,0 +1,13 @@ +#pragma once + +extern ObjectTurboSpiker* TurboSpiker; + +extern void (*TurboSpiker_State_Spike)(); +extern void (*TurboSpiker_State_Ember)(); + +void TurboSpiker_EnemyInfoHook(); + +#define OBJ_TURBOSPIKER_SETUP \ + IMPORT_PUBLIC_FUNC(TurboSpiker_State_Spike); \ + IMPORT_PUBLIC_FUNC(TurboSpiker_State_Ember); \ + REGISTER_ENEMY(TurboSpiker) \ No newline at end of file diff --git a/src/hypermania/Mania/LRZ/Drillerdroid.c b/src/hypermania/link/LRZ/Drillerdroid.c similarity index 100% rename from src/hypermania/Mania/LRZ/Drillerdroid.c rename to src/hypermania/link/LRZ/Drillerdroid.c diff --git a/src/hypermania/link/LRZ/Drillerdroid.h b/src/hypermania/link/LRZ/Drillerdroid.h new file mode 100644 index 0000000..25394aa --- /dev/null +++ b/src/hypermania/link/LRZ/Drillerdroid.h @@ -0,0 +1,31 @@ +#pragma once + +extern ObjectDrillerdroid* Drillerdroid; + +extern void (*Drillerdroid_State_SetupArena)(); +extern void (*Drillerdroid_State_AwaitPlayer)(); +extern void (*Drillerdroid_State_FinishDrilling)(); +extern void (*Drillerdroid_State_JumpTargeting)(); +extern void (*Drillerdroid_State_DecidingDropPos)(); +extern void (*Drillerdroid_State_DropFailReset)(); +extern void (*Drillerdroid_State_Destroyed)(); +extern void (*Drillerdroid_State_Finish)(); +extern void (*Drillerdroid_State_DropSignPost)(); +extern void (*Drillerdroid_State_Target)(); +extern void (*Drillerdroid_Hit)(); + +void Drillerdroid_EnemyInfoHook(); + +#define OBJ_DRILLERDROID_SETUP \ + IMPORT_PUBLIC_FUNC(Drillerdroid_State_SetupArena); \ + IMPORT_PUBLIC_FUNC(Drillerdroid_State_AwaitPlayer); \ + IMPORT_PUBLIC_FUNC(Drillerdroid_State_FinishDrilling); \ + IMPORT_PUBLIC_FUNC(Drillerdroid_State_JumpTargeting); \ + IMPORT_PUBLIC_FUNC(Drillerdroid_State_DecidingDropPos); \ + IMPORT_PUBLIC_FUNC(Drillerdroid_State_DropFailReset); \ + IMPORT_PUBLIC_FUNC(Drillerdroid_State_Destroyed); \ + IMPORT_PUBLIC_FUNC(Drillerdroid_State_Finish); \ + IMPORT_PUBLIC_FUNC(Drillerdroid_State_DropSignPost); \ + IMPORT_PUBLIC_FUNC(Drillerdroid_State_Target); \ + IMPORT_PUBLIC_FUNC(Drillerdroid_Hit); \ + REGISTER_ENEMY(Drillerdroid) \ No newline at end of file diff --git a/src/hypermania/Mania/LRZ/DrillerdroidO.c b/src/hypermania/link/LRZ/DrillerdroidO.c similarity index 100% rename from src/hypermania/Mania/LRZ/DrillerdroidO.c rename to src/hypermania/link/LRZ/DrillerdroidO.c diff --git a/src/hypermania/link/LRZ/DrillerdroidO.h b/src/hypermania/link/LRZ/DrillerdroidO.h new file mode 100644 index 0000000..d40cae8 --- /dev/null +++ b/src/hypermania/link/LRZ/DrillerdroidO.h @@ -0,0 +1,35 @@ +#pragma once + +extern ObjectDrillerdroidO* DrillerdroidO; + +extern void (*DrillerdroidO_State_Dropping)(); +extern void (*DrillerdroidO_State_Landed)(); +extern void (*DrillerdroidO_State_LandRecoil)(); +extern void (*DrillerdroidO_State_BeginDrilling)(); +extern void (*DrillerdroidO_State_Drilling)(); +extern void (*DrillerdroidO_State_FinishDrilling)(); +extern void (*DrillerdroidO_State_Overheat)(); +extern void (*DrillerdroidO_State_OverheatRecoil)(); +extern void (*DrillerdroidO_State_JumpTargetDelay)(); +extern void (*DrillerdroidO_State_OverheatRecoil_DestroyedSegment)(); +extern void (*DrillerdroidO_State_Cooldown)(); +extern void (*DrillerdroidO_State_ResetFromCooldown)(); +extern void (*DrillerdroidO_State_Destroyed)(); + +void DrillerdroidO_EnemyInfoHook(); + +#define OBJ_DRILLERDROIDO_SETUP \ + IMPORT_PUBLIC_FUNC(DrillerdroidO_State_Dropping); \ + IMPORT_PUBLIC_FUNC(DrillerdroidO_State_Landed); \ + IMPORT_PUBLIC_FUNC(DrillerdroidO_State_LandRecoil); \ + IMPORT_PUBLIC_FUNC(DrillerdroidO_State_BeginDrilling); \ + IMPORT_PUBLIC_FUNC(DrillerdroidO_State_Drilling); \ + IMPORT_PUBLIC_FUNC(DrillerdroidO_State_FinishDrilling); \ + IMPORT_PUBLIC_FUNC(DrillerdroidO_State_Overheat); \ + IMPORT_PUBLIC_FUNC(DrillerdroidO_State_OverheatRecoil); \ + IMPORT_PUBLIC_FUNC(DrillerdroidO_State_JumpTargetDelay); \ + IMPORT_PUBLIC_FUNC(DrillerdroidO_State_OverheatRecoil_DestroyedSegment); \ + IMPORT_PUBLIC_FUNC(DrillerdroidO_State_Cooldown); \ + IMPORT_PUBLIC_FUNC(DrillerdroidO_State_ResetFromCooldown); \ + IMPORT_PUBLIC_FUNC(DrillerdroidO_State_Destroyed); \ + REGISTER_ENEMY(DrillerdroidO) \ No newline at end of file diff --git a/src/hypermania/Mania/LRZ/Fireworm.c b/src/hypermania/link/LRZ/Fireworm.c similarity index 100% rename from src/hypermania/Mania/LRZ/Fireworm.c rename to src/hypermania/link/LRZ/Fireworm.c diff --git a/src/hypermania/link/LRZ/Fireworm.h b/src/hypermania/link/LRZ/Fireworm.h new file mode 100644 index 0000000..897a16e --- /dev/null +++ b/src/hypermania/link/LRZ/Fireworm.h @@ -0,0 +1,11 @@ +#pragma once + +extern ObjectFireworm* Fireworm; + +extern void (*Fireworm_State_FlyAround)(); + +void Fireworm_EnemyInfoHook(); + +#define OBJ_FIREWORM_SETUP \ + IMPORT_PUBLIC_FUNC(Fireworm_State_FlyAround); \ + REGISTER_ENEMY(Fireworm) \ No newline at end of file diff --git a/src/hypermania/Mania/LRZ/HeavyKing.c b/src/hypermania/link/LRZ/HeavyKing.c similarity index 100% rename from src/hypermania/Mania/LRZ/HeavyKing.c rename to src/hypermania/link/LRZ/HeavyKing.c diff --git a/src/hypermania/link/LRZ/HeavyKing.h b/src/hypermania/link/LRZ/HeavyKing.h new file mode 100644 index 0000000..498dc6b --- /dev/null +++ b/src/hypermania/link/LRZ/HeavyKing.h @@ -0,0 +1,15 @@ +#pragma once + +extern ObjectHeavyRider* HeavyRider; + +extern void (*HeavyRider_State_Moving)(); +extern void (*HeavyRider_State_Turning)(); +extern void (*HeavyRider_Hit)(); + +void HeavyRider_EnemyInfoHook(); + +#define OBJ_HEAVYRIDER_SETUP \ + IMPORT_PUBLIC_FUNC(HeavyRider_State_Moving); \ + IMPORT_PUBLIC_FUNC(HeavyRider_State_Turning); \ + IMPORT_PUBLIC_FUNC(HeavyRider_Hit); \ + REGISTER_ENEMY(HeavyRider) \ No newline at end of file diff --git a/src/hypermania/Mania/LRZ/HeavyRider.c b/src/hypermania/link/LRZ/HeavyRider.c similarity index 100% rename from src/hypermania/Mania/LRZ/HeavyRider.c rename to src/hypermania/link/LRZ/HeavyRider.c diff --git a/src/hypermania/link/LRZ/HeavyRider.h b/src/hypermania/link/LRZ/HeavyRider.h new file mode 100644 index 0000000..1b93135 --- /dev/null +++ b/src/hypermania/link/LRZ/HeavyRider.h @@ -0,0 +1,35 @@ +#pragma once + +extern ObjectHeavyKing* HeavyKing; + +extern void (*HeavyKing_State_JumpToTargetEmerald)(); +extern void (*HeavyKing_State_Leaping)(); +extern void (*HeavyKing_State_LeapToMasterEmerald)(); +extern void (*HeavyKing_State_LandedOnMasterEmerald)(); +extern void (*HeavyKing_State_ChargeStart)(); +extern void (*HeavyKing_State_ChargeStop)(); +extern void (*HeavyKing_State_PrepareHover)(); +extern void (*HeavyKing_State_StartHovering)(); +extern void (*HeavyKing_State_Hovering)(); +extern void (*HeavyKing_State_LaserAttack)(); +extern void (*HeavyKing_State_ExpandRingAttack)(); +extern void (*HeavyKing_State_TwinChargeAttack)(); +extern void (*HeavyKing_Hit)(); + +void HeavyKing_EnemyInfoHook(); + +#define OBJ_HEAVYKING_SETUP \ + IMPORT_PUBLIC_FUNC(HeavyKing_State_JumpToTargetEmerald); \ + IMPORT_PUBLIC_FUNC(HeavyKing_State_Leaping); \ + IMPORT_PUBLIC_FUNC(HeavyKing_State_LeapToMasterEmerald); \ + IMPORT_PUBLIC_FUNC(HeavyKing_State_LandedOnMasterEmerald); \ + IMPORT_PUBLIC_FUNC(HeavyKing_State_ChargeStart); \ + IMPORT_PUBLIC_FUNC(HeavyKing_State_ChargeStop); \ + IMPORT_PUBLIC_FUNC(HeavyKing_State_PrepareHover); \ + IMPORT_PUBLIC_FUNC(HeavyKing_State_StartHovering); \ + IMPORT_PUBLIC_FUNC(HeavyKing_State_Hovering); \ + IMPORT_PUBLIC_FUNC(HeavyKing_State_LaserAttack); \ + IMPORT_PUBLIC_FUNC(HeavyKing_State_ExpandRingAttack); \ + IMPORT_PUBLIC_FUNC(HeavyKing_State_TwinChargeAttack); \ + IMPORT_PUBLIC_FUNC(HeavyKing_Hit); \ + REGISTER_ENEMY(HeavyKing) \ No newline at end of file diff --git a/src/hypermania/Mania/LRZ/Rexon.c b/src/hypermania/link/LRZ/Rexon.c similarity index 100% rename from src/hypermania/Mania/LRZ/Rexon.c rename to src/hypermania/link/LRZ/Rexon.c diff --git a/src/hypermania/link/LRZ/Rexon.h b/src/hypermania/link/LRZ/Rexon.h new file mode 100644 index 0000000..ffa3739 --- /dev/null +++ b/src/hypermania/link/LRZ/Rexon.h @@ -0,0 +1,17 @@ +#pragma once + +extern ObjectRexon* Rexon; + +extern void (*Rexon_State_Hidden)(); +extern void (*Rexon_State_Rising)(); +extern void (*Rexon_State_Shooting)(); +extern void (*Rexon_State_Destroyed)(); + +void Rexon_EnemyInfoHook(); + +#define OBJ_REXON_SETUP \ + IMPORT_PUBLIC_FUNC(Rexon_State_Hidden); \ + IMPORT_PUBLIC_FUNC(Rexon_State_Rising); \ + IMPORT_PUBLIC_FUNC(Rexon_State_Shooting); \ + IMPORT_PUBLIC_FUNC(Rexon_State_Destroyed); \ + REGISTER_ENEMY(Rexon) \ No newline at end of file diff --git a/src/hypermania/Mania/LRZ/RockDrill.c b/src/hypermania/link/LRZ/RockDrill.c similarity index 100% rename from src/hypermania/Mania/LRZ/RockDrill.c rename to src/hypermania/link/LRZ/RockDrill.c diff --git a/src/hypermania/link/LRZ/RockDrill.h b/src/hypermania/link/LRZ/RockDrill.h new file mode 100644 index 0000000..86a228e --- /dev/null +++ b/src/hypermania/link/LRZ/RockDrill.h @@ -0,0 +1,11 @@ +#pragma once + +extern ObjectRockDrill* RockDrill; + +extern void (*RockDrill_State_Drilling)(); + +void RockDrill_EnemyInfoHook(); + +#define OBJ_ROCKDRILL_SETUP \ + IMPORT_PUBLIC_FUNC(RockDrill_State_Drilling); \ + REGISTER_ENEMY(RockDrill) \ No newline at end of file diff --git a/src/hypermania/Mania/LRZ/Toxomister.c b/src/hypermania/link/LRZ/Toxomister.c similarity index 100% rename from src/hypermania/Mania/LRZ/Toxomister.c rename to src/hypermania/link/LRZ/Toxomister.c diff --git a/src/hypermania/link/LRZ/Toxomister.h b/src/hypermania/link/LRZ/Toxomister.h new file mode 100644 index 0000000..595d56f --- /dev/null +++ b/src/hypermania/link/LRZ/Toxomister.h @@ -0,0 +1,9 @@ +extern ObjectToxomister* Toxomister; + +extern void (*Toxomister_State_CreateClouds)(); + +void Toxomister_EnemyInfoHook(); + +#define OBJ_TOXOMISTER_SETUP \ + IMPORT_PUBLIC_FUNC(Toxomister_State_CreateClouds); \ + REGISTER_ENEMY(Toxomister) \ No newline at end of file diff --git a/src/hypermania/Mania/MMZ/EggPistonsMKII.c b/src/hypermania/link/MMZ/EggPistonsMKII.c similarity index 100% rename from src/hypermania/Mania/MMZ/EggPistonsMKII.c rename to src/hypermania/link/MMZ/EggPistonsMKII.c diff --git a/src/hypermania/link/MMZ/EggPistonsMKII.h b/src/hypermania/link/MMZ/EggPistonsMKII.h new file mode 100644 index 0000000..8638b8e --- /dev/null +++ b/src/hypermania/link/MMZ/EggPistonsMKII.h @@ -0,0 +1,17 @@ +#pragma once + +extern ObjectEggPistonsMKII* EggPistonsMKII; + +extern void (*EggPistonsMKII_State_ClassicMode)(); +extern void (*EggPistonsMKII_State_PinchMode)(); +extern void (*EggPistonsMKII_State_Destroyed)(); +extern void (*EggPistonsMKII_Hit)(); + +void EggPistonsMKII_EnemyInfoHook(); + +#define OBJ_EGGPISTONSMKII_SETUP \ + IMPORT_PUBLIC_FUNC(EggPistonsMKII_State_ClassicMode); \ + IMPORT_PUBLIC_FUNC(EggPistonsMKII_State_PinchMode); \ + IMPORT_PUBLIC_FUNC(EggPistonsMKII_State_Destroyed); \ + IMPORT_PUBLIC_FUNC(EggPistonsMKII_Hit); \ + REGISTER_ENEMY(EggPistonsMKII) \ No newline at end of file diff --git a/src/hypermania/Mania/MMZ/FarPlane.c b/src/hypermania/link/MMZ/FarPlane.c similarity index 98% rename from src/hypermania/Mania/MMZ/FarPlane.c rename to src/hypermania/link/MMZ/FarPlane.c index 97beb83..ce79804 100644 --- a/src/hypermania/Mania/MMZ/FarPlane.c +++ b/src/hypermania/link/MMZ/FarPlane.c @@ -1,8 +1,4 @@ #include "FarPlane.h" -#include "HyperStars.h" -#include "SuperFlicky.h" -#include "ImageTrail.h" -#include "Global/InvincibleStars.h" ObjectFarPlane* FarPlane; void (*FarPlane_SetupEntities)(); diff --git a/src/hypermania/link/MMZ/FarPlane.h b/src/hypermania/link/MMZ/FarPlane.h new file mode 100644 index 0000000..9769d67 --- /dev/null +++ b/src/hypermania/link/MMZ/FarPlane.h @@ -0,0 +1,16 @@ +#pragma once + +extern ObjectFarPlane* FarPlane; + +extern void (*FarPlane_SetupEntities)(); +extern void (*FarPlane_SetEntityActivities)(uint8 active); + +void FarPlane_LateUpdate_OVERLOAD(); + +void FarPlane_DrawHook_ApplyFarPlane(); +void FarPlane_DrawHook_RemoveFarPlane(); + +#define OBJ_FARPLANE_SETUP \ + IMPORT_PUBLIC_FUNC(FarPlane_SetupEntities); \ + IMPORT_PUBLIC_FUNC(FarPlane_SetEntityActivities); \ + MOD_REGISTER_OBJ_OVERLOAD(FarPlane, NULL, FarPlane_LateUpdate_OVERLOAD, NULL, NULL, NULL, NULL, NULL, NULL, NULL) \ No newline at end of file diff --git a/src/hypermania/Mania/MMZ/Gachapandora.c b/src/hypermania/link/MMZ/Gachapandora.c similarity index 100% rename from src/hypermania/Mania/MMZ/Gachapandora.c rename to src/hypermania/link/MMZ/Gachapandora.c diff --git a/src/hypermania/link/MMZ/Gachapandora.h b/src/hypermania/link/MMZ/Gachapandora.h new file mode 100644 index 0000000..f30a50b --- /dev/null +++ b/src/hypermania/link/MMZ/Gachapandora.h @@ -0,0 +1,19 @@ +#pragma once + +extern ObjectGachapandora* Gachapandora; + +extern void (*Gachapandora_StatePrize_DrillerMove)(); +extern void (*Gachapandora_StatePrize_FireDropperMove)(); +extern void (*Gachapandora_StatePrize_AmyWalk)(); +extern void (*Gachapandora_StatePrize_AmyIdle)(); +extern void (*Gachapandora_StatePrize_Destroyed)(); + +void Gachapandora_EnemyInfoHook(); + +#define OBJ_GACHAPANDORA_SETUP \ + IMPORT_PUBLIC_FUNC(Gachapandora_StatePrize_DrillerMove); \ + IMPORT_PUBLIC_FUNC(Gachapandora_StatePrize_FireDropperMove); \ + IMPORT_PUBLIC_FUNC(Gachapandora_StatePrize_AmyWalk); \ + IMPORT_PUBLIC_FUNC(Gachapandora_StatePrize_AmyIdle); \ + IMPORT_PUBLIC_FUNC(Gachapandora_StatePrize_Destroyed); \ + REGISTER_ENEMY(Gachapandora) \ No newline at end of file diff --git a/src/hypermania/Mania/MMZ/MechaBu.c b/src/hypermania/link/MMZ/MechaBu.c similarity index 100% rename from src/hypermania/Mania/MMZ/MechaBu.c rename to src/hypermania/link/MMZ/MechaBu.c diff --git a/src/hypermania/link/MMZ/MechaBu.h b/src/hypermania/link/MMZ/MechaBu.h new file mode 100644 index 0000000..d612260 --- /dev/null +++ b/src/hypermania/link/MMZ/MechaBu.h @@ -0,0 +1,15 @@ +#pragma once + +extern ObjectMechaBu* MechaBu; + +extern void (*MechaBu_State_Moving)(); +extern void (*MechaBu_State_Stopped)(); +extern void (*MechaBu_State_Falling)(); + +void MechaBu_EnemyInfoHook(); + +#define OBJ_MECHABU_SETUP \ + IMPORT_PUBLIC_FUNC(MechaBu_State_Moving); \ + IMPORT_PUBLIC_FUNC(MechaBu_State_Stopped); \ + IMPORT_PUBLIC_FUNC(MechaBu_State_Falling); \ + REGISTER_ENEMY(MechaBu) \ No newline at end of file diff --git a/src/hypermania/Mania/MMZ/PohBee.c b/src/hypermania/link/MMZ/PohBee.c similarity index 100% rename from src/hypermania/Mania/MMZ/PohBee.c rename to src/hypermania/link/MMZ/PohBee.c diff --git a/src/hypermania/link/MMZ/PohBee.h b/src/hypermania/link/MMZ/PohBee.h new file mode 100644 index 0000000..f239123 --- /dev/null +++ b/src/hypermania/link/MMZ/PohBee.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectPohBee* PohBee; + +void PohBee_EnemyInfoHook(); + +#define OBJ_POHBEE_SETUP \ + REGISTER_ENEMY(PohBee) \ No newline at end of file diff --git a/src/hypermania/Mania/MMZ/Scarab.c b/src/hypermania/link/MMZ/Scarab.c similarity index 100% rename from src/hypermania/Mania/MMZ/Scarab.c rename to src/hypermania/link/MMZ/Scarab.c diff --git a/src/hypermania/link/MMZ/Scarab.h b/src/hypermania/link/MMZ/Scarab.h new file mode 100644 index 0000000..0ef73f4 --- /dev/null +++ b/src/hypermania/link/MMZ/Scarab.h @@ -0,0 +1,11 @@ +#pragma once + +extern ObjectScarab* Scarab; + +extern void (*Scarab_HandlePlayerRelease)(); + +void Scarab_EnemyInfoHook(); + +#define OBJ_SCARAB_SETUP \ + IMPORT_PUBLIC_FUNC(Scarab_HandlePlayerRelease); \ + REGISTER_ENEMY(Scarab) \ No newline at end of file diff --git a/src/hypermania/Mania/MSZ/Armadiloid.c b/src/hypermania/link/MSZ/Armadiloid.c similarity index 100% rename from src/hypermania/Mania/MSZ/Armadiloid.c rename to src/hypermania/link/MSZ/Armadiloid.c diff --git a/src/hypermania/link/MSZ/Armadiloid.h b/src/hypermania/link/MSZ/Armadiloid.h new file mode 100644 index 0000000..3ec950f --- /dev/null +++ b/src/hypermania/link/MSZ/Armadiloid.h @@ -0,0 +1,10 @@ +#pragma once + +extern ObjectArmadiloid* Armadiloid; + +void Armadiloid_EnemyInfoHook(); +extern void (*Armadiloid_State_Rider)(); + +#define OBJ_ARMADILOID_SETUP \ + IMPORT_PUBLIC_FUNC(Armadiloid_State_Rider); \ + REGISTER_ENEMY(Armadiloid) \ No newline at end of file diff --git a/src/hypermania/Mania/MSZ/Bumpalo.c b/src/hypermania/link/MSZ/Bumpalo.c similarity index 100% rename from src/hypermania/Mania/MSZ/Bumpalo.c rename to src/hypermania/link/MSZ/Bumpalo.c diff --git a/src/hypermania/link/MSZ/Bumpalo.h b/src/hypermania/link/MSZ/Bumpalo.h new file mode 100644 index 0000000..ab0ac17 --- /dev/null +++ b/src/hypermania/link/MSZ/Bumpalo.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectBumpalo* Bumpalo; + +void Bumpalo_EnemyInfoHook(); + +#define OBJ_BUMPALO_SETUP \ + REGISTER_ENEMY(Bumpalo) \ No newline at end of file diff --git a/src/hypermania/Mania/MSZ/Cactula.c b/src/hypermania/link/MSZ/Cactula.c similarity index 100% rename from src/hypermania/Mania/MSZ/Cactula.c rename to src/hypermania/link/MSZ/Cactula.c diff --git a/src/hypermania/link/MSZ/Cactula.h b/src/hypermania/link/MSZ/Cactula.h new file mode 100644 index 0000000..81afa87 --- /dev/null +++ b/src/hypermania/link/MSZ/Cactula.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectCactula* Cactula; + +void Cactula_EnemyInfoHook(); + +#define OBJ_CACTULA_SETUP \ + REGISTER_ENEMY(Cactula) \ No newline at end of file diff --git a/src/hypermania/Mania/MSZ/DBTower.c b/src/hypermania/link/MSZ/DBTower.c similarity index 100% rename from src/hypermania/Mania/MSZ/DBTower.c rename to src/hypermania/link/MSZ/DBTower.c diff --git a/src/hypermania/link/MSZ/DBTower.h b/src/hypermania/link/MSZ/DBTower.h new file mode 100644 index 0000000..ac55be4 --- /dev/null +++ b/src/hypermania/link/MSZ/DBTower.h @@ -0,0 +1,13 @@ +#pragma once + +extern ObjectDBTower* DBTower; + +extern void (*DBTower_State_HandleBoss)(); +extern void (*DBTower_State_Destroyed)(); + +void DBTower_EnemyInfoHook(); + +#define OBJ_DBTOWER_SETUP \ + IMPORT_PUBLIC_FUNC(DBTower_State_HandleBoss); \ + IMPORT_PUBLIC_FUNC(DBTower_State_Destroyed); \ + REGISTER_ENEMY(DBTower) \ No newline at end of file diff --git a/src/hypermania/Mania/MSZ/Hatterkiller.c b/src/hypermania/link/MSZ/Hatterkiller.c similarity index 100% rename from src/hypermania/Mania/MSZ/Hatterkiller.c rename to src/hypermania/link/MSZ/Hatterkiller.c diff --git a/src/hypermania/link/MSZ/Hatterkiller.h b/src/hypermania/link/MSZ/Hatterkiller.h new file mode 100644 index 0000000..9a48ad8 --- /dev/null +++ b/src/hypermania/link/MSZ/Hatterkiller.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectHatterkiller* Hatterkiller; + +void Hatterkiller_EnemyInfoHook(); + +#define OBJ_HATTERKILLER_SETUP \ + REGISTER_ENEMY(Hatterkiller) \ No newline at end of file diff --git a/src/hypermania/Mania/MSZ/HeavyMystic.c b/src/hypermania/link/MSZ/HeavyMystic.c similarity index 100% rename from src/hypermania/Mania/MSZ/HeavyMystic.c rename to src/hypermania/link/MSZ/HeavyMystic.c diff --git a/src/hypermania/link/MSZ/HeavyMystic.h b/src/hypermania/link/MSZ/HeavyMystic.h new file mode 100644 index 0000000..bb667da --- /dev/null +++ b/src/hypermania/link/MSZ/HeavyMystic.h @@ -0,0 +1,36 @@ +#pragma once + +extern ObjectHeavyMystic* HeavyMystic; + +extern void (*HeavyMystic_Hit)(); +extern void (*HeavyMystic_StateBoss_RougeHit)(); +extern void (*HeavyMystic_StateBoss_MysticReveal)(); +extern void (*HeavyMystic_StateBoss_FangIdle)(); +extern void (*HeavyMystic_StateBoss_FangTell)(); +extern void (*HeavyMystic_StateBoss_FangHop)(); +extern void (*HeavyMystic_StateBoss_BarkIdle)(); +extern void (*HeavyMystic_StateBoss_BarkPounding)(); +extern void (*HeavyMystic_StateBoss_BarkJump)(); +extern void (*HeavyMystic_StateBoss_BeanIdle)(); +extern void (*HeavyMystic_StateBoss_BeanBomb1Throw)(); +extern void (*HeavyMystic_StateBoss_BeanBomb2Throw)(); +extern void (*HeavyMystic_StateBoss_BeanJump)(); + +void HeavyMystic_EnemyInfoHook(); + +#define OBJ_HEAVYMYSTIC_SETUP \ + IMPORT_PUBLIC_FUNC(HeavyMystic_Hit); \ + HeavyMystic_StateBoss_RougeHit = Mod.GetPublicFunction(NULL, "HeavyMystic_StateBoss_RougeHit"); \ + if (!HeavyMystic_StateBoss_RougeHit) HeavyMystic_StateBoss_RougeHit = Mod.GetPublicFunction(NULL, "HeavyMystic_StateBoss_RogueHit"); \ + IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_MysticReveal); \ + IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_FangIdle); \ + IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_FangTell); \ + IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_FangHop); \ + IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_BarkIdle); \ + IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_BarkPounding); \ + IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_BarkJump); \ + IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_BeanIdle); \ + IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_BeanBomb1Throw); \ + IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_BeanBomb2Throw); \ + IMPORT_PUBLIC_FUNC(HeavyMystic_StateBoss_BeanJump); \ + REGISTER_ENEMY(HeavyMystic) \ No newline at end of file diff --git a/src/hypermania/Mania/MSZ/Rattlekiller.c b/src/hypermania/link/MSZ/Rattlekiller.c similarity index 100% rename from src/hypermania/Mania/MSZ/Rattlekiller.c rename to src/hypermania/link/MSZ/Rattlekiller.c diff --git a/src/hypermania/link/MSZ/Rattlekiller.h b/src/hypermania/link/MSZ/Rattlekiller.h new file mode 100644 index 0000000..0ebd1f4 --- /dev/null +++ b/src/hypermania/link/MSZ/Rattlekiller.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectRattlekiller* Rattlekiller; + +void Rattlekiller_EnemyInfoHook(); + +#define OBJ_RATTLEKILLER_SETUP \ + REGISTER_ENEMY(Rattlekiller) \ No newline at end of file diff --git a/src/hypermania/Mania/MSZ/RollerMKII.c b/src/hypermania/link/MSZ/RollerMKII.c similarity index 100% rename from src/hypermania/Mania/MSZ/RollerMKII.c rename to src/hypermania/link/MSZ/RollerMKII.c diff --git a/src/hypermania/link/MSZ/RollerMKII.h b/src/hypermania/link/MSZ/RollerMKII.h new file mode 100644 index 0000000..b5e3544 --- /dev/null +++ b/src/hypermania/link/MSZ/RollerMKII.h @@ -0,0 +1,13 @@ +#pragma once + +extern ObjectRollerMKII* RollerMKII; + +extern void (*RollerMKII_State_Idle)(); +extern void (*RollerMKII_State_SpinUp)(); + +void RollerMKII_EnemyInfoHook(); + +#define OBJ_ROLLERMKII_SETUP \ + IMPORT_PUBLIC_FUNC(RollerMKII_State_Idle); \ + IMPORT_PUBLIC_FUNC(RollerMKII_State_SpinUp); \ + REGISTER_ENEMY(RollerMKII) \ No newline at end of file diff --git a/src/hypermania/Mania/MSZ/UberCaterkiller.c b/src/hypermania/link/MSZ/UberCaterkiller.c similarity index 100% rename from src/hypermania/Mania/MSZ/UberCaterkiller.c rename to src/hypermania/link/MSZ/UberCaterkiller.c diff --git a/src/hypermania/link/MSZ/UberCaterkiller.h b/src/hypermania/link/MSZ/UberCaterkiller.h new file mode 100644 index 0000000..c8fc6fb --- /dev/null +++ b/src/hypermania/link/MSZ/UberCaterkiller.h @@ -0,0 +1,17 @@ +#pragma once + +extern ObjectUberCaterkiller* UberCaterkiller; + +extern void (*UberCaterkiller_State_HorizontalJump)(); +extern void (*UberCaterkiller_State_FirstJump)(); +extern void (*UberCaterkiller_State_RepeatedJumps)(); +extern void (*UberCaterkiller_Hit)(); + +void UberCaterkiller_EnemyInfoHook(); + +#define OBJ_UBERCATERKILLER_SETUP \ + IMPORT_PUBLIC_FUNC(UberCaterkiller_State_HorizontalJump); \ + IMPORT_PUBLIC_FUNC(UberCaterkiller_State_FirstJump); \ + IMPORT_PUBLIC_FUNC(UberCaterkiller_State_RepeatedJumps); \ + IMPORT_PUBLIC_FUNC(UberCaterkiller_Hit); \ + REGISTER_ENEMY(UberCaterkiller) \ No newline at end of file diff --git a/src/hypermania/Mania/MSZ/Vultron.c b/src/hypermania/link/MSZ/Vultron.c similarity index 100% rename from src/hypermania/Mania/MSZ/Vultron.c rename to src/hypermania/link/MSZ/Vultron.c diff --git a/src/hypermania/link/MSZ/Vultron.h b/src/hypermania/link/MSZ/Vultron.h new file mode 100644 index 0000000..77d41d8 --- /dev/null +++ b/src/hypermania/link/MSZ/Vultron.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectVultron* Vultron; + +void Vultron_EnemyInfoHook(); + +#define OBJ_VULTRON_SETUP \ + REGISTER_ENEMY(Vultron) diff --git a/src/hypermania/Mania/OOZ/Aquis.c b/src/hypermania/link/OOZ/Aquis.c similarity index 100% rename from src/hypermania/Mania/OOZ/Aquis.c rename to src/hypermania/link/OOZ/Aquis.c diff --git a/src/hypermania/link/OOZ/Aquis.h b/src/hypermania/link/OOZ/Aquis.h new file mode 100644 index 0000000..350a0ad --- /dev/null +++ b/src/hypermania/link/OOZ/Aquis.h @@ -0,0 +1,11 @@ +#pragma once + +extern ObjectAquis* Aquis; + +extern void (*Aquis_State_Shot)(); + +void Aquis_EnemyInfoHook(); + +#define OBJ_AQUIS_SETUP \ + IMPORT_PUBLIC_FUNC(Aquis_State_Shot); \ + REGISTER_ENEMY(Aquis) diff --git a/src/hypermania/Mania/OOZ/MegaOctus.c b/src/hypermania/link/OOZ/MegaOctus.c similarity index 100% rename from src/hypermania/Mania/OOZ/MegaOctus.c rename to src/hypermania/link/OOZ/MegaOctus.c diff --git a/src/hypermania/link/OOZ/MegaOctus.h b/src/hypermania/link/OOZ/MegaOctus.h new file mode 100644 index 0000000..764e84b --- /dev/null +++ b/src/hypermania/link/OOZ/MegaOctus.h @@ -0,0 +1,30 @@ +#pragma once + +extern ObjectMegaOctus* MegaOctus; + +extern void (*MegaOctus_State_EnterMegaOctus)(); +extern void (*MegaOctus_State_OpenHatchAndLaugh)(); +extern void (*MegaOctus_State_CloseHatch)(); +extern void (*MegaOctus_State_DiveIntoOil)(); +extern void (*MegaOctus_State_SpawnWeapons)(); +extern void (*MegaOctus_State_CannonThenSpawnOrbs)(); +extern void (*MegaOctus_StateOrb_Wait)(); +extern void (*MegaOctus_StateOrb_FireShot)(); +extern void (*MegaOctus_StateOrb_Idle)(); +extern void (*MegaOctus_StateOrb_Destroyed)(); +extern void (*MegaOctus_Hit)(); + +void MegaOctus_EnemyInfoHook(); + +#define OBJ_MEGAOCTUS_SETUP \ + IMPORT_PUBLIC_FUNC(MegaOctus_Hit); \ + IMPORT_PUBLIC_FUNC(MegaOctus_State_OpenHatchAndLaugh); \ + IMPORT_PUBLIC_FUNC(MegaOctus_State_CloseHatch); \ + IMPORT_PUBLIC_FUNC(MegaOctus_State_DiveIntoOil); \ + IMPORT_PUBLIC_FUNC(MegaOctus_State_SpawnWeapons); \ + IMPORT_PUBLIC_FUNC(MegaOctus_State_CannonThenSpawnOrbs); \ + IMPORT_PUBLIC_FUNC(MegaOctus_StateOrb_Wait); \ + IMPORT_PUBLIC_FUNC(MegaOctus_StateOrb_FireShot); \ + IMPORT_PUBLIC_FUNC(MegaOctus_StateOrb_Idle); \ + IMPORT_PUBLIC_FUNC(MegaOctus_StateOrb_Destroyed); \ + REGISTER_ENEMY(MegaOctus) \ No newline at end of file diff --git a/src/hypermania/Mania/OOZ/MeterDroid.c b/src/hypermania/link/OOZ/MeterDroid.c similarity index 100% rename from src/hypermania/Mania/OOZ/MeterDroid.c rename to src/hypermania/link/OOZ/MeterDroid.c diff --git a/src/hypermania/link/OOZ/MeterDroid.h b/src/hypermania/link/OOZ/MeterDroid.h new file mode 100644 index 0000000..b231a6d --- /dev/null +++ b/src/hypermania/link/OOZ/MeterDroid.h @@ -0,0 +1,21 @@ +#pragma once + +extern ObjectMeterDroid* MeterDroid; + +extern void (*MeterDroid_State_TurningValve)(); +extern void (*MeterDroid_State_StopTurningValve)(); +extern void (*MeterDroid_State_WatchPlatformsPopUp)(); +extern void (*MeterDroid_State_Destroyed)(); +extern void (*MeterDroid_State_FinishAct)(); +extern void (*MeterDroid_Hit)(); + +void MeterDroid_EnemyInfoHook(); + +#define OBJ_METERDROID_SETUP \ + IMPORT_PUBLIC_FUNC(MeterDroid_State_TurningValve); \ + IMPORT_PUBLIC_FUNC(MeterDroid_State_StopTurningValve); \ + IMPORT_PUBLIC_FUNC(MeterDroid_State_WatchPlatformsPopUp); \ + IMPORT_PUBLIC_FUNC(MeterDroid_State_Destroyed); \ + IMPORT_PUBLIC_FUNC(MeterDroid_State_FinishAct); \ + IMPORT_PUBLIC_FUNC(MeterDroid_Hit); \ + REGISTER_ENEMY(MeterDroid) \ No newline at end of file diff --git a/src/hypermania/Mania/OOZ/OOZSetup.c b/src/hypermania/link/OOZ/OOZSetup.c similarity index 100% rename from src/hypermania/Mania/OOZ/OOZSetup.c rename to src/hypermania/link/OOZ/OOZSetup.c diff --git a/src/hypermania/link/OOZ/OOZSetup.h b/src/hypermania/link/OOZ/OOZSetup.h new file mode 100644 index 0000000..2176a34 --- /dev/null +++ b/src/hypermania/link/OOZ/OOZSetup.h @@ -0,0 +1,3 @@ +#pragma once + +extern ObjectOOZSetup* OOZSetup; \ No newline at end of file diff --git a/src/hypermania/Mania/OOZ/Octus.c b/src/hypermania/link/OOZ/Octus.c similarity index 100% rename from src/hypermania/Mania/OOZ/Octus.c rename to src/hypermania/link/OOZ/Octus.c diff --git a/src/hypermania/link/OOZ/Octus.h b/src/hypermania/link/OOZ/Octus.h new file mode 100644 index 0000000..517f41e --- /dev/null +++ b/src/hypermania/link/OOZ/Octus.h @@ -0,0 +1,11 @@ +#pragma once + +extern ObjectOctus* Octus; + +extern void (*Octus_State_Shot)(); + +void Octus_EnemyInfoHook(); + +#define OBJ_OCTUS_SETUP \ + IMPORT_PUBLIC_FUNC(Octus_State_Shot); \ + REGISTER_ENEMY(Octus) \ No newline at end of file diff --git a/src/hypermania/Mania/OOZ/Sol.c b/src/hypermania/link/OOZ/Sol.c similarity index 100% rename from src/hypermania/Mania/OOZ/Sol.c rename to src/hypermania/link/OOZ/Sol.c diff --git a/src/hypermania/link/OOZ/Sol.h b/src/hypermania/link/OOZ/Sol.h new file mode 100644 index 0000000..313aee3 --- /dev/null +++ b/src/hypermania/link/OOZ/Sol.h @@ -0,0 +1,17 @@ +#pragma once + +extern ObjectSol* Sol; + +extern void (*Sol_State_Moving)(); +extern void (*Sol_State_ShootingOrbs)(); +extern void (*Sol_State_NoOrbs)(); +extern void (*Sol_State_ActiveFireball)(); + +void Sol_EnemyInfoHook(); + +#define OBJ_SOL_SETUP \ + IMPORT_PUBLIC_FUNC(Sol_State_Moving); \ + IMPORT_PUBLIC_FUNC(Sol_State_ShootingOrbs); \ + IMPORT_PUBLIC_FUNC(Sol_State_NoOrbs); \ + IMPORT_PUBLIC_FUNC(Sol_State_ActiveFireball); \ + REGISTER_ENEMY(Sol) diff --git a/src/hypermania/Mania/PGZ/Dragonfly.c b/src/hypermania/link/PGZ/Dragonfly.c similarity index 100% rename from src/hypermania/Mania/PGZ/Dragonfly.c rename to src/hypermania/link/PGZ/Dragonfly.c diff --git a/src/hypermania/link/PGZ/Dragonfly.h b/src/hypermania/link/PGZ/Dragonfly.h new file mode 100644 index 0000000..493cfb3 --- /dev/null +++ b/src/hypermania/link/PGZ/Dragonfly.h @@ -0,0 +1,11 @@ +#pragma once + +extern ObjectDragonfly* Dragonfly; + +extern void (*Dragonfly_State_Move)(); + +void Dragonfly_EnemyInfoHook(); + +#define OBJ_DRAGONFLY_SETUP \ + IMPORT_PUBLIC_FUNC(Dragonfly_State_Move); \ + REGISTER_ENEMY(Dragonfly) \ No newline at end of file diff --git a/src/hypermania/Mania/PGZ/HeavyShinobi.c b/src/hypermania/link/PGZ/HeavyShinobi.c similarity index 100% rename from src/hypermania/Mania/PGZ/HeavyShinobi.c rename to src/hypermania/link/PGZ/HeavyShinobi.c diff --git a/src/hypermania/link/PGZ/HeavyShinobi.h b/src/hypermania/link/PGZ/HeavyShinobi.h new file mode 100644 index 0000000..785fb7a --- /dev/null +++ b/src/hypermania/link/PGZ/HeavyShinobi.h @@ -0,0 +1,18 @@ +#pragma once + +extern ObjectHeavyShinobi* HeavyShinobi; + +void HeavyShinobi_EnemyInfoHook(void); +extern void (*HeavyShinobi_State_Idle)(); +extern void (*HeavyShinobi_State_Slash)(); +extern void (*HeavyShinobi_State_Jump)(); +extern void (*HeavyShinobi_State_Glitched)(); +extern void (*HeavyShinobi_State_Destroyed)(); + +#define OBJ_HEAVYSHINOBI_SETUP \ + IMPORT_PUBLIC_FUNC(HeavyShinobi_State_Idle); \ + IMPORT_PUBLIC_FUNC(HeavyShinobi_State_Slash); \ + IMPORT_PUBLIC_FUNC(HeavyShinobi_State_Jump); \ + IMPORT_PUBLIC_FUNC(HeavyShinobi_State_Glitched); \ + IMPORT_PUBLIC_FUNC(HeavyShinobi_State_Destroyed); \ + REGISTER_ENEMY(HeavyShinobi) \ No newline at end of file diff --git a/src/hypermania/Mania/PGZ/IceBomba.c b/src/hypermania/link/PGZ/IceBomba.c similarity index 100% rename from src/hypermania/Mania/PGZ/IceBomba.c rename to src/hypermania/link/PGZ/IceBomba.c diff --git a/src/hypermania/link/PGZ/IceBomba.h b/src/hypermania/link/PGZ/IceBomba.h new file mode 100644 index 0000000..a262eff --- /dev/null +++ b/src/hypermania/link/PGZ/IceBomba.h @@ -0,0 +1,15 @@ +#pragma once + +extern ObjectIceBomba* IceBomba; + +extern void (*IceBomba_State_Flying)(); +extern void (*IceBomba_State_Turning)(); +extern void (*IceBomba_State_FlyAway)(); + +void IceBomba_EnemyInfoHook(); + +#define OBJ_ICEBOMBA_SETUP \ + IMPORT_PUBLIC_FUNC(IceBomba_State_Flying); \ + IMPORT_PUBLIC_FUNC(IceBomba_State_Turning); \ + IMPORT_PUBLIC_FUNC(IceBomba_State_FlyAway); \ + REGISTER_ENEMY(IceBomba) \ No newline at end of file diff --git a/src/hypermania/Mania/PGZ/JuggleSaw.c b/src/hypermania/link/PGZ/JuggleSaw.c similarity index 100% rename from src/hypermania/Mania/PGZ/JuggleSaw.c rename to src/hypermania/link/PGZ/JuggleSaw.c diff --git a/src/hypermania/link/PGZ/JuggleSaw.h b/src/hypermania/link/PGZ/JuggleSaw.h new file mode 100644 index 0000000..059dcf7 --- /dev/null +++ b/src/hypermania/link/PGZ/JuggleSaw.h @@ -0,0 +1,13 @@ +#pragma once + +extern ObjectJuggleSaw* JuggleSaw; + +extern void (*JuggleSaw_StateCrab_Handle)(); +extern void (*JuggleSaw_StateCrab_ThrowSaw)(); + +void JuggleSaw_EnemyInfoHook(); + +#define OBJ_JUGGLESAW_SETUP \ + IMPORT_PUBLIC_FUNC(JuggleSaw_StateCrab_Handle); \ + IMPORT_PUBLIC_FUNC(JuggleSaw_StateCrab_ThrowSaw); \ + REGISTER_ENEMY(JuggleSaw) \ No newline at end of file diff --git a/src/hypermania/Mania/PGZ/Shiversaw.c b/src/hypermania/link/PGZ/Shiversaw.c similarity index 100% rename from src/hypermania/Mania/PGZ/Shiversaw.c rename to src/hypermania/link/PGZ/Shiversaw.c diff --git a/src/hypermania/link/PGZ/Shiversaw.h b/src/hypermania/link/PGZ/Shiversaw.h new file mode 100644 index 0000000..90c79ed --- /dev/null +++ b/src/hypermania/link/PGZ/Shiversaw.h @@ -0,0 +1,17 @@ +#pragma once + +extern ObjectShiversaw* Shiversaw; + +extern void (*Shiversaw_State_Idle)(); +extern void (*Shiversaw_State_MoveToPlayer)(); +extern void (*Shiversaw_State_HitRecoil)(); +extern void (*Shiversaw_Hit)(); + +void Shiversaw_EnemyInfoHook(); + +#define OBJ_SHIVERSAW_SETUP \ + IMPORT_PUBLIC_FUNC(Shiversaw_State_Idle); \ + IMPORT_PUBLIC_FUNC(Shiversaw_State_MoveToPlayer); \ + IMPORT_PUBLIC_FUNC(Shiversaw_State_HitRecoil); \ + IMPORT_PUBLIC_FUNC(Shiversaw_Hit); \ + REGISTER_ENEMY(Shiversaw) \ No newline at end of file diff --git a/src/hypermania/Mania/PGZ/Woodrow.c b/src/hypermania/link/PGZ/Woodrow.c similarity index 100% rename from src/hypermania/Mania/PGZ/Woodrow.c rename to src/hypermania/link/PGZ/Woodrow.c diff --git a/src/hypermania/link/PGZ/Woodrow.h b/src/hypermania/link/PGZ/Woodrow.h new file mode 100644 index 0000000..70a795b --- /dev/null +++ b/src/hypermania/link/PGZ/Woodrow.h @@ -0,0 +1,15 @@ +#pragma once + +extern ObjectWoodrow* Woodrow; + +extern void (*Woodrow_State_Idle)(); +extern void (*Woodrow_State_MoveUp)(); +extern void (*Woodrow_State_MoveDown)(); + +void Woodrow_EnemyInfoHook(); + +#define OBJ_WOODROW_SETUP \ + IMPORT_PUBLIC_FUNC(Woodrow_State_Idle); \ + IMPORT_PUBLIC_FUNC(Woodrow_State_MoveUp); \ + IMPORT_PUBLIC_FUNC(Woodrow_State_MoveDown); \ + REGISTER_ENEMY(Woodrow) \ No newline at end of file diff --git a/src/hypermania/Mania/SPZ/Canista.c b/src/hypermania/link/SPZ/Canista.c similarity index 100% rename from src/hypermania/Mania/SPZ/Canista.c rename to src/hypermania/link/SPZ/Canista.c diff --git a/src/hypermania/link/SPZ/Canista.h b/src/hypermania/link/SPZ/Canista.h new file mode 100644 index 0000000..15d826c --- /dev/null +++ b/src/hypermania/link/SPZ/Canista.h @@ -0,0 +1,13 @@ +#pragma once + +extern ObjectCanista* Canista; + +extern void (*Canista_State_Moving)(); +extern void (*Canista_State_Idle)(); + +void Canista_EnemyInfoHook(); + +#define OBJ_CANISTA_SETUP \ + IMPORT_PUBLIC_FUNC(Canista_State_Moving); \ + IMPORT_PUBLIC_FUNC(Canista_State_Idle); \ + REGISTER_ENEMY(Canista) \ No newline at end of file diff --git a/src/hypermania/Mania/SPZ/MicDrop.c b/src/hypermania/link/SPZ/MicDrop.c similarity index 100% rename from src/hypermania/Mania/SPZ/MicDrop.c rename to src/hypermania/link/SPZ/MicDrop.c diff --git a/src/hypermania/link/SPZ/MicDrop.h b/src/hypermania/link/SPZ/MicDrop.h new file mode 100644 index 0000000..843194f --- /dev/null +++ b/src/hypermania/link/SPZ/MicDrop.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectMicDrop* MicDrop; + +void MicDrop_EnemyInfoHook(); + +#define OBJ_MICDROP_SETUP \ + REGISTER_ENEMY(MicDrop) diff --git a/src/hypermania/Mania/SPZ/Shutterbug.c b/src/hypermania/link/SPZ/Shutterbug.c similarity index 100% rename from src/hypermania/Mania/SPZ/Shutterbug.c rename to src/hypermania/link/SPZ/Shutterbug.c diff --git a/src/hypermania/link/SPZ/Shutterbug.h b/src/hypermania/link/SPZ/Shutterbug.h new file mode 100644 index 0000000..a125e80 --- /dev/null +++ b/src/hypermania/link/SPZ/Shutterbug.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectShutterbug* Shutterbug; + +void Shutterbug_EnemyInfoHook(); + +#define OBJ_SHUTTERBUG_SETUP \ + REGISTER_ENEMY(Shutterbug) \ No newline at end of file diff --git a/src/hypermania/Mania/SPZ/Tubinaut.c b/src/hypermania/link/SPZ/Tubinaut.c similarity index 100% rename from src/hypermania/Mania/SPZ/Tubinaut.c rename to src/hypermania/link/SPZ/Tubinaut.c diff --git a/src/hypermania/link/SPZ/Tubinaut.h b/src/hypermania/link/SPZ/Tubinaut.h new file mode 100644 index 0000000..3a35d74 --- /dev/null +++ b/src/hypermania/link/SPZ/Tubinaut.h @@ -0,0 +1,11 @@ +#pragma once + +extern ObjectTubinaut* Tubinaut; + +extern void (*Tubinaut_State_Move)(); + +void Tubinaut_EnemyInfoHook(); + +#define OBJ_TUBINAUT_SETUP \ + IMPORT_PUBLIC_FUNC(Tubinaut_State_Move); \ + REGISTER_ENEMY(Tubinaut) \ No newline at end of file diff --git a/src/hypermania/Mania/SPZ/WeatherMobile.c b/src/hypermania/link/SPZ/WeatherMobile.c similarity index 100% rename from src/hypermania/Mania/SPZ/WeatherMobile.c rename to src/hypermania/link/SPZ/WeatherMobile.c diff --git a/src/hypermania/link/SPZ/WeatherMobile.h b/src/hypermania/link/SPZ/WeatherMobile.h new file mode 100644 index 0000000..3646157 --- /dev/null +++ b/src/hypermania/link/SPZ/WeatherMobile.h @@ -0,0 +1,19 @@ +#pragma once + +extern ObjectWeatherMobile* WeatherMobile; + +extern void (*WeatherMobile_State_EnterEggman)(); +extern void (*WeatherMobile_State_HandleMovement)(); +extern void (*WeatherMobile_State_WindAttack)(); +extern void (*WeatherMobile_State_SunAttack)(); +extern void (*WeatherMobile_Hit)(); + +void WeatherMobile_EnemyInfoHook(); + +#define OBJ_WEATHERMOBILE_SETUP \ + IMPORT_PUBLIC_FUNC(WeatherMobile_State_EnterEggman); \ + IMPORT_PUBLIC_FUNC(WeatherMobile_State_HandleMovement); \ + IMPORT_PUBLIC_FUNC(WeatherMobile_State_WindAttack); \ + IMPORT_PUBLIC_FUNC(WeatherMobile_State_SunAttack); \ + IMPORT_PUBLIC_FUNC(WeatherMobile_Hit); \ + REGISTER_ENEMY(WeatherMobile) \ No newline at end of file diff --git a/src/hypermania/Mania/SSZ/Dango.c b/src/hypermania/link/SSZ/Dango.c similarity index 100% rename from src/hypermania/Mania/SSZ/Dango.c rename to src/hypermania/link/SSZ/Dango.c diff --git a/src/hypermania/link/SSZ/Dango.h b/src/hypermania/link/SSZ/Dango.h new file mode 100644 index 0000000..f86a0af --- /dev/null +++ b/src/hypermania/link/SSZ/Dango.h @@ -0,0 +1,23 @@ +#pragma once + +extern ObjectDango* Dango; + +extern void (*Dango_State_Walking)(); +extern void (*Dango_State_Turning)(); +extern void (*Dango_State_Falling_Uncurled)(); +extern void (*Dango_State_Curling)(); +extern void (*Dango_State_Rolling)(); +extern void (*Dango_State_Falling_Curled)(); +extern void (*Dango_State_Uncurling)(); + +void Dango_EnemyInfoHook(); + +#define OBJ_DANGO_SETUP \ + IMPORT_PUBLIC_FUNC(Dango_State_Walking); \ + IMPORT_PUBLIC_FUNC(Dango_State_Turning); \ + IMPORT_PUBLIC_FUNC(Dango_State_Falling_Uncurled); \ + IMPORT_PUBLIC_FUNC(Dango_State_Curling); \ + IMPORT_PUBLIC_FUNC(Dango_State_Rolling); \ + IMPORT_PUBLIC_FUNC(Dango_State_Falling_Curled); \ + IMPORT_PUBLIC_FUNC(Dango_State_Uncurling); \ + REGISTER_ENEMY(Dango) \ No newline at end of file diff --git a/src/hypermania/Mania/SSZ/GigaMetal.c b/src/hypermania/link/SSZ/GigaMetal.c similarity index 100% rename from src/hypermania/Mania/SSZ/GigaMetal.c rename to src/hypermania/link/SSZ/GigaMetal.c diff --git a/src/hypermania/link/SSZ/GigaMetal.h b/src/hypermania/link/SSZ/GigaMetal.h new file mode 100644 index 0000000..8470a9a --- /dev/null +++ b/src/hypermania/link/SSZ/GigaMetal.h @@ -0,0 +1,18 @@ +#pragma once + +#if MANIA_USE_PLUS + extern ObjectGigaMetal* GigaMetal; + + extern void (*GigaMetal_StateBody_Marching)(); + extern void (*GigaMetal_Hit)(); + + void GigaMetal_EnemyInfoHook(); + + #define OBJ_GIGAMETAL_SETUP \ + IMPORT_PUBLIC_FUNC(GigaMetal_StateBody_Marching); \ + IMPORT_PUBLIC_FUNC(GigaMetal_Hit); \ + REGISTER_ENEMY(GigaMetal) + +#else + #define OBJ_GIGAMETAL_SETUP +#endif \ No newline at end of file diff --git a/src/hypermania/Mania/SSZ/Hotaru.c b/src/hypermania/link/SSZ/Hotaru.c similarity index 100% rename from src/hypermania/Mania/SSZ/Hotaru.c rename to src/hypermania/link/SSZ/Hotaru.c diff --git a/src/hypermania/link/SSZ/Hotaru.h b/src/hypermania/link/SSZ/Hotaru.h new file mode 100644 index 0000000..6232e1c --- /dev/null +++ b/src/hypermania/link/SSZ/Hotaru.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectHotaru* Hotaru; + +void Hotaru_EnemyInfoHook(); + +#define OBJ_HOTARU_SETUP \ + REGISTER_ENEMY(Hotaru) \ No newline at end of file diff --git a/src/hypermania/Mania/SSZ/HotaruHiWatt.c b/src/hypermania/link/SSZ/HotaruHiWatt.c similarity index 100% rename from src/hypermania/Mania/SSZ/HotaruHiWatt.c rename to src/hypermania/link/SSZ/HotaruHiWatt.c diff --git a/src/hypermania/link/SSZ/HotaruHiWatt.h b/src/hypermania/link/SSZ/HotaruHiWatt.h new file mode 100644 index 0000000..fa16b54 --- /dev/null +++ b/src/hypermania/link/SSZ/HotaruHiWatt.h @@ -0,0 +1,41 @@ +#pragma once + +extern ObjectHotaruHiWatt* HotaruHiWatt; + +extern void (*HotaruHiWatt_StateBoss_Appear)(); +extern void (*HotaruHiWatt_StateBoss_FlyUp)(); +extern void (*HotaruHiWatt_StateBoss_LaserAttackDelay)(); +extern void (*HotaruHiWatt_StateBoss_ChargingLaser)(); +extern void (*HotaruHiWatt_StateBoss_FinishedLaserAttack)(); +extern void (*HotaruHiWatt_StateBoss_LaserAttack_Left)(); +extern void (*HotaruHiWatt_StateBoss_LaserAttack_Right)(); +extern void (*HotaruHiWatt_StateHotaru_Charging)(); +extern void (*HotaruHiWatt_StateHotaru_Attacking)(); +extern void (*HotaruHiWatt_StateHotaru_FinishedAttack)(); +extern void (*HotaruHiWatt_StateHotaru_EndAttackSequence)(); +extern void (*HotaruHiWatt_StateHotaruPair_AttackMovingDown)(); +extern void (*HotaruHiWatt_StateHotaruPair_AttackMovingUp)(); +extern void (*HotaruHiWatt_SetupHHWReappear)(); +extern void (*HotaruHiWatt_SpawnPairHotarus)(); +extern void (*HotaruHiWatt_Hit)(); + +void HotaruHiWatt_EnemyInfoHook(); + +#define OBJ_HOTARUHIWATT_SETUP \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateBoss_Appear); \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateBoss_FlyUp); \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateBoss_LaserAttackDelay); \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateBoss_LaserAttack_Left); \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateBoss_LaserAttack_Right); \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateBoss_ChargingLaser); \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateBoss_FinishedLaserAttack); \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateHotaru_Charging); \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateHotaru_Attacking); \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateHotaru_FinishedAttack); \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateHotaru_EndAttackSequence); \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateHotaruPair_AttackMovingDown); \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_StateHotaruPair_AttackMovingUp); \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_SetupHHWReappear); \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_SpawnPairHotarus); \ + IMPORT_PUBLIC_FUNC(HotaruHiWatt_Hit); \ + REGISTER_ENEMY(HotaruHiWatt) \ No newline at end of file diff --git a/src/hypermania/Mania/SSZ/HotaruMKII.c b/src/hypermania/link/SSZ/HotaruMKII.c similarity index 100% rename from src/hypermania/Mania/SSZ/HotaruMKII.c rename to src/hypermania/link/SSZ/HotaruMKII.c diff --git a/src/hypermania/link/SSZ/HotaruMKII.h b/src/hypermania/link/SSZ/HotaruMKII.h new file mode 100644 index 0000000..9a53fa6 --- /dev/null +++ b/src/hypermania/link/SSZ/HotaruMKII.h @@ -0,0 +1,13 @@ +#pragma once + +extern ObjectHotaruMKII* HotaruMKII; + +extern void (*HotaruMKII_State_Charging)(); +extern void (*HotaruMKII_State_LaserAttack)(); + +void HotaruMKII_EnemyInfoHook(); + +#define OBJ_HOTARUMKII_SETUP \ + IMPORT_PUBLIC_FUNC(HotaruMKII_State_Charging); \ + IMPORT_PUBLIC_FUNC(HotaruMKII_State_LaserAttack); \ + REGISTER_ENEMY(HotaruMKII) \ No newline at end of file diff --git a/src/hypermania/Mania/SSZ/Kabasira.c b/src/hypermania/link/SSZ/Kabasira.c similarity index 100% rename from src/hypermania/Mania/SSZ/Kabasira.c rename to src/hypermania/link/SSZ/Kabasira.c diff --git a/src/hypermania/link/SSZ/Kabasira.h b/src/hypermania/link/SSZ/Kabasira.h new file mode 100644 index 0000000..0a8b40b --- /dev/null +++ b/src/hypermania/link/SSZ/Kabasira.h @@ -0,0 +1,11 @@ +#pragma once + +extern ObjectKabasira* Kabasira; + +extern void (*Kabasira_State_Moving)(); + +void Kabasira_EnemyInfoHook(); + +#define OBJ_KABASIRA_SETUP \ + IMPORT_PUBLIC_FUNC(Kabasira_State_Moving); \ + REGISTER_ENEMY(Kabasira) \ No newline at end of file diff --git a/src/hypermania/Mania/SSZ/Kanabun.c b/src/hypermania/link/SSZ/Kanabun.c similarity index 100% rename from src/hypermania/Mania/SSZ/Kanabun.c rename to src/hypermania/link/SSZ/Kanabun.c diff --git a/src/hypermania/link/SSZ/Kanabun.h b/src/hypermania/link/SSZ/Kanabun.h new file mode 100644 index 0000000..f040401 --- /dev/null +++ b/src/hypermania/link/SSZ/Kanabun.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectKanabun* Kanabun; + +void Kanabun_EnemyInfoHook(); + +#define OBJ_KANABUN_SETUP \ + REGISTER_ENEMY(Kanabun) \ No newline at end of file diff --git a/src/hypermania/Mania/SSZ/MetalSonic.c b/src/hypermania/link/SSZ/MetalSonic.c similarity index 100% rename from src/hypermania/Mania/SSZ/MetalSonic.c rename to src/hypermania/link/SSZ/MetalSonic.c diff --git a/src/hypermania/link/SSZ/MetalSonic.h b/src/hypermania/link/SSZ/MetalSonic.h new file mode 100644 index 0000000..3788a70 --- /dev/null +++ b/src/hypermania/link/SSZ/MetalSonic.h @@ -0,0 +1,20 @@ +#pragma once + +extern ObjectMetalSonic* MetalSonic; + +// hopefully this works because i dont feel like compiling a pre-mania Game.so to test it lol +#if !MANIA_USE_PLUS + extern void (*MetalSonic_State_Hover_Phase2)(); + extern void (*MetalSonic_State_FinishAttack_Phase2)(); + extern void (*MetalSonic_Hit)(); + + void MetalSonic_EnemyInfoHook(); + + #define OBJ_METALSONIC_SETUP \ + IMPORT_PUBLIC_FUNC(MetalSonic_State_Hover_Phase2); \ + IMPORT_PUBLIC_FUNC(MetalSonic_State_FinishAttack_Phase2); \ + IMPORT_PUBLIC_FUNC(MetalSonic_Hit); \ + REGISTER_ENEMY(MetalSonic) +#else + #define OBJ_METALSONIC_SETUP +#endif \ No newline at end of file diff --git a/src/hypermania/Mania/TMZ/BallHog.c b/src/hypermania/link/TMZ/BallHog.c similarity index 100% rename from src/hypermania/Mania/TMZ/BallHog.c rename to src/hypermania/link/TMZ/BallHog.c diff --git a/src/hypermania/link/TMZ/BallHog.h b/src/hypermania/link/TMZ/BallHog.h new file mode 100644 index 0000000..66d56c8 --- /dev/null +++ b/src/hypermania/link/TMZ/BallHog.h @@ -0,0 +1,11 @@ +#pragma once + +extern ObjectBallHog *BallHog; + +extern void (*BallHog_State_Bomb)(); + +void BallHog_EnemyInfoHook(); + +#define OBJ_BALLHOG_SETUP \ + IMPORT_PUBLIC_FUNC(BallHog_State_Bomb); \ + REGISTER_ENEMY(BallHog) \ No newline at end of file diff --git a/src/hypermania/Mania/TMZ/CrimsonEye.c b/src/hypermania/link/TMZ/CrimsonEye.c similarity index 100% rename from src/hypermania/Mania/TMZ/CrimsonEye.c rename to src/hypermania/link/TMZ/CrimsonEye.c diff --git a/src/hypermania/link/TMZ/CrimsonEye.h b/src/hypermania/link/TMZ/CrimsonEye.h new file mode 100644 index 0000000..1882ef1 --- /dev/null +++ b/src/hypermania/link/TMZ/CrimsonEye.h @@ -0,0 +1,17 @@ +#pragma once + +extern ObjectCrimsonEye* CrimsonEye; + +extern void (*CrimsonEye_StateCore_ContainerActive)(); +extern void (*CrimsonEye_StateCore_Hovering)(); +extern void (*CrimsonEye_StateCore_ImpactLift)(); +extern void (*CrimsonEye_Hit)(); + +void CrimsonEye_EnemyInfoHook(); + +#define OBJ_CRIMSONEYE_SETUP \ + IMPORT_PUBLIC_FUNC(CrimsonEye_StateCore_ContainerActive); \ + IMPORT_PUBLIC_FUNC(CrimsonEye_StateCore_Hovering); \ + IMPORT_PUBLIC_FUNC(CrimsonEye_StateCore_ImpactLift); \ + IMPORT_PUBLIC_FUNC(CrimsonEye_Hit); \ + REGISTER_ENEMY(CrimsonEye) \ No newline at end of file diff --git a/src/hypermania/Mania/TMZ/FlasherMKII.c b/src/hypermania/link/TMZ/FlasherMKII.c similarity index 100% rename from src/hypermania/Mania/TMZ/FlasherMKII.c rename to src/hypermania/link/TMZ/FlasherMKII.c diff --git a/src/hypermania/link/TMZ/FlasherMKII.h b/src/hypermania/link/TMZ/FlasherMKII.h new file mode 100644 index 0000000..b4302f5 --- /dev/null +++ b/src/hypermania/link/TMZ/FlasherMKII.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectFlasherMKII* FlasherMKII; + +void FlasherMKII_EnemyInfoHook(); + +#define OBJ_FLASHERMKII_SETUP \ + REGISTER_ENEMY(FlasherMKII) \ No newline at end of file diff --git a/src/hypermania/Mania/TMZ/SentryBug.c b/src/hypermania/link/TMZ/SentryBug.c similarity index 100% rename from src/hypermania/Mania/TMZ/SentryBug.c rename to src/hypermania/link/TMZ/SentryBug.c diff --git a/src/hypermania/link/TMZ/SentryBug.h b/src/hypermania/link/TMZ/SentryBug.h new file mode 100644 index 0000000..725e89f --- /dev/null +++ b/src/hypermania/link/TMZ/SentryBug.h @@ -0,0 +1,21 @@ +#pragma once + +extern ObjectSentryBug* SentryBug; + +extern void (*SentryBug_State_AwaitPlayer)(); +extern void (*SentryBug_State_DropOrbs)(); +extern void (*SentryBug_State_NetAppear)(); +extern void (*SentryBug_State_NetShrink)(); +extern void (*SentryBug_State_NetFlash)(); +extern void (*SentryBug_State_ReturnToSlots)(); + +void SentryBug_EnemyInfoHook(); + +#define OBJ_SENTRYBUG_SETUP \ + IMPORT_PUBLIC_FUNC(SentryBug_State_AwaitPlayer); \ + IMPORT_PUBLIC_FUNC(SentryBug_State_DropOrbs); \ + IMPORT_PUBLIC_FUNC(SentryBug_State_NetAppear); \ + IMPORT_PUBLIC_FUNC(SentryBug_State_NetShrink); \ + IMPORT_PUBLIC_FUNC(SentryBug_State_NetFlash); \ + IMPORT_PUBLIC_FUNC(SentryBug_State_ReturnToSlots); \ + REGISTER_ENEMY(SentryBug) \ No newline at end of file diff --git a/src/hypermania/Mania/TMZ/TurboTurtle.c b/src/hypermania/link/TMZ/TurboTurtle.c similarity index 100% rename from src/hypermania/Mania/TMZ/TurboTurtle.c rename to src/hypermania/link/TMZ/TurboTurtle.c diff --git a/src/hypermania/link/TMZ/TurboTurtle.h b/src/hypermania/link/TMZ/TurboTurtle.h new file mode 100644 index 0000000..59be3e3 --- /dev/null +++ b/src/hypermania/link/TMZ/TurboTurtle.h @@ -0,0 +1,8 @@ +#pragma once + +extern ObjectTurboTurtle* TurboTurtle; + +void TurboTurtle_EnemyInfoHook(); + +#define OBJ_TURBOTURTLE_SETUP \ + REGISTER_ENEMY(TurboTurtle) \ No newline at end of file diff --git a/src/hypermania/mod/All.h b/src/hypermania/mod/All.h new file mode 100644 index 0000000..29e8f66 --- /dev/null +++ b/src/hypermania/mod/All.h @@ -0,0 +1,32 @@ +#pragma once + +// im sorry jesus +typedef struct { + int32 type; // -1 means untransformed + Animator animator; +} HPZEmeraldExt; + +struct { + uint16 aniFrames; + uint16 sfxSpecialWarp; +} HPZEmeraldStaticExt; + +// left to right ordering converted to a centered origin that fans out with a left-leaning bias +uint32 super_emerald_lookup[7] = { 5, 3, 1, 0, 2, 4, 6 }; // linear order -> super emerald order +uint32 super_emerald_revlookup[7] = { 3, 2, 4, 1, 5, 0, 6 }; // super emerald order -> linear order + +// Sonic 3's emerald order is identical to Mania's with the exceptions being blue/purple and cyan/red are flipped +uint32 sonic3_emerald_lookup[7] = { 0, 1, 3, 2, 4, 6, 5 }; + +#include "Global/Debris.h" +#include "Global/HUD.h" +#include "Global/ImageTrail.h" +#include "Global/Player.h" +#include "Global/SpecialRing.h" +#include "LRZ/HPZEmerald.h" +#include "Menu/LevelSelect.h" +#include "Menu/UISaveSlot.h" +#include "MMZ/PlaneSeeSaw.h" +#include "UFO/SpecialClear.h" +#include "UFO/UFO_Player.h" +#include "UFO/UFO_Setup.h" diff --git a/src/hypermania/Objects/Debris.c b/src/hypermania/mod/Global/Debris.c similarity index 100% rename from src/hypermania/Objects/Debris.c rename to src/hypermania/mod/Global/Debris.c diff --git a/src/hypermania/mod/Global/Debris.h b/src/hypermania/mod/Global/Debris.h new file mode 100644 index 0000000..be04e96 --- /dev/null +++ b/src/hypermania/mod/Global/Debris.h @@ -0,0 +1,11 @@ +#pragma once + +extern ObjectDebris* Debris; + +extern void (*Debris_State_Move)(); +extern void (*Debris_State_FallAndFlicker)(); + +void Debris_Draw_OVERLOAD(); + +#define OBJ_DEBRIS_SETUP \ + MOD_REGISTER_OBJ_OVERLOAD(Debris, NULL, NULL, NULL, Debris_Draw_OVERLOAD, NULL, NULL, NULL, NULL, NULL) \ No newline at end of file diff --git a/src/hypermania/Objects/HUD.c b/src/hypermania/mod/Global/HUD.c similarity index 100% rename from src/hypermania/Objects/HUD.c rename to src/hypermania/mod/Global/HUD.c diff --git a/src/hypermania/mod/Global/HUD.h b/src/hypermania/mod/Global/HUD.h new file mode 100644 index 0000000..39336af --- /dev/null +++ b/src/hypermania/mod/Global/HUD.h @@ -0,0 +1,13 @@ +#pragma once + +extern ObjectHUD* HUD; + +// ============================================================================= + +// Functions ------------------------------------------------------------------- + +// ============================================================================= +void HUD_LateUpdate_OVERLOAD(); + +#define OBJ_HUD_SETUP \ + MOD_REGISTER_OBJ_OVERLOAD(HUD, NULL, HUD_LateUpdate_OVERLOAD, NULL, NULL, NULL, NULL, NULL, NULL, NULL) diff --git a/src/hypermania/Objects/ImageTrail.c b/src/hypermania/mod/Global/ImageTrail.c similarity index 98% rename from src/hypermania/Objects/ImageTrail.c rename to src/hypermania/mod/Global/ImageTrail.c index 85152f7..1dfc96e 100644 --- a/src/hypermania/Objects/ImageTrail.c +++ b/src/hypermania/mod/Global/ImageTrail.c @@ -1,6 +1,4 @@ #include "ImageTrail.h" -#include "Player.h" -#include "Mania/Global/Zone.h" ObjectImageTrail* ImageTrail; diff --git a/src/hypermania/Objects/ImageTrail.h b/src/hypermania/mod/Global/ImageTrail.h similarity index 55% rename from src/hypermania/Objects/ImageTrail.h rename to src/hypermania/mod/Global/ImageTrail.h index 80afa8a..811de5a 100644 --- a/src/hypermania/Objects/ImageTrail.h +++ b/src/hypermania/mod/Global/ImageTrail.h @@ -1,42 +1,10 @@ -#ifndef OBJ_IMAGETRAIL_H -#define OBJ_IMAGETRAIL_H - -#include "GameAPI/Game.h" +#pragma once // ============================================================================= // Definitions ----------------------------------------------------------------- // ============================================================================= -// Constants -#define IMAGETRAIL_TRACK_COUNT (7) - -// Object Class -typedef struct { - RSDK_OBJECT -} ObjectImageTrail; - -// Entity Class -typedef struct { - RSDK_ENTITY - EntityPlayer *player; - int32 playerClassID; - Vector2 currentPos; - Vector2 statePos[IMAGETRAIL_TRACK_COUNT]; - int32 currentRotation; - int32 stateRotation[IMAGETRAIL_TRACK_COUNT]; - uint8 currentDirection; - uint8 stateDirection[IMAGETRAIL_TRACK_COUNT]; - uint8 currentVisible; - uint8 stateVisible[IMAGETRAIL_TRACK_COUNT]; - int32 currentScale; - int32 stateScale[IMAGETRAIL_TRACK_COUNT]; - Animator currentAnimator; - Animator stateAnimator[IMAGETRAIL_TRACK_COUNT]; - int32 baseAlpha; - int32 fadeoutTimer; -} EntityImageTrail; - // Object Struct extern ObjectImageTrail *ImageTrail; @@ -61,6 +29,4 @@ typedef struct { // ============================================================================= void ImageTrail_Create_OVERLOAD(void* data); void ImageTrail_Draw_OVERLOAD(); -void ImageTrail_LateUpdate_OVERLOAD(); - -#endif //! OBJ_IMAGETRAIL_H +void ImageTrail_LateUpdate_OVERLOAD(); \ No newline at end of file diff --git a/src/hypermania/Objects/Player.c b/src/hypermania/mod/Global/Player.c similarity index 98% rename from src/hypermania/Objects/Player.c rename to src/hypermania/mod/Global/Player.c index fafcd91..feedb1c 100644 --- a/src/hypermania/Objects/Player.c +++ b/src/hypermania/mod/Global/Player.c @@ -1,20 +1,4 @@ #include "Player.h" -#include "Mania/Global/Camera.h" -#include "Debris.h" -#include "Mania/Cutscene/FXFade.h" -#include "Mania/Global/Ring.h" -#include "Mania/Global/ItemBox.h" -#include "ImageTrail.h" -#include "SuperFlicky.h" -#include "HyperStars.h" -#include "JetGlideEffect.h" -#include "Mania/Global/Zone.h" - -#include "CPZ/CPZSetup.h" -#include "OOZ/OOZSetup.h" -#include "HCZ/HCZSetup.h" -#include "MMZ/FarPlane.h" -#include "ERZ/ERZStart.h" // ----------------------------------------------------------------------------- diff --git a/src/hypermania/Objects/Player.h b/src/hypermania/mod/Global/Player.h similarity index 97% rename from src/hypermania/Objects/Player.h rename to src/hypermania/mod/Global/Player.h index 936af4b..48e6d6c 100644 --- a/src/hypermania/Objects/Player.h +++ b/src/hypermania/mod/Global/Player.h @@ -1,7 +1,4 @@ -#ifndef OBJ_PLAYER_H -#define OBJ_PLAYER_H - -#include "GameAPI/Game.h" +#pragma once extern ObjectPlayer* Player; @@ -100,4 +97,3 @@ void Player_ClearEnemiesOnScreen(EntityPlayer* player); void Player_HyperSonicDash(); int32 Player_GetIndexFromID(int32 ID); -#endif //! OBJ_PLAYER_H diff --git a/src/hypermania/Objects/SpecialRing.c b/src/hypermania/mod/Global/SpecialRing.c similarity index 99% rename from src/hypermania/Objects/SpecialRing.c rename to src/hypermania/mod/Global/SpecialRing.c index eb505e6..900dbc8 100644 --- a/src/hypermania/Objects/SpecialRing.c +++ b/src/hypermania/mod/Global/SpecialRing.c @@ -1,6 +1,4 @@ #include "SpecialRing.h" -#include "HPZ/HPZSetup.h" -#include "Mania/Global/Zone.h" // ----------------------------------------------------------------------------- diff --git a/src/hypermania/Objects/SpecialRing.h b/src/hypermania/mod/Global/SpecialRing.h similarity index 67% rename from src/hypermania/Objects/SpecialRing.h rename to src/hypermania/mod/Global/SpecialRing.h index ff70cd2..c2d881f 100644 --- a/src/hypermania/Objects/SpecialRing.h +++ b/src/hypermania/mod/Global/SpecialRing.h @@ -1,40 +1,10 @@ -#ifndef OBJ_SPECIALRING_H -#define OBJ_SPECIALRING_H - -#include "GameAPI/Game.h" +#pragma once // ============================================================================= // Definitions ----------------------------------------------------------------- // ============================================================================= -typedef struct { - RSDK_OBJECT - uint16 aniFrames; - Hitbox hitbox; - uint16 sfxSpecialRing; - uint16 sfxSpecialWarp; - uint16 modelIndex; - uint16 sceneIndex; -} ObjectSpecialRing; - -typedef struct { - RSDK_ENTITY - StateMachine(state); - int32 id; - int32 planeFilter; - int32 warpTimer; - int32 sparkleRadius; - Animator warpAnimator; - int32 angleZ; - int32 angleY; - bool32 enabled; - Matrix matTempRot; - Matrix matTransform; - Matrix matWorld; - Matrix matNormal; -} EntitySpecialRing; - extern ObjectSpecialRing* SpecialRing; // ============================================================================= @@ -59,5 +29,3 @@ void SpecialRing_Draw_OVERLOAD(); HOOK_STATE(SpecialRing_State_Idle, 1); \ HOOK_IMPORTED_STATE(SpecialRing_State_Flash, 1); \ MOD_REGISTER_OBJ_OVERLOAD(SpecialRing, NULL, NULL, NULL, SpecialRing_Draw_OVERLOAD, NULL, SpecialRing_StageLoad_OVERLOAD, NULL, NULL, NULL) - -#endif //! OBJ_SPECIALRING_H diff --git a/src/hypermania/Objects/HPZ/HPZEmerald.c b/src/hypermania/mod/LRZ/HPZEmerald.c similarity index 99% rename from src/hypermania/Objects/HPZ/HPZEmerald.c rename to src/hypermania/mod/LRZ/HPZEmerald.c index 778d0d4..5af60da 100644 --- a/src/hypermania/Objects/HPZ/HPZEmerald.c +++ b/src/hypermania/mod/LRZ/HPZEmerald.c @@ -1,6 +1,6 @@ #include "HPZEmerald.h" -ObjectHPZEmerald *HPZEmerald; +ObjectHPZEmerald* HPZEmerald; int32 counter; color SuperEmeraldPalette[57] = { diff --git a/src/hypermania/mod/LRZ/HPZEmerald.h b/src/hypermania/mod/LRZ/HPZEmerald.h new file mode 100644 index 0000000..dafa8ac --- /dev/null +++ b/src/hypermania/mod/LRZ/HPZEmerald.h @@ -0,0 +1,9 @@ +#pragma once + +extern ObjectHPZEmerald* HPZEmerald; + +// Overload Functions +void HPZEmerald_Update_Hook(void); +void HPZEmerald_Draw_Hook(void); +void HPZEmerald_Create_Hook(void* data); +void HPZEmerald_StageLoad_Hook(void); diff --git a/src/hypermania/Objects/PlaneSeeSaw.c b/src/hypermania/mod/MMZ/PlaneSeeSaw.c similarity index 98% rename from src/hypermania/Objects/PlaneSeeSaw.c rename to src/hypermania/mod/MMZ/PlaneSeeSaw.c index 93988cc..bb30ca8 100644 --- a/src/hypermania/Objects/PlaneSeeSaw.c +++ b/src/hypermania/mod/MMZ/PlaneSeeSaw.c @@ -1,5 +1,4 @@ #include "PlaneSeeSaw.h" -#include "SuperFlicky.h" ObjectPlaneSeeSaw* PlaneSeeSaw; diff --git a/src/hypermania/mod/MMZ/PlaneSeeSaw.h b/src/hypermania/mod/MMZ/PlaneSeeSaw.h new file mode 100644 index 0000000..f4ff27f --- /dev/null +++ b/src/hypermania/mod/MMZ/PlaneSeeSaw.h @@ -0,0 +1,11 @@ +#pragma once + +extern ObjectPlaneSeeSaw* PlaneSeeSaw; + +bool32 PlaneSeeSaw_State_Launch_HOOK(bool32 skippedState); +bool32 PlaneSeeSaw_PlayerState_ToBG_HOOK(bool32 skippedState); + +#define OBJ_PLANESEESAW_SETUP \ + HOOK_STATE(PlaneSeeSaw_State_Launch, 1); \ + HOOK_STATE(PlaneSeeSaw_PlayerState_ToBG, 0); \ + MOD_REGISTER_OBJ_OVERLOAD(PlaneSeeSaw, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL) diff --git a/src/hypermania/Objects/LevelSelect.c b/src/hypermania/mod/Menu/LevelSelect.c similarity index 100% rename from src/hypermania/Objects/LevelSelect.c rename to src/hypermania/mod/Menu/LevelSelect.c diff --git a/src/hypermania/mod/Menu/LevelSelect.h b/src/hypermania/mod/Menu/LevelSelect.h new file mode 100644 index 0000000..085aa80 --- /dev/null +++ b/src/hypermania/mod/Menu/LevelSelect.h @@ -0,0 +1,15 @@ +#pragma once + +extern ObjectLevelSelect* LevelSelect; + +// ============================================================================= + +// Functions ------------------------------------------------------------------- + +// ============================================================================= +void LevelSelect_StageLoad_OVERLOAD(); + +#define OBJ_LEVELSELECT_SETUP \ + MOD_REGISTER_OBJ_OVERLOAD(LevelSelect, NULL, NULL, NULL, NULL, NULL, LevelSelect_StageLoad_OVERLOAD, NULL, NULL, NULL) + +void LevelSelect_Cheat_AllEmeralds(); diff --git a/src/hypermania/Objects/UISaveSlot.c b/src/hypermania/mod/Menu/UISaveSlot.c similarity index 100% rename from src/hypermania/Objects/UISaveSlot.c rename to src/hypermania/mod/Menu/UISaveSlot.c diff --git a/src/hypermania/Objects/UISaveSlot.h b/src/hypermania/mod/Menu/UISaveSlot.h similarity index 55% rename from src/hypermania/Objects/UISaveSlot.h rename to src/hypermania/mod/Menu/UISaveSlot.h index a957cfa..fa5f36a 100644 --- a/src/hypermania/Objects/UISaveSlot.h +++ b/src/hypermania/mod/Menu/UISaveSlot.h @@ -1,74 +1,4 @@ -#ifndef OBJ_UISAVESLOT_H -#define OBJ_UISAVESLOT_H - -#include "GameAPI/Game.h" - -typedef enum { - UISAVESLOT_REGULAR, - UISAVESLOT_NOSAVE, -} UISaveSlotTypes; - -typedef struct { - RSDK_OBJECT - uint16 aniFrames; -} ObjectUISaveSlot; - -typedef struct { - MANIA_UI_ITEM_BASE - bool32 isNewSave; -#if MANIA_USE_PLUS - StateMachine(stateInput); -#endif - int32 listID; - int32 frameID; - int32 saveZoneID; - int32 saveLives; -#if MANIA_USE_PLUS - int32 saveContinues; -#endif - int32 saveEmeralds; -#if MANIA_USE_PLUS - uint8 saveEncorePlayer; - uint8 saveEncoreBuddy; - uint8 saveEncoreFriends[3]; -#endif - UISaveSlotTypes type; - int32 slotID; -#if MANIA_USE_PLUS - bool32 encoreMode; -#endif - bool32 currentlySelected; - int32 zoneIconSprX; - int32 textBounceOffset; - int32 buttonBounceOffset; - int32 textBouncePos; - int32 buttonBouncePos; - int32 fxRadius; -#if MANIA_USE_PLUS - void *fxRuby; - bool32 debugEncoreDraw; - uint8 dCharPoint; - uint8 dCharPartner; - uint8 dCharStock1; - uint8 dCharStock2; - uint8 dCharStock3; -#endif - Animator uiAnimator; - Animator playersAnimator; - Animator shadowsAnimator; - Animator livesAnimator; -#if MANIA_USE_PLUS - Animator continuesAnimator; -#endif - Animator emeraldsAnimator; - Animator zoneIconAnimator; - Animator zoneNameAnimator; - Animator fuzzAnimator; - Animator iconBGAnimator; - Animator saveStatusAnimator; - Animator numbersAnimator; - uint16 textFrames; -} EntityUISaveSlot; +#pragma once extern ObjectUISaveSlot *UISaveSlot; @@ -113,5 +43,3 @@ void UISaveSlot_StageLoad_OVERLOAD(); IMPORT_PUBLIC_FUNC(UISaveSlot_DrawPlayerInfo); \ IMPORT_PUBLIC_FUNC(UISaveSlot_State_Selected); \ MOD_REGISTER_OBJ_OVERLOAD(UISaveSlot, NULL, NULL, UISaveSlot_StaticUpdate_OVERLOAD, UISaveSlot_Draw_OVERLOAD, UISaveSlot_Create_OVERLOAD, UISaveSlot_StageLoad_OVERLOAD, NULL, NULL, NULL) - -#endif //! OBJ_UISAVESLOT_H diff --git a/src/hypermania/Objects/SpecialClear.c b/src/hypermania/mod/UFO/SpecialClear.c similarity index 100% rename from src/hypermania/Objects/SpecialClear.c rename to src/hypermania/mod/UFO/SpecialClear.c diff --git a/src/hypermania/Objects/SpecialClear.h b/src/hypermania/mod/UFO/SpecialClear.h similarity index 60% rename from src/hypermania/Objects/SpecialClear.h rename to src/hypermania/mod/UFO/SpecialClear.h index 463e373..ee70f0c 100644 --- a/src/hypermania/Objects/SpecialClear.h +++ b/src/hypermania/mod/UFO/SpecialClear.h @@ -1,91 +1,10 @@ -#ifndef OBJ_SPECIALCLEAR_H -#define OBJ_SPECIALCLEAR_H - -#include "GameAPI/Game.h" +#pragma once // ============================================================================= // Definitions ----------------------------------------------------------------- // ============================================================================= -typedef enum { - SC_MSG_SPECIALCLEAR, - SC_MSG_GOTEMERALD, - SC_MSG_ALLEMERALDS, - SC_MSG_SUPER, -} SpecialClearTypes; - -typedef enum { - SC_ANI_SONIC, - SC_ANI_TAILS, - SC_ANI_KNUX, -#if MANIA_USE_PLUS - SC_ANI_MIGHTY, - SC_ANI_RAY, -#endif - SC_ANI_BONUS, - SC_ANI_NUMBERS, - SC_ANI_EMERALDS, -#if MANIA_USE_PLUS - SC_ANI_CONTINUE, -#endif -} SpecialClearAniIDs; - -typedef struct { - RSDK_OBJECT - uint16 aniFrames; -#if !MANIA_USE_PLUS - uint16 continueFrames; -#endif - uint16 sfxScoreAdd; - uint16 sfxScoreTotal; - uint16 sfxEvent; - uint16 sfxSpecialWarp; - uint16 sfxContinue; - uint16 sfxEmerald; -} ObjectSpecialClear; - -typedef struct { - RSDK_ENTITY - StateMachine(state); - bool32 isBSS; - int32 messageType; - int32 timer; - bool32 showFade; - bool32 continueIconVisible; - bool32 hasContinues; - int32 fillColor; - int32 score; - int32 score1UP; - int32 lives; - int32 ringBonus; - int32 perfectBonus; - int32 machBonus; - Vector2 messagePos1; - Vector2 messagePos2; - Vector2 scoreBonusPos; - Vector2 ringBonusPos; - Vector2 perfectBonusPos; - Vector2 machBonusPos; - Vector2 continuePos; - int32 emeraldPositions[7]; - int32 emeraldSpeeds[7]; - int32 unused1; - int32 unused2; - int32 unused3; - int32 unused4; - int32 unused5; - int32 unused6; - int32 unused7; - int32 unused8; - bool32 saveInProgress; - Animator playerNameAnimator; - Animator bonusAnimator; - Animator numbersAnimator; - Animator emeraldsAnimator; - Animator continueAnimator; -} EntitySpecialClear; - extern ObjectSpecialClear *SpecialClear; typedef struct { @@ -145,5 +64,3 @@ void SpecialClear_State_ShowHyperMessage(); HOOK_STATE(SpecialClear_State_ShowTotalScore_Continues, 1); \ HOOK_STATE(SpecialClear_State_ShowTotalScore_NoContinues, 1); \ MOD_REGISTER_OBJ_OVERLOAD(SpecialClear, SpecialClear_Update_OVERLOAD, NULL, NULL, SpecialClear_Draw_OVERLOAD, SpecialClear_Create_OVERLOAD, SpecialClear_StageLoad_OVERLOAD, NULL, NULL, NULL) - -#endif //! OBJ_SPECIALCLEAR_H diff --git a/src/hypermania/Objects/UFO_Player.c b/src/hypermania/mod/UFO/UFO_Player.c similarity index 100% rename from src/hypermania/Objects/UFO_Player.c rename to src/hypermania/mod/UFO/UFO_Player.c diff --git a/src/hypermania/mod/UFO/UFO_Player.h b/src/hypermania/mod/UFO/UFO_Player.h new file mode 100644 index 0000000..1434e4a --- /dev/null +++ b/src/hypermania/mod/UFO/UFO_Player.h @@ -0,0 +1,9 @@ +#pragma once + +extern ObjectUFO_Player *UFO_Player; + +bool32 UFO_Player_State_UFOCaught_Released_HOOK(bool32); + +#define OBJ_UFO_PLAYER_SETUP \ + HOOK_STATE(UFO_Player_State_UFOCaught_Released, 1); \ + MOD_REGISTER_OBJECT_HOOK(UFO_Player) diff --git a/src/hypermania/Objects/UFO_Setup.c b/src/hypermania/mod/UFO/UFO_Setup.c similarity index 95% rename from src/hypermania/Objects/UFO_Setup.c rename to src/hypermania/mod/UFO/UFO_Setup.c index aca5a27..e938a80 100644 --- a/src/hypermania/Objects/UFO_Setup.c +++ b/src/hypermania/mod/UFO/UFO_Setup.c @@ -1,7 +1,4 @@ #include "UFO_Setup.h" -#include "SpecialClear.h" -#include "HPZ/HPZIntro.h" - ObjectUFO_Setup *UFO_Setup; void (*UFO_Setup_State_FinishFadeout)(); diff --git a/src/hypermania/mod/UFO/UFO_Setup.h b/src/hypermania/mod/UFO/UFO_Setup.h new file mode 100644 index 0000000..ed9d70d --- /dev/null +++ b/src/hypermania/mod/UFO/UFO_Setup.h @@ -0,0 +1,28 @@ +#pragma once + +extern ObjectUFO_Setup *UFO_Setup; + +typedef struct { + int32 timedOut; + int32 machLevel; + int32 scoreBonus; + int32 rings; + int32 specialStageID; +} UFO_HPZbuffer_t; + +extern UFO_HPZbuffer_t UFO_HPZbuffer; + +bool32 UFO_Setup_State_FinishFadeout_HOOK(bool32); + +extern void (*UFO_Setup_State_FinishFadeout)(); +extern void (*UFO_Setup_Finish_Win)(); + +void SetupHPZResults(void* data); + +// lol +#define OBJ_UFO_SETUP_SETUP \ + Mod.AddModCallback(MODCB_ONUPDATE, SetupHPZResults); \ + IMPORT_PUBLIC_FUNC(UFO_Setup_State_FinishFadeout); \ + IMPORT_PUBLIC_FUNC(UFO_Setup_Finish_Win); \ + HOOK_IMPORTED_STATE(UFO_Setup_State_FinishFadeout, 1); \ + MOD_REGISTER_OBJECT_HOOK(UFO_Setup) diff --git a/src/hypermania/new/All.h b/src/hypermania/new/All.h new file mode 100644 index 0000000..1e05080 --- /dev/null +++ b/src/hypermania/new/All.h @@ -0,0 +1,8 @@ +#pragma once + +#include "Global/HyperStars.h" +#include "Global/JetGlideEffect.h" +#include "Global/SuperFlicky.h" +#include "HPZ/HPZBeam.h" +#include "HPZ/HPZIntro.h" +#include "HPZ/HPZSetup.h" \ No newline at end of file diff --git a/src/hypermania/Objects/HyperStars.c b/src/hypermania/new/Global/HyperStars.c similarity index 98% rename from src/hypermania/Objects/HyperStars.c rename to src/hypermania/new/Global/HyperStars.c index 1c5a6c3..1e3ae34 100644 --- a/src/hypermania/Objects/HyperStars.c +++ b/src/hypermania/new/Global/HyperStars.c @@ -1,6 +1,4 @@ #include "HyperStars.h" -#include "Player.h" -#include "Mania/Global/Zone.h" ObjectHyperStars* HyperStars; diff --git a/src/hypermania/Objects/HyperStars.h b/src/hypermania/new/Global/HyperStars.h similarity index 84% rename from src/hypermania/Objects/HyperStars.h rename to src/hypermania/new/Global/HyperStars.h index addc9e1..a539792 100644 --- a/src/hypermania/Objects/HyperStars.h +++ b/src/hypermania/new/Global/HyperStars.h @@ -1,7 +1,4 @@ -#ifndef OBJ_HYPERSTARS_H -#define OBJ_HYPERSTARS_H - -#include "GameAPI/Game.h" +#pragma once // Constants #define HYPERSTARS_COUNT (4) @@ -35,6 +32,4 @@ void HyperStars_Create(void* data); void HyperStars_StageLoad(void); void HyperStars_EditorDraw(void); void HyperStars_EditorLoad(void); -void HyperStars_Serialize(void); - -#endif //! OBJ_HYPERSTARS_H \ No newline at end of file +void HyperStars_Serialize(void); \ No newline at end of file diff --git a/src/hypermania/Objects/JetGlideEffect.c b/src/hypermania/new/Global/JetGlideEffect.c similarity index 100% rename from src/hypermania/Objects/JetGlideEffect.c rename to src/hypermania/new/Global/JetGlideEffect.c diff --git a/src/hypermania/Objects/JetGlideEffect.h b/src/hypermania/new/Global/JetGlideEffect.h similarity index 81% rename from src/hypermania/Objects/JetGlideEffect.h rename to src/hypermania/new/Global/JetGlideEffect.h index 5888685..b0c0fa7 100644 --- a/src/hypermania/Objects/JetGlideEffect.h +++ b/src/hypermania/new/Global/JetGlideEffect.h @@ -1,7 +1,4 @@ -#ifndef OBJ_JETGLIDEEFFECT_H -#define OBJ_JETGLIDEEFFECT_H - -#include "GameAPI/Game.h" +#pragma once // Object Class typedef struct { @@ -33,6 +30,4 @@ void JetGlideEffect_Create(void* data); void JetGlideEffect_StageLoad(); void JetGlideEffect_EditorDraw(); void JetGlideEffect_EditorLoad(); -void JetGlideEffect_Serialize(); - -#endif //! OBJ_JETGLIDEEFFECT_H \ No newline at end of file +void JetGlideEffect_Serialize(); \ No newline at end of file diff --git a/src/hypermania/Objects/SuperFlicky.c b/src/hypermania/new/Global/SuperFlicky.c similarity index 98% rename from src/hypermania/Objects/SuperFlicky.c rename to src/hypermania/new/Global/SuperFlicky.c index 6cf8fa5..470dcad 100644 --- a/src/hypermania/Objects/SuperFlicky.c +++ b/src/hypermania/new/Global/SuperFlicky.c @@ -1,12 +1,4 @@ #include "SuperFlicky.h" -#include "Debris.h" -#include "Player.h" -#include "Mania/Global/Zone.h" - -#include "CPZ/CPZSetup.h" -#include "OOZ/OOZSetup.h" -#include "HCZ/HCZSetup.h" -#include "MMZ/FarPlane.h" ObjectSuperFlicky* SuperFlicky; diff --git a/src/hypermania/Objects/SuperFlicky.h b/src/hypermania/new/Global/SuperFlicky.h similarity index 91% rename from src/hypermania/Objects/SuperFlicky.h rename to src/hypermania/new/Global/SuperFlicky.h index 5379f34..9768253 100644 --- a/src/hypermania/Objects/SuperFlicky.h +++ b/src/hypermania/new/Global/SuperFlicky.h @@ -1,7 +1,4 @@ -#ifndef OBJ_SUPERFLICKY_H -#define OBJ_SUPERFLICKY_H - -#include "GameAPI/Game.h" +#pragma once // Constants #define SUPERFLICKY_COUNT (4) @@ -49,5 +46,3 @@ void SuperFlicky_BlendSuperPalette(int32 bankID); // Reserved Slot extern int16 SuperFlickySlot; - -#endif //! OBJ_SUPERFLICKY_H \ No newline at end of file diff --git a/src/hypermania/Objects/HPZ/HPZBeam.c b/src/hypermania/new/HPZ/HPZBeam.c similarity index 98% rename from src/hypermania/Objects/HPZ/HPZBeam.c rename to src/hypermania/new/HPZ/HPZBeam.c index 0e0c490..eca4278 100644 --- a/src/hypermania/Objects/HPZ/HPZBeam.c +++ b/src/hypermania/new/HPZ/HPZBeam.c @@ -1,6 +1,4 @@ #include "HPZBeam.h" -#include "ModFunctions.h" -//#include "Mania/Zone.h" ObjectHPZBeam* HPZBeam; diff --git a/src/hypermania/Objects/HPZ/HPZBeam.h b/src/hypermania/new/HPZ/HPZBeam.h similarity index 83% rename from src/hypermania/Objects/HPZ/HPZBeam.h rename to src/hypermania/new/HPZ/HPZBeam.h index 6a64e1a..89e4401 100644 --- a/src/hypermania/Objects/HPZ/HPZBeam.h +++ b/src/hypermania/new/HPZ/HPZBeam.h @@ -1,7 +1,4 @@ -#ifndef OBJ_HPZBEAM_H -#define OBJ_HPZBEAM_H - -#include "GameAPI/Game.h" +#pragma once // Object Class typedef struct { @@ -34,6 +31,4 @@ void HPZBeam_Create(void *data); void HPZBeam_StageLoad(void); void HPZBeam_EditorDraw(void); void HPZBeam_EditorLoad(void); -void HPZBeam_Serialize(void); - -#endif //! OBJ_HPZBEAM_H +void HPZBeam_Serialize(void); \ No newline at end of file diff --git a/src/hypermania/Objects/HPZ/HPZIntro.c b/src/hypermania/new/HPZ/HPZIntro.c similarity index 99% rename from src/hypermania/Objects/HPZ/HPZIntro.c rename to src/hypermania/new/HPZ/HPZIntro.c index ff04d5d..35cc1fb 100644 --- a/src/hypermania/Objects/HPZ/HPZIntro.c +++ b/src/hypermania/new/HPZ/HPZIntro.c @@ -1,6 +1,4 @@ #include "HPZIntro.h" -#include "HPZEmerald.h" -#include "HPZBeam.h" ObjectHPZIntro* HPZIntro; diff --git a/src/hypermania/Objects/HPZ/HPZIntro.h b/src/hypermania/new/HPZ/HPZIntro.h similarity index 87% rename from src/hypermania/Objects/HPZ/HPZIntro.h rename to src/hypermania/new/HPZ/HPZIntro.h index 60b1ce0..b5c7761 100644 --- a/src/hypermania/Objects/HPZ/HPZIntro.h +++ b/src/hypermania/new/HPZ/HPZIntro.h @@ -1,7 +1,4 @@ -#ifndef OBJ_HPZINTRO_H -#define OBJ_HPZINTRO_H - -#include "GameAPI/Game.h" +#pragma once enum HPZIntroDrawFlags { HPZI_NONE = 0x00, @@ -54,6 +51,4 @@ void HPZIntro_Serialize(); void HPZIntro_State_TeleportPlayer(); void HPZIntro_State_RaiseEmeralds(); void HPZIntro_State_EmeraldsFlyOff(); -void HPZIntro_State_ActivateSuperEmeralds(); - -#endif //! OBJ_HPZINTRO_H +void HPZIntro_State_ActivateSuperEmeralds(); \ No newline at end of file diff --git a/src/hypermania/Objects/HPZ/HPZSetup.c b/src/hypermania/new/HPZ/HPZSetup.c similarity index 97% rename from src/hypermania/Objects/HPZ/HPZSetup.c rename to src/hypermania/new/HPZ/HPZSetup.c index 14d42df..85d1fcc 100644 --- a/src/hypermania/Objects/HPZ/HPZSetup.c +++ b/src/hypermania/new/HPZ/HPZSetup.c @@ -1,5 +1,4 @@ #include "HPZSetup.h" -#include "HPZIntro.h" ObjectHPZSetup* HPZSetup; diff --git a/src/hypermania/Objects/HPZ/HPZSetup.h b/src/hypermania/new/HPZ/HPZSetup.h similarity index 82% rename from src/hypermania/Objects/HPZ/HPZSetup.h rename to src/hypermania/new/HPZ/HPZSetup.h index 1d3b8cd..dd52a1e 100644 --- a/src/hypermania/Objects/HPZ/HPZSetup.h +++ b/src/hypermania/new/HPZ/HPZSetup.h @@ -1,7 +1,4 @@ -#ifndef OBJ_HPZSETUP_H -#define OBJ_HPZSETUP_H - -#include "GameAPI/Game.h" +#pragma once // Object Class typedef struct { @@ -26,5 +23,3 @@ void HPZSetup_StageLoad(void); void HPZSetup_EditorDraw(void); void HPZSetup_EditorLoad(void); void HPZSetup_Serialize(void); - -#endif //! OBJ_HPZSETUP_H