Skip to content
This repository has been archived by the owner on Apr 29, 2020. It is now read-only.

GetCurrentContinent: Check if zone is middle lands ship #6375

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

pyromaniackeca
Copy link

  • Not sure if any zones are still missing
  • Not sure if any added zones should be omitted

P.S.
Any comments on approach and style will be greatly appreciated as I haven't written any serious cpp since university.

@TeoTwawki
Copy link
Member

the only reason they aren't considered part of the continent is they don't have a region so the switch hits "REGION_UNKNOWN" which is the default. Anything that is that region is considered not middle lands. from the look of it currently all zones with a region are being counted as middle lands, which is wrong..

return REGION_UNKNOWN;

        case ZONE_CEIZAK_BATTLEGROUNDS:
        case ZONE_FORET_DE_HENNETIEL:
        case ZONE_SIH_GATES:
        case ZONE_MOH_GATES:
        case ZONE_CIRDAS_CAVERNS:
        case ZONE_CIRDAS_CAVERNS_U:
        case ZONE_YAHSE_HUNTING_GROUNDS:
        case ZONE_MORIMAR_BASALT_FIELDS:
            return REGION_EAST_ULBUKA;
    }
    return REGION_UNKNOWN;
CONTINENTTYPE GetCurrentContinent(uint16 ZoneID)
{
    return GetCurrentRegion(ZoneID) != REGION_UNKNOWN ? THE_MIDDLE_LANDS : OTHER_AREAS;
}

@TeoTwawki
Copy link
Member

I think we should fix our region debacle and then give these a region that counts as middle lands, instead of making a new function to bypass that system

@zynjec
Copy link
Contributor

zynjec commented Jan 16, 2020

Before we go any further, could we have some proof that they're subject to signet effects on retail?

@nfaletra
Copy link
Member

Confirmed signet effects work on ferry ships on retail.

@pyromaniackeca
Copy link
Author

The PR was opened as a response to this: EdenServer/community#2408

I am still unfamiliar with the bigger context of this change, so am open to suggestions on how to improve this or any discussions I could read about the region debacle @TeoTwawki mentioned to get a better understanding of the issue.

@TeoTwawki
Copy link
Member

TeoTwawki commented Jan 23, 2020

The reason these aren’t counting is the function that checks if its “the middle land” doesn't do what its name implied - its just checking the region is “unknown” or not and since these zones were never assigned a region and the defaultis unknown, they are and fail that check. Additionally a ton of zones that are NOT in middle lands are counted as if they are.

Better?

The isMiddleLands crap needs to go and continent ids need to move in

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants