/*
* This file is part of the Pandaria 5.4.8 Project. See THANKS file for Copyright information
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the
* Free Software Foundation; either version 2 of the License, or (at your
* option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along
* with this program. If not, see <http://www.gnu.org/licenses/>.
*/

#ifndef SECRETS_OF_RAGEFIRE_H_
#define SECRETS_OF_RAGEFIRE_H_

const Position newtDetonatorPath[15] =
{
    { 1392.043f, 817.7743f, 38.46221f, 0.0f },
    { 1392.293f, 821.5243f, 38.21221f, 0.0f },
    { 1393.784f, 828.3873f, 38.07181f, 0.0f },
    { 1396.534f, 833.8873f, 37.82181f, 0.0f },
    { 1396.597f, 834.0892f, 37.88713f, 0.0f },
    { 1399.597f, 840.0892f, 37.88713f, 0.0f },
    { 1405.847f, 848.5892f, 38.13713f, 0.0f },
    { 1406.039f, 848.7728f, 38.29267f, 0.0f },
    { 1406.539f, 849.2728f, 38.29267f, 0.0f },
    { 1411.539f, 856.7728f, 38.04267f, 0.0f },
    { 1414.797f, 866.9714f, 38.63203f, 0.0f },
    { 1416.047f, 873.2214f, 38.13203f, 0.0f },
    { 1416.547f, 875.9714f, 38.13203f, 0.0f },
    { 1418.547f, 885.4714f, 38.13203f, 0.0f },
    { 1419.797f, 889.9714f, 38.13203f, 0.0f },
};

const Position gritDetonatorPath[15]=
{
    { 1389.789f, 812.3082f, 38.46331f, 0.0f },
    { 1390.289f, 816.3082f, 38.46331f, 0.0f },
    { 1390.539f, 819.3082f, 38.21331f, 0.0f },
    { 1390.789f, 820.8082f, 38.21331f, 0.0f },
    { 1391.039f, 822.3082f, 38.21331f, 0.0f },
    { 1391.539f, 824.0582f, 37.96331f, 0.0f },
    { 1392.039f, 825.3082f, 37.96331f, 0.0f },
    { 1393.039f, 828.5582f, 37.96331f, 0.0f },
    { 1394.789f, 832.8082f, 37.96331f, 0.0f },
    { 1395.098f, 833.151f, 37.96811f, 0.0f },
    { 1396.848f, 838.151f, 37.71811f, 0.0f },
    { 1399.598f, 840.401f, 37.96811f, 0.0f },
    { 1404.598f, 845.401f, 38.21811f, 0.0f },
    { 1407.098f, 847.651f, 38.46811f, 0.0f },
    { 1411.995f, 857.4622f, 38.15794f, 0.0f },
};

const Position pathDetonatorPath[14] =
{
    { 1385.515f, 829.951f, 37.50122f, 0.0f },
    { 1387.515f, 833.201f, 37.50122f, 0.0f },
    { 1391.015f, 839.201f, 37.50122f, 0.0f },
    { 1396.891f, 848.8566f, 37.70827f, 0.0f },
    { 1398.891f, 852.3566f, 38.20827f, 0.0f },
    { 1399.037f, 852.5749f, 38.17024f, 0.0f },
    { 1401.037f, 856.3249f, 38.17024f, 0.0f },
    { 1405.839f, 864.0608f, 38.14886f, 0.0f },
    { 1408.339f, 865.5608f, 38.14886f, 0.0f },
    { 1409.089f, 866.0608f, 38.14886f, 0.0f },
    { 1409.839f, 868.5608f, 38.39886f, 0.0f },
    { 1410.075f, 868.3301f, 38.34711f, 0.0f },
    { 1412.325f, 876.5801f, 37.84711f, 0.0f },
    { 1412.075f, 878.0801f, 37.84711f, 0.0f },
};

