-- Note: The closedDoorUnlocked transform the door closed (only with onUse of the player) to the door locked (with onUse of the key), only need add the id of closedDoor and the lockedDoor.
-- The rest of the variables are self-explanatory, create more variables within the table and add the door ids in their variables.
-- Be careful, do not add quest door inside the level door table or vice versa, this will lock the doors.

-- ID of the keys.
keysID = {2086, 2087, 2088, 2089, 2090, 2091, 2092}

-- Keys doors start.
-- Doors locked. This is the doors with the description "It is locked".
keyLockedDoor = {
	{ closedDoor = 1209, openDoor = 1211 },
	{ closedDoor = 1212, openDoor = 1214 },
	{ closedDoor = 1231, openDoor = 1233 },
	{ closedDoor = 1234, openDoor = 1236 },
	{ closedDoor = 1249, openDoor = 1251 },
	{ closedDoor = 1252, openDoor = 1254 },
	{ closedDoor = 3535, openDoor = 3537 },
	{ closedDoor = 3544, openDoor = 3546 },
	{ closedDoor = 4916, openDoor = 4918 },
	{ closedDoor = 4913, openDoor = 4915 },
	{ closedDoor = 5098, openDoor = 5100 },
	{ closedDoor = 5107, openDoor = 5109 },
	{ closedDoor = 5116, openDoor = 5118 },
	{ closedDoor = 5125, openDoor = 5127 },
	{ closedDoor = 5134, openDoor = 5136 },
	{ closedDoor = 5137, openDoor = 5139 },
	{ closedDoor = 5140, openDoor = 5142 },
	{ closedDoor = 5143, openDoor = 5145 },
	{ closedDoor = 5278, openDoor = 5280 },
	{ closedDoor = 5281, openDoor = 5283 },
	{ closedDoor = 5732, openDoor = 5734 },
	{ closedDoor = 5735, openDoor = 5737 },
	{ closedDoor = 6192, openDoor = 6194 },
	{ closedDoor = 6195, openDoor = 6197 },
	{ closedDoor = 6249, openDoor = 6251 },
	{ closedDoor = 6252, openDoor = 6254 },
	{ closedDoor = 6799, openDoor = 6796 },
	{ closedDoor = 6801, openDoor = 6798 },
	{ closedDoor = 6891, openDoor = 6893 },
	{ closedDoor = 6900, openDoor = 6902 },
	{ closedDoor = 7033, openDoor = 7035 },
	{ closedDoor = 7042, openDoor = 7044 },
	{ closedDoor = 8541, openDoor = 8543 },
	{ closedDoor = 8544, openDoor = 8546 },
	{ closedDoor = 9165, openDoor = 9167 },
	{ closedDoor = 9168, openDoor = 9170 },
	{ closedDoor = 9267, openDoor = 9269 },
	{ closedDoor = 9270, openDoor = 9272 },
	{ closedDoor = 10268, openDoor = 10270 },
	{ closedDoor = 10271, openDoor = 10273 },
	{ closedDoor = 10468, openDoor = 10470 },
	{ closedDoor = 10477, openDoor = 10479 },
	{ closedDoor = 10775, openDoor = 10777 },
	{ closedDoor = 10784, openDoor = 10786 },
	{ closedDoor = 12092, openDoor = 12094 },
	{ closedDoor = 12099, openDoor = 12101 },
	{ closedDoor = 12188, openDoor = 12190 },
	{ closedDoor = 12197, openDoor = 12199 },
	{ closedDoor = 14633, openDoor = 14635 },
	{ closedDoor = 19840, openDoor = 19842 },
	{ closedDoor = 19849, openDoor = 19851 },
	{ closedDoor = 19980, openDoor = 19982 },
	{ closedDoor = 19989, openDoor = 19991 },
	{ closedDoor = 20273, openDoor = 20275 },
	{ closedDoor = 20282, openDoor = 20284 },
	{ closedDoor = 22814, openDoor = 22816 },
	{ closedDoor = 22823, openDoor = 22825 },
	{ closedDoor = 26541, openDoor = 26545 },
	{ closedDoor = 26543, openDoor = 26546 },
	{ closedDoor = 33117, openDoor = 32582 },
	{ closedDoor = 33119, openDoor = 32583 },
	}
	
