Replies: 1 (Who?), Viewed: 110 times.
Field Researcher
Original Poster
#1 Old 30th Jul 2022 at 5:50 PM Last edited by lizcandor : 30th Jul 2022 at 9:59 PM.
Default Posture problems
I'm trying to make a working wheelchair, as a hopefully easier way to learn to work with postures than my first attempt at that. The posture I've made (InWheelchairPosture) is at this point just a clone of SittingPosture with as little altered as possible; but I'm trying to make it so sims can route and do other interactions while *staying* in this posture, and the problem is sims keep trying to go back to StandingPosture every time I make them do anything.

I've been editing the posture preconditions for a bunch of interactions in bulk on preload (looping through InteractionTuning.sAllTunings.Values and changing the posture precondition fields of all interactions with "GoHere" or "Watch" in their names, to add an entry for the CommodityKind I created to go with InWheelchairPosture), but this doesn't seem to be enough to keep the sim seated. I'm kind of stuck. Is there an additional component I'm missing in the game's decision about which postures are and aren't compatible with whatever interaction a sim is trying to do? Code for InWheelchairPosture is in the spoiler if it's any use.



Edit: Looks like I've fixed this at least in the one case I was testing - problem was with the values I'd given to my new posture precondition entries when I was making the ITUN edits (0 when they should have been 1), and then with the combination of the commodities I'd set InWheelchairPosture to satisfy and the interaction I was using to test it (I was testing by having the sim watch TV, and that interaction assumes the sim is in SittingPosture if their posture satisfies the Sitting commodity kind, which was causing a null value error here. So solution was to either derive InWheelchairPosture from SittingPosture, or make InWheelchairPosture not satisfy Sitting).
Advertisement
Field Researcher
Original Poster
#2 Old 31st Jul 2022 at 1:12 PM
I've now got the posture and a super rudimentary custom walkstyle down (it's a new walkstyle, which I'll put notes on how to make in another post once I'm more confident it works, but it just uses the same walking animations as the original walkstyle it copied for now because I had some animation difficulties that I will also ask about later) so I'm now working on getting the sim in the wheelchair to 1) route properly and 2) take the chair with them when they do. Right now, the sim routes to their destination but leaves the chair behind; and then when they reach where they were going, they disappear, and reappear sitting in the chair again. But then focusing the camera on that sim focuses on the spot they routed to, not where it looks like they are; and when I cancel the InWheelChair posture, the sim shoots across the ground as soon as they finish the standing-up animation, to stand in the spot they routed to.

Has anyone seen this before?
Back to top