const Position voltDetonatorPath[12] =
{
    { 1394.361f, 820.4288f, 38.42365f, 0.0f },
    { 1394.111f, 821.9288f, 38.67365f, 0.0f },
    { 1394.111f, 822.9288f, 38.67365f, 0.0f },
    { 1393.861f, 828.1788f, 38.17365f, 0.0f },
    { 1395.424f, 833.313f, 38.01848f, 0.0f },
    { 1400.674f, 838.813f, 38.26848f, 0.0f },
    { 1403.174f, 841.313f, 38.26848f, 0.0f },
    { 1404.978f, 843.2765f, 38.38256f, 0.0f },
    { 1408.478f, 846.7765f, 38.63256f, 0.0f },
    { 1409.978f, 848.2765f, 38.63256f, 0.0f },
    { 1412.742f, 851.0181f, 38.48668f, 0.0f },
    { 1415.742f, 851.7681f, 38.48668f, 0.0f },
};

const Position tickerDetonatorPath[9] =
{
    { 1388.664f, 819.9031f, 38.19055f, 0.0f },
    { 1389.414f, 827.1531f, 37.69055f, 0.0f },
    { 1391.164f, 830.1531f, 37.44055f, 0.0f },
    { 1394.414f, 836.1531f, 37.44055f, 0.0f },
    { 1398.031f, 842.2872f, 37.41706f, 0.0f },
    { 1403.281f, 850.2872f, 37.91706f, 0.0f },
    { 1406.031f, 854.2872f, 37.91706f, 0.0f },
    { 1409.164f, 859.3151f, 37.98228f, 0.0f },
    { 1411.414f, 868.0651f, 38.48228f, 0.0f },
};

const Position newtMechaPath[3]=
{
    { 1415.899f, 872.3109f, 38.08f, 0.0f },
    { 1421.149f, 865.0609f, 38.33f, 0.0f },
    { 1422.632f, 862.7257f, 38.42861f, 0.0f },
};

const Position korkronPeonsLeavePath[3] =
{
    { 1470.97f, 1006.11f, 34.37f, 6.07f },
    { 1497.46f, 1002.49f, 38.36f, 6.16f },
    { 1528.54f, 1013.28f, 38.18f, 0.36f },
};

const Position voltRagefirePath[10]=
{
    { 1419.298f, 878.0057f, 38.09418f, 0.0f },
    { 1419.548f, 883.2557f, 38.09418f, 0.0f },
    { 1419.548f, 890.0057f, 38.09418f, 0.0f },
    { 1419.834f, 898.0093f, 38.31787f, 0.0f },
    { 1419.584f, 899.0093f, 38.31787f, 0.0f },
    { 1418.584f, 903.2593f, 38.56787f, 0.0f },
    { 1417.334f, 908.7593f, 38.31787f, 0.0f },
    { 1417.084f, 910.7593f, 38.06787f, 0.0f },
    { 1415.584f, 918.0093f, 37.56787f, 0.0f },
    { 1414.587f, 920.8976f, 37.18552f, 0.0f },
};

const Position tickerRagefirePath[7] =
{
    { 1413.805f, 878.1471f, 37.96119f, 0.0f },
    { 1414.805f, 881.3971f, 37.96119f, 0.0f },
    { 1412.805f, 900.8971f, 37.96119f, 0.0f },
    { 1412.305f, 907.3971f, 37.71119f, 0.0f },
    { 1411.805f, 914.1471f, 37.46119f, 0.0f },
    { 1411.555f, 916.1471f, 37.46119f, 0.0f },
    { 1411.097f, 917.7864f, 37.17408f, 0.0f },
};

const Position newtRagefirePath[9] =
{
    { 1413.597f, 887.3683f, 37.85545f, 0.0f },
    { 1411.847f, 900.6183f, 37.85545f, 0.0f },
    { 1411.097f, 905.1183f, 37.60545f, 0.0f },
    { 1411.672f, 900.7391f, 37.77251f, 0.0f },
    { 1410.922f, 905.4891f, 37.77251f, 0.0f },
    { 1410.672f, 907.2391f, 37.52251f, 0.0f },
    { 1410.422f, 914.9891f, 37.27251f, 0.0f },
    { 1410.172f, 918.9891f, 37.27251f, 0.0f },
    { 1409.922f, 922.9891f, 37.27251f, 0.0f },
};