-- This is the commons doors usually used in the keys, are opened just by using.
keyUnlockedDoor = {
	{ closedDoor = 1210, openDoor = 1211 },
	{ closedDoor = 1213, openDoor = 1214 },
	{ closedDoor = 1232, openDoor = 1233 },
	{ closedDoor = 1235, openDoor = 1236 },
	{ closedDoor = 1250, openDoor = 1251 },
	{ closedDoor = 1253, openDoor = 1254 },
	{ closedDoor = 3536, openDoor = 3537 },
	{ closedDoor = 3545, openDoor = 3546 },	
	{ closedDoor = 4914, openDoor = 4915 },
	{ closedDoor = 4917, openDoor = 4918 },
	{ closedDoor = 5099, openDoor = 5100 },
	{ closedDoor = 5108, openDoor = 5109 },
	{ closedDoor = 5117, openDoor = 5118 },
	{ closedDoor = 5126, openDoor = 5127 },
	{ closedDoor = 5135, openDoor = 5136 },
	{ closedDoor = 5138, openDoor = 5139 },
	{ closedDoor = 5141, openDoor = 5142 },
	{ closedDoor = 5144, openDoor = 5145 },
	{ closedDoor = 5279, openDoor = 5280 },
	{ closedDoor = 5282, openDoor = 5283 },
	{ closedDoor = 5733, openDoor = 5734 },
	{ closedDoor = 5736, openDoor = 5737 },
	{ closedDoor = 6193, openDoor = 6194 },
	{ closedDoor = 6196, openDoor = 6197 },
	{ closedDoor = 6250, openDoor = 6251 },
	{ closedDoor = 6253, openDoor = 6254 },
	{ closedDoor = 6795, openDoor = 6796 },
	{ closedDoor = 6892, openDoor = 6893 },
	{ closedDoor = 6894, openDoor = 6895 },
	{ closedDoor = 6901, openDoor = 6902 },
	{ closedDoor = 6903, openDoor = 6904 },
	{ closedDoor = 7034, openDoor = 7035 },
	{ closedDoor = 7043, openDoor = 7044 },
	{ closedDoor = 8542, openDoor = 8543 },
	{ closedDoor = 8545, openDoor = 8546 },
	{ closedDoor = 9166, openDoor = 9167 },
	{ closedDoor = 9169, openDoor = 9170 },
	{ closedDoor = 9268, openDoor = 9269 },
	{ closedDoor = 9271, openDoor = 9272 },
	{ closedDoor = 10269, openDoor = 10270 },
	{ closedDoor = 10272, openDoor = 10273 },
	{ closedDoor = 10469, openDoor = 10470 },
	{ closedDoor = 10478, openDoor = 10479 },
	{ closedDoor = 10776, openDoor = 10777 },
	{ closedDoor = 10785, openDoor = 10786 },
	{ closedDoor = 12093, openDoor = 12094 },
	{ closedDoor = 12100, openDoor = 12101 },
	{ closedDoor = 12189, openDoor = 12190 },
	{ closedDoor = 12198, openDoor = 12199 },
	{ closedDoor = 14634, openDoor = 14635 },
	{ closedDoor = 19841, openDoor = 19842 },
	{ closedDoor = 19850, openDoor = 19851 },
	{ closedDoor = 19981, openDoor = 19982 },
	{ closedDoor = 19990, openDoor = 19991 },
	{ closedDoor = 20274, openDoor = 20275 },
	{ closedDoor = 20283, openDoor = 20284 },
	{ closedDoor = 22815, openDoor = 22816 },
	{ closedDoor = 22824, openDoor = 22825 },
	{ closedDoor = 26542, openDoor = 26545 },
	{ closedDoor = 26544, openDoor = 26546 },
	{ closedDoor = 33118, openDoor = 32582 },
	{ closedDoor = 33120, openDoor = 32583 },
	}
	
