Jump to content
View in the app

A better way to browse. Learn more.

RDR2Mods.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

cardermartyr

Members
  • Joined

  • Last visited

Everything posted by cardermartyr

  1. Pasted content Of course. Here is a conceptual design and a pseudo-code script in the style of an `.asi` mod (typically written in C++ using the Script Hook RDR2 SDK) that implements an illness system into Red Dead Redemption 2. **Disclaimer:** This is a blueprint and conceptual code. Actual implementation requires deep knowledge of C++, the RDR2 game memory, and the Script Hook RDR2 SDK. It cannot be compiled and run as-is. --- ### **Mod Concept: "The Grim Reality - Sickness" ASI Mod** **Overview:** This mod introduces a realistic and challenging illness system to Red Dead Redemption 2. Players must manage their health, diet, and environment to avoid contracting debilitating diseases that affect core stats, stamina, and can even be fatal. --- ### **1. Core Mechanics & Data Structure** The mod would need to persistently track variables for the player. ```cpp // -- Pseudocode for persistent data structure -- struct PlayerHealthData { // Illness States bool hasScurvy; bool hasConsumption; bool hasTuberculosis; bool hasPneumonia; bool hasSpanishFlu; // Timers and Progress (in-game milliseconds) int scurvyTimer; // Time since last fruit consumed int illnessProgress; // General progress of an active illness (0-100%) int timeSinceInfection; // Timer for illness stages // Environmental Trackers bool isInDampArea; // For Consumption bool isInColdArea; // For Pneumonia bool wasNearSickPerson; // For Spanish Flu & TB int exposureToCrowds; // Counter for time in towns/saloons // Vital Stats (to be manipulated) float originalStaminaCoreRate; float originalHealthCoreRate; }; ``` --- ### **2. Environmental Triggers & Checks** A main loop function running every few game ticks would check the player's status and environment. ```cpp void updateIllnessChecks() { Ped playerPed = PLAYER::PLAYER_PED_ID(); // --- Check Environmental Factors --- // Is player in a cold region? (e.g., Ambarino, cold nights) if (GAMEPLAY::GET_TEMPERATURE_AT_COORDS(playerCoords.x, playerCoords.y, playerCoords.z) < 5.0) { data.isInColdArea = true; } else { data.isInColdArea = false; } // Is player in a damp area? (e.g., swamps, heavy rain, rivers) if (GAMEPLAY::IS_POINT_IN_ANGLED_AREA(/* Check for water volume */) || MISC::GET_RAIN_LEVEL() > 0.5) { data.isInDampArea = true; } else { data.isInDampArea = false; } // Is player near a sick NPC? (Could use proximity to certain ambient event NPCs who cough/sneeze) data.wasNearSickPerson = PED::IS_PED_IN_COMBAT(playerPed); // Placeholder: more complex logic needed // Is player in a crowded town? (St Denis, Valentine, etc.) if (ZONE::GET_ZONE_AT_COORDS(playerCoords) == ZONE_ST_DENIS) { data.exposureToCrowds++; } // --- Check Dietary Factors (Scurvy) --- data.scurvyTimer += elapsedGameTime; // If player eats any fruit (canned or fresh), reset the timer. // This would require hooking into the item consumption event. if (/* Event: Player consumed item "FRUIT" */) { data.scurvyTimer = 0; if (data.hasScurvy) { startRecovery(ILLNESS_SCURVY); // Begin healing if sick } } // If no fruit for 5 in-game days, contract scurvy. if (data.scurvyTimer > (7200000 * 5) && !data.hasScurvy) { // 7200000 ms = 2 game hours contractIllness(ILLNESS_SCURVY); } // --- Trigger Other Illnesses Based on Environment --- // High chance of Pneumonia after prolonged exposure to cold while in poor health if (data.isInColdArea && GET_PLAYER_HEALTH_CORE_LEVEL() < 25 && !data.hasPneumonia) { if (GAMEPLAY::RANDOM_INT(0, 1000) < 5) { // 0.5% chance per check contractIllness(ILLNESS_PNEUMONIA); } } // Consumption triggered by damp environments and poor health if (data.isInDampArea && GET_PLAYER_STAMINA_CORE_LEVEL() < 25 && !data.hasConsumption) { if (GAMEPLAY::RANDOM_INT(0, 1000) < 3) { // 0.3% chance per check contractIllness(ILLNESS_CONSUMPTION); } } // Spanish Flu is rare but very dangerous, triggered by crowds and sick people if (data.exposureToCrowds > 300 && data.wasNearSickPerson && !data.hasSpanishFlu) { // After 5 minutes in a crowd if (GAMEPLAY::RANDOM_INT(0, 10000) < 10) { // 0.1% chance - make it rare and scary contractIllness(ILLNESS_SPANISH_FLU); } } // Update active illnesses updateActiveIllnesses(); } ``` --- ### **3. Contracting an Illness & Effects** This function would start the illness and apply its initial debuffs. ```cpp void contractIllness(IllnessType type) { switch (type) { case ILLNESS_SCURVY: data.hasScurvy = true; data.illnessProgress = 10; // Apply effect: Health core drains 50% faster, slight health drain data.originalHealthCoreRate = GET_CORE_DRAIN_RATE(HEALTH_CORE); SET_CORE_DRAIN_RATE(HEALTH_CORE, data.originalHealthCoreRate * 1.5); UI::_SHOW_HELP_TEXT("You feel weak and your gums are bleeding. You need fresh fruit."); break; case ILLNESS_PNEUMONIA: data.hasPneumonia = true; data.illnessProgress = 20; // Effect: Severe Stamina drain, constant coughing (audio cue), health slowly drains data.originalStaminaCoreRate = GET_CORE_DRAIN_RATE(STAMINA_CORE); SET_CORE_DRAIN_RATE(STAMINA_CORE, data.originalStaminaCoreRate * 3.0); AUDIO::_PLAY_AMBIENT_SOUND_FROM_POSITION("COUGH", playerCoords); // Placeholder UI::_SHOW_HELP_TEXT("Your chest is tight and you struggle to breathe. You have a fever."); break; case ILLNESS_SPANISH_FLU: data.hasSpanishFlu = true; data.illnessProgress = 30; // Effect: MASSIVE health and stamina drain, very high fever (screen effect), high contagion SET_CORE_DRAIN_RATE(HEALTH_CORE, 10.0); // Extremely high drain SET_CORE_DRAIN_RATE(STAMINA_CORE, 8.0); GRAPHICS::_SET_SCREEN_EFFECT("PlayerSwampMode", 500); // Use a feverish screen effect UI::_SHOW_HELP_TEXT("You are burning up with a devastating fever. This is serious."); break; // ... Cases for other illnesses } } ``` --- ### **4. Progression, Recovery, and Death** The `updateActiveIllnesses()` function would handle the progression of diseases. ```cpp void updateActiveIllnesses() { // Example: Spanish Flu progression if (data.hasSpanishFlu) { data.illnessProgress += 1; // Progress gets worse over time // Stage 2: Even worse effects if (data.illnessProgress > 60) { SET_CORE_DRAIN_RATE(HEALTH_CORE, 15.0); } // Death Condition if (data.illnessProgress >= 100 || GET_PLAYER_HEALTH() <= 0) { AI::_SET_DEATH_RESULT(DEATH_BY_ILLNESS); // Placeholder PLAYER::FORCE_PLAYER_DEATH(); // Trigger death cutscene resetIllness(ILLNESS_SPANISH_FLU); // Reset on death } // Very small chance to start recovering if health core is managed perfectly if (data.illnessProgress > 80 && GET_PLAYER_HEALTH_CORE_LEVEL() > 90) { if (GAMEPLAY::RANDOM_INT(0, 10000) < 2) { // 0.02% chance per update startRecovery(ILLNESS_SPANISH_FLU); } } } // Similar logic for other illnesses... } void startRecovery(IllnessType type) { // Slowly reduce illnessProgress back to 0. // Remove debuffs and reset core drain rates to original values. // Set illness bool to false. UI::_SHOW_HELP_TEXT("You finally start to feel like you're recovering."); } ``` --- ### **5. Implementation & .asi Structure** A real `main.cpp` for the `.asi` would look something like this skeleton: ```cpp #include <Windows.h> #include <script.h> // RDR2 Script Hook SDK PlayerHealthData data; void scriptMain() { while (true) { if (PLAYER::IS_PLAYER_PLAYING(PLAYER::PLAYER_ID())) { updateIllnessChecks(); // Run our main function } WAIT(1000); // Wait 1 second (game time) between checks to avoid being too resource heavy } } void initializeMod() { data = PlayerHealthData(); // Initialize our data struct } BOOL APIENTRY DllMain(HMODULE hModule, DWORD ul_reason_for_call, LPVOID lpReserved) { switch (ul_reason_for_call) { case DLL_PROCESS_ATTACH: scriptRegister(hModule, scriptMain); initializeMod(); break; case DLL_PROCESS_DETACH: scriptUnregister(hModule); break; } return TRUE; } ``` This blueprint outlines the complex logic, data tracking, and integration with game systems required for such a mod. A real modder would need to find the correct native functions, memory addresses, and likely create a system to save/load the mod's data to avoid losing progress on illness states when the game is closed. Pasted content Of course. Integrating a doctor visit as a core mechanic for curing these severe illnesses is a fantastic addition. It creates a gold sink, a clear gameplay loop, and reinforces the realism. Here is the improved conceptual design and pseudo-code. --- ### **Mod Concept: "The Grim Reality - Sickness" ASI Mod v2.0** **New Feature:** Illnesses can now be diagnosed and treated by doctors in towns (e.g., Saint Denis, Valentine, Blackwater). Treatment costs money and time, and may involve using specific items prescribed by the doctor. --- ### **1. Expanded Data Structure** We need to track diagnosis, treatment plans, and doctor interactions. ```cpp struct PlayerHealthData { // Illness States bool hasScurvy; bool hasConsumption; // ... other illnesses // Illness Stages (0 = Not diagnosed, 1 = Diagnosed, 2 = In treatment, 3 = Cured/Recovering) int illnessStage_SCURVY; int illnessStage_TUBERCULOSIS; // ... stages for other illnesses // Timers and Progress int illnessProgress; // General severity of the active, *untreated* illness (0-100%) int treatmentTimer; // Time left on current treatment (e.g., medicine duration) int timeSinceLastDoctorVisit; // Cooldown to prevent spam // Environmental Trackers // ... (previous trackers remain) // Doctor & Treatment bool hasMedicine; // Is the player carrying and using prescribed medicine? int medicineEffectiveness; // A counter for how much the medicine has helped // Vital Stats float originalStaminaCoreRate; float originalHealthCoreRate; }; ``` --- ### **2. Doctor Interaction System** A key function to handle the dialogue and transaction with a doctor NPC. ```cpp void interactWithDoctor() { Ped playerPed = PLAYER::PLAYER_PED_ID(); Vector3 playerCoords = ENTITY::GET_ENTITY_COORDS(playerPed, true, 0); // Check if player is near a doctor's office (e.g., in Saint Denis, Valentine) if (ZONE::GET_ZONE_AT_COORDS(playerCoords) == ZONE_ST_DENIS && // Check for town GAMEPLAY::GET_DISTANCE_BETWEEN_COORDS(playerCoords, DOCTOR_ST_DENIS_COORDS, true) < 5.0) { // Check near doctor's door // -- Diagnosis Phase -- UI::_SHOW_SUBTITLE("Doctor: Let's have a look at you...", 5000); WAIT(5000); // Simulate examination time // Check mod's internal illness flags to "diagnose" the player if (data.hasTuberculosis && data.illnessStage_TUBERCULOSIS == 0) { UI::_SHOW_SUBTITLE("Doctor: I'm sorry, son. It's consumption. A nasty business. There's a treatment, but it's costly and won't be easy.", 7000); data.illnessStage_TUBERCULOSIS = 1; // Set to Diagnosed } else if (data.hasScurvy && data.illnessStage_SCURVY == 0) { UI::_SHOW_SUBTITLE("Doctor: Your diet is lacking, my friend. No fresh fruit? It's scurvy. Eat oranges. Plenty of them. That'll be $5 for the advice.", 7000); data.illnessStage_SCURVY = 1; // Diagnosed // Scurvy is "cured" by diet, but you pay for the diagnosis. if (MONEY::_MONEY_DECREMENT_CASH_BALANCE(5)) { data.hasScurvy = false; resetIllnessEffects(ILLNESS_SCURVY); UI::_SHOW_SUBTITLE("Paid $5 to the doctor.", 3000); } } // ... diagnoses for other illnesses // -- Treatment Phase (If diagnosed but not in treatment) -- if (data.illnessStage_TUBERCULOSIS == 1) { // If diagnosed with TB UI::_SHOW_SUBTITLE("Doctor: I can sell you a course of medicine. It will help you manage the symptoms and slow the disease. It's $100.", 7000); // Prompt player to accept (Y/N) if (/* Player presses Y */) { if (MONEY::_MONEY_DECREMENT_CASH_BALANCE(100)) { UI::_SHOW_SUBTITLE("Paid $100. Use the medicine from your kit regularly for the next few days.", 5000); data.illnessStage_TUBERCULOSIS = 2; // Set to "In Treatment" data.hasMedicine = true; data.treatmentTimer = 7200000 * 3; // 3 in-game days worth of treatment data.medicineEffectiveness = 0; // This would also add a specific "Tuberculosis Medicine" item to the player's inventory. } else { UI::_SHOW_SUBTITLE("Doctor: Come back when you can afford it.", 3000); } } } } } ``` --- ### **3. Updated Illness Progression with Treatment** The `updateActiveIllnesses()` function now accounts for treatment. ```cpp void updateActiveIllnesses() { // Example: Tuberculosis Progression with Treatment if (data.hasTuberculosis) { if (data.illnessStage_TUBERCULOSIS < 2) { // If NOT in treatment // Disease progresses normally, faster in damp areas int progressRate = data.isInDampArea ? 2 : 1; data.illnessProgress += progressRate; APPLY_TB_EFFECTS(data.illnessProgress); // Apply cough, core drain, etc. // Death Condition for untreated TB if (data.illnessProgress >= 100) { PLAYER::FORCE_PLAYER_DEATH(); resetIllness(ILLNESS_TUBERCULOSIS); } } else if (data.illnessStage_TUBERCULOSIS == 2) { // If IN treatment // Slow the progression dramatically or halt it data.illnessProgress += 0.1; // Progresses very slowly // If player is using the medicine (e.g., consumes it from inventory) if (data.hasMedicine && data.treatmentTimer > 0) { data.medicineEffectiveness += 2; data.illnessProgress -= 1; // Medicine actively reduces severity data.treatmentTimer -= elapsedTime; // Decrement the treatment timer } // If treatment is completed successfully if (data.medicineEffectiveness > 100) { startRecovery(ILLNESS_TUBERCULOSIS); data.illnessStage_TUBERCULOSIS = 3; // Cured! UI::_SHOW_HELP_TEXT("You have finished your treatment. The disease is in remission."); } // If treatment timer runs out before completion if (data.treatmentTimer <= 0 && data.medicineEffectiveness < 100) { UI::_SHOW_HELP_TEXT("You have run out of medicine. The disease is worsening again."); data.illnessStage_TUBERCULOSIS = 1; // Back to just diagnosed data.hasMedicine = false; } } } // ... logic for other illnesses } ``` --- ### **4. New Helper Functions** ```cpp void startRecovery(IllnessType type) { switch (type) { case ILLNESS_TUBERCULOSIS: data.hasTuberculosis = false; data.illnessProgress = 0; resetIllnessEffects(ILLNESS_TUBERCULOSIS); // Restore core drain rates // Maybe leave a permanent slight debuff to health core as "scarring" SET_CORE_DRAIN_RATE(HEALTH_CORE, data.originalHealthCoreRate * 1.1); break; case ILLNESS_PNEUMONIA: // Pneumonia might be curable with a cheaper, one-time doctor visit break; } } void resetIllnessEffects(IllnessType type) { // General function to reset core drain rates and remove screen effects SET_CORE_DRAIN_RATE(HEALTH_CORE, data.originalHealthCoreRate); SET_CORE_DRAIN_RATE(STAMINA_CORE, data.originalStaminaCoreRate); GRAPHICS::_STOP_ALL_SCREEN_EFFECTS(); } ``` --- ### **5. Key Implementation Notes for a Real Mod** 1. **Native Functions:** Replace placeholders like `MONEY::_MONEY_DECREMENT_CASH_BALANCE` with the actual native functions from the RDR2 SDK (e.g., `MONEY::_MONEY_DECREMENT_CASH_BALANCE` is likely `MONEY::_MONEY_DECREMENT_CASH_BALANCE`). 2. **Inventory Management:** Adding and checking for medicine would require hooking into the game's inventory system, which is complex. A simpler workaround is to use the `data.hasMedicine` flag and a timer, as shown. 3. **Player Prompts:** Implementing a "Press Y to pay" system requires using the game's control states and custom text prompts. 4. **Saving/Loading:** The `PlayerHealthData` struct **must** be saved to a file when the game saves and loaded when the game loads. This is non-negotiable for a mod like this. The Script Hook SDK may provide callbacks for this. 5. **Doctor Coordinates:** You would need to define the precise coordinates (`DOCTOR_ST_DENIS_COORDS`) for each doctor's office in the game world. This expanded design creates a much more engaging and immersive system, turning illness from a mere punishment into a structured gameplay challenge with a clear path to resolution.
  2. Hey so I have another idea for a realism immersion mod; your character can now contrat illnesses! LMK what ya'll think! (details below): Pasted content Of course. Integrating a doctor visit as a core mechanic for curing these severe illnesses is a fantastic addition. It creates a gold sink, a clear gameplay loop, and reinforces the realism. Here is the improved conceptual design and pseudo-code. --- ### **Mod Concept: "The Grim Reality - Sickness" ASI Mod v2.0** **New Feature:** Illnesses can now be diagnosed and treated by doctors in towns (e.g., Saint Denis, Valentine, Blackwater). Treatment costs money and time, and may involve using specific items prescribed by the doctor. --- ### **1. Expanded Data Structure** We need to track diagnosis, treatment plans, and doctor interactions. ```cpp struct PlayerHealthData { // Illness States bool hasScurvy; bool hasConsumption; // ... other illnesses // Illness Stages (0 = Not diagnosed, 1 = Diagnosed, 2 = In treatment, 3 = Cured/Recovering) int illnessStage_SCURVY; int illnessStage_TUBERCULOSIS; // ... stages for other illnesses // Timers and Progress int illnessProgress; // General severity of the active, *untreated* illness (0-100%) int treatmentTimer; // Time left on current treatment (e.g., medicine duration) int timeSinceLastDoctorVisit; // Cooldown to prevent spam // Environmental Trackers // ... (previous trackers remain) // Doctor & Treatment bool hasMedicine; // Is the player carrying and using prescribed medicine? int medicineEffectiveness; // A counter for how much the medicine has helped // Vital Stats float originalStaminaCoreRate; float originalHealthCoreRate; }; ``` --- ### **2. Doctor Interaction System** A key function to handle the dialogue and transaction with a doctor NPC. ```cpp void interactWithDoctor() { Ped playerPed = PLAYER::PLAYER_PED_ID(); Vector3 playerCoords = ENTITY::GET_ENTITY_COORDS(playerPed, true, 0); // Check if player is near a doctor's office (e.g., in Saint Denis, Valentine) if (ZONE::GET_ZONE_AT_COORDS(playerCoords) == ZONE_ST_DENIS && // Check for town GAMEPLAY::GET_DISTANCE_BETWEEN_COORDS(playerCoords, DOCTOR_ST_DENIS_COORDS, true) < 5.0) { // Check near doctor's door // -- Diagnosis Phase -- UI::_SHOW_SUBTITLE("Doctor: Let's have a look at you...", 5000); WAIT(5000); // Simulate examination time // Check mod's internal illness flags to "diagnose" the player if (data.hasTuberculosis && data.illnessStage_TUBERCULOSIS == 0) { UI::_SHOW_SUBTITLE("Doctor: I'm sorry, son. It's consumption. A nasty business. There's a treatment, but it's costly and won't be easy.", 7000); data.illnessStage_TUBERCULOSIS = 1; // Set to Diagnosed } else if (data.hasScurvy && data.illnessStage_SCURVY == 0) { UI::_SHOW_SUBTITLE("Doctor: Your diet is lacking, my friend. No fresh fruit? It's scurvy. Eat oranges. Plenty of them. That'll be $5 for the advice.", 7000); data.illnessStage_SCURVY = 1; // Diagnosed // Scurvy is "cured" by diet, but you pay for the diagnosis. if (MONEY::_MONEY_DECREMENT_CASH_BALANCE(5)) { data.hasScurvy = false; resetIllnessEffects(ILLNESS_SCURVY); UI::_SHOW_SUBTITLE("Paid $5 to the doctor.", 3000); } } // ... diagnoses for other illnesses // -- Treatment Phase (If diagnosed but not in treatment) -- if (data.illnessStage_TUBERCULOSIS == 1) { // If diagnosed with TB UI::_SHOW_SUBTITLE("Doctor: I can sell you a course of medicine. It will help you manage the symptoms and slow the disease. It's $100.", 7000); // Prompt player to accept (Y/N) if (/* Player presses Y */) { if (MONEY::_MONEY_DECREMENT_CASH_BALANCE(100)) { UI::_SHOW_SUBTITLE("Paid $100. Use the medicine from your kit regularly for the next few days.", 5000); data.illnessStage_TUBERCULOSIS = 2; // Set to "In Treatment" data.hasMedicine = true; data.treatmentTimer = 7200000 * 3; // 3 in-game days worth of treatment data.medicineEffectiveness = 0; // This would also add a specific "Tuberculosis Medicine" item to the player's inventory. } else { UI::_SHOW_SUBTITLE("Doctor: Come back when you can afford it.", 3000); } } } } } ``` --- ### **3. Updated Illness Progression with Treatment** The `updateActiveIllnesses()` function now accounts for treatment. ```cpp void updateActiveIllnesses() { // Example: Tuberculosis Progression with Treatment if (data.hasTuberculosis) { if (data.illnessStage_TUBERCULOSIS < 2) { // If NOT in treatment // Disease progresses normally, faster in damp areas int progressRate = data.isInDampArea ? 2 : 1; data.illnessProgress += progressRate; APPLY_TB_EFFECTS(data.illnessProgress); // Apply cough, core drain, etc. // Death Condition for untreated TB if (data.illnessProgress >= 100) { PLAYER::FORCE_PLAYER_DEATH(); resetIllness(ILLNESS_TUBERCULOSIS); } } else if (data.illnessStage_TUBERCULOSIS == 2) { // If IN treatment // Slow the progression dramatically or halt it data.illnessProgress += 0.1; // Progresses very slowly // If player is using the medicine (e.g., consumes it from inventory) if (data.hasMedicine && data.treatmentTimer > 0) { data.medicineEffectiveness += 2; data.illnessProgress -= 1; // Medicine actively reduces severity data.treatmentTimer -= elapsedTime; // Decrement the treatment timer } // If treatment is completed successfully if (data.medicineEffectiveness > 100) { startRecovery(ILLNESS_TUBERCULOSIS); data.illnessStage_TUBERCULOSIS = 3; // Cured! UI::_SHOW_HELP_TEXT("You have finished your treatment. The disease is in remission."); } // If treatment timer runs out before completion if (data.treatmentTimer <= 0 && data.medicineEffectiveness < 100) { UI::_SHOW_HELP_TEXT("You have run out of medicine. The disease is worsening again."); data.illnessStage_TUBERCULOSIS = 1; // Back to just diagnosed data.hasMedicine = false; } } } // ... logic for other illnesses } ``` --- ### **4. New Helper Functions** ```cpp void startRecovery(IllnessType type) { switch (type) { case ILLNESS_TUBERCULOSIS: data.hasTuberculosis = false; data.illnessProgress = 0; resetIllnessEffects(ILLNESS_TUBERCULOSIS); // Restore core drain rates // Maybe leave a permanent slight debuff to health core as "scarring" SET_CORE_DRAIN_RATE(HEALTH_CORE, data.originalHealthCoreRate * 1.1); break; case ILLNESS_PNEUMONIA: // Pneumonia might be curable with a cheaper, one-time doctor visit break; } } void resetIllnessEffects(IllnessType type) { // General function to reset core drain rates and remove screen effects SET_CORE_DRAIN_RATE(HEALTH_CORE, data.originalHealthCoreRate); SET_CORE_DRAIN_RATE(STAMINA_CORE, data.originalStaminaCoreRate); GRAPHICS::_STOP_ALL_SCREEN_EFFECTS(); } ``` --- ### **5. Key Implementation Notes for a Real Mod** 1. **Native Functions:** Replace placeholders like `MONEY::_MONEY_DECREMENT_CASH_BALANCE` with the actual native functions from the RDR2 SDK (e.g., `MONEY::_MONEY_DECREMENT_CASH_BALANCE` is likely `MONEY::_MONEY_DECREMENT_CASH_BALANCE`). 2. **Inventory Management:** Adding and checking for medicine would require hooking into the game's inventory system, which is complex. A simpler workaround is to use the `data.hasMedicine` flag and a timer, as shown. 3. **Player Prompts:** Implementing a "Press Y to pay" system requires using the game's control states and custom text prompts. 4. **Saving/Loading:** The `PlayerHealthData` struct **must** be saved to a file when the game saves and loaded when the game loads. This is non-negotiable for a mod like this. The Script Hook SDK may provide callbacks for this. 5. **Doctor Coordinates:** You would need to define the precise coordinates (`DOCTOR_ST_DENIS_COORDS`) for each doctor's office in the game world. This expanded design creates a much more engaging and immersive system, turning illness from a mere punishment into a structured gameplay challenge with a clear path to resolution.
  3. So I am seriously a noob at modding, and I only have a basic template for what I'm trying to accomplish. I'm hoping that somebody with the wherewithal to make this happen also sees my point of adding realism to the game. Essentially I have a skeleton of the project, but frankly I need somebody who knows what the hell they're doing to help! I really think this mod would augment wonderfully into the needs mod for far more challenging and realistic survival! Perishable Foods.cpp Perishable Foods.ini

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.