diff --git a/.vscode/c_cpp_properties.json b/.vscode/c_cpp_properties.json index aa011ad..9bf22bb 100644 --- a/.vscode/c_cpp_properties.json +++ b/.vscode/c_cpp_properties.json @@ -6,10 +6,10 @@ "${workspaceFolder}/**", "${PLUGIN_SDK_DIR}/*", "${DIRECTX9_SDK_DIR}/Include/*", - "${PLUGIN_SDK_DIR}/plugin_sa/*", - "${PLUGIN_SDK_DIR}/plugin_sa/game_sa/*", - // "${PLUGIN_SDK_DIR}/plugin_vc/*", - // "${PLUGIN_SDK_DIR}/plugin_vc/game_vc/*", + // "${PLUGIN_SDK_DIR}/plugin_sa/*", + // "${PLUGIN_SDK_DIR}/plugin_sa/game_sa/*", + "${PLUGIN_SDK_DIR}/plugin_vc/*", + "${PLUGIN_SDK_DIR}/plugin_vc/game_vc/*", "${PLUGIN_SDK_DIR}/shared/*", "${PLUGIN_SDK_DIR}/shared/game/*", "C:\\Program Files (x86)\\Windows Kits\\10\\Include\\10.0.19041.0\\ucrt\\*", @@ -20,7 +20,7 @@ "IS_PLATFORM_WIN", "_CRT_SECURE_NO_WARNINGS", "_CRT_NON_CONFORMING_SWPRINTFS", - "GTASA", + "GTAVC", "_DX9_SDK_INSTALLED", "PLUGIN_SGV_10US" ], diff --git a/src/menuinfo.h b/src/menuinfo.h index 30cf672..686ebf8 100644 --- a/src/menuinfo.h +++ b/src/menuinfo.h @@ -2,5 +2,5 @@ #define MENU_NAME "Cheat Menu" #define MENU_VERSION_NUMBER "3.0" #define MENU_VERSION MENU_VERSION_NUMBER"-beta" -#define BUILD_NUMBER "20210922" +#define BUILD_NUMBER "20210923" #define MENU_TITLE MENU_NAME " v" MENU_VERSION "(" BUILD_NUMBER ")" diff --git a/src/util.cpp b/src/util.cpp index 181d00e..347ea4d 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -150,7 +150,7 @@ CPlayerPed* player = FindPlayerPed(); CVector pos = pVeh->GetPosition(); float dist = DistanceBetweenPoints(playerPos, pos); - if (dist < distance && pVeh->m_pDriver != player) + if (dist < distance) { pClosestVeh = pVeh; distance = dist; diff --git a/src/vehicle.cpp b/src/vehicle.cpp index d19e19b..f88202f 100644 --- a/src/vehicle.cpp +++ b/src/vehicle.cpp @@ -749,6 +749,7 @@ void Vehicle::Draw() Command(hplayer, pClosestVeh); } +#ifdef GTASA for (int i = 0; i < seats; ++i) { if (i % 2 != 1) @@ -759,9 +760,24 @@ void Vehicle::Draw() if (ImGui::Button((std::string("Passenger ") + std::to_string(i + 1)).c_str(), ImVec2(Ui::GetSize(2)))) { - Command(hplayer, pClosestVeh, i); + Command(hplayer, pClosestVeh, i); } } +#elif GTAVC + // ImGui::SameLine(); + // if (ImGui::Button("Passenger", ImVec2(Ui::GetSize(2)))) + // { + // if (pPlayer->m_bInVehicle) + // { + // CVector pos = pClosestVeh->GetPosition(); + // Command(hplayer, pos.x, pos.y, pos.z); + // } + + // pPlayer->SetObjective(OBJECTIVE_ENTER_CAR_AS_PASSENGER); + // pPlayer->WarpPedIntoCar(pClosestVeh); + // // Command(CPools::GetVehicleRef(pClosestVeh), 0); + // } +#endif } else { diff --git a/tools/premake5.lua b/tools/premake5.lua index 38ee450..8d9376f 100644 --- a/tools/premake5.lua +++ b/tools/premake5.lua @@ -53,42 +53,45 @@ project "CheatMenuVC" targetextension ".asi" files { - "../src/CheatMenu.h", - "../src/CheatMenu.cpp", + "../src/cheatmenu.h", + "../src/cheatmenu.cpp", "../src/pch.h", "../src/pch.cpp", - "../src/Hook.h", - "../src/Hook.cpp", - "../src/Updater.h", - "../src/Updater.cpp", - "../src/Json.h", - "../src/Json.cpp", - "../src/Animation.h", - "../src/Animation.cpp", - "../src/Teleport.h", - "../src/Teleport.cpp", - "../src/Player.h", - "../src/Player.cpp", - "../src/Ped.h", - "../src/Ped.cpp", - "../src/Ui.h", - "../src/Ui.cpp", - "../src/Vehicle.h", - "../src/Vehicle.cpp", - "../src/Util.h", - "../src/Util.cpp", - "../src/Menu.h", - "../src/Menu.cpp", - "../src/Weapon.h", - "../src/Weapon.cpp", - "../src/Game.h", - "../src/Game.cpp", - "../src/Visual.h", - "../src/Visual.cpp", - "../src/ResourceStore.h", - "../src/ResourceStore.cpp", - "../src/FileHandler.h", - "../src/FileHandler.cpp" + "../src/hook.h", + "../src/hook.cpp", + "../src/updater.h", + "../src/updater.cpp", + "../src/json.h", + "../src/json.cpp", + "../src/animation.h", + "../src/animation.cpp", + "../src/teleport.h", + "../src/teleport.cpp", + "../src/player.h", + "../src/player.cpp", + "../src/ped.h", + "../src/ped.cpp", + "../src/ui.h", + "../src/ui.cpp", + "../src/vehicle.h", + "../src/vehicle.cpp", + "../src/util.h", + "../src/util.cpp", + "../src/menu.h", + "../src/menu.cpp", + "../src/weapon.h", + "../src/weapon.cpp", + "../src/game.h", + "../src/game.cpp", + "../src/visual.h", + "../src/visual.cpp", + "../src/resourcestore.h", + "../src/resourcestore.cpp", + "../src/filehandler.h", + "../src/filehandler.cpp", + "../src/hotkeys.h", + "../src/hotkeys.cpp", + "../src/dllmain.cpp" } includedirs { PSDK_DIR .. "/plugin_vc/",