-- Add the common closed key door here and in the second variable the door locked with the key.
-- This allows that when using the closed door with the key, it becomes the locked door.
fromClosedToLockedDoor = {
	{ keyDoorClosed = 1210, keyDoorLocked = 1209 },
	{ keyDoorClosed = 1213, keyDoorLocked = 1212 },
	{ keyDoorClosed = 1232, keyDoorLocked = 1231 },
	{ keyDoorClosed = 1235, keyDoorLocked = 1234 },
	{ keyDoorClosed = 1250, keyDoorLocked = 1249 },
	{ keyDoorClosed = 1253, keyDoorLocked = 1252 },
	{ keyDoorClosed = 3536, keyDoorLocked = 3535 },
	{ keyDoorClosed = 3545, keyDoorLocked = 3544 },
	{ keyDoorClosed = 4914, keyDoorLocked = 4913 },
	{ keyDoorClosed = 4917, keyDoorLocked = 4916 },
	{ keyDoorClosed = 5099, keyDoorLocked = 5098 },
	{ keyDoorClosed = 5108, keyDoorLocked = 5107 },
	{ keyDoorClosed = 5117, keyDoorLocked = 5116 },
	{ keyDoorClosed = 5126, keyDoorLocked = 5125 },
	{ keyDoorClosed = 5135, keyDoorLocked = 5134 },
	{ keyDoorClosed = 5141, keyDoorLocked = 5140 },
	{ keyDoorClosed = 5144, keyDoorLocked = 5143 },
	{ keyDoorClosed = 5279, keyDoorLocked = 5278 },
	{ keyDoorClosed = 5282, keyDoorLocked = 5281 },
	{ keyDoorClosed = 5733, keyDoorLocked = 5732 },
	{ keyDoorClosed = 5736, keyDoorLocked = 5735 },
	{ keyDoorClosed = 6193, keyDoorLocked = 6192 },
	{ keyDoorClosed = 6196, keyDoorLocked = 6195 },
	{ keyDoorClosed = 6250, keyDoorLocked = 6249 },
	{ keyDoorClosed = 6253, keyDoorLocked = 6252 },
	{ keyDoorClosed = 6795, keyDoorLocked = 6799 },
	{ keyDoorClosed = 6797, keyDoorLocked = 6801 },
	{ keyDoorClosed = 6892, keyDoorLocked = 6891 },
	{ keyDoorClosed = 6901, keyDoorLocked = 6900 },
	{ keyDoorClosed = 7034, keyDoorLocked = 7033 },
	{ keyDoorClosed = 7043, keyDoorLocked = 7042 },
	{ keyDoorClosed = 8542, keyDoorLocked = 8541 },
	{ keyDoorClosed = 8545, keyDoorLocked = 8544 },
	{ keyDoorClosed = 9166, keyDoorLocked = 9165 },
	{ keyDoorClosed = 9169, keyDoorLocked = 9168 },
	{ keyDoorClosed = 9268, keyDoorLocked = 9267 },
	{ keyDoorClosed = 9271, keyDoorLocked = 9270 },
	{ keyDoorClosed = 10269, keyDoorLocked = 10268 },
	{ keyDoorClosed = 10272, keyDoorLocked = 10271 },
	{ keyDoorClosed = 10469, keyDoorLocked = 10468 },
	{ keyDoorClosed = 10478, keyDoorLocked = 10477 },
	{ keyDoorClosed = 10776, keyDoorLocked = 10775 },
	{ keyDoorClosed = 10785, keyDoorLocked = 10784 },
	{ keyDoorClosed = 12093, keyDoorLocked = 12092 },
	{ keyDoorClosed = 12100, keyDoorLocked = 12099 },
	{ keyDoorClosed = 12189, keyDoorLocked = 12188 },
	{ keyDoorClosed = 12198, keyDoorLocked = 12197 },
	{ keyDoorClosed = 14634, keyDoorLocked = 14633 },
	{ keyDoorClosed = 14641, keyDoorLocked = 14640 },
	{ keyDoorClosed = 19841, keyDoorLocked = 19840 },
	{ keyDoorClosed = 19850, keyDoorLocked = 19849 },
	{ keyDoorClosed = 19981, keyDoorLocked = 19980 },
	{ keyDoorClosed = 19990, keyDoorLocked = 19989 },
	{ keyDoorClosed = 20274, keyDoorLocked = 20273 },
	{ keyDoorClosed = 20283, keyDoorLocked = 20282 },
	{ keyDoorClosed = 22815, keyDoorLocked = 22814 },
	{ keyDoorClosed = 22824, keyDoorLocked = 22823 },
	{ keyDoorClosed = 26542, keyDoorLocked = 26541 },
	{ keyDoorClosed = 26544, keyDoorLocked = 26543 },
	{ keyDoorClosed = 33118, keyDoorLocked = 33117 },
	{ keyDoorClosed = 33120, keyDoorLocked = 33119 },
	}
