模組:沙盒/TimWu007/MTR/data

local lines = {
	tsuen_wan = {
		name = '荃灣綫',
		codes = {'TSUEN WAN LINE', 'TSUEN WAN', 'TWL', 'TW', '荃灣線', '荃灣綫', '荃灣', '荃'},
		color = 'ED1D24',
	},
	kwun_tong = {
		name = '觀塘綫',
		codes = {'KWUN TONG LINE', 'KWUN TONG', 'KTL', 'KT', 'K', '觀塘線', '觀塘綫', '觀塘', '觀'},
		color = '00AB4E',
	},
	island = {
		name = '港島綫',
		codes = {'ISLAND LINE', 'ISLAND', 'ISL', 'IS', 'I', '港島線', '港島綫', '港島', '港'},
		color = '007DC5',
		needs_dab = false, -- 後備迴避歧義用參數,儘管在中文維基百科用不上,如有必要則將false改為true。
	},
	tseung_kwan_o = {
		name = '將軍澳綫',
		codes = {'TSEUNG KWAN O LINE', 'TSEUNG KWAN O', 'TKOL', 'TKO', 'TKL', 'TK', '將軍澳線', '將軍澳綫', '將軍澳', '將'},
		color = '7D499D',
	},
	tung_chung = {
		name = '東涌綫',
		codes = {'TUNG CHUNG LINE', 'TUNG CHUNG', 'TCL', 'TC', '東涌線', '東涌綫', '東涌'},
		color = 'F7943E',
	},
	disneyland = {
		name = '迪士尼綫',
		codes = {'DISNEYLAND RESORT LINE', 'DISNEYLAND RESORT', 'DISNEYLAND', 'DISNEY', 'DRL', 'DR', 'D', '迪士尼線', '迪士尼綫', '迪士尼', '迪'},
		color = 'F173AC',
	},
	airport_express = {
		name = '機場快綫',
		codes = {'AIRPORT EXPRESS', 'AIRPORT', 'AEL', 'AE', 'A', '機場快線', '機場快綫', '機場', '機', 'AEL機', 'A機'},
		color = '00888A',
		needs_dab = false,
	},
	east_rail = {
		name = '東鐵綫',
		codes = {'EAST RAIL LINE', 'EAST RAIL', 'EAST', 'EAL', 'ERL', 'ER', 'E', '東鐵線', '東鐵綫', '東鐵', '東'},
		color = '53B7E8',
	},
	west_rail = {
		name = '西鐵綫',
		codes = {'WEST RAIL LINE', 'WEST RAIL', 'WEST', 'WRL', 'WR', 'W', '西鐵線', '西鐵綫', '西鐵', '西'},
		color = 'A3238F',
	},
	ma_on_shan = {
		name = '馬鞍山綫',
		codes = {'MA ON SHAN LINE', 'MA ON SHAN', 'MOSL', 'MOS', 'MOL', 'MO', 'M', '馬鞍山線', '馬鞍山綫', '馬鞍山', '馬'},
		color = '923011',
	},
	tuen_ma = {
		name = '屯馬綫',
		codes = {'TUEN MA', 'TUEN MA LINE', 'TML', 'TM', 'EAST WEST CORRIDOR', 'EAST WEST LINE', 'EAST-WEST LINE', 'EAST WEST', 'EAST-WEST', 'EWL', 'EWC', 'EW', '屯馬綫', '屯馬', '屯馬線', '東西綫', '東西走廊', '東西線', '東西'},
		color = '923011',
	},
	ngong_ping_360 = {
		name = '昂坪360',
		codes = {'NGONG PING 360', 'NGONG PING CABLE CAR', 'NGONG PING', '360', 'NP360', 'NGP', '昂坪纜車', '昂坪360', '昂坪', '昂'},
		color = '94989A',
	},
	light_rail = {
		name = '輕鐵',
		codes = {'LIGHT RAIL', 'LIGHT', 'LIR', 'LRT', 'LR', 'L', '香港輕鐵', '輕', '輕鐵'},
		color = 'D3A809',
		needs_dab = true,
	},
	kcr_east = {
		name = '九廣東鐵',
		codes = {'KCR EAST RAIL', 'KCR-ER', 'ER-KCR', 'ER-KCRC', 'E-KCR', '東鐵KCR', '九廣東鐵', '九東', '東K'},
		color = '005DA0',
	},
	kcr_west = {
		name = '九廣西鐵',
		codes = {'KCR WEST RAIL', 'KCR-WR', 'WR-KCR', 'WR-KCRC', 'W-KCR', '九廣西鐵', '西鐵', '西鐵KCR', '九西', '西K'},
		color = 'AC2571',
	},
	kcr_ma_on_shan = {
		name = '九廣馬鐵',
		codes = {'KCR MA ON SHAN RAIL', 'KCR-MOS', 'MOR-KCR', 'MOR-KCRC', 'M-KCR', '九廣馬鐵', '馬鞍山鐵路', '馬鐵KCR', '九馬', '馬K', '馬鐵'},
		color = '761E10',
	},
	kcr_light = {
		name = '九廣輕鐵',
		codes = {'KCR LIGHT RAIL', 'KCR-LRT', 'KCR-LR', 'LRT-KCR', 'LR-KCR', 'LR-KCRC', 'LR-KCRC', 'L-KCR', '輕鐵KCR', '九廣輕鐵', '九輕', '輕K'},
		color = 'FD722D',
	},
	south_island_east = {
		name = '南港島綫',
		codes = {'SOUTH ISLAND LINE EAST SECTION', 'SOUTH ISLAND LINE EAST', 'SOUTH ISLAND EAST', 'SILE', 'SIL', 'SIE', 'SEL', 'SE', '南港島線東段', '南港島綫東段', '南港島綫', '南港島線', '南港島東', '南港', '南東', '南港島'},
		color = 'C1CD23',
	},
	south_island_west = {
		name = '南港島綫西段',
		codes = {'SOUTH ISLAND LINE WEST SECTION', 'SOUTH ISLAND LINE WEST', 'SOUTH ISLAND WEST', 'SILW', 'SIW', 'SWL', 'SW', '南港島線西段', '南港島綫西段', '南港島西', '南西'},
		color = '9182C2',
	},
	north_island = {
		name = '北港島綫',
		codes = {'NORTH ISLAND LINE', 'NORTH ISLAND', 'NIL', 'NI', '北港島線', '北港島綫', '北港'},
		color = 'F7943E',
	},
	northern_link = {
		name = '北環綫',
		codes = {'NORTHERN LINK', 'NORTHERN', 'NOL', 'NRL', 'NR', '北環線', '北環綫', '北環', '北'},
		color = 'E0027A',
	},
	express_rail = {
		name = '高速鐵路',
		codes = {'EXPRESS RAIL', 'XRL', '高速鐵路', '高鐵', '高'},
		color = 'BBB0A3',
	},
	east_kowloon = {
		name = '東九龍綫',
		codes = {'EAST KOWLOON LINE', 'EAST KOWLOON', 'EKL', 'EK', '東九龍綫', '東九龍', '東九'},
		color = '006633',
	},
}
 
local names, colors, needs_dab = {}, {}, {}
for k, t in pairs(lines) do
	local name = t.name
	local color = t.color
	for i, code in ipairs(t.codes) do
		names[code] = name
		colors[code] = color
	end
	needs_dab[name] = t.needs_dab
end
 
return {
	names = names,
	colors = colors,
	needs_dab = needs_dab
}