#ifndef INTERNAL_HPP_INCLUDED
#define INTERNAL_HPP_INCLUDED

#include "Debug.hpp"
#include "Input.hpp"
#include "Math.hpp"
#include "Paint.hpp"
#include "Script.hpp"
#include "Time.hpp"

#include "Types/Tile.hpp"
#include "Types/Point.hpp"
#include "Types/Box.hpp"
#include "Types/Timer.hpp"
#include "Types/Counter.hpp"
#include "Types/Countdown.hpp"
#include "Types/Convex.hpp"
#include "Types/Area.hpp"
#include "Types/Logger.hpp"
#include "Types/Triangle.hpp"
#include "Types/Wireframe.hpp"

#include "JavaClass/ByteBuffer.hpp"
#include "JavaClass/Canvas.hpp"
#include "JavaClass/FocusEvent.hpp"
#include "JavaClass/Integer.hpp"
#include "JavaClass/KeyEvent.hpp"
#include "JavaClass/LinkedHashMap.hpp"
#include "JavaClass/Map.hpp"
#include "JavaClass/MouseEvent.hpp"
#include "JavaClass/MouseWheelEvent.hpp"
#include "JavaClass/Object.hpp"

#include "Classes/AbstractByteBuffer.hpp"
#include "Classes/Animation.hpp"
#include "Classes/AttackOption.hpp"
#include "Classes/Cache.hpp"
#include "Classes/CacheableNode.hpp"
#include "Classes/Character.hpp"
#include "Classes/ChatLineBuffer.hpp"
#include "Classes/ClanMember.hpp"
#include "Classes/ClanMemberList.hpp"
#include "Classes/CollisionData.hpp"
#include "Classes/CombatInfo.hpp"
#include "Classes/DecorativeObject.hpp"
#include "Classes/Deque.hpp"
#include "Classes/DirectByteBuffer.hpp"
#include "Classes/DynamicObject.hpp"
#include "Classes/ExchangeOffer.hpp"
#include "Classes/Font.hpp"
#include "Classes/FontFamily.hpp"
#include "Classes/FontName.hpp"
#include "Classes/Fonts.hpp"
#include "Classes/Frame.hpp"
#include "Classes/FrameMap.hpp"
#include "Classes/Frames.hpp"
#include "Classes/Friend.hpp"
#include "Classes/FriendList.hpp"
#include "Classes/GameObject.hpp"
#include "Classes/GameShell.hpp"
#include "Classes/GraphicsObject.hpp"
#include "Classes/GroundItem.hpp"
#include "Classes/GroundObject.hpp"
#include "Classes/HashTable.hpp"
#include "Classes/HealthBar.hpp"
#include "Classes/HealthInfo.hpp"
#include "Classes/Ignore.hpp"
#include "Classes/IgnoreList.hpp"
#include "Classes/IndexableData.hpp"
#include "Classes/ItemContainer.hpp"
#include "Classes/ItemInfo.hpp"
#include "Classes/LinkedList.hpp"
#include "Classes/MessageNode.hpp"
#include "Classes/Model.hpp"
#include "Classes/Nameable.hpp"
#include "Classes/NameableContainer.hpp"
#include "Classes/NamePair.hpp"
#include "Classes/Node.hpp"
#include "Classes/NPC.hpp"
#include "Classes/NPCInfo.hpp"
#include "Classes/ObjectInfo.hpp"
#include "Classes/Player.hpp"
#include "Classes/PlayerInfo.hpp"
#include "Classes/PlayerManager.hpp"
#include "Classes/Preferences.hpp"
#include "Classes/Projectile.hpp"
#include "Classes/Queue.hpp"
#include "Classes/Region.hpp"
#include "Classes/Renderable.hpp"
#include "Classes/SceneTile.hpp"
#include "Classes/SpotAnimation.hpp"
#include "Classes/Sprite.hpp"
#include "Classes/Talkable.hpp"
#include "Classes/Varbit.hpp"
#include "Classes/WallObject.hpp"
#include "Classes/Widget.hpp"
#include "Classes/WidgetNode.hpp"
#include "Classes/World.hpp"


namespace Internal
{

    extern GameShell Client;