-- Keys doors end. 
	
-- These are the common doors, the ones that just open and close without any special requirements.
customDoor = {
	{ closedDoor = 1219, openDoor = 1220 },
	{ closedDoor = 1221, openDoor = 1222 },
	{ closedDoor = 1237, openDoor = 1238 },
	{ closedDoor = 1239, openDoor = 1240 },
	{ closedDoor = 3538, openDoor = 3539 },
	{ closedDoor = 3547, openDoor = 3548 },
	{ closedDoor = 1539, openDoor = 1540 },
	{ closedDoor = 1541, openDoor = 1542 },
	{ closedDoor = 5082, openDoor = 5083 },
	{ closedDoor = 5084, openDoor = 5085 },
	{ closedDoor = 5101, openDoor = 5102 },
	{ closedDoor = 5110, openDoor = 5111 },
	{ closedDoor = 5119, openDoor = 5120 },
	{ closedDoor = 5128, openDoor = 5129 },
	{ closedDoor = 5284, openDoor = 5285 },
	{ closedDoor = 5286, openDoor = 5287 },
	{ closedDoor = 5515, openDoor = 5516 },
	{ closedDoor = 5517, openDoor = 5518 },
	{ closedDoor = 6198, openDoor = 6199 },
	{ closedDoor = 6200, openDoor = 6201 },
	{ closedDoor = 6255, openDoor = 6256 },
	{ closedDoor = 6257, openDoor = 6258 },
	{ closedDoor = 6797, openDoor = 6798 },
	{ closedDoor = 7036, openDoor = 7037 },
	{ closedDoor = 7045, openDoor = 7046 },
	{ closedDoor = 7054, openDoor = 7055 },
	{ closedDoor = 7056, openDoor = 7057 },
	{ closedDoor = 8547, openDoor = 8548 },
	{ closedDoor = 8549, openDoor = 8550 },
	{ closedDoor = 9171, openDoor = 9172 },
	{ closedDoor = 9173, openDoor = 9174 },
	{ closedDoor = 9273, openDoor = 9274 },
	{ closedDoor = 9275, openDoor = 9276 },
	{ closedDoor = 10274, openDoor = 10275 },
	{ closedDoor = 10276, openDoor = 10277 },
	{ closedDoor = 10471, openDoor = 10472 },
	{ closedDoor = 10480, openDoor = 10481 },
	{ closedDoor = 12692, openDoor = 12695 },
	{ closedDoor = 12701, openDoor = 12703 },
	{ closedDoor = 13236, openDoor = 13237 },
	{ closedDoor = 18208, openDoor = 18209 },
	{ closedDoor = 19843, openDoor = 19844 },
	{ closedDoor = 19852, openDoor = 19853 },
	{ closedDoor = 19983, openDoor = 19984 },
	{ closedDoor = 19992, openDoor = 19993 },
	{ closedDoor = 20276, openDoor = 20277 },
	{ closedDoor = 20285, openDoor = 20286 },
	{ closedDoor = 20305, openDoor = 20306 },
	{ closedDoor = 22817, openDoor = 22818 },
	{ closedDoor = 22826, openDoor = 22827 },
	{ closedDoor = 27209, openDoor = 27210 },
	{ closedDoor = 27211, openDoor = 27212 },
	{ closedDoor = 27571, openDoor = 33296 },
	{ closedDoor = 35007, openDoor = 35016 },
	{ closedDoor = 35008, openDoor = 35017 },
	--[[ do not have the open door id, if activate this, have a conflict of id (is only a locked door?)
	{ closedDoor = 34687, openDoor = 34673 },
	{ closedDoor = 34688, openDoor = 34674 },
	{ closedDoor = 34689, openDoor = 34677 },
	{ closedDoor = 34690, openDoor = 34678 },
	]]
	{ closedDoor = 35607, openDoor = 35611 },
	{ closedDoor = 35608, openDoor = 35611 },
	{ closedDoor = 35609, openDoor = 35612 },
	{ closedDoor = 35610, openDoor = 35612 },
	{ closedDoor = 35668, openDoor = 35672 },
	{ closedDoor = 35669, openDoor = 35672 },
	{ closedDoor = 35670, openDoor = 35673 },
	{ closedDoor = 35671, openDoor = 35673 },
	{ closedDoor = 35684, openDoor = 35688 },
	{ closedDoor = 35685, openDoor = 35689 },
	{ closedDoor = 35686, openDoor = 35690 },
	{ closedDoor = 35687, openDoor = 35691 },
	{ closedDoor = 36329, openDoor = 36331 },
	{ closedDoor = 36330, openDoor = 36332 },
	{ closedDoor = 36498, openDoor = 36499 },
	{ closedDoor = 36500, openDoor = 36501 },
	}

