Skip to content

Quest names refactor

Player Name requested to merge PlayerName/2009scape:bullshit into master

Note: this MR is 99% syntax, except for the Frem Trials bit; see below.

What has been done in this MR?

  • Moved all quest names into a separate class
  • Refactored all code interfacing with quests to refer to quests via this class
  • Fixed incorrect requirements checking for The Fremennik Trials completion due to some pieces of the code checking "The Fremennik Trials" and others checking "Fremennik Trials" - now they all check QuestNames.THE_FREMENNIK_TRIALS. Fixes the ability to use the shooting star ring to teleport to a Miscellania star.
  • A couple of quests were defining their own name constant in a companion object; this was replaced with the new enum value and inlined to make the code compile
  • Removed a bunch of unused imports; IDEA did this when I was refactoring all the quests and it doesn't seem like a negative so I've kept it

What should testers check?

Frem Trials is quest 64. Specifically for this quest:

  • The star ring restriction code previously used the correct name and was hence not working; now it should be. So ::submit until you drop a star at misc and confirm that you can tele there if you have the quest complete.
  • Other things that required this quest previously used the incorrect name and have now been fixed with a big find-replace; test this too. For my local testing, I tested that Yrsa 1301 gives her dialogue of "Welcome to my clothes shop. I can change your shoes, or I've got a fine selection of clothes for sale." when I have the quest complete, and doesn't when I don't.
  • Check that you can still start and finish the quest (no need to bother with everything in between).

In general, i.e. for any random quest you like (testing just one random quest should suffice, since every quest uses the same set of names now):

  • Test that pre-reqs checks, quest-completion checks, quest-stage checks, starting quests, completing quests, and advancing quest stages still work.

Also confirm that I didn't find-replace any strings that shouldn't have been find-replaced. A particular example that comes to mind is a quest like Shilo Village: the "Shilo Village" text string is not only used to talk about the quest (in which case I should and will have replaced it), but is also used as a normal destination for the Brimhaven cart guy. Check (by reviewing the code, not the game behavior!) that I didn't erroneously change such non-quest references to QuestNames.SHILO_VILLAGE for example.

  • I have tested these changes thoroughly.
  • I used the relevant Zaros tool for any JSON edits where possible, and have attached screenshots of any changes.
Edited by Player Name

Merge request reports

Loading