    Cache GetAnimationCache();
    std::int32_t GetCameraPitch();
    std::int32_t GetCameraX();
    std::int32_t GetCameraY();
    std::int32_t GetCameraYaw();
    std::int32_t GetCameraZ();
    Map GetChatLineCache();
    Map GetClientFonts();
    std::vector<std::int32_t> GetClientKeyCodes();
    std::int32_t GetClientPlane();
    Preferences GetClientPreferences();
    std::int32_t GetClientX();
    std::int32_t GetClientY();
    std::vector<CollisionData> GetCollisionMaps();
    std::int32_t GetCrosshairState();
    std::vector<std::int32_t> GetCurrentLevels();
    std::int32_t GetCurrentWorld();
    bool GetDraggingItem();
    Cache GetDynamicObjectCache();
    std::vector<ExchangeOffer> GetExchangeOffers();
    std::vector<std::int32_t> GetExperiences();
    bool GetFocused();
    Cache GetFramesCache();
    std::int32_t GetGameState();
    std::int32_t GetGameTick();
    Deque GetGraphicsObjects();
    std::vector<std::vector<std::vector<Deque>>> GetGroundItems();
    bool GetIsMember();
    HashTable GetItemContainers();
    IndexableData GetItemIndexableData();
    Cache GetItemInfoCache();
    Cache GetItemModelCache();
    std::int32_t GetItemSelected();
    std::int32_t GetItemSelectedIndex();
    Cache GetItemSpriteCache();
    std::vector<std::int8_t> GetKeysPressed();
    std::vector<std::int32_t> GetLevels();
    ClanMemberList GetLocalClanMemberList();
    std::int32_t GetLocalDestinationX();
    std::int32_t GetLocalDestinationY();
    Player GetLocalPlayer();
    std::int32_t GetLocalPlayerIndex();
    PlayerManager GetLocalPlayerManager();
    Region GetLocalRegion();
    std::int32_t GetLoginCaret();
    std::string GetLoginMessage0();
    std::string GetLoginMessage1();
    std::string GetLoginMessage2();
    std::int32_t GetLoginScreenX();
    std::int32_t GetLoginState();
    std::int32_t GetLoginWindow();
    std::int32_t GetMapAngle();
    std::vector<std::int32_t> GetMapRegions();
    std::vector<std::string> GetMenuActions();
    std::int32_t GetMenuCount();
    std::int32_t GetMenuHeight();
    std::vector<std::string> GetMenuTargets();
    bool GetMenuVisible();
    std::int32_t GetMenuWidth();
    std::int32_t GetMenuX();
    std::int32_t GetMenuY();
    std::int32_t GetMouseX();
    std::int32_t GetMouseY();
    AttackOption GetNPCAttackOption();
    IndexableData GetNPCIndexableData();
    std::vector<std::int32_t> GetNPCIndices();
    Cache GetNPCModelCache();
    std::vector<NPC> GetNPCs();
    IndexableData GetObjectIndexableData();
    Cache GetObjectInfoCache();
    std::string GetPassword();
    AttackOption GetPlayerAttackOption();
    Cache GetPlayerModelCache();
    std::vector<Player> GetPlayers();
    Deque GetProjectiles();
    std::int32_t GetRunEnergy();
    std::string GetSelectedItemName();
    std::string GetSelectedSpellName();
    std::vector<std::int32_t> GetSettings();
    bool GetSpellSelected();
    Cache GetSpotAnimationCache();
    Cache GetSpotAnimationModelCache();
    std::vector<std::vector<std::vector<std::int32_t>>> GetTileHeights();
    std::vector<std::vector<std::vector<std::int8_t>>> GetTileSettings();
    std::string GetUsername();
    Cache GetVarbitCache();
    std::vector<std::int32_t> GetVarbitSettings();
    std::int32_t GetViewportHeight();
    std::int32_t GetViewportScale();
    std::int32_t GetViewportWidth();
    std::int32_t GetWeight();
    Cache GetWidgetFontCache();
    HashTable GetWidgetNodeCache();
    std::int32_t GetWidgetRoot();
    std::vector<std::vector<Widget>> GetWidgets();
    std::vector<std::int32_t> GetWidgetsHeight();
    std::vector<std::int32_t> GetWidgetsWidth();
    std::vector<std::int32_t> GetWidgetsX();
    std::vector<std::int32_t> GetWidgetsY();
    bool GetWorldSelectOpen();
    std::vector<World> GetWorlds();
    ItemInfo LoadItemInfo(std::int32_t ID);
    NPCInfo LoadNPCInfo(std::int32_t ID);
    ObjectInfo LoadObjectInfo(std::int32_t ID);
    bool LoadWorlds();
    void SetWorld(const World& W);