const Position gritRagefirePath[11] =
{
    { 1416.766f, 880.2284f, 37.98886f, 0.0f },
    { 1417.016f, 887.7284f, 37.98886f, 0.0f },
    { 1415.266f, 899.9784f, 37.98886f, 0.0f },
    { 1415.016f, 901.2284f, 37.98886f, 0.0f },
    { 1414.954f, 900.3909f, 37.936f, 0.0f },
    { 1414.704f, 901.6409f, 37.936f, 0.0f },
    { 1413.704f, 907.3909f, 37.936f, 0.0f },
    { 1413.204f, 912.8909f, 37.686f, 0.0f },
    { 1412.704f, 916.6409f, 37.436f, 0.0f },
    { 1411.954f, 921.3909f, 37.436f, 0.0f },
    { 1411.454f, 924.8909f, 37.186f, 0.0f },
};

const Position patchRagefirePath[12] =
{
    { 1410.075f, 868.3301f, 38.34711f, 0.0f },
    { 1412.325f, 876.5801f, 37.84711f, 0.0f },
    { 1412.075f, 878.0801f, 37.84711f, 0.0f },
    { 1412.627f, 886.6437f, 37.91214f, 0.0f },
    { 1413.127f, 889.8937f, 37.91214f, 0.0f },
    { 1412.377f, 900.6437f, 37.91214f, 0.0f },
    { 1410.676f, 904.7796f, 37.60917f, 0.0f },
    { 1407.676f, 910.7796f, 37.35917f, 0.0f },
    { 1407.426f, 914.0296f, 37.10917f, 0.0f },
    { 1407.176f, 918.0296f, 37.10917f, 0.0f },
    { 1406.926f, 919.5296f, 37.10917f, 0.0f },
    { 1406.766f, 920.059f, 36.66113f, 0.0f },
};

const Position voltSealedGatePath[27]=
{
    { 1399.425f, 993.925f, 33.45583f, 0.0f },
    { 1407.925f, 994.675f, 33.95583f, 0.0f },
    { 1409.925f, 994.675f, 34.20583f, 0.0f },
    { 1410.925f, 994.925f, 34.70583f, 0.0f },
    { 1413.175f, 994.925f, 34.70583f, 0.0f },
    { 1413.925f, 995.175f, 34.45583f, 0.0f },
    { 1417.175f, 995.425f, 34.45583f, 0.0f },
    { 1419.425f, 995.425f, 34.45583f, 0.0f },
    { 1424.925f, 995.175f, 34.45583f, 0.0f },
    { 1425.425f, 995.175f, 34.70583f, 0.0f },
    { 1438.175f, 994.175f, 34.70583f, 0.0f },
    { 1443.425f, 994.925f, 34.95583f, 0.0f },
    { 1446.925f, 995.425f, 34.70583f, 0.0f },
    { 1450.675f, 995.675f, 34.95583f, 0.0f },
    { 1450.925f, 995.175f, 34.45583f, 0.0f },
    { 1454.925f, 994.425f, 34.45583f, 0.0f },
    { 1461.175f, 995.675f, 34.45583f, 0.0f },
    { 1461.675f, 995.675f, 34.70583f, 0.0f },
    { 1465.175f, 996.425f, 34.70583f, 0.0f },
    { 1466.175f, 996.675f, 34.20583f, 0.0f },
    { 1466.925f, 996.925f, 34.45583f, 0.0f },
    { 1467.675f, 996.925f, 34.70583f, 0.0f },
    { 1468.925f, 997.175f, 34.95583f, 0.0f },
    { 1469.675f, 997.175f, 35.45583f, 0.0f },
    { 1475.925f, 997.925f, 36.95583f, 0.0f },
    { 1480.675f, 999.175f, 38.45583f, 0.0f },
    { 1483.425f, 999.675f, 38.95583f, 0.0f },
};

