EasyRPG / TestGame

RPG Maker 2000/2003 test suite game project
https://easyrpg.org/play/
GNU General Public License v3.0
23 stars 12 forks source link

Fix some issues with the Test Game and add some missing tests #40

Closed Mimigris closed 1 year ago

Mimigris commented 1 year ago

This pull request was made to fix some issues present in the 2k Test Game, in addition to adding some missing tests to better test the differences between EasyRPG Player and the RPG_RT. Due to the addition and edition of some text lines, this pull request will impact a bit on Pull Request # 37 of the Test Game, but it should not cause an issue ultimately since the lines can easily be updated thanks to lcftrans.

Content changed in the RPG 2000 Test Game

Listed the following tests as working entirely:

Listed the following tests as working except the following issues:

Content changed in the RPG 2003 Test Game

Issues found while testing this:

The following commands called in battle in 2k3 through a Common Event don't work correctly:


Issues that are extremely minor/only useful if you want to be 1:1 with the RPG_RT:

Ghabry commented 1 year ago

Oh wow. Thanks for this. I will slowly fight through the list 😅

Ghabry commented 1 year ago

@Mimigris

Issues I found:

I'm honestly a bit overwhelmed by your work and the issues you found. Except for the panorama one they do not look like regressions or game breaking so is likely fine to omit them from 0.8.0.


Sorry for generating even more work but can you create issues in Player for them?

When striked through no issue needed

Teleport target fix:

diff --git a/src/game_targets.cpp b/src/game_targets.cpp
index da5b5cefd..13307625d 100644
--- a/src/game_targets.cpp
+++ b/src/game_targets.cpp
@@ -40,6 +40,9 @@ void Game_Targets::AddTeleportTarget(int map_id, int x, int y, bool switch_on, i
    iter->map_y = y;
    iter->switch_on = switch_on;
    iter->switch_id = switch_id;
+
+   // Teleports must be sorted by map id.
+   std::sort(teleports.begin(), teleports.end(), [](auto& l, auto& r) { return l.map_id < r.map_id; });
 }

 void Game_Targets::RemoveTeleportTarget(int map_id) {