文件路径:data/presets/humanai.pre
小黄人预设
Preset("BTZ_Suicider")
{
SetField("MeshName", "zombie_man_a.msh");
SetField("SkinName", "zombie_hazmat");
SetField("m_AlarmedMimicPreset", "");
SetField("m_ArmInfluenceMul", "0.3");
SetField("m_AttachableItem1Name", "SuiciderTank");
SetField("m_AttachableItem1Probability", "1.0");
SetField("m_BurnOnStart", "0");
SetField("m_CanCutOffHead", "0");
SetField("m_CanUseAttractors", "0");
SetField("m_ConflictSide", CONFLICT_SIDE_COUNTER_ALL);
SetField("m_CrippleBonesEnable", "0");
SetField("m_CutOffBonesEnable", "0");
SetField("m_ForcedBodyScaleMax", "1.15");
SetField("m_ForcedBodyScaleMin", "1.05");
SetField("m_Gender", "0");
SetField("m_GrabEnabled", "0");
SetField("m_HarvestingLevelRequired", "1");
SetField("m_HarvestingLootType", "Harvesting_Bomber_Body");
SetField("m_IsHarvestable", "1");
SetField("m_CustomDataPreset", "btz_suicider");
SetField("m_KnowledgeBasePreset", "btz_suicider");
SetField("m_MainGoalRulesPreset", "btz_suicider");
SetField("m_ModulesPreset", "11");
SetField("m_MaxLevelDiff", "2");
SetField("m_MinLevelDiff", "-5");
SetField("m_NeverHolsterWeapon", "1");
SetField("m_PrimaryWeaponProbability", "0.5");
SetField("m_Seed", "0");
SetField("m_ShowFlies", "0");
SetField("m_SoundPreset", "SuicideBomber");
SetField("m_StepPreset", "Default_Zombie");
SetField("m_Type", "3");
}
文件路径data/curve_di.xml
小黄人爆炸伤害
//爆炸伤害函数
<curve Name="btz_suicider_explosion_damage" NumberOfSamples="2" MaxX="80" MinX="1" MaxY="1300" MinY="0">
<knots Count="2">
<knot TypeOfSpline="LINE" X="1" Y="1300" />
<knot TypeOfSpline="HERMITE" X="60" Y="1300" />
</knots>
</curve>
//升级版的爆炸伤害函数
<curve Name="btz_suicider_explosion_damage_upgraded" NumberOfSamples="2" MaxX="80" MinX="1" MaxY="1300" MinY="0">
<knots Count="2">
<knot TypeOfSpline="LINE" X="1" Y="1300" />
<knot TypeOfSpline="HERMITE" X="60" Y="1300" />
</knots>
</curve>
文件路径
data/ai/infectedinfected_data_custom_preset_btz_suicider.scr
data/ai/infected_data_custom_preset_btz_suicider_upgraded.scr
小黄人行为参数
!include("ai_data.def") // 包含 AI 数据文件
!include("infected_timing_events.def") // 包含感染事件计时文件
// 入侵小黄人
////////////////////////////////////////////// 数据 ///////////////////////////////////////////////
//
//
//
//
//
Data("alarming:standing::alarmed:::", 0, "", -1, 1)
// 数据定义了警觉状态,包括站立状态、警报级别、角度、方向和移动状态
//
//
//
//
//
Data("idle:standing::special:::", -2, "btz_suicide_explode",-1, 1)
// 数据定义了空闲状态,包括站立状态、姿势、空闲类型、物品类型、恐惧级别、准备空闲和完成空闲
//
//
//
//
//
Data("movement:standing:run:forward::::", -2, "suicide_bomber_upset_run", -1, 1)
Data("movement:standing:sprint:forward::::", -2, "suicide_bomber_upset_run", -1, 1)
// 数据定义了移动状态,包括站立状态、移动类型、移动方向、警报级别、物品类型、冲撞类型和楼梯攀爬状态
/////////////////////////////////////////// 参数 ////////////////////////////////////////////
ParamFloat("melee_range", 2.0) // 表示小黄人爆炸的范围距离,当玩家与其距离不超过2.0时,它会引爆。
ParamFloat("explode_range", 5.5) // 表示爆炸的范围大小,伤害会根据距离的平方衰减。
// 创建名为 "btz_suicider_explosion_damage" 的曲线,用于表示爆炸伤害的变化
Curve(CURVE_EXPLOSION_DAMAGE, "btz_suicider_explosion_damage")
ParamFloat("health_mul", 0.3) // 生命值乘数
ParamFloat("damage_mul", 1.0) // 伤害乘数
ParamBool("can_fall", 0) // 是否能够掉落
ParamBool("can_react_on_hit", 0) // 是否能够对被击中作出反应
ParamBool("can_react_on_bullet", 0) // 是否能够对子弹作出反应
ParamBool("can_attack_from_move", 0) // 是否能够在移动中攻击
ParamBool("can_strike_from_stand", 0) // 是否能够在站立时攻击
ParamProb("taunt_prob", 0, 1) // 在未成功抓取狂暴者或目标注意到后的嘲讽概率
ParamFloat("taunt_prob_on_target_change", 0.0) // 在未成功抓取狂暴者后的嘲讽概率
ParamFloat("taunt_prob_on_take_damage", 0.0) // 受到伤害后的嘲讽概率
ParamBool("navigate_through_generic_nav_mesh_connections", 1) // 是否可以通过通用导航网格连接导航
ParamBool("navigate_through_user_nav_mesh_connections", 0) // 是否可以通过用户导航网格连接导航
ParamBool("can_move_through_low_obstacles", 1) // 是否可以穿越低障碍物
ParamBool("can_move_through_high_obstacles", 0) // 是否可以穿越高障碍物
ParamFloat("connection_cost_mul", 4.0) // 连接成本乘数
ParamFloat("min_jump_on_height", 0.5) // 最小跳跃高度
ParamFloat("max_jump_on_height", 1.3) // 最大跳跃高度
ParamFloat("max_jump_over_dist", 0.7) // 最大跳跃距离
ParamFloat("min_jump_down_height", 0.0) // 最小跳跃下落高度
// 阻止他们攀爬
ParamFloat("max_connection_height_up", 1.5) // 最大连接高度(向上)
ParamFloat("max_connection_height_down", 1.7) // 最大连接高度(向下),在攀爬后可以掉落(参考:min_fall_height)
ParamFloat("max_connection_horiz_dist", 1.0) // 最大连接水平距离
ParamFloat("navi_mesh_sight_range", 200.0) // 视线范围
ParamBool("stop_in_last_node_when_path_not_found", 0) // 当找不到路径时是否停在最后一个节点
ParamInt("zombie_type", 8) // 僵尸类型
ParamBool("update_async_arrival", 0) // 异步更新到达状态
ParamBool("can_attack_enemy_in_vehicle", 1) // 是否可以攻击车辆中的敌人
ParamFloat("humanity_hit_reaction_prob", 0.0) // 被击中后人性的反应概率
ParamFloat("blast_damage_mul", 1.0) // 爆炸伤害乘数
ParamBool("explode_on_destination_reached", 0) // 到达目标时是否爆炸
ParamBool("explode_on_destination_unreachable", 1) // 目标无法到达时是否爆炸
ParamFloat("explode_on_destination_unreachable_delay", 20) // 无法到达目标时的爆炸延迟时间
ParamBool("can_attack_objects_from_move", 0) // 是否可以在移动中攻击对象