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.

HELP ME! I'm not able to identify the negative responses from the ped.

Featured Replies

Hi, I'm Brazilian, I'm a beginner in programming and I don't have money to take a fullstacks programming course. I'm using ChatGPT to do between 70 and 80% of the code, so don't judge me.

 

My problem is that I'm using "NATIVE_DECL BOOL GET_IS_PED_RESPONDING_TO_NEGATIVE_INTERACTION(Ped ped, Player player) { return invoke<BOOL>(0xA454D234E45BB6E5, ped, player); } // 0xA454D234E45BB6E5 b1207" to identify the interactions of the peds with the player, but I couldn't identify the interactions. I don't know why, but I've tried everything. If someone can help me, I would be very grateful.

 

// Function to detect if the interaction between the player and the Ped is negative
bool detectNegativeInteraction(Ped playerPed, Ped ped) {
PRINT_INFO("Checking interaction for Ped ID: " + std::to_string(ped));

// Additional debugging: Checking ped model and type
Hash pedModel = ENTITY::GET_ENTITY_MODEL(ped);
PRINT_INFO("Ped ID model: " + std::to_string(ped) + " is: " + std::to_string(pedModel));

int pedType = PED::GET_PED_TYPE(ped);
PRINT_INFO("Ped ID type: " + std::to_string(ped) + " is: " + std::to_string(pedType));

// Status checks
if (PED::IS_PED_IN_COMBAT(ped, playerPed)) {
PRINT_INFO("Ped ID: " + std::to_string(ped) + " is in combat with the player.");
return true;
}
if (PED::IS_PED_IN_ANY_VEHICLE(ped, false)) {
PRINT_INFO("Ped ID: " + std::to_string(ped) + " is in a vehicle.");
return false;
}
if (TASK::_GET_PED_USING_SCENARIO_POINT(ped)) {
PRINT_INFO("Ped ID: " + std::to_string(ped) + " is using a scenario.");
return false; }

// Check if it is responding to negative interactions
BOOL isRespondingNegative = invoke<BOOL>(0xA454D234E45BB6E5, ped, playerPed);
if (isRespondingNegative) {
PRINT_INFO("Ped ID: " + std::to_string(ped) + " is responding negatively.");
return true;
}

// Fallback when there is no recognized interaction
PRINT_WARN("Ped ID: " + std::to_string(ped) + " is not responding to positive or negative interactions.");
return false;
}

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

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.