Forum Discussion
9 years ago
Edit3: Same thing worked for bed by putting in a posture_BedUndercovers constraint. So... issue resolved for now. I should pretty much be able to do what I was wanting to do when I made this thread. If I were wanting to add generic use interactions for any sim, that'd be another matter. But for the purpose of trait-based interactions, it's all coolio for now.
Edit2: Well that's interesting. Just adding the following to the piano interaction fixed its issue.
Which would seem to imply that if I'm adding custom interactions to objects, I can't rely on the animation constraints doing their job. Doesn't fully make sense, but it's progress!
-----
Edit: Now I'm thinking maybe this is a problem that goes beyond the method of pushing it on the object. Just no idea how. What I do know is I tried it with a piano and ran into virtually the same issue:
So there's at least a common thing happening.
The problem is, I recall having this problem in the past, even when I used a script injector to force an interaction on a single piano one time, just to see if I could get it to work at all. The only form of injecting I know how to do that I haven't tried is just straight up adding it to an XML file manually and using an override.
I might have to try that, just to see if I can narrow this problem down more.
Logically, it makes no sense with the information I have. All I'm doing is adding a new affordance to the list of affordances that the object has. Only thing I can think of at the moment that appeals to my sense of reason is if there's something more to object affordances than simply having them in a list (for some object types). This thought makes a kind of sense, as piano and bed both have _anim_overrides and telescope does not (will have to research on what those are exactly).
-----
So to follow up on what I meant by this...
Someone reminded me of the functions in trait buffs, where you can add affordances specific to a trait, through super_affordances and target_super_affordances.
I saw that and thought, maybe I can use target_super_affordances to make stuff appear on particular objects (since I'm primarily operating through traits right now anyway). The person was pointing out that you can specify by tags, which put me on the thought of objects through tag reference.
So I used something like this in a trait buff:
Which sort of worked and sort of didn't.
It worked for a telescope interaction just fine. The interaction showed up on the telescope and functioned the same as it was when I injected it.
Had (and am still having) some problems with a bed interaction though. The interaction is mostly a carbon copy of Bed_Undercovers_Hide. I even tried a carbon copy of Bed_Undercovers_Hide to see if that would make a difference.
It gives me the same ASM error every time when I try to use the interaction:
For some reason, it apparently thinks that the virtual actors for bedIKRef are none. Which I can only assume has something to do with the way the interaction is being pushed on the object because that's basically the only factor I haven't eliminated. Maybe target_super_affordances just isn't built to handle pushing interactions on objects that require a special posture change and the like. I'm also not sure about it's efficiency in loading... it may increase on_add load times, where injections can put most of the load pressure on startup. Not totally sure on that.
Anyway, I'm digressing. And rambling. The point is, out of the frying pan and into the fire. One solution into another problem. Oh, modding...
Edit2: Well that's interesting. Just adding the following to the piano interaction fixed its issue.
Which would seem to imply that if I'm adding custom interactions to objects, I can't rely on the animation constraints doing their job. Doesn't fully make sense, but it's progress!
HUMAN
15535
-----
Edit: Now I'm thinking maybe this is a problem that goes beyond the method of pushing it on the object. Just no idea how. What I do know is I tried it with a piano and ran into virtually the same issue:
PianoPlayPractice: Virtual actors for sitTemplate do not include None
So there's at least a common thing happening.
The problem is, I recall having this problem in the past, even when I used a script injector to force an interaction on a single piano one time, just to see if I could get it to work at all. The only form of injecting I know how to do that I haven't tried is just straight up adding it to an XML file manually and using an override.
I might have to try that, just to see if I can narrow this problem down more.
Logically, it makes no sense with the information I have. All I'm doing is adding a new affordance to the list of affordances that the object has. Only thing I can think of at the moment that appeals to my sense of reason is if there's something more to object affordances than simply having them in a list (for some object types). This thought makes a kind of sense, as piano and bed both have _anim_overrides and telescope does not (will have to research on what those are exactly).
-----
"Triplis;c-15957418" wrote:
Edit: On second thought, I may not need the injection to objects after all. More on this later, depending on where it goes.
So to follow up on what I meant by this...
Someone reminded me of the functions in trait buffs, where you can add affordances specific to a trait, through super_affordances and target_super_affordances.
I saw that and thought, maybe I can use target_super_affordances to make stuff appear on particular objects (since I'm primarily operating through traits right now anyway). The person was pointing out that you can specify by tags, which put me on the thought of objects through tag reference.
So I used something like this in a trait buff:
13436945359271848694
Func_Bed
Which sort of worked and sort of didn't.
It worked for a telescope interaction just fine. The interaction showed up on the telescope and functioned the same as it was when I injected it.
Had (and am still having) some problems with a bed interaction though. The interaction is mostly a carbon copy of Bed_Undercovers_Hide. I even tried a carbon copy of Bed_Undercovers_Hide to see if that would make a difference.
It gives me the same ASM error every time when I try to use the interaction:
Bed_Undercovers_InteractionIdle: Virtual actors for bedIKRef do not include None
For some reason, it apparently thinks that the virtual actors for bedIKRef are none. Which I can only assume has something to do with the way the interaction is being pushed on the object because that's basically the only factor I haven't eliminated. Maybe target_super_affordances just isn't built to handle pushing interactions on objects that require a special posture change and the like. I'm also not sure about it's efficiency in loading... it may increase on_add load times, where injections can put most of the load pressure on startup. Not totally sure on that.
Anyway, I'm digressing. And rambling. The point is, out of the frying pan and into the fire. One solution into another problem. Oh, modding...