-- These are the doors for missions, they need access from some mission (storage) to be able to enter. Put the storage value in the action id of the door and it will open only to the player who has the storage value.
questDoor = {
	{ closedDoor = 1223, openDoor = 1224 },
	{ closedDoor = 1225, openDoor = 1226 },
	{ closedDoor = 1241, openDoor = 1242 },
	{ closedDoor = 1243, openDoor = 1244 },
	{ closedDoor = 1255, openDoor = 1256 },
	{ closedDoor = 1257, openDoor = 1258 },
	{ closedDoor = 3542, openDoor = 3543 },
	{ closedDoor = 3551, openDoor = 3552 },
	{ closedDoor = 5105, openDoor = 5106 },
	{ closedDoor = 5114, openDoor = 5115 },
	{ closedDoor = 5123, openDoor = 5124 },
	{ closedDoor = 5132, openDoor = 5133 },
	{ closedDoor = 5288, openDoor = 5289 },
	{ closedDoor = 5290, openDoor = 5291 },
	{ closedDoor = 6202, openDoor = 6203 },
	{ closedDoor = 6204, openDoor = 6205 },
	{ closedDoor = 6259, openDoor = 6260 },
	{ closedDoor = 6261, openDoor = 6262 },
	{ closedDoor = 6898, openDoor = 6899 },
	{ closedDoor = 6907, openDoor = 6908 },
	{ closedDoor = 7040, openDoor = 7041 },
	{ closedDoor = 7049, openDoor = 7050 },
	{ closedDoor = 8551, openDoor = 8552 },
	{ closedDoor = 8553, openDoor = 8554 },
	{ closedDoor = 9175, openDoor = 9176 },
	{ closedDoor = 9177, openDoor = 9178 },
	{ closedDoor = 9277, openDoor = 9278 },
	{ closedDoor = 9279, openDoor = 9280 },
	{ closedDoor = 10278, openDoor = 10279 },
	{ closedDoor = 10280, openDoor = 10281 },
	{ closedDoor = 10475, openDoor = 10476 },
	{ closedDoor = 10484, openDoor = 10485 },
	{ closedDoor = 10782, openDoor = 10783 },
	{ closedDoor = 10791, openDoor = 10792 },
	{ closedDoor = 12104, openDoor = 12105 },
	{ closedDoor = 12195, openDoor = 12196 },
	{ closedDoor = 12204, openDoor = 12205 },
	{ closedDoor = 13022, openDoor = 13023 },
	{ closedDoor = 19847, openDoor = 19848 },
	{ closedDoor = 19856, openDoor = 19857 },
	{ closedDoor = 19987, openDoor = 19988 },
	{ closedDoor = 19996, openDoor = 19997 },
	{ closedDoor = 20280, openDoor = 20281 },
	{ closedDoor = 20289, openDoor = 20290 },
	{ closedDoor = 22821, openDoor = 22822 },
	{ closedDoor = 22830, openDoor = 22831 },
	{ closedDoor = 25162, openDoor = 25163 },
	{ closedDoor = 25164, openDoor = 25165 },
	{ closedDoor = 34679, openDoor = 34680 },
	{ closedDoor = 34681, openDoor = 34682 },
	{ closedDoor = 34683, openDoor = 34684 },
	{ closedDoor = 34685, openDoor = 34686 },
	{ closedDoor = 36403, openDoor = 36404 },
	{ closedDoor = 36405, openDoor = 36406 },
	}
	
