/* * * The file for communicating with entitys in the game. * * Since we cant give direct entity pointers to the framework, * Instead we will give the framework a "handle" which we can break down later * and resolve it into a proper entity. * * This is on your side, the java side. * */ #include "../../../framework/entitys.hpp" namespace modules::jni { void Init() { // main functions to get info out of entities GetDormant = [](CatEntity* in) -> bool { // These are static as they shouldnt change, so they would be fast to do // once and forget static auto entity_class = FindClass(g_Enviroment, "neko/framework/entitys"); static auto dormant_method = GetStaticMethodID(g_Enviroment, entity_class, "GetDormant", "") }; GetAlive = [](CatEntity* in) -> bool { }; extern CMFunction GetHealth; extern CMFunction GetMaxHealth; extern CMFunction GetTeam; extern CMFunction GetType; extern CMFunction GetName; extern CMFunction GetOrigin; extern CMFunction GetCollision; extern CMFunction GetSteamId; extern CMFunction GetBone; // Local player specific extern CMFunction Attack; extern CMFunction Jump; extern CMFunction WalkTo; extern CMFunction InThirdperson; extern CMFunction GetCamera; extern CMFunction GetCameraAngle; extern CMFunction SetCameraAngle; extern CMFunction SetSilentCameraAngle; // Entity manager stuff extern CMFunction GetEntityCount; extern CMFunction GetEntity; extern CMFunction GetLocalPlayer; }