KRISS Vector
Interaction points New
An interaction point is a context with a position, a radius and optionally a facing direction.
Facing a direction
A context with Omnidirectional 0 and a VisibilityAngle is only visible from the side its PointInfo angles point to.
UserActionContext "{...}" {
ContextName "my_rail_left"
Position PointInfo "{...}" {
PivotID "w_root"
Offset -0.0265 0.0083 0.202
Angles 0 -90 0 // pitch yaw roll: yaw +90 = visible from the right, -90 = from the left
}
Radius 0.02
Omnidirectional 0
VisibilityAngle 85 // half the opening angle of the cone
}
Test it, do not guess
UserActionContext.IsInVisibilityAngle(position) tells whether a position sees the context. A small probe that logs it for six
directions (left, right, up, down, front, back, 0.5 m from the point) shows right away whether the signs are correct. The nearby display uses
the same call with the camera position.
Foreign actions land in default
Attachments of other mods put their Attach and Detach actions into the context named default and their On/Off into their own user context, which
sits on the device. So your weapon's default context is the collection point for everything foreign: the Attach and Detach lines you see there are not yours.
You cannot move or hide them from the weapon – you can only decide where the point sits.
Item names
The vanilla attach and detach actions build their label as #AR-UserAction_Attach + the item name. A plain text item name then reads as one string ID:
#AR-UserAction_AttachMy Rifle is shown raw. A leading space in the item name ends the key before the name starts.