Use ReadOnlySpan for nest location fetch

skips allocating that big byte[][] entirely
No more static byte[][] references in PKHeX.Core !
This commit is contained in:
Kurt
2024-06-29 10:41:11 -05:00
parent 496c66bd46
commit a84e59c0fe
2 changed files with 204 additions and 202 deletions

View File

@@ -7,207 +7,209 @@ namespace PKHeX.Core;
internal static class Encounters8Nest
{
internal static readonly byte[][] NestLocations =
[
[144, 134, 122], // 000 : Stony Wilderness, South Lake Miloch, Rolling Fields
[144, 126], // 001 : Stony Wilderness, Watchtower Ruins
[144, 122], // 002 : Stony Wilderness, Rolling Fields
[142, 124, 122], // 003 : Bridge Field, Dappled Grove, Rolling Fields
[142, 134], // 004 : Bridge Field, South Lake Miloch
[144, 126], // 005 : Stony Wilderness, Watchtower Ruins
[128, 130], // 006 : East Lake Axewell, West Lake Axewell
[154, 142, 134], // 007 : Lake of Outrage, Bridge Field, South Lake Miloch
[146, 130], // 008 : Dusty Bowl, West Lake Axewell
[146, 138], // 009 : Dusty Bowl, North Lake Miloch
[146, 136], // 010 : Dusty Bowl, Giants Seat
[150, 144, 136], // 011 : Hammerlocke Hills, Stony Wilderness, Giants Seat
[142], // 012 : Bridge Field
[150, 144, 140], // 013 : Hammerlocke Hills, Stony Wilderness, Motostoke Riverbank
[146, 136], // 014 : Dusty Bowl, Giants Seat
[142, 122], // 015 : Bridge Field, Rolling Fields
[146], // 016 : Dusty Bowl
[154, 152, 144], // 017 : Lake of Outrage, Giants Cap, Stony Wilderness
[150, 144], // 018 : Hammerlocke Hills, Stony Wilderness
[146], // 019 : Dusty Bowl
[146], // 020 : Dusty Bowl
[144], // 021 : Stony Wilderness
[150, 152], // 022 : Hammerlocke Hills, Giants Cap
[152, 140], // 023 : Giants Cap, Motostoke Riverbank
[154, 148], // 024 : Lake of Outrage, Giants Mirror
[124], // 025 : Dappled Grove
[148, 144, 142], // 026 : Giants Mirror, Stony Wilderness, Bridge Field
[148, 124, 146], // 027 : Giants Mirror, Dappled Grove AND Dusty Bowl (Giant's Mirror load-line overlap)
[138, 128], // 028 : North Lake Miloch, East Lake Axewell
[150, 152, 140], // 029 : Hammerlocke Hills, Giants Cap, Motostoke Riverbank
[128, 122], // 030 : East Lake Axewell, Rolling Fields
[150, 152], // 031 : Hammerlocke Hills, Giants Cap
[150, 122], // 032 : Hammerlocke Hills, Rolling Fields
[154, 142], // 033 : Lake of Outrage, Bridge Field
[144, 130], // 034 : Stony Wilderness, West Lake Axewell
[142, 146, 148], // 035 : Bridge Field, Dusty Bowl, Giants Mirror
[122], // 036 : Rolling Fields
[132], // 037 : Axew's Eye
[128, 122], // 038 : East Lake Axewell, Rolling Fields
[144, 142, 140], // 039 : Stony Wilderness, Bridge Field, Motostoke Riverbank
[134, 138], // 040 : South Lake Miloch, North Lake Miloch
[148, 130], // 041 : Giants Mirror, West Lake Axewell
[148, 144, 134, 146], // 042 : Giants Mirror, Stony Wilderness, South Lake Miloch AND Dusty Bowl (Giant's Mirror load-line overlap)
[154, 142, 128, 130], // 043 : Lake of Outrage, Bridge Field, East Lake Axewell, West Lake Axewell
[150, 136], // 044 : Hammerlocke Hills, Giants Seat
[142, 134, 122], // 045 : Bridge Field, South Lake Miloch, Rolling Fields
[126], // 046 : Watchtower Ruins
[146, 138, 122, 134], // 047 : Dusty Bowl, North Lake Miloch, Rolling Fields, South Lake Miloch
[146, 136], // 048 : Dusty Bowl, Giants Seat
[144, 140, 126], // 049 : Stony Wilderness, Motostoke Riverbank, Watchtower Ruins
[144, 136, 122], // 050 : Stony Wilderness, Giants Seat, Rolling Fields
[146, 142, 122], // 051 : Dusty Bowl, Bridge Field, Rolling Fields
[150], // 052 : Hammerlocke Hills
[146, 144], // 053 : Dusty Bowl, Stony Wilderness
[152, 146, 144], // 054 : Giants Cap, Dusty Bowl, Stony Wilderness
[154, 140], // 055 : Lake of Outrage, Motostoke Riverbank
[150], // 056 : Hammerlocke Hills
[124], // 057 : Dappled Grove
[144, 142, 124], // 058 : Stony Wilderness, Bridge Field, Dappled Grove
[152, 140, 138], // 059 : Giants Cap, Motostoke Riverbank, North Lake Miloch
[150, 128], // 060 : Hammerlocke Hills, East Lake Axewell
[150, 122], // 061 : Hammerlocke Hills, Rolling Fields
[144, 142, 130], // 062 : Stony Wilderness, Bridge Field, West Lake Axewell
[132, 122], // 063 : Axew's Eye, Rolling Fields
[142, 140, 128, 122], // 064 : Bridge Field, Motostoke Riverbank, East Lake Axewell, Rolling Fields
[144], // 065 : Stony Wilderness
[148], // 066 : Giants Mirror
[150], // 067 : Hammerlocke Hills
[148], // 068 : Giants Mirror
[148], // 069 : Giants Mirror
[152], // 070 : Giants Cap
[148], // 071 : Giants Mirror
[150], // 072 : Hammerlocke Hills
[154], // 073 : Lake of Outrage
[146, 130], // 074 : Dusty Bowl, West Lake Axewell
[138, 134], // 075 : North Lake Miloch, South Lake Miloch
[154], // 076 : Lake of Outrage
[152], // 077 : Giants Cap
[124], // 078 : Dappled Grove
[144], // 079 : Stony Wilderness
[144], // 080 : Stony Wilderness
[142], // 081 : Bridge Field
[136], // 082 : Giants Seat
[136], // 083 : Giants Seat
[144], // 084 : Stony Wilderness
[128], // 085 : East Lake Axewell
[142], // 086 : Bridge Field
[146], // 087 : Dusty Bowl
[152], // 088 : Giants Cap
[122], // 089 : Rolling Fields
[130, 134], // 090 : West Lake Axewell, South Lake Miloch
[142, 124], // 091 : Bridge Field, Dappled Grove
[146], // 092 : Dusty Bowl
[], // 093 : None
[], // 094 : None
[], // 095 : None
[], // 096 : None
[], // 097 : None
[164, 166, 188, 190], // 098 : Fields of Honor, Soothing Wetlands, Stepping-Stone Sea, Insular Sea
[164, 166, 188, 190], // 099 : Fields of Honor, Soothing Wetlands, Stepping-Stone Sea, Insular Sea
[166, 176, 180], // 100 : Soothing Wetlands, Courageous Cavern, Training Lowlands
[166, 176, 180], // 101 : Soothing Wetlands, Courageous Cavern, Training Lowlands
[170, 176, 184, 188], // 102 : Challenge Beach, Courageous Cavern, Potbottom Desert, Stepping-Stone Sea
[170, 176, 188], // 103 : Challenge Beach, Courageous Cavern, Stepping-Stone Sea
[164, 168, 170, 192], // 104 : Fields of Honor, Forest of Focus, Challenge Beach, Honeycalm Sea
[164, 168, 170, 192], // 105 : Fields of Honor, Forest of Focus, Challenge Beach, Honeycalm Sea
[174, 178, 186, 188], // 106 : Challenge Road, Loop Lagoon, Workout Sea, Stepping-Stone Sea
[174, 178, 186, 188], // 107 : Challenge Road, Loop Lagoon, Workout Sea, Stepping-Stone Sea
[164, 168, 180, 186], // 108 : Fields of Honor, Forest of Focus, Training Lowlands, Workout Sea
[164, 168, 186], // 109 : Fields of Honor, Forest of Focus, Workout Sea
[164, 166, 180, 190], // 110 : Fields of Honor, Soothing Wetlands, Training Lowlands, Insular Sea
[164, 166, 180, 190], // 111 : Fields of Honor, Soothing Wetlands, Training Lowlands, Insular Sea
[164, 170, 178, 184], // 112 : Fields of Honor, Challenge Beach, Loop Lagoon, Potbottom Desert
[164, 170, 178, 184], // 113 : Fields of Honor, Challenge Beach, Loop Lagoon, Potbottom Desert
[164, 180, 184], // 114 : Fields of Honor, Training Lowlands, Potbottom Desert
[164, 180, 184], // 115 : Fields of Honor, Training Lowlands, Potbottom Desert
[166, 170, 180, 188], // 116 : Soothing Wetlands, Challenge Beach, Training Lowlands, Stepping-Stone Sea
[166, 170, 180, 188], // 117 : Soothing Wetlands, Challenge Beach, Training Lowlands, Stepping-Stone Sea
[166, 168, 180, 188], // 118 : Soothing Wetlands, Forest of Focus, Training Lowlands, Stepping-Stone Sea
[166, 168, 180, 188], // 119 : Soothing Wetlands, Forest of Focus, Training Lowlands, Stepping-Stone Sea
[166, 174, 186, 192], // 120 : Soothing Wetlands, Challenge Road, Workout Sea, Honeycalm Sea
[166, 174, 186, 192], // 121 : Soothing Wetlands, Challenge Road, Workout Sea, Honeycalm Sea
[164, 170, 174, 192], // 122 : Fields of Honor, Challenge Beach, Challenge Road, Honeycalm Sea
[164, 170, 174, 192], // 123 : Fields of Honor, Challenge Beach, Challenge Road, Honeycalm Sea
[164, 166, 168, 190], // 124 : Fields of Honor, Soothing Wetlands, Forest of Focus, Insular Sea
[164, 166, 168, 190], // 125 : Fields of Honor, Soothing Wetlands, Forest of Focus, Insular Sea
[170, 176, 188], // 126 : Challenge Beach, Courageous Cavern, Stepping-Stone Sea
[170, 176, 188], // 127 : Challenge Beach, Courageous Cavern, Stepping-Stone Sea
[172, 176, 188], // 128 : Brawlers' Cave, Courageous Cavern, Stepping-Stone Sea
[172, 176, 188], // 129 : Brawlers' Cave, Courageous Cavern, Stepping-Stone Sea
[178, 186, 192], // 130 : Loop Lagoon, Workout Sea, Honeycalm Sea
[186, 192], // 131 : Workout Sea, Honeycalm Sea
[164, 166, 176], // 132 : Fields of Honor, Soothing Wetlands, Courageous Cavern
[164, 166, 176], // 133 : Fields of Honor, Soothing Wetlands, Courageous Cavern
[166, 168, 170, 176], // 134 : Soothing Wetlands, Forest of Focus, Challenge Beach, Courageous Cavern
[166, 168, 170], // 135 : Soothing Wetlands, Forest of Focus, Challenge Beach
[164, 170, 178, 190], // 136 : Fields of Honor, Challenge Beach, Loop Lagoon, Insular Sea
[164, 170, 178], // 137 : Fields of Honor, Challenge Beach, Loop Lagoon
[186, 188, 190, 192], // 138 : Workout Sea, Stepping-Stone Sea, Insular Sea, Honeycalm Sea
[186, 188, 190, 192], // 139 : Workout Sea, Stepping-Stone Sea, Insular Sea, Honeycalm Sea
[], // 140 : None
[], // 141 : None
[194], // 142 : Honeycalm Island
[194], // 143 : Honeycalm Island
[168, 180], // 144 : Forest of Focus, Training Lowlands
[186, 188], // 145 : Workout Sea, Stepping-Stone Sea
[190], // 146 : Insular Sea
[176], // 147 : Courageous Cavern
[180], // 148 : Training Lowlands
[184], // 149 : Potbottom Desert
[178], // 150 : Loop Lagoon
[186], // 151 : Workout Sea
[186], // 152 : Workout Sea
[168, 180], // 153 : Forest of Focus, Training Lowlands
[186, 188], // 154 : Workout Sea, Stepping-Stone Sea
[174], // 155 : Challenge Road
[174], // 156 : Challenge Road
internal static ReadOnlySpan<byte> GetNestLocations(byte loc) => loc switch
{
000 => [144, 134, 122], // 000 : Stony Wilderness, South Lake Miloch, Rolling Fields
001 => [144, 126], // 001 : Stony Wilderness, Watchtower Ruins
002 => [144, 122], // 002 : Stony Wilderness, Rolling Fields
003 => [142, 124, 122], // 003 : Bridge Field, Dappled Grove, Rolling Fields
004 => [142, 134], // 004 : Bridge Field, South Lake Miloch
005 => [144, 126], // 005 : Stony Wilderness, Watchtower Ruins
006 => [128, 130], // 006 : East Lake Axewell, West Lake Axewell
007 => [154, 142, 134], // 007 : Lake of Outrage, Bridge Field, South Lake Miloch
008 => [146, 130], // 008 : Dusty Bowl, West Lake Axewell
009 => [146, 138], // 009 : Dusty Bowl, North Lake Miloch
010 => [146, 136], // 010 : Dusty Bowl, Giants Seat
011 => [150, 144, 136], // 011 : Hammerlocke Hills, Stony Wilderness, Giants Seat
012 => [142], // 012 : Bridge Field
013 => [150, 144, 140], // 013 : Hammerlocke Hills, Stony Wilderness, Motostoke Riverbank
014 => [146, 136], // 014 : Dusty Bowl, Giants Seat
015 => [142, 122], // 015 : Bridge Field, Rolling Fields
016 => [146], // 016 : Dusty Bowl
017 => [154, 152, 144], // 017 : Lake of Outrage, Giants Cap, Stony Wilderness
018 => [150, 144], // 018 : Hammerlocke Hills, Stony Wilderness
019 => [146], // 019 : Dusty Bowl
020 => [146], // 020 : Dusty Bowl
021 => [144], // 021 : Stony Wilderness
022 => [150, 152], // 022 : Hammerlocke Hills, Giants Cap
023 => [152, 140], // 023 : Giants Cap, Motostoke Riverbank
024 => [154, 148], // 024 : Lake of Outrage, Giants Mirror
025 => [124], // 025 : Dappled Grove
026 => [148, 144, 142], // 026 : Giants Mirror, Stony Wilderness, Bridge Field
027 => [148, 124, 146], // 027 : Giants Mirror, Dappled Grove AND Dusty Bowl (Giant's Mirror load-line overlap)
028 => [138, 128], // 028 : North Lake Miloch, East Lake Axewell
029 => [150, 152, 140], // 029 : Hammerlocke Hills, Giants Cap, Motostoke Riverbank
030 => [128, 122], // 030 : East Lake Axewell, Rolling Fields
031 => [150, 152], // 031 : Hammerlocke Hills, Giants Cap
032 => [150, 122], // 032 : Hammerlocke Hills, Rolling Fields
033 => [154, 142], // 033 : Lake of Outrage, Bridge Field
034 => [144, 130], // 034 : Stony Wilderness, West Lake Axewell
035 => [142, 146, 148], // 035 : Bridge Field, Dusty Bowl, Giants Mirror
036 => [122], // 036 : Rolling Fields
037 => [132], // 037 : Axew's Eye
038 => [128, 122], // 038 : East Lake Axewell, Rolling Fields
039 => [144, 142, 140], // 039 : Stony Wilderness, Bridge Field, Motostoke Riverbank
040 => [134, 138], // 040 : South Lake Miloch, North Lake Miloch
041 => [148, 130], // 041 : Giants Mirror, West Lake Axewell
042 => [148, 144, 134, 146], // 042 : Giants Mirror, Stony Wilderness, South Lake Miloch AND Dusty Bowl (Giant's Mirror load-line overlap)
043 => [154, 142, 128, 130], // 043 : Lake of Outrage, Bridge Field, East Lake Axewell, West Lake Axewell
044 => [150, 136], // 044 : Hammerlocke Hills, Giants Seat
045 => [142, 134, 122], // 045 : Bridge Field, South Lake Miloch, Rolling Fields
046 => [126], // 046 : Watchtower Ruins
047 => [146, 138, 122, 134], // 047 : Dusty Bowl, North Lake Miloch, Rolling Fields, South Lake Miloch
048 => [146, 136], // 048 : Dusty Bowl, Giants Seat
049 => [144, 140, 126], // 049 : Stony Wilderness, Motostoke Riverbank, Watchtower Ruins
050 => [144, 136, 122], // 050 : Stony Wilderness, Giants Seat, Rolling Fields
051 => [146, 142, 122], // 051 : Dusty Bowl, Bridge Field, Rolling Fields
052 => [150], // 052 : Hammerlocke Hills
053 => [146, 144], // 053 : Dusty Bowl, Stony Wilderness
054 => [152, 146, 144], // 054 : Giants Cap, Dusty Bowl, Stony Wilderness
055 => [154, 140], // 055 : Lake of Outrage, Motostoke Riverbank
056 => [150], // 056 : Hammerlocke Hills
057 => [124], // 057 : Dappled Grove
058 => [144, 142, 124], // 058 : Stony Wilderness, Bridge Field, Dappled Grove
059 => [152, 140, 138], // 059 : Giants Cap, Motostoke Riverbank, North Lake Miloch
060 => [150, 128], // 060 : Hammerlocke Hills, East Lake Axewell
061 => [150, 122], // 061 : Hammerlocke Hills, Rolling Fields
062 => [144, 142, 130], // 062 : Stony Wilderness, Bridge Field, West Lake Axewell
063 => [132, 122], // 063 : Axew's Eye, Rolling Fields
064 => [142, 140, 128, 122], // 064 : Bridge Field, Motostoke Riverbank, East Lake Axewell, Rolling Fields
065 => [144], // 065 : Stony Wilderness
066 => [148], // 066 : Giants Mirror
067 => [150], // 067 : Hammerlocke Hills
068 => [148], // 068 : Giants Mirror
069 => [148], // 069 : Giants Mirror
070 => [152], // 070 : Giants Cap
071 => [148], // 071 : Giants Mirror
072 => [150], // 072 : Hammerlocke Hills
073 => [154], // 073 : Lake of Outrage
074 => [146, 130], // 074 : Dusty Bowl, West Lake Axewell
075 => [138, 134], // 075 : North Lake Miloch, South Lake Miloch
076 => [154], // 076 : Lake of Outrage
077 => [152], // 077 : Giants Cap
078 => [124], // 078 : Dappled Grove
079 => [144], // 079 : Stony Wilderness
080 => [144], // 080 : Stony Wilderness
081 => [142], // 081 : Bridge Field
082 => [136], // 082 : Giants Seat
083 => [136], // 083 : Giants Seat
084 => [144], // 084 : Stony Wilderness
085 => [128], // 085 : East Lake Axewell
086 => [142], // 086 : Bridge Field
087 => [146], // 087 : Dusty Bowl
088 => [152], // 088 : Giants Cap
089 => [122], // 089 : Rolling Fields
090 => [130, 134], // 090 : West Lake Axewell, South Lake Miloch
091 => [142, 124], // 091 : Bridge Field, Dappled Grove
092 => [146], // 092 : Dusty Bowl
093 => [], // 093 : None
094 => [], // 094 : None
095 => [], // 095 : None
096 => [], // 096 : None
097 => [], // 097 : None
098 => [164, 166, 188, 190], // 098 : Fields of Honor, Soothing Wetlands, Stepping-Stone Sea, Insular Sea
099 => [164, 166, 188, 190], // 099 : Fields of Honor, Soothing Wetlands, Stepping-Stone Sea, Insular Sea
100 => [166, 176, 180], // 100 : Soothing Wetlands, Courageous Cavern, Training Lowlands
101 => [166, 176, 180], // 101 : Soothing Wetlands, Courageous Cavern, Training Lowlands
102 => [170, 176, 184, 188], // 102 : Challenge Beach, Courageous Cavern, Potbottom Desert, Stepping-Stone Sea
103 => [170, 176, 188], // 103 : Challenge Beach, Courageous Cavern, Stepping-Stone Sea
104 => [164, 168, 170, 192], // 104 : Fields of Honor, Forest of Focus, Challenge Beach, Honeycalm Sea
105 => [164, 168, 170, 192], // 105 : Fields of Honor, Forest of Focus, Challenge Beach, Honeycalm Sea
106 => [174, 178, 186, 188], // 106 : Challenge Road, Loop Lagoon, Workout Sea, Stepping-Stone Sea
107 => [174, 178, 186, 188], // 107 : Challenge Road, Loop Lagoon, Workout Sea, Stepping-Stone Sea
108 => [164, 168, 180, 186], // 108 : Fields of Honor, Forest of Focus, Training Lowlands, Workout Sea
109 => [164, 168, 186], // 109 : Fields of Honor, Forest of Focus, Workout Sea
110 => [164, 166, 180, 190], // 110 : Fields of Honor, Soothing Wetlands, Training Lowlands, Insular Sea
111 => [164, 166, 180, 190], // 111 : Fields of Honor, Soothing Wetlands, Training Lowlands, Insular Sea
112 => [164, 170, 178, 184], // 112 : Fields of Honor, Challenge Beach, Loop Lagoon, Potbottom Desert
113 => [164, 170, 178, 184], // 113 : Fields of Honor, Challenge Beach, Loop Lagoon, Potbottom Desert
114 => [164, 180, 184], // 114 : Fields of Honor, Training Lowlands, Potbottom Desert
115 => [164, 180, 184], // 115 : Fields of Honor, Training Lowlands, Potbottom Desert
116 => [166, 170, 180, 188], // 116 : Soothing Wetlands, Challenge Beach, Training Lowlands, Stepping-Stone Sea
117 => [166, 170, 180, 188], // 117 : Soothing Wetlands, Challenge Beach, Training Lowlands, Stepping-Stone Sea
118 => [166, 168, 180, 188], // 118 : Soothing Wetlands, Forest of Focus, Training Lowlands, Stepping-Stone Sea
119 => [166, 168, 180, 188], // 119 : Soothing Wetlands, Forest of Focus, Training Lowlands, Stepping-Stone Sea
120 => [166, 174, 186, 192], // 120 : Soothing Wetlands, Challenge Road, Workout Sea, Honeycalm Sea
121 => [166, 174, 186, 192], // 121 : Soothing Wetlands, Challenge Road, Workout Sea, Honeycalm Sea
122 => [164, 170, 174, 192], // 122 : Fields of Honor, Challenge Beach, Challenge Road, Honeycalm Sea
123 => [164, 170, 174, 192], // 123 : Fields of Honor, Challenge Beach, Challenge Road, Honeycalm Sea
124 => [164, 166, 168, 190], // 124 : Fields of Honor, Soothing Wetlands, Forest of Focus, Insular Sea
125 => [164, 166, 168, 190], // 125 : Fields of Honor, Soothing Wetlands, Forest of Focus, Insular Sea
126 => [170, 176, 188], // 126 : Challenge Beach, Courageous Cavern, Stepping-Stone Sea
127 => [170, 176, 188], // 127 : Challenge Beach, Courageous Cavern, Stepping-Stone Sea
128 => [172, 176, 188], // 128 : Brawlers' Cave, Courageous Cavern, Stepping-Stone Sea
129 => [172, 176, 188], // 129 : Brawlers' Cave, Courageous Cavern, Stepping-Stone Sea
130 => [178, 186, 192], // 130 : Loop Lagoon, Workout Sea, Honeycalm Sea
131 => [186, 192], // 131 : Workout Sea, Honeycalm Sea
132 => [164, 166, 176], // 132 : Fields of Honor, Soothing Wetlands, Courageous Cavern
133 => [164, 166, 176], // 133 : Fields of Honor, Soothing Wetlands, Courageous Cavern
134 => [166, 168, 170, 176], // 134 : Soothing Wetlands, Forest of Focus, Challenge Beach, Courageous Cavern
135 => [166, 168, 170], // 135 : Soothing Wetlands, Forest of Focus, Challenge Beach
136 => [164, 170, 178, 190], // 136 : Fields of Honor, Challenge Beach, Loop Lagoon, Insular Sea
137 => [164, 170, 178], // 137 : Fields of Honor, Challenge Beach, Loop Lagoon
138 => [186, 188, 190, 192], // 138 : Workout Sea, Stepping-Stone Sea, Insular Sea, Honeycalm Sea
139 => [186, 188, 190, 192], // 139 : Workout Sea, Stepping-Stone Sea, Insular Sea, Honeycalm Sea
140 => [], // 140 : None
141 => [], // 141 : None
142 => [194], // 142 : Honeycalm Island
143 => [194], // 143 : Honeycalm Island
144 => [168, 180], // 144 : Forest of Focus, Training Lowlands
145 => [186, 188], // 145 : Workout Sea, Stepping-Stone Sea
146 => [190], // 146 : Insular Sea
147 => [176], // 147 : Courageous Cavern
148 => [180], // 148 : Training Lowlands
149 => [184], // 149 : Potbottom Desert
150 => [178], // 150 : Loop Lagoon
151 => [186], // 151 : Workout Sea
152 => [186], // 152 : Workout Sea
153 => [168, 180], // 153 : Forest of Focus, Training Lowlands
154 => [186, 188], // 154 : Workout Sea, Stepping-Stone Sea
155 => [174], // 155 : Challenge Road
156 => [174], // 156 : Challenge Road
[204,210,222,230], // 157 : Slippery Slope, Giant's Bed, Giant's Foot, Ballimere Lake
[204,210,222,230], // 158 : Slippery Slope, Giant's Bed, Giant's Foot, Ballimere Lake
[210,214,222,230], // 159 : Giant's Bed, Snowslide Slope, Giant's Foot, Ballimere Lake
[210,214,222,230], // 160 : Giant's Bed, Snowslide Slope, Giant's Foot, Ballimere Lake
[210,222,226,230], // 161 : Giant's Bed, Giant's Foot, Frigid Sea, Ballimere Lake
[210,222,226,230], // 162 : Giant's Bed, Giant's Foot, Frigid Sea, Ballimere Lake
[208,210,226,228,230],// 163 : Frostpoint Field, Giant's Bed, Frigid Sea, Three-Point Pass, Ballimere Lake
[208,210,226,228,230],// 164 : Frostpoint Field, Giant's Bed, Frigid Sea, Three-Point Pass, Ballimere Lake
[204,210,220,222,230],// 165 : Slippery Slope, Giant's Bed, Crown Shrine, Giant's Foot, Ballimere Lake
[204,210,220,222,230],// 166 : Slippery Slope, Giant's Bed, Crown Shrine, Giant's Foot, Ballimere Lake
[204,214,226], // 167 : Slippery Slope, Snowslide Slope, Frigid Sea
[204,214,226], // 168 : Slippery Slope, Snowslide Slope, Frigid Sea
[210,226], // 169 : Giant's Bed, Frigid Sea
[210,226], // 170 : Giant's Bed, Frigid Sea
[208,210,214,226,230],// 171 : Frostpoint Field, Giant's Bed, Snowslide Slope, Frigid Sea, Ballimere Lake
[208,210,214,226,230],// 172 : Frostpoint Field, Giant's Bed, Snowslide Slope, Frigid Sea, Ballimere Lake
[210,226,230], // 173 : Giant's Bed, Frigid Sea, Ballimere Lake
[210,226,230], // 174 : Giant's Bed, Frigid Sea, Ballimere Lake
[208,210,226,230,234],// 175 : Frostpoint Field, Giant's Bed, Frigid Sea, Ballimere Lake, Dyna Tree Hill
[208,210,226,230,234],// 176 : Frostpoint Field, Giant's Bed, Frigid Sea, Ballimere Lake, Dyna Tree Hill
[210,214,218,230], // 177 : Giant's Bed, Snowslide Slope, Path to the Peak, Ballimere Lake
[210,214,218,230], // 178 : Giant's Bed, Snowslide Slope, Path to the Peak, Ballimere Lake
[204,210,214,230], // 179 : Slippery Slope, Giant's Bed, Snowslide Slope, Ballimere Lake
[204,210,214,230], // 180 : Slippery Slope, Giant's Bed, Snowslide Slope, Ballimere Lake
[204,212,222,226,230],// 181 : Slippery Slope, Old Cemetery, Giant's Foot, Frigid Sea, Ballimere Lake
[204,212,222,226,230],// 182 : Slippery Slope, Old Cemetery, Giant's Foot, Frigid Sea, Ballimere Lake
[210,218,226,228,230],// 183 : Giant's Bed, Path to the Peak, Frigid Sea, Three-Point Pass, Ballimere Lake
[210,218,226,228,230],// 184 : Giant's Bed, Path to the Peak, Frigid Sea, Three-Point Pass, Ballimere Lake
[208,210,214,222,226],// 185 : Frostpoint Field, Giant's Bed, Snowslide Slope, Giant's Foot, Frigid Sea
[208,210,214,222,226],// 186 : Frostpoint Field, Giant's Bed, Snowslide Slope, Giant's Foot, Frigid Sea
[210,214,218,226], // 187 : Giant's Bed, Snowslide Slope, Path to the Peak, Frigid Sea
[210,214,218,226], // 188 : Giant's Bed, Snowslide Slope, Path to the Peak, Frigid Sea
[208,210,214,226,230],// 189 : Frostpoint Field, Giant's Bed, Snowslide Slope, Frigid Sea, Ballimere Lake
[208,210,214,226,230],// 190 : Frostpoint Field, Giant's Bed, Snowslide Slope, Frigid Sea, Ballimere Lake
[210,212,230], // 191 : Giant's Bed, Old Cemetery, Ballimere Lake
[210,212,230], // 192 : Giant's Bed, Old Cemetery, Ballimere Lake
[230], // 193 : Ballimere Lake
[230], // 194 : Ballimere Lake
[214], // 195 : Snowslide Slope
[214], // 196 : Snowslide Slope
];
157 => [204,210,222,230], // 157 : Slippery Slope, Giant's Bed, Giant's Foot, Ballimere Lake
158 => [204,210,222,230], // 158 : Slippery Slope, Giant's Bed, Giant's Foot, Ballimere Lake
159 => [210,214,222,230], // 159 : Giant's Bed, Snowslide Slope, Giant's Foot, Ballimere Lake
160 => [210,214,222,230], // 160 : Giant's Bed, Snowslide Slope, Giant's Foot, Ballimere Lake
161 => [210,222,226,230], // 161 : Giant's Bed, Giant's Foot, Frigid Sea, Ballimere Lake
162 => [210,222,226,230], // 162 : Giant's Bed, Giant's Foot, Frigid Sea, Ballimere Lake
163 => [208,210,226,228,230],// 163 : Frostpoint Field, Giant's Bed, Frigid Sea, Three-Point Pass, Ballimere Lake
164 => [208,210,226,228,230],// 164 : Frostpoint Field, Giant's Bed, Frigid Sea, Three-Point Pass, Ballimere Lake
165 => [204,210,220,222,230],// 165 : Slippery Slope, Giant's Bed, Crown Shrine, Giant's Foot, Ballimere Lake
166 => [204,210,220,222,230],// 166 : Slippery Slope, Giant's Bed, Crown Shrine, Giant's Foot, Ballimere Lake
167 => [204,214,226], // 167 : Slippery Slope, Snowslide Slope, Frigid Sea
168 => [204,214,226], // 168 : Slippery Slope, Snowslide Slope, Frigid Sea
169 => [210,226], // 169 : Giant's Bed, Frigid Sea
170 => [210,226], // 170 : Giant's Bed, Frigid Sea
171 => [208,210,214,226,230],// 171 : Frostpoint Field, Giant's Bed, Snowslide Slope, Frigid Sea, Ballimere Lake
172 => [208,210,214,226,230],// 172 : Frostpoint Field, Giant's Bed, Snowslide Slope, Frigid Sea, Ballimere Lake
173 => [210,226,230], // 173 : Giant's Bed, Frigid Sea, Ballimere Lake
174 => [210,226,230], // 174 : Giant's Bed, Frigid Sea, Ballimere Lake
175 => [208,210,226,230,234],// 175 : Frostpoint Field, Giant's Bed, Frigid Sea, Ballimere Lake, Dyna Tree Hill
176 => [208,210,226,230,234],// 176 : Frostpoint Field, Giant's Bed, Frigid Sea, Ballimere Lake, Dyna Tree Hill
177 => [210,214,218,230], // 177 : Giant's Bed, Snowslide Slope, Path to the Peak, Ballimere Lake
178 => [210,214,218,230], // 178 : Giant's Bed, Snowslide Slope, Path to the Peak, Ballimere Lake
179 => [204,210,214,230], // 179 : Slippery Slope, Giant's Bed, Snowslide Slope, Ballimere Lake
180 => [204,210,214,230], // 180 : Slippery Slope, Giant's Bed, Snowslide Slope, Ballimere Lake
181 => [204,212,222,226,230],// 181 : Slippery Slope, Old Cemetery, Giant's Foot, Frigid Sea, Ballimere Lake
182 => [204,212,222,226,230],// 182 : Slippery Slope, Old Cemetery, Giant's Foot, Frigid Sea, Ballimere Lake
183 => [210,218,226,228,230],// 183 : Giant's Bed, Path to the Peak, Frigid Sea, Three-Point Pass, Ballimere Lake
184 => [210,218,226,228,230],// 184 : Giant's Bed, Path to the Peak, Frigid Sea, Three-Point Pass, Ballimere Lake
185 => [208,210,214,222,226],// 185 : Frostpoint Field, Giant's Bed, Snowslide Slope, Giant's Foot, Frigid Sea
186 => [208,210,214,222,226],// 186 : Frostpoint Field, Giant's Bed, Snowslide Slope, Giant's Foot, Frigid Sea
187 => [210,214,218,226], // 187 : Giant's Bed, Snowslide Slope, Path to the Peak, Frigid Sea
188 => [210,214,218,226], // 188 : Giant's Bed, Snowslide Slope, Path to the Peak, Frigid Sea
189 => [208,210,214,226,230],// 189 : Frostpoint Field, Giant's Bed, Snowslide Slope, Frigid Sea, Ballimere Lake
190 => [208,210,214,226,230],// 190 : Frostpoint Field, Giant's Bed, Snowslide Slope, Frigid Sea, Ballimere Lake
191 => [210,212,230], // 191 : Giant's Bed, Old Cemetery, Ballimere Lake
192 => [210,212,230], // 192 : Giant's Bed, Old Cemetery, Ballimere Lake
193 => [230], // 193 : Ballimere Lake
194 => [230], // 194 : Ballimere Lake
195 => [214], // 195 : Snowslide Slope
196 => [214], // 196 : Snowslide Slope
_ => [],
};
/// <summary>
/// Location IDs containing Dens that cannot be accessed without Rotom Bike's Water Mode.

View File

@@ -18,7 +18,7 @@ public sealed record EncounterStatic8N : EncounterStatic8Nest<EncounterStatic8N>
private string RankString=> MinRank == MaxRank ? $"{MinRank+1}" : $"{MinRank+1}-{MaxRank+1}";
public override string Name => $"Stock Raid Den Encounter [{NestID:000}] {RankString}★";
private byte[] NestLocations => Encounters8Nest.NestLocations[NestID];
private bool IsNestLocation(byte loc) => GetNestLocations(NestID).Contains(loc);
public override byte Level { get => LevelMin; init { } }
public override byte LevelMin => LevelCaps[MinRank * 2];
@@ -105,7 +105,7 @@ protected override bool IsMatchLocation(PKM pk)
return true;
if (loc > byte.MaxValue)
return false;
return Array.IndexOf(NestLocations, (byte)loc) >= 0;
return IsNestLocation((byte)loc);
}
public (bool Possible, bool ForceNoShiny) IsPossibleSeed<T>(T pk, ulong seed, bool checkDmax) where T : PKM