Posted December 21, 20213 yr _TASK_START_SCENARIO_IN_PLACE works fine at making peds start scenarios. However, some scenarios generate props (brooms, buckets etc) which get left behind when the ped finishes the scenario, eventually leading to prop clutter. Question is, how to script the props / peds / scenarios whatever to clean up the props when the scenario ends? TY My Fallout 4 and Skyrim mods: SAC - LoversLab
December 22, 20213 yr You can use this to make whatever is in the ped's hand disappear before they drop it, I don't know if there's a better way, let me know if you find one :) WEAPON::_HIDE_PED_WEAPONS(myPed, 0, true);
December 29, 20213 yr Author DM-ed the author of Rampage, because Rampage ends the scenarios gracefully, and got this guidance void PlayScenarioFunc(std::string scenario) { Ped PlayerPed = PLAYER::PLAYER_PED_ID(); TASK::CLEAR_PED_TASKS_IMMEDIATELY(PlayerPed, false, false); TASK::TASK_START_SCENARIO_IN_PLACE_HASH(PlayerPed, StringHash(std::move(scenario)), 0, true, 0, 0.0f, false); } To directly abort scenarios use TASK::CLEAR_PED_TASKS_IMMEDIATELY(PLAYER::PLAYER_PED_ID(), false, false); To end the scenario normally use TASK::CLEAR_PED_TASKS(PLAYER::PLAYER_PED_ID(), true, true); Haven't checked it yet, I am busy tracing a game crash (most likely something related to rope physics) My Fallout 4 and Skyrim mods: SAC - LoversLab
December 30, 20213 yr On 12/29/2021 at 4:53 AM, SAC said: DM-ed the author of Rampage, because Rampage ends the scenarios gracefully, and got this guidance void PlayScenarioFunc(std::string scenario) { Ped PlayerPed = PLAYER::PLAYER_PED_ID(); TASK::CLEAR_PED_TASKS_IMMEDIATELY(PlayerPed, false, false); TASK::TASK_START_SCENARIO_IN_PLACE_HASH(PlayerPed, StringHash(std::move(scenario)), 0, true, 0, 0.0f, false); } To directly abort scenarios use TASK::CLEAR_PED_TASKS_IMMEDIATELY(PLAYER::PLAYER_PED_ID(), false, false); To end the scenario normally use TASK::CLEAR_PED_TASKS(PLAYER::PLAYER_PED_ID(), true, true); Haven't checked it yet, I am busy tracing a game crash (most likely something related to rope physics) This is true for the task the npc is executing. I dont know if it will make spawned objects vanish, though.
December 30, 20213 yr Author On 12/30/2021 at 11:35 AM, HughJanus said: This is true for the task the npc is executing. I dont know if it will make spawned objects vanish, though. It doesn't, back to square 1 😕 My Fallout 4 and Skyrim mods: SAC - LoversLab
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.