Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ concurrency:

jobs:
ci:
runs-on: windows-latest
runs-on: windows-2022
name: CI
steps:
- uses: actions/checkout@v4
Expand All @@ -28,7 +28,7 @@ jobs:
arch: amd64

- name: Generate CMake project
run: cmake -D CMAKE_BUILD_TYPE=RelWithDebInfo -D OPTIMIZE=YES -S. -Bbuild -G Ninja
run: cmake -D CMAKE_BUILD_TYPE=RelWithDebInfo -D OPTIMIZE=YES -D CMAKE_POLICY_VERSION_MINIMUM=3.5 -S. -Bbuild -G Ninja

- name: Build 64bit release DLL
run: cmake --build ./build --config RelWithDebInfo --target YimMenu --
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
fi

build_nightly:
runs-on: windows-latest
runs-on: windows-2022
name: Build Nightly
needs: check_recent_commit
if: needs.check_recent_commit.outputs.should_run == 'true'
Expand All @@ -50,7 +50,7 @@ jobs:
arch: amd64

- name: Generate CMake project
run: cmake -D CMAKE_BUILD_TYPE=RelWithDebInfo -D OPTIMIZE=YES -S. -Bbuild -G Ninja
run: cmake -D CMAKE_BUILD_TYPE=RelWithDebInfo -D OPTIMIZE=YES -D CMAKE_POLICY_VERSION_MINIMUM=3.5 -S. -Bbuild -G Ninja

- name: Build 64bit release DLL
run: cmake --build ./build --config RelWithDebInfo --target YimMenu --
Expand Down
14 changes: 10 additions & 4 deletions cmake/gtav-classes.cmake
Original file line number Diff line number Diff line change
@@ -1,8 +1,14 @@
include(FetchContent)
message(STATUS "Fetching GTAV-Classes (Build_3751.0)")

FetchContent_Declare(
gtav_classes
GIT_REPOSITORY https://github.com/Hexlane/GTAV-Classes-1.git
GIT_TAG Build_3751.0
GIT_REPOSITORY https://github.com/Pyxalon/GTAV-Classes-1.git
GIT_TAG b3889
GIT_PROGRESS TRUE
CONFIGURE_COMMAND ""
BUILD_COMMAND ""
)
FetchContent_MakeAvailable(gtav_classes)
message("GTAV-Classes")
if(NOT gtav_classes_POPULATED)
FetchContent_Populate(gtav_classes)
endif()
9 changes: 3 additions & 6 deletions cmake/json.cmake
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
include(FetchContent)

set(JSON_MultipleHeaders OFF)

FetchContent_Declare(
json
GIT_REPOSITORY https://github.com/ArthurSonzogni/nlohmann_json_cmake_fetchcontent.git
GIT_TAG 67e6070f9d9a44b4dec79ebe6b591f39d2285593
GIT_PROGRESS TRUE
URL https://github.com/nlohmann/json/releases/download/v3.12.0/json.tar.xz
DOWNLOAD_EXTRACT_TIMESTAMP TRUE
)
message("json")
option(JSON_MultipleHeaders "Disable nlohmann JSON multi header default." OFF)
FetchContent_MakeAvailable(json)
4 changes: 2 additions & 2 deletions cmake/minhook.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ include(FetchContent)