const Position newtSealedGatePath[14]=
{
    { 1444.018f, 1029.357f, 34.88434f, 0.0f },
    { 1450.268f, 1026.107f, 34.88434f, 0.0f },
    { 1451.268f, 1025.607f, 34.88434f, 0.0f },
    { 1452.518f, 1025.107f, 34.63434f, 0.0f },
    { 1455.268f, 1023.607f, 34.38434f, 0.0f },
    { 1459.768f, 1021.357f, 34.38434f, 0.0f },
    { 1465.268f, 1018.607f, 34.38434f, 0.0f },
    { 1468.018f, 1017.357f, 34.88434f, 0.0f },
    { 1469.018f, 1016.857f, 34.13434f, 0.0f },
    { 1472.268f, 1015.107f, 35.13434f, 0.0f },
    { 1477.768f, 1012.357f, 36.13434f, 0.0f },
    { 1480.518f, 1011.107f, 36.63434f, 0.0f },
    { 1482.518f, 1010.107f, 37.38434f, 0.0f },
    { 1483.768f, 1009.357f, 38.38434f, 0.0f },
};

const Position pathSealedGatePath[21] =
{
    { 1416.72f, 1043.305f, 34.10373f, 0.0f },
    { 1422.72f, 1040.055f, 34.10373f, 0.0f },
    { 1423.97f, 1039.305f, 34.85373f, 0.0f },
    { 1426.47f, 1037.805f, 34.60373f, 0.0f },
    { 1428.22f, 1036.805f, 34.35373f, 0.0f },
    { 1432.72f, 1034.305f, 34.35373f, 0.0f },
    { 1438.47f, 1031.055f, 34.35373f, 0.0f },
    { 1439.97f, 1030.305f, 34.60373f, 0.0f },
    { 1442.47f, 1028.805f, 34.85373f, 0.0f },
    { 1446.97f, 1026.305f, 34.85373f, 0.0f },
    { 1449.97f, 1024.805f, 34.85373f, 0.0f },
    { 1453.72f, 1022.805f, 34.85373f, 0.0f },
    { 1454.72f, 1022.055f, 34.60373f, 0.0f },
    { 1460.22f, 1019.055f, 34.35373f, 0.0f },
    { 1465.47f, 1016.305f, 34.35373f, 0.0f },
    { 1468.47f, 1014.555f, 34.85373f, 0.0f },
    { 1469.47f, 1014.055f, 34.10373f, 0.0f },
    { 1475.22f, 1010.805f, 35.60373f, 0.0f },
    { 1477.97f, 1009.305f, 36.10373f, 0.0f },
    { 1478.97f, 1008.555f, 36.35373f, 0.0f },
    { 1482.22f, 1006.805f, 37.60373f, 0.0f },
};

const Position gritSealedGatePath = { 1491.19f, 1003.23f, 38.2666f, 0.0f };
const Position tickerSealedGatePath = { 1490.56f, 1000.74f, 38.1681f, 0.0f };
const Position tickerSealedGateReachPoint = { 1493.12f, 1001.03f, 38.17221f, 0.0f };

enum Data
{
    DATA_INFILTRATION,
    DATA_RECONNAISSANCE,
    DATA_SEALED_GATE,
    DATA_HOLDOUT,

    // Misc
    PLAYER_DATA,
    PROTDRAKES_DATA,
    DATA_ALLOW_BRING_ITEMS,
};

enum Creatures
{
    NPC_DETONATOR            = 70662,
    NPC_BOMB                 = 70672,
    NPC_VOLT                 = 70608,
    NPC_NEWT                 = 70606,
    NPC_TICKER               = 70609,
    NPC_GRIT                 = 70605,
    NPC_PATCH                = 70607,

    // Korkron
    NPC_KORKRON_SHADOWBLADE  = 71244,
    NPC_KORKRON_DARK_SHAMAN  = 71245,
    NPC_KORKRON_EMBERGUARD   = 70798,
    NPC_RAGEFIRE_PEON        = 71097,
    NPC_FLAME_HOUND          = 70702,
    NPC_OVERSEER_ELAGLO      = 71030,
    NPC_KORKRON_DIRE_SOLDER  = 70665,
    NPC_DARK_SHAMAN_XORENTH  = 70683,
    NPC_PROTO_DRAKE_WHELP    = 71401,