-- Level doors.
-- It's simple, just add a 1 followed by the amount of levels the player needs to be able to pass.
-- For example:
-- Level 10 put the action id: 1010 on the door.
-- Level 100 put the action id: 1100 on the door. And so on.
levelDoor = {
	{ closedDoor = 1227, openDoor = 1228 },
	{ closedDoor = 1229, openDoor = 1230 },
	{ closedDoor = 1245, openDoor = 1246 },
	{ closedDoor = 1247, openDoor = 1248 },
	{ closedDoor = 1259, openDoor = 1260 },
	{ closedDoor = 1261, openDoor = 1262 },
	{ closedDoor = 3540, openDoor = 3541 },
	{ closedDoor = 3549, openDoor = 3550 },
	{ closedDoor = 5103, openDoor = 5104 },
	{ closedDoor = 5112, openDoor = 5113 },
	{ closedDoor = 5121, openDoor = 5122 },
	{ closedDoor = 5130, openDoor = 5131 },
	{ closedDoor = 5292, openDoor = 5293 },
	{ closedDoor = 5294, openDoor = 5295 },
	{ closedDoor = 6206, openDoor = 6207 },
	{ closedDoor = 6208, openDoor = 6209 },
	{ closedDoor = 6263, openDoor = 6264 },
	{ closedDoor = 6265, openDoor = 6266 },
	{ closedDoor = 6896, openDoor = 6897 },
	{ closedDoor = 6905, openDoor = 6906 },
	{ closedDoor = 7038, openDoor = 7039 },
	{ closedDoor = 7047, openDoor = 7048 },
	{ closedDoor = 8555, openDoor = 8556 },
	{ closedDoor = 8557, openDoor = 8558 },
	{ closedDoor = 9179, openDoor = 9180 },
	{ closedDoor = 9181, openDoor = 9182 },
	{ closedDoor = 9281, openDoor = 9282 },
	{ closedDoor = 9283, openDoor = 9284 },
	{ closedDoor = 10282, openDoor = 10283 },
	{ closedDoor = 10284, openDoor = 10285 },
	{ closedDoor = 10473, openDoor = 10474 },
	{ closedDoor = 10482, openDoor = 10483 },
	{ closedDoor = 10780, openDoor = 10781 },
	{ closedDoor = 10789, openDoor = 10790 },
	{ closedDoor = 12095, openDoor = 12096 },
	{ closedDoor = 12102, openDoor = 12103 },
	{ closedDoor = 12193, openDoor = 12194 },
	{ closedDoor = 12202, openDoor = 12203 },
	{ closedDoor = 13020, openDoor = 13021 },
	{ closedDoor = 17235, openDoor = 17236 },
	{ closedDoor = 17237, openDoor = 17238 },
	{ closedDoor = 19845, openDoor = 19846 },
	{ closedDoor = 19854, openDoor = 19855 },
	{ closedDoor = 19985, openDoor = 19986 },
	{ closedDoor = 19994, openDoor = 19995 },
	{ closedDoor = 20278, openDoor = 20279 },
	{ closedDoor = 20287, openDoor = 20288 },
	{ closedDoor = 22819, openDoor = 22820 },
	{ closedDoor = 22828, openDoor = 22829 },
	{ closedDoor = 25158, openDoor = 25159 },
	{ closedDoor = 25160, openDoor = 25161 },
	{ closedDoor = 34671, openDoor = 34673 },
	{ closedDoor = 34672, openDoor = 34674 },
	{ closedDoor = 34675, openDoor = 34677 },
	{ closedDoor = 34676, openDoor = 34678 },
	}