FetchContent_Declare(
minhook
GIT_REPOSITORY https://github.com/YimMenu/minhook.git
GIT_TAG 902ab63e0a771547961e132ccc0700d62e2a1423
GIT_REPOSITORY https://github.com/TsudaKageyu/minhook.git
GIT_TAG 2b003bb063d66f016cc1aef7d63951350ce60f35
GIT_PROGRESS TRUE
)
message("MinHook")
Expand Down
2 changes: 1 addition & 1 deletion cmake/pugixml.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ include(FetchContent)
FetchContent_Declare(
pugixml
GIT_REPOSITORY https://github.com/zeux/pugixml.git
GIT_TAG a0e064336317c9347a91224112af9933598714e9
GIT_TAG 27b68329de32cf9c601ca8eb6c588fd639960c40
GIT_PROGRESS TRUE
)
message("pugixml")
Expand Down
68 changes: 34 additions & 34 deletions src/backend/commands/player/misc/enter_interior.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,44 +8,44 @@
namespace big
{
class enter_interior : player_command
{
using player_command::player_command;

virtual void execute(player_ptr player, const command_arguments& _args, const std::shared_ptr<command_context> ctx) override
{
int id = player->id();
if (scr_globals::gpbd_fm_1.as<GPBD_FM*>()->Entries[id].PropertyData.Index != -1)
{
const size_t arg_count = 10;
int64_t args[arg_count] = {(int64_t)eRemoteEvent::Teleport,
self::id,
1 << self::id,
(int64_t)player->id(),
(int64_t)(int)-1,
1,
(int64_t)scr_globals::gpbd_fm_1.as<GPBD_FM*>()->Entries[id].PropertyData.Index,
1,
0,
1};
using player_command::player_command;

g_pointers->m_gta.m_trigger_script_event(1, args, arg_count, 1 << self::id, (int)eRemoteEvent::Teleport);
}
else if (scr_globals::globalplayer_bd.as<GlobalPlayerBD*>()->Entries[id].SimpleInteriorData.Index != eSimpleInteriorIndex::SIMPLE_INTERIOR_INVALID)
virtual void execute(player_ptr player, const command_arguments& _args, const std::shared_ptr<command_context> ctx) override
{
*scr_globals::interiors.at(3891).as<Player*>() =
scr_globals::globalplayer_bd.as<GlobalPlayerBD*>()->Entries[id].SimpleInteriorData.Owner;
*scr_globals::interiors.at(4248).as<eSimpleInteriorIndex*>() =
scr_globals::globalplayer_bd.as<GlobalPlayerBD*>()->Entries[id].SimpleInteriorData.Index;
*scr_globals::interiors.at(4247).as<bool*>() = true;
scr_globals::globalplayer_bd.as<GlobalPlayerBD*>()->Entries[self::id].SimpleInteriorData.InteriorSubtype =
scr_globals::globalplayer_bd.as<GlobalPlayerBD*>()->Entries[id].SimpleInteriorData.InteriorSubtype;
}
else
{
ctx->report_error("BACKEND_ENTER_INTERIOR_NOT_IN_INTERIOR"_T.data());
int id = player->id();
if (scr_globals::gpbd_fm_1.as<GPBD_FM*>()->Entries[id].PropertyData.Index != -1)
{
const size_t arg_count = 10;
int64_t args[arg_count] = {(int64_t)eRemoteEvent::Teleport,
self::id,
1 << self::id,
(int64_t)player->id(),
(int64_t)(int)-1,
1,
(int64_t)scr_globals::gpbd_fm_1.as<GPBD_FM*>()->Entries[id].PropertyData.Index,
1,
0,
1};

g_pointers->m_gta.m_trigger_script_event(1, args, arg_count, 1 << self::id, (int)eRemoteEvent::Teleport);
}
else if (scr_globals::globalplayer_bd.as<GlobalPlayerBD*>()->Entries[id].SimpleInteriorData.Index != eSimpleInteriorIndex::SIMPLE_INTERIOR_INVALID)
{
*scr_globals::interiors.at(3892).as<Player*>() =
scr_globals::globalplayer_bd.as<GlobalPlayerBD*>()->Entries[id].SimpleInteriorData.Owner;
*scr_globals::interiors.at(4249).as<eSimpleInteriorIndex*>() =
scr_globals::globalplayer_bd.as<GlobalPlayerBD*>()->Entries[id].SimpleInteriorData.Index;
*scr_globals::interiors.at(4248).as<bool*>() = true;
scr_globals::globalplayer_bd.as<GlobalPlayerBD*>()->Entries[self::id].SimpleInteriorData.InteriorSubtype =
scr_globals::globalplayer_bd.as<GlobalPlayerBD*>()->Entries[id].SimpleInteriorData.InteriorSubtype;
}
else
{
ctx->report_error("BACKEND_ENTER_INTERIOR_NOT_IN_INTERIOR"_T.data());
}
}
}
};
};

