ProceduralADS_NEW (1)

程序化瞄准(不影响右手拉栓)
首先要用到3个虚拟骨骼
notion image
VB FirearmCollision是作为武器是否被阻挡检测用的不是本文内容
鼠标选中head骨骼右键添加虚拟骨骼虚拟骨骼选择head 就得到了VB ik_hand_gun_parent
鼠标选中VB ik_hand_gun_parent 右键添加虚拟骨骼选择head 得到VB ik_hand_gun_ads
鼠标选中VB ik_hand_gun_parent 右键添加虚拟骨骼选择ik_hand_gun 得到VB ik_hand_gun
然后就是要获取第一人称相机的Location Rotation
这是相机的Transform
notion image
这里的Camera就是第一人称相机
SetADS这部分我暂时放动画蓝图里了你在其他地方写这部分也是可以的
notion image
Camera依然是指第一人称相机
SightLPVO是瞄具的网格体
MyPawn就是玩家角色
Gun是武器的网格体(Mesh Component) 这里的gun是骨骼网格体
ADStoSightDistance是瞄具与玩家相机之间的距离
SetADS你可以放动画蓝图每帧更新里当玩家按下瞄准才开始执行能稍微节省点性能
这是动画图表
notion image
notion image
notion image
notion image
notion image
notion image
notion image
notion image
notion image
角色蓝图
notion image
动画蓝图
notion image
notion image
notion image
这里使用了插值让瞄准变得丝滑
Loading...