Author Topic: Default Destination Checker  (Read 271 times)

0 Members and 1 Guest are viewing this topic.

llamazing

  • Full Member
  • ***
  • Posts: 219
    • View Profile
Default Destination Checker
« on: January 27, 2021, 01:57:34 AM »
So apparently if a map has no default destination designated, then the first one listed in the map data file becomes the default. This caused a bug in Ocean's Heart where if someone saved the game on a particular map then they would spawn at a destination that was blocked by a locked door, and the hero would be stuck. The solution is to always designate one of the map's destinations as the default whenever there is more than one (choosing one that won't be blocked by an obstruction, of course).

I wrote a script to scan all the map data files, reporting any found that have more than one destination without a default destination specified.

Usage:
require"scripts/default_destination_checker"()

The list of maps found is printed to the console.

PeterB
  • Newbie
  • *
  • Posts: 35
    • View Profile
Re: Default Destination Checker
« Reply #1 on: January 29, 2021, 08:29:17 PM »
Great catch llamazing, thanks for posting this.