Everything posted by SAC
-
Adding ambient peds
BTW, it is this easy to mess up ambientpeds and the effect of a single error is empty towns everywhere, like you are experiencing <Item type="CAmbientModelSet"> <Name>VAL_PROSTITUTES</Name> <Models> <Name>A_F_M_VALPROSTITUTE_01</Name> <Variations type="NULL" /> <Probability value="1.000000" /> <TimeOfDay /> <InventoryInfoHash /> </Item> </Models> <SpawnDistance value="100.000000" /> <AIMemoryGroup>VALENTINE_RESIDENTS</AIMemoryGroup> </Item> Notice the error? validatexml detects this type of error, but, for example, it would not detect any error it if I were missing the </Item> too. However, the game would probably break. This is why it's essential to validate the xml continuously, be careful, test each incremental change, keep backups etc - proper modding discipline. The methodology works, you need to execute properly.
-
Adding ambient peds
It is done exactly as explained a long number of times to you, both on DM and on Discord. Suggest experimenting with it until you get it right, then coming back and pay it forward by explaining how you have achieved it. You have all the information you need, you just need to apply it in an orderly and progressive manner.
-
Need help tracing scripting issue (player paralyzed walking in place)
I am trying to track down a random issue manifesting as the PC, and other NPCs around, including horses, suddenly get stuck walking in place and sometimes spinning first person camera. I have added countless traces and conditions into the code I am working on, I get no trace of any function such as "CLEAR_PED_TASKS_IMMEDIATELY" running on the player. So, I don't really know if it's my code, or some of the other mods I am using - sure there's the option of taking ASIs out until the problem stops manifesting, but it's very random and very tedious. So: - have you ever encountered a bug where the player and/or the NPCs around, including horses, get stuck walking on the spot without advancing? - does this sound like the effect of which native? - ever had the player suddenly sinking through the ground and falling into a void? (had this too) - any idea about the task ids below, and which native would trigger which? left is normal player behavior, right is player paralyzed TY!
-
Barefoot NPCs
DM me: - the modded ambientgangs file - ModManager.log, vfs.log (from the RDR2 root directory)
-
Barefoot NPCs
No, it goes into lml\PedExpressBySAC\PedExpress after you unpack the mod I've provided you above, however... of course it would conflict, Ambient gangs introduces new models and updates the sandboxing by updating the same file. So, in this case, forget PedExpress and modify the ambient gangs file direcly (which, if I read it right, should be in \lml\Ambient Gang - RDR1 Gang). This way you are effectively creating what we've called a "merged patch" in FO4/Skyrim, i.e. two mods coexisting even though they affect the same file. Backup the AG file in advance, keep in mind that updating Ambient gangs will overwrite your modded file, so back it up while you work on it. You can use https://www.xmlvalidation.com/ to make sure you are not introducing errors - upload the file after you mod it and it will tell you if you have structural issues.
-
SAC various quality of life utilities
New in 1.0.4 introduced a minimum sandboxing interval per ped, should help improve performance fixed auto-spawn chances overall logic optimization to minimize inefficient validations and help performance improvement slightly updated sandbox scenario list, eliminated scenarios which require props such as seats pariah events have their own dedicated ini settings (enable, minimum recurrence interval, chance of occurring)
-
Barefoot NPCs
This it the item (model) you want to insert. Notice it starts with <Item>, closes with </Item> ( / is for closing) and inserts what between them. Where you add it is up to your own testing, what I've posted is some examples of proper placing where it would have a noticeable impact.
-
Barefoot NPCs
Yes, I did some changes and was asking if it feels more balanced now. I think I'll add in the bunch of quasi-hillbillies from Rhodes. Install the mod I've attached earlier, edit ambientpedmodelsets.meta, search for "val_", find the relevant female Valentine Town model sets, add the rough traveler, see if they spawn and sandbox <Item type="CAmbientModelSet"> <Name>VAL_TOWN_FEMALE_FANCY</Name> <Models> <Item> <Name>A_F_M_ValTownfolk_01</Name> <Variations type="NULL" /> <Probability value="1.000000" /> <TimeOfDay /> <InventoryInfoHash /> </Item> <!-- ^^ this is the original entry --> <Item> <Name>a_f_m_roughtravellers_01</Name> <Variations type="NULL" /> <Probability value="1.000000" /> <TimeOfDay /> <InventoryInfoHash /> </Item> <!-- ^^ this is added --> </Models> <SpawnDistance value="100.000000" /> <AIMemoryGroup>VALENTINE_RESIDENTS</AIMemoryGroup> </Item> <!-- ... --> <Item type="CAmbientModelSet"> <Name>VAL_TOWN_FEMALE_POOR</Name> <Models> <Item> <!-- SAC --> <Name>a_f_m_roughtravellers_01</Name> <Variations type="NULL" /> <Probability value="1.000000" /> <TimeOfDay /> <InventoryInfoHash /> </Item> <Item> <Name>A_F_M_ValTownfolk_01</Name> <Variations type="NULL" /> <Probability value="1.000000" /> <TimeOfDay /> <InventoryInfoHash /> </Item> </Models> <SpawnDistance value="100.000000" /> <AIMemoryGroup>VALENTINE_RESIDENTS</AIMemoryGroup> </Item> <!-- ... other relevant model sets -->
-
Barefoot NPCs
Please test these (overwrite the initial ones) and let me know if they provide a better balance for males in Valentine (it's a balance test for males that I've done for Valentine only for the moment). a_m_m_valtownfolk_02.ymt a_m_m_valfarmer_01.ymt a_m_m_vallaborer_01.ymt a_m_m_valtownfolk_01.ymt
-
Barefoot NPCs
Failing is part of the process. I've failed dozens (hundreds) of attempts to do various stuff, depending of the complexity, a lot of which due to the fact we are doing this partially in blind for lack of documentation, another lot due to sheer incompetence until I've learnt better. You cannot do permanent damage (the game saves are not persistent enough to do so), just give it a shot, see what happens. Worst case scenario, you delete the mod. (btw, speaking of failing, my example above is failed due to the fact females, or at least NPC females don't seem to have animations for piano playing, meaning they just stand around the piano with a blank look on their faces... oh well, notch another fail)
-
Placing a ped at a location
Because I needed precise positioning and I kept getting random glitches (NPCs being strung off-position), I've ended up using a loop to attempt multiple placements until the position is confirmed PED::SET_BLOCKING_OF_NON_TEMPORARY_EVENTS(victim, true); int position_i = 0; float trapdoor_distance = 10; Vector3 victim_pos; Vector3 trapdoor_pos; trapdoor_pos = nooseSpot->getTrapdoorPosition(); while (position_i < 10 && trapdoor_distance > 1) { ENTITY::_SET_ENTITY_COORDS_AND_HEADING_NO_OFFSET(victim, nooseSpot->getAnchorPosition().x, nooseSpot->getAnchorPosition().y, nooseSpot->getAnchorPosition().z - 0.5, requested_gallow->noosedPedHeading, true, true); WAIT(500); victim_pos = ENTITY::GET_ENTITY_COORDS(victim, 1, 0); trapdoor_distance = GAMEPLAY::GET_DISTANCE_BETWEEN_COORDS(victim_pos.x, victim_pos.y, victim_pos.z, trapdoor_pos.x, trapdoor_pos.y, trapdoor_pos.z, 1); position_i = position_i + 1; // WAIT(0); // must have a wait in while loops } SAC_appendLineToFile("sac_rdr2_log.txt", "autogallows - check 3, required " + to_string(position_i) + " positioning iterations, distance to trapdoor is " + to_string(trapdoor_distance)); Sometimes it works straight up, sometimes it takes a number of tries - these are the results for 4 different NPCs being placed sequentially, note that 3 out of 4 were placed at the first try, however the 4th required 3 cycles to position correctly (which are the glitches I've seen happening in-game as well) autogallows - check 3, required 1 positioning iterations, distance to trapdoor is 0.830377 autogallows - check 3, required 1 positioning iterations, distance to trapdoor is 0.851509 autogallows - check 3, required 1 positioning iterations, distance to trapdoor is 0.579172 autogallows - check 3, required 3 positioning iterations, distance to trapdoor is 0.788400 <!-- later edit --> autogallows - check 3, required 3 positioning iterations, distance to trapdoor is 0.831077 autogallows - check 3, required 4 positioning iterations, distance to trapdoor is 0.632743 autogallows - check 3, required 1 positioning iterations, distance to trapdoor is 0.829728 autogallows - check 3, required 1 positioning iterations, distance to trapdoor is 0.794881 LE: added more attempts demonstrating some of the NPCs take multiple iterations to position correctly
-
Dead body persistence
Thank you, persistence_Constance.meta looks interesting, I'll have to test
-
Barefoot NPCs
I'm not sure about riding horses, has not been a focus for me. There is this ambientpedmodelsets.metafile where you can specify which models go into which "ambient model set" which is linked to a specific set of sandboxing scenarios. For example, I have added "abs" (Annesburg) females (the mining town) to be eligible piano players in Valentine. Which makes no sense until you factor in my other mod which spawns various females (including "abs") around the player, so you eventually do get "abs" females into Valentine and I want them to be able to sandbox as much as possible. <Item type="CAmbientModelSet"> <Name>VAL_PIANO_PLAYER</Name> <Models> <Item> <!-- SAC --> <Name>a_f_m_asbtownfolk_01</Name> <Variations type="NULL" /> <Probability value="1.000000" /> <TimeOfDay /> <InventoryInfoHash /> </Item> You can play with the file and use this barebone LML mod to get it into the game: PedExpressBySAC.rar (replace the payload file with your modded one). Search for <!-- SAC --> to see where I made additions, for now I am testing Valentine only to figure out how the system works). Please note that adding models into model sets also makes those models eligible spawns - in this case, you will get Annesburg females spawning as piano players in Valentine, not just sandboxing just in case they are there. Which is something I wish I knew before messing with the ymts to mix up population, but this feature is something I've learnt a few days ago. This does not mean females will be able to perform all the male scenarios (far from it) because there are no female animations for that scenario - e.g. you cannot make females carry timber because there is no female animation for that, only male. I don't have a solution for that, I've tried making a female model to use a male skeleton but that did not go pretty. But some activities are accessible, I'm sure I've seen females driving carts around Valentine - riding, I don't know, haven't seen them, but that can also mean I need to add them into a different "model set" (e.g. "cowboys", Idk) Give me some examples of what you mean by "models". Due to reasons that escape me, RDR uses different skeletons for the unique characters, which means that haircuts or clothes that fit unique characters cannot be worn by vanilla NPC skeletons. This is also why the player cannot wear NPC clothes, mismatched skeletons. But mashing up some models can be achieved the same way I did this mod, as long as the skeletons are compatible.
-
Barefoot NPCs
Correct Partially There is, but not an easy one. Each of the main ymts (a_x_m_xxx_towfolk, laborers and some others) contain around 30-50 models each, in vanilla, plus those added by me (the ones you are seeing as "new"). I need to go through each of the lists and remove some in order to rebalance. Not easy, not fast. On top of that, the game seems to have a weird (or unknown to me) randomization engine. Meaning if you have two sets of models in an ymt (vanilla plus others added), if they are not interlaced in the files (and they aren't) it will pick a number of random NPCs from one "block", then switch to the other and pick another number of randoms. It doesn't seem to do real randomization, or at least I don't understand the methodology. So yeah, whenever I get the time and the disposition I take one of the population files and go through each model, remove some, clone some, mashup some others, but there is no set calendar.
-
Barefoot NPCs
- 1,131 downloads
- Version 1.0.0
Makes a lot of low class NPCs barefoot + introduces a number of personal mash-ups and population diversity. 1. The vast majority of the low-mid class NPCs are barefoot, especially females 2. Mixes a number of population models (e.g. you will get Guarma natives or hillbilly females spawning in Valentine) 3. Introduces a number of personal mash-ups to the general population Installation: requires LML. Unpack in \lml\stream, no need for an installer. Be aware of overwriting any other modded model lists you might have installed (if any). Aspects to consider: 1. There will be clipping 2. There will be occasional gaps between clothing / body parts 3. There will be skin tone mismatches 4. I have removed a number of vanilla models which I've found particularly unattractive and added a number of variants for the ones I liked 5. This is an ongoing project with probably no end in sight, I am going to release updates for as long as I have patience to go through the models, it is a very tedious piece of work Recommend using together with ... for that extra grubby look -
SAC various quality of life utilities
What's New in Version 1.0.3 See changelog - fixed a coding error causing the scenarios and scenario points to not trigger for NPC sandboxing - more safeguards implemented to prevent possible crashes when (auto-)spawning new peds Can use the ini from 1.0.2 if previously downloaded / configured, no new ini controls have been added in 1.0.3
-
SAC various quality of life utilities
What's New in Version 1.0.2 See changelog - (important) fixed a potential crash when calling "lobotomize" on the same ped twice, please make sure to update the mod if you have downloaded the previous version - added ini toggle for previously un-documented "mute player" function - added ini toggle for previously un-documented "flee horse" function
-
Placing a ped at a location
Thank you, seems to work fine. Actually, SET_ENTITY_COORDS seems to work too, but only sometimes. Anyway, will use yours, thanks\
-
SAC various quality of life utilities
Pool of female models Pool of random scenarios
-
SAC various quality of life utilities
- 712 downloads
- Version 1.0.4
Please note that, by default, all the features of this mod are disabled in the ini file, they need to be enabled in the ini file in order to work. I chose this in order for the user to be very much aware of which of them he/she enables (hopefully after reading the description below). To enable each feature, set it to 1 in the ini, instead of 0 population_size = 1024 Size of the surrounding population scan, can be reduced for performance, I haven't seen any impact with the features included in this mod enable_3p_melee = 1 If enabled, the player camera will switch automatically to 3rd person whenever the player is engaged in melee, then switch back to 1p automatically a few seconds after the melee action is finished; I have implemented this because I like the 3p view when hogtying peds enable_sandboxing = 1 If enabled, surrounding females picked randomly will either (a) start wandering about, or (b) perform some scenarios from a list (like praying or mopping) enable_pariah = 1 If enabled, random NPC will become "pariah", e.g. public enemy. Pariah NPCs will run towards the player while the surrounding population will become aggressive towards them (purpose of running towards the player is for the player to watch the action without too much effort). I do not suggest attempting to protect the pariah, the status is irreversible and all NPCs will continue targeting them until they are dead Frequency of pariah events is set by pariah_min_interval and pariah_chance. The ini is pre-configured for reasonable intervals, but feel free to experiment. enable_morph_checks= 1 If enabled, all females will be morphed into a slim body shape that is pleasant to my personal taste; this might require adjusting the model ymt to allow for "random expressions", I am not sure yet enable_female_autospawn = 1 If enabled, it will spawn females regularly near (in front of) the player, picked randomly from a varied pool of models listed in the first post below; this leads to a diverse female population quite quickly enable_hotkeys = 1 Enables the following hotkeys (not configurable at this time): F3 = spawn a random female from the model pool, in front of the player NUM0 = lobotomize the ped in focus, i.e. make them unresponsive and blocking sandboxing NUM1 = set the ped in focus as pariah enable_replenish_player_cores = 1 Constantly and automatically fills up the player cores mute_player = 1 Mutes the player character, silencing all the "get out of my way" yells. Likely to affect missions, recommend to not enable if still playing the story flee_horse = 1 Makes the player's horse to flee away (it was starting to get in my way as I was constantly teleporting around). Most likely not useful for the normal player. verbose_logging = 1 Logs some mod actions into sac_util_log.txt; recommend leaving disabled unless there are issues which need tracking. Don't forget to delete the log file if enabled, it will keep appending, there is no automatic deletion -
Placing a ped at a location
I am trying to teleport a ped to a nearby location (within the local map, not remote) I am trying to use SAC_appendLineToFile("sac_rdr2_log.txt", "Noose victim at x = " + to_string(nooseSpot->getAnchorPosition().x) + " y = " + to_string(nooseSpot->getAnchorPosition().y) + " z = " + to_string(nooseSpot->getAnchorPosition().z)); // trace file logs: Noose victim at x = -315.040009 y = 732.947998 z = 122.899002, so x, y and z should be valid ENTITY::SET_ENTITY_COORDS(victim, nooseSpot->getAnchorPosition().x, nooseSpot->getAnchorPosition().y, nooseSpot->getAnchorPosition().z + 1, 1, 1, 1, false); and it doesn't do anything How should I implement this?
- [SOLVED] How to make a ped flee or cower properly?
-
Fps drops caused by the asi loader/.dll
How does one manage threading properly? I am having this exact issue, too much stuff happening in the main thread, I would like to branch it / multithread it, but don't know how
-
[SOLVED] How to make a ped flee or cower properly?
Vector3 playerpos = ENTITY::GET_OFFSET_FROM_ENTITY_IN_WORLD_COORDS(PLAYER::PLAYER_PED_ID(), 0.0f + 5, 0.0f + 5, 0.0f + 0); TASK::TASK_GO_TO_COORD_ANY_MEANS(ped, playerpos.x, playerpos.y, playerpos.z, 3.0f, 0, 0, 3, 0); This works just fine (the offset is just cosmetic so they don't run into the player). Questions is how to make them do some other stuff when they complete the walking. The "go to coord" function does not return a bool on completion - I suppose a while which breaks only when coordinates are near the player?
- [SOLVED] How to make a ped flee or cower properly?