    // Misc
    NPC_EMERGENCY_TELEPORTER = 71296,
    NPC_PANDARIA_ARTIFACTS   = 71032,
    NPC_PROTO_DRAKE_EGGS     = 71031,
    NPC_SLG_GENERIC_MOP      = 63420,
    NPC_RUINED_EARTH         = 71262,
    NPC_GLACIAL_FREEZE_TOTEM = 71323,
    NPC_SUPPLY_CRATES        = 71203,
    NPC_MANTID_BOMB          = 71174,
    NPC_BATTERY              = 71195,
    NPC_POOL_PONY            = 71175,
    NPC_BROKEN_DRAKE_EGG     = 71197,
    NPC_CANNON_BALLS         = 71176,
    NPC_MANTID_BOMB_TARGET   = 71221,
    NPC_POISON_BOLT_TOTEM    = 71334,
    NPC_SHATTERED_EARTH      = 71446,
};

enum GameObjects
{
    GO_IRON_GATE_EXIT       = 220169, // these door not explosive!
    GO_IRON_GATE            = 220168,
    GO_EMERGENCY_TELEPORTER = 220066,
};

enum ExtraSpells
{
    SPELL_GOBLIN_ILLUSION = 142783,
    SPELL_SEALED_GATE     = 140923,
    SPELL_POOL_PONY       = 141898,
    SPELL_BATTERY         = 141904,
    SPELL_EGG_YOLK        = 141914,
    SPELL_CANNON_BALL     = 141832,
    SPELL_ROCKET_JUMP     = 142512,
};

enum Yells
{
    TALK_INTRO,
    TALK_SPECIAL_1,
    TALK_SPECIAL_2,
    TALK_SPECIAL_3,
    TALK_SPECIAL_4,
    TALK_SPECIAL_5,
    TALK_SPECIAL_6,
    TALK_SPECIAL_7,
    TALK_SPECIAL_8,
    TALK_SPECIAL_9,
    TALK_SPECIAL_10,
    TALK_SPECIAL_11,
    TALK_SPECIAL_12,
    TALK_SPECIAL_13,
    TALK_SPECIAL_14,
    TALK_SPECIAL_15,
    TALK_SPECIAL_16,
    TALK_SPECIAL_17,
    TALK_SPECIAL_18,
    TALK_SPECIAL_19,
    TALK_SPECIAL_20,
    TALK_SPECIAL_21,
    TALK_SPECIAL_22,
};

enum Actions
{
    ACTION_START_INTRO,
    ACTION_INNER_RAGEFIRE,
    ACTION_RECONNAISSANCE,
    ACTION_SEALED_GATES,
    ACTION_REACH_SEALED_GATES,
    ACTION_EXPLOSIVE_GATES,
    ACTION_GOB_SQUAD_DEFENDED,
};

enum Criteries
{
    CRITERIA_REACH_RAGEFIRE         = 23213,
    CRITERIA_DEFEAT_ENEMIES         = 23216,
    CRITERIA_INVESTIGATE_DRAKE_EGGS = 23254,
    CRITERIA_INVESTIGATE_BOXES      = 23255,
    CRITERIA_INVESTIGATE_ARTIFACTS  = 23256,
    CRITERIA_MEET_WITH_TICKER       = 23313,
    CRITERIA_CANNON_BALLS           = 23307, // 3
    CRITERIA_BATTERY                = 23310, // 2
    CRITERIA_POOL_PONY              = 23308, // 1
    CRITERIA_EGGS                   = 23309, // 1
    CRITERIA_GOB_SQUAD_DEFENDED     = 23311,
};

const std::multimap<uint32, Position> invKorkronAssault1 =
{
    { NPC_FLAME_HOUND,         { 1447.29f, 1072.03f, 49.79f, 4.45f } },
    { NPC_FLAME_HOUND,         { 1460.92f, 1065.97f, 50.48f, 4.41f } },
    { NPC_KORKRON_DARK_SHAMAN, { 1450.51f, 1070.02f, 49.36f, 4.45f } },
    { NPC_KORKRON_DARK_SHAMAN, { 1456.69f, 1067.36f, 49.70f, 4.41f } },
};