    ItemInfo GetItemInfo(std::int32_t ID);
    NPCInfo GetNPCInfo(std::int32_t ID);
    ObjectInfo GetObjectInfo(std::int32_t ID);
    ObjectInfo GetObjectInfo(std::int32_t ID, const std::vector<Node>& Buckets);
    Widget GetWidget(std::int32_t Container, std::int32_t Component);
    Widget GetWidgetParent(const Widget& W);
    std::int32_t GetWidgetX(const Widget& W);
    std::int32_t GetWidgetX(const Widget& W, const std::vector<std::int32_t>& Xs);
    std::int32_t GetWidgetY(const Widget& W);
    std::int32_t GetWidgetY(const Widget& W, const std::vector<std::int32_t>& Ys);
    bool GetWidgetHidden(const Widget& W);
    Box GetWidgetBox(const Widget& W);
    Box GetWidgetBox(const Widget& W, const std::vector<std::int32_t>& Xs, const std::vector<std::int32_t>& Ys);
    ItemContainer GetItemContainer(std::int32_t ID);
    NPC GetNPC(std::int32_t Index);
    Player GetPlayer(std::int32_t Index);
    std::vector<Point> ProjectModel(const Model& M, std::int32_t LocalX, std::int32_t LocalY,
                                    std::int32_t LocalZ, std::int32_t Angle);
    Model GetPlayerModel(std::int64_t ID);
    Model GetNPCModel(std::int32_t ID);
    Varbit GetVarbit(std::int32_t ID);
    Animation GetAnimation(std::int32_t ID);
    Frames GetFrames(std::int32_t ID);
    Model GetItemModel(std::int32_t ID);
    Model GetItemModel(std::int32_t ID, std::int32_t Amount);
    SpotAnimation GetSpotAnimation(std::int32_t ID);
    Model GetSpotAnimationModel(std::int32_t ID);
    Model GetGameObjectModel(const GameObject& O);
    Model GetWallObjectModel(const WallObject& O);
    Model GetDecorativeObjectModel(const DecorativeObject& O);
    Model GetGroundObjectModel(const GroundObject& O);
    Model GetDynamicObjectModel(std::int32_t ID);
    std::vector<std::vector<Deque>> GetGroundItems(std::int32_t Plane);
    Deque GetGroundItems(std::int32_t X, std::int32_t Y);
    Deque GetGroundItems(std::int32_t X, std::int32_t Y, std::int32_t Plane);
    std::vector<Point> GetPlayerModel(const Player& P);
    std::vector<Point> GetNPCModel(const NPC& N);
    std::vector<Point> GetGraphicsObjectModel(const GraphicsObject& O);
    std::vector<Point> GetProjectileModel(const Internal::Projectile& P);
    SceneTile GetSceneTile(std::int32_t X, std::int32_t Y, std::int32_t Plane);
    std::vector<std::vector<SceneTile>> GetSceneTiles(std::int32_t Plane);
    Point TileToMinimap(const Tile& T);
    std::int32_t GetTileItemHeight(std::int32_t X, std::int32_t Y, std::int32_t Plane);
    Sprite GetItemSprite(std::int32_t ID, std::int32_t Amount);
    Convex GetItemSpriteConvex(const Sprite& S);
    std::int32_t GetSettings(std::int32_t ID);
    std::int32_t GetVarbitSettings(std::int32_t VarbitSettingIndex);
    Point TileToMainscreen(const Tile& T, std::int32_t X, std::int32_t Y, std::int32_t Z);
    std::string GetItemName(std::int32_t ID);
    bool IsItemPlaceholder(std::int32_t ID);
    bool IsItemStackable(std::int32_t ID);
    std::vector<Box> GetBlockingWidgetBoxes();
    std::int32_t GetHealthPercentage(const Internal::Character& C);
    std::vector<Widget> GetWidgets(std::int32_t Container);

}
#endif // INTERNAL_HPP_INCLUDED