enter_interior g_enter_interior("enterint", "ENTER_INTERIOR", "ENTER_INTERIOR_DESC", 0, false);
}
16 changes: 16 additions & 0 deletions src/core/data/all_script_names.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,11 @@ namespace big
"fm_content_survival_grouping"_J,
"fm_content_valentine_cheater"_J,
"fm_content_survival"_J,
"fm_content_kortz_scoping"_J,
"fm_content_kortz_entry"_J,
"fm_content_kortz_equipment"_J,
"fm_content_kortz_disruption"_J,
"fm_content_kortz_task"_J,
"AM_BOAT_TAXI"_J,
"AM_HELI_TAXI"_J,
"fm_hold_up_tut"_J,
Expand Down Expand Up @@ -401,6 +406,7 @@ namespace big
"am_mp_island",
"am_mp_juggalo_hideout",
"am_mp_mansion",
"am_mp_mansion_art_workshop",
"am_mp_mansion_driveway",
"am_mp_mansion_garage",
"am_mp_multistorey_garage",
Expand Down Expand Up @@ -712,6 +718,7 @@ namespace big
"flow_help",
"flyunderbridges",
"fmmc_contentquicklauncher",
"fmmc_lasers",
"fmmc_launcher",
"fmmc_playlist_controller",
"fm_bj_race_controler",
Expand Down Expand Up @@ -768,6 +775,11 @@ namespace big
"fm_content_hsw_time_trial",
"fm_content_island_dj",
"fm_content_island_heist",
"fm_content_kortz_disruption",
"fm_content_kortz_entry",
"fm_content_kortz_equipment",
"fm_content_kortz_scoping",
"fm_content_kortz_task",
"fm_content_metal_detector",
"fm_content_movie_props",
"fm_content_mp_intro",
Expand Down Expand Up @@ -827,6 +839,7 @@ namespace big
"fm_main_menu",
"fm_mission_controller",
"fm_mission_controller_2020",
"fm_mission_controller_v3",
"fm_mission_creator",
"fm_race_controler",
"fm_race_creator",
Expand Down Expand Up @@ -991,6 +1004,7 @@ namespace big
"josh4",
"juggalo_hideout_carmod",
"juggalo_hideout_seating",
"kortz_planning",
"lamar1",
"landing_pre_startup",
"laptop_trigger",
Expand Down Expand Up @@ -1040,6 +1054,7 @@ namespace big
"maintransition",
"main_install",
"main_persistent",
"mansion_art_workshop_seating",
"mansion_basement_seating",
"mansion_carmod",
"mansion_club_bar",
Expand Down Expand Up @@ -1093,6 +1108,7 @@ namespace big
"mp_registration",
"mp_save_game_global_block",
"mp_skycam_stuck_wiggler",
"mp_strand_f9",
"mp_unlocks",
"mp_weapons",
"mrsphilips1",
Expand Down
2 changes: 1 addition & 1 deletion src/core/data/stack_sizes.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ namespace big
{"INGAMEHUD", 4600},
{"TRANSITION", 8032},
{"FMMC_LAUNCHER", 28000},
{"MULTIPLAYER_FREEMODE", 89500},
{"MULTIPLAYER_FREEMODE", 92500},
{"MISSION", 64500},
{"MP_LAUNCH_SCRIPT", 35250},
};
Expand Down
77 changes: 38 additions & 39 deletions src/core/scr_globals.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,102 +4,101 @@

namespace big::scr_globals
{
static inline const script_global gsbd(2649159);
static inline const script_global gsbd_kicking(1877125);
static inline const script_global gsbd_fm_events(1922477);
static inline const script_global gsbd(2649161);
static inline const script_global gsbd_kicking(1877205);
static inline const script_global gsbd_fm_events(1922845);

static inline const script_global globalplayer_bd(2658291);
static inline const script_global gpbd_fm_3(1892653);
static inline const script_global globalplayer_bd(2658293);
static inline const script_global gpbd_fm_3(1892925);
static inline const script_global gpbd_fm_1(1845298);
static inline const script_global interiors(1950702);

static inline const script_global gpbd_fm_1(1845250);
static inline const script_global interiors(1950198);

static inline const script_global launcher_global(2699984);
static inline const script_global launcher_global(2700095);

// creator globals usually remain the same after updates
static inline const script_global terminate_creator(1574607); // NETWORK::NETWORK_BAIL(1, 0, 0); fm_*_creator
static inline const script_global switch_struct(1574634);
static inline const script_global switch_struct(1574635);
static inline const script_global mission_creator_radar_follows_camera(2621443);
static inline const script_global mission_creator_exited(1574530);

static inline const script_global transition_state(1575018);
static inline const script_global sctv_spectator(2698539); // pausemenu_multiplayer function 0xE49C42EC
static inline const script_global transition_state(1575022);
static inline const script_global sctv_spectator(2698647); // pausemenu_multiplayer function 0xE49C42EC

static inline const script_global vehicle_global(1583765);
static inline const script_global vehicle_global(1583771);

static inline const script_global freemode_properties(2673271);
static inline const script_global freemode_global(2733002);
static inline const script_global freemode_properties(2673273);
static inline const script_global freemode_global(2733190);

static inline const script_global spawn_global(2697006);
static inline const script_global spawn_global(2697114);

static inline const script_global transaction_overlimit(4516902);
static inline const script_global transaction_overlimit(4516981);

static inline const script_global stats(2359296);

static inline const script_global session(1574589);
static inline const script_global session2(1575042);
static inline const script_global session3(33776);
static inline const script_global session4(2686090);
static inline const script_global session5(1575017);
static inline const script_global session6(2696922); // freemode -> if (NETWORK::NETWORK_IS_GAME_IN_PROGRESS() && !NETWORK::NETWORK_IS_ACTIVITY_SESSION())
static inline const script_global session2(1575046);
static inline const script_global session3(33816);
static inline const script_global session4(1574944);
static inline const script_global session5(1575021);
static inline const script_global session6(2697030); // freemode -> if (NETWORK::NETWORK_IS_GAME_IN_PROGRESS() && !NETWORK::NETWORK_IS_ACTIVITY_SESSION())

static inline const script_global interaction_menu_access(2711261); // am_pi_menu -> if (NETWORK::NETWORK_IS_SIGNED_ONLINE()) first global after that
static inline const script_global interaction_menu_access(2712187); // am_pi_menu -> if (NETWORK::NETWORK_IS_SIGNED_ONLINE()) first global after that

static inline const script_global disable_wasted_sound(2708893); // freemode -> AUDIO::PLAY_SOUND_FRONTEND(-1, "Wasted", "POWER_PLAY_General_Soundset", true);
static inline const script_global disable_wasted_sound(2709004); // freemode -> AUDIO::PLAY_SOUND_FRONTEND(-1, "Wasted", "POWER_PLAY_General_Soundset", true);

static inline const script_global passive(1574582); // if (((!PED::IS_PED_IN_ANY_VEHICLE(PLAYER::GET_PLAYER_PED(bVar1), false) || Global_

static inline const script_global property_garage(1944263);
static inline const script_global property_garage(1944657);
static inline const script_global property_names(1312440);

static inline const script_global reset_clothing(105008); // freemode 75, &iLocal_.*, 2\);
static inline const script_global reset_clothing(105065); // freemode 75, &iLocal_.*, 2\);

static inline const script_global gun_van(1956819); // return -29.532f, 6435.136f, 31.162f;
static inline const script_global gun_van(1957326); // return -29.532f, 6435.136f, 31.162f;

static inline const script_global disable_phone(21593);
static inline const script_global disable_phone(21632);

static inline const script_global should_reset_fm_weapons(1576473);
static inline const script_global should_reset_fm_weapons(1576478);
}

namespace big::scr_locals
{
namespace am_hunt_the_beast
{
constexpr static auto broadcast_idx = 624; // (bParam0) != 0;
constexpr static auto player_broadcast_idx = 2608; // if (NETWORK::PARTICIPANT_ID_TO_INT() != -1)
constexpr static auto broadcast_idx = 633; // (bParam0) != 0;
constexpr static auto player_broadcast_idx = 2617; // if (NETWORK::PARTICIPANT_ID_TO_INT() != -1)
}

namespace am_criminal_damage
{
constexpr static auto broadcast_idx = 119; // /* Tunable: CRIMINAL_DAMAGE_DISABLE_SHARE_CASH */)
constexpr static auto score_idx = 114; // AUDIO::PLAY_SOUND_FRONTEND(-1, "Criminal_Damage_High_Value", "GTAO_FM_Events_Soundset", false);
constexpr static auto broadcast_idx = 144; // /* Tunable: CRIMINAL_DAMAGE_DISABLE_SHARE_CASH */)
constexpr static auto score_idx = 139; // AUDIO::PLAY_SOUND_FRONTEND(-1, "Criminal_Damage_High_Value", "GTAO_FM_Events_Soundset", false);
}

namespace am_cp_collection
{
constexpr static auto broadcast_idx = 824; // bVar1 = NETWORK::NETWORK_GET_PLAYER_INDEX(PLAYER::INT_TO_PARTICIPANTINDEX(iVar0));
constexpr static auto player_broadcast_idx = 3465; // bVar1 = NETWORK::NETWORK_GET_PLAYER_INDEX(PLAYER::INT_TO_PARTICIPANTINDEX(iVar0));
constexpr static auto broadcast_idx = 849; // bVar1 = NETWORK::NETWORK_GET_PLAYER_INDEX(PLAYER::INT_TO_PARTICIPANTINDEX(iVar0));
constexpr static auto player_broadcast_idx = 3490; // bVar1 = NETWORK::NETWORK_GET_PLAYER_INDEX(PLAYER::INT_TO_PARTICIPANTINDEX(iVar0));
}

namespace am_king_of_the_castle
{
constexpr static auto broadcast_idx = 102; // KING_OF_THE_CASTLE_EVENT_TIME_LIMIT
constexpr static auto broadcast_idx = 127; // KING_OF_THE_CASTLE_EVENT_TIME_LIMIT
}

namespace fmmc_launcher
{
constexpr static auto broadcast_idx = 12827; // if (NETWORK::NETWORK_IS_PLAYER_ACTIVE(PLAYER::INT_TO_PLAYERINDEX(Global_
constexpr static auto broadcast_idx = 12988; // if (NETWORK::NETWORK_IS_PLAYER_ACTIVE(PLAYER::INT_TO_PLAYERINDEX(Global_
}

namespace fm_mission_controller
{
constexpr static auto mission_controller_wanted_state_flags = 60892; // if (PLAYER::GET_PLAYER_WANTED_LEVEL(bLocal_
constexpr static auto mission_controller_wanted_state_flags = 61913; // if (PLAYER::GET_PLAYER_WANTED_LEVEL(bLocal_
}

namespace freemode
{
// first uLocal_ in this function call
// func_\d+\((&.Local_\d+(, )?){9}\);
inline static script_local mobile(19361);
inline static script_local mobile(19586);
}
}
Loading
Loading