const std::multimap<uint32, Position> invKorkronAssault2 =
{
    { NPC_KORKRON_DARK_SHAMAN, { 1468.26f, 950.79f, 51.07f, 2.58f } },
    { NPC_FLAME_HOUND,         { 1466.69f, 948.39f, 50.56f, 2.56f } },
    { NPC_FLAME_HOUND,         { 1462.33f, 943.00f, 50.68f, 2.56f } },
    { NPC_KORKRON_DARK_SHAMAN, { 1462.19f, 939.83f, 51.21f, 2.58f } },
    { NPC_KORKRON_DIRE_SOLDER, { 1464.42f, 945.63f, 49.94f, 2.53f } },
};

const std::multimap<uint32, Position> invKorkronAssault3 =
{
    { NPC_KORKRON_DARK_SHAMAN, { 1395.76f, 1054.82f, 56.81f, 5.65f } },
    { NPC_KORKRON_EMBERGUARD,  { 1398.18f, 1057.19f, 56.49f, 5.48f } },
    { NPC_KORKRON_EMBERGUARD,  { 1399.84f, 1060.61f, 56.51f, 5.48f } },
    { NPC_KORKRON_SHADOWBLADE, { 1402.34f, 1063.95f, 57.11f, 5.60f } },
};

const std::multimap<uint32, Position> invKorkronAssault4 =
{
    { NPC_KORKRON_SHADOWBLADE, { 1356.27f,  994.96f, 60.40f, 0.22f } },
    { NPC_KORKRON_DIRE_SOLDER, { 1352.82f, 1001.09f, 59.09f, 0.22f } },
    { NPC_KORKRON_EMBERGUARD,  { 1359.83f, 1003.59f, 61.90f, 0.22f } },
    { NPC_KORKRON_DARK_SHAMAN, { 1353.61f, 1008.22f, 60.85f, 0.22f } },
};

const std::vector<uint32> goblinsList =
{
    NPC_VOLT,
    NPC_NEWT,
    NPC_TICKER,
    NPC_GRIT,
    NPC_PATCH,
};

enum Worldstates
{
    WORLDSTATE_FEW_PROUD_GOB_SQUAD = 14102, 
};

const std::map<uint32, uint32> investigatedItems =
{
    { NPC_PANDARIA_ARTIFACTS, CRITERIA_INVESTIGATE_ARTIFACTS  },
    { NPC_PROTO_DRAKE_EGGS,   CRITERIA_INVESTIGATE_DRAKE_EGGS },
    { NPC_SUPPLY_CRATES,      CRITERIA_INVESTIGATE_BOXES      },
};

// Entry - [AllowUse, SpellId]
const std::map<uint32, std::array<uint32, 2>> invBringItemsType =
{
    { NPC_BATTERY,          { 2, SPELL_BATTERY     } },
    { NPC_POOL_PONY,        { 1, SPELL_POOL_PONY   } },
    { NPC_BROKEN_DRAKE_EGG, { 1, SPELL_EGG_YOLK    } },
    { NPC_CANNON_BALLS,     { 3, SPELL_CANNON_BALL } },
};

const std::map<uint32, uint32> invDeliveringType =
{
    { SPELL_BATTERY,     CRITERIA_BATTERY      },
    { SPELL_POOL_PONY,   CRITERIA_POOL_PONY    },
    { SPELL_EGG_YOLK,    CRITERIA_EGGS         },
    { SPELL_CANNON_BALL, CRITERIA_CANNON_BALLS },
};

const std::map<uint32, std::multimap<uint32, Position>> invAssaultType =
{
    { 1, invKorkronAssault2 },
    { 2, invKorkronAssault3 },
    { 3, invKorkronAssault4 },
};

#endif // SECRETS_OF_RAGEFIRE_H_