BiGBoY
20.06.2005, 12:09
I had that idea in my head for long time already. Now some wiseasses crossed the line of good taste on my server with hitting non fighting NPC's all the time. This just triggered me to recall the old idea and here it is:
Client side:
npcgrp.txt
npc_begin npc_id=10224 npc_name=[npc_bodyguard] npc_speed=1 class_name=[LineageNPC.a_guard_MHuman] mesh_name=[LineageNPCs.a_guard_MHuman_m00] texture_name={[LineageNPCsTex.a_guard_MHuman_m00_t00_b00];[LineageNPCsTex.a_guard_MHuman_m00_t00_b01];[LineageNPCsTex.a_guard_MHuman_m00_t00_h]} texture_name_second=[none] collision_radius=8 collision_height=24 attack_sound1={[ItemSound.fist_1];[ItemSound.fist_2];[ItemSound.fist_3]} defense_sound1={[ItemSound.armor_metal_strong_4];[ItemSound.armor_metal_strong_7];[ItemSound.armor_metal_strong_9];[ItemSound.armor_metal_alt_8];[ItemSound.armor_metal_alt_1]} damage_sound={[ChrSound.MNpc_Fighter_Dmg_1];[ChrSound.MNpc_Fighter_Dmg_2];[ChrSound.MNpc_Fighter_Dmg_3]} sound_vol=250 sound_radius=50 sound_random=70 attack_effect=[LineageEffect.p_u002_a] quest_be=0 level_limit={[]} class_limit={[]} npc_end
npcname-e.txt
npc_begin id=10224 nickcolor=raid nick=[NPC Bodyguard] name=[Will Kill] reserved1=0 npc_end
Server side:
npcdata.txt
npc_begin guard 10224 [npc_bodyguard] level=70 exp=4296345xx.xx5 acquire_exp_rate=0.3 undying=1 can_be_attacked=0 acquire_sp=30 race=castle_guard sex=male temper=100 safe_height=100 org_jump=15 skill_list={@s_full_magic_defence} magic_list={} max_item=80 item_make_list={} corpse_make_list={} additional_make_list={} additional_make_multi_list={} slot_chest=[dragon_scale_mail] slot_rhand=[shining_bow] slot_lhand=[] base_attack_type=bow base_can_penetrate=0 base_attack_range=1100 base_damage_range={0;0;80;120} base_rand_dam=10 str=60 int=21 dex=60 wit=20 con=43 men=10 hp_increase=40 mp_increase=7 org_hp_regen=7.5 org_mp_regen=10 ground_low={80;0;10} ground_high={160;-30;30} underwater_low={50;0;10} underwater_high={0;0;30} fly_low={0;0;10} fly_high={0;-30;30} float_low={0;0;10} float_high={0;-30;30} org_earshot=100 sight={0;0;2500;120;5} agro_range=1000 org_hp=67xx.xx146118935 org_mp=5000 base_defend=5xx.xx5040328361 base_magic_attack=5xx.xx5709791816 base_magic_defend=2xx.xx8467292763 base_physical_attack=5300 physical_hit_modify=0 physical_avoid_modify=0 base_attack_speed=400 base_reuse_delay=0 base_critical=8 magic_use_speed_modify=0 status={normal} align=-4900 collision_radius=8 collision_height=27 category={} clan={@bodyguard_clan} clan_help_range=1200 guild={} pledge={} pledge_leader=0 alliance={} alliance_leader=0 ignore_clan_list={} ruler=0 ruling_domain={} npc_ai={[ol_mahum_patrol]} corpse_time=7 no_sleep_mode=1 npc_end
Example for one gatekeeper (note the clan={@bodyguard_clan} ! this is needed so the bodyguards will protect them) Add this clan tag to every NPC u want to protect.
npc_begin teleporter 7215 [__gatekeeper_angelina] level=70 exp=4296345xx.xx5 acquire_exp_rate=0.1 undying=1 can_be_attacked=0 acquire_sp=10 race=human sex=female temper=100 safe_height=100 org_jump=15 skill_list={@s_full_magic_defence} magic_list={} max_item=50 item_make_list={} corpse_make_list={} additional_make_list={} additional_make_multi_list={} slot_chest=[] slot_rhand=[] slot_lhand=[] base_attack_type=fist base_can_penetrate=0 base_attack_range=40 base_damage_range={0;0;80;120} base_rand_dam=30 str=40 int=21 dex=30 wit=20 con=43 men=10 hp_increase=40 mp_increase=7 org_hp_regen=7.5 org_mp_regen=2.7 ground_low={80;0;10} ground_high={120;-30;30} underwater_low={50;0;10} underwater_high={0;0;30} fly_low={0;0;10} fly_high={0;-30;30} float_low={0;0;10} float_high={0;-30;30} org_earshot=100 sight={0;0;2500;120;5} agro_range=1000 org_hp=24xx.xx818899627 org_mp=1345.8 base_defend=2xx.xx597408024 base_magic_attack=4xx.xx4627426724 base_magic_defend=2xx.xx8467292763 base_physical_attack=6xx.xx3725587608 physical_hit_modify=4.75 physical_avoid_modify=0 base_attack_speed=253 base_reuse_delay=0 base_critical=4 magic_use_speed_modify=0 status={normal} align=-4900 collision_radius=8 collision_height=25 category={} clan={@bodyguard_clan} clan_help_range=300 guild={} pledge={} pledge_leader=0 alliance={} alliance_leader=0 ignore_clan_list={} ruler=0 ruling_domain={} npc_ai={[default_npc]} corpse_time=7 no_sleep_mode=0 npc_end
ai.obj
class npc_bodyguard : ol_mahum_patrol
class_end
npc_pch.txt
[npc_bodyguard] = 1010224
npcpos.txt
Put it wherever u want
manual_pch.txt
[all_elemental_clan] = 1
[all_elemental2_clan] = 2
[ant_clan] = 3
[bugbear_clan] = 4
[demonic_clan] = 5
[dragon_clan] = 6
[elemental1_clan] = 7
[elemental2_clan] = 8
[elemental3_clan] = 9
[elemental4_clan] = 10
[goblin_clan] = 11
[lizardman_clan] = 12
[mandragora_clan] = 13
[neer_crawler_clan] = 14
[oel_mahum_clan] = 15
[ol_mahum_clan] = 16
[orc_clan] = 17
[scropio_clan] = 18
[serpent_clan] = 19
[silenos_clan] = 20
[skeleton_clan] = 21
[stakato_clan] = 22
[undead_clan] = 23
[wererat_clan] = 24
[werewolf_clan] = 25
[tyrant_clan] = 26
[q403_clan] = 27
[queen_ant_clan] = 28
[wolf_clan] = 29
[porta_clan] = 30
[torfe_clan] = 31
[giant_leech_clan] = 32
[cave_servant_clan] = 33
[succubus_clan] = 34
[gludio_siege_clan] = 35
[curma_core_clan] = 36
[ghost_clan] = 37
[monster_eye_clan] = 38
[partisan_clan] = 39
[bapuk_clan] = 40
[orfen_clan] = 41
[elemental_clan] = 42
[kobold_clan] = 43
[abyss_jewel_clan] = 44
[grave_guard_clan] = 45
[grave_keeper_clan] = 46
[malruk_clan] = 47
[mirrorforest_clan] = 48
[giant_clan] = 49
[hatar_clan] = 50
[dion_siege_clan] = 51
[giran_siege_clan] = 52
[oren_siege_clan] = 53
[aden_siege_clan] = 54
[mercenary_siege_clan] = 55
[door_clan] = 56
[bodyguard_clan] = 57
Client side:
npcgrp.txt
npc_begin npc_id=10224 npc_name=[npc_bodyguard] npc_speed=1 class_name=[LineageNPC.a_guard_MHuman] mesh_name=[LineageNPCs.a_guard_MHuman_m00] texture_name={[LineageNPCsTex.a_guard_MHuman_m00_t00_b00];[LineageNPCsTex.a_guard_MHuman_m00_t00_b01];[LineageNPCsTex.a_guard_MHuman_m00_t00_h]} texture_name_second=[none] collision_radius=8 collision_height=24 attack_sound1={[ItemSound.fist_1];[ItemSound.fist_2];[ItemSound.fist_3]} defense_sound1={[ItemSound.armor_metal_strong_4];[ItemSound.armor_metal_strong_7];[ItemSound.armor_metal_strong_9];[ItemSound.armor_metal_alt_8];[ItemSound.armor_metal_alt_1]} damage_sound={[ChrSound.MNpc_Fighter_Dmg_1];[ChrSound.MNpc_Fighter_Dmg_2];[ChrSound.MNpc_Fighter_Dmg_3]} sound_vol=250 sound_radius=50 sound_random=70 attack_effect=[LineageEffect.p_u002_a] quest_be=0 level_limit={[]} class_limit={[]} npc_end
npcname-e.txt
npc_begin id=10224 nickcolor=raid nick=[NPC Bodyguard] name=[Will Kill] reserved1=0 npc_end
Server side:
npcdata.txt
npc_begin guard 10224 [npc_bodyguard] level=70 exp=4296345xx.xx5 acquire_exp_rate=0.3 undying=1 can_be_attacked=0 acquire_sp=30 race=castle_guard sex=male temper=100 safe_height=100 org_jump=15 skill_list={@s_full_magic_defence} magic_list={} max_item=80 item_make_list={} corpse_make_list={} additional_make_list={} additional_make_multi_list={} slot_chest=[dragon_scale_mail] slot_rhand=[shining_bow] slot_lhand=[] base_attack_type=bow base_can_penetrate=0 base_attack_range=1100 base_damage_range={0;0;80;120} base_rand_dam=10 str=60 int=21 dex=60 wit=20 con=43 men=10 hp_increase=40 mp_increase=7 org_hp_regen=7.5 org_mp_regen=10 ground_low={80;0;10} ground_high={160;-30;30} underwater_low={50;0;10} underwater_high={0;0;30} fly_low={0;0;10} fly_high={0;-30;30} float_low={0;0;10} float_high={0;-30;30} org_earshot=100 sight={0;0;2500;120;5} agro_range=1000 org_hp=67xx.xx146118935 org_mp=5000 base_defend=5xx.xx5040328361 base_magic_attack=5xx.xx5709791816 base_magic_defend=2xx.xx8467292763 base_physical_attack=5300 physical_hit_modify=0 physical_avoid_modify=0 base_attack_speed=400 base_reuse_delay=0 base_critical=8 magic_use_speed_modify=0 status={normal} align=-4900 collision_radius=8 collision_height=27 category={} clan={@bodyguard_clan} clan_help_range=1200 guild={} pledge={} pledge_leader=0 alliance={} alliance_leader=0 ignore_clan_list={} ruler=0 ruling_domain={} npc_ai={[ol_mahum_patrol]} corpse_time=7 no_sleep_mode=1 npc_end
Example for one gatekeeper (note the clan={@bodyguard_clan} ! this is needed so the bodyguards will protect them) Add this clan tag to every NPC u want to protect.
npc_begin teleporter 7215 [__gatekeeper_angelina] level=70 exp=4296345xx.xx5 acquire_exp_rate=0.1 undying=1 can_be_attacked=0 acquire_sp=10 race=human sex=female temper=100 safe_height=100 org_jump=15 skill_list={@s_full_magic_defence} magic_list={} max_item=50 item_make_list={} corpse_make_list={} additional_make_list={} additional_make_multi_list={} slot_chest=[] slot_rhand=[] slot_lhand=[] base_attack_type=fist base_can_penetrate=0 base_attack_range=40 base_damage_range={0;0;80;120} base_rand_dam=30 str=40 int=21 dex=30 wit=20 con=43 men=10 hp_increase=40 mp_increase=7 org_hp_regen=7.5 org_mp_regen=2.7 ground_low={80;0;10} ground_high={120;-30;30} underwater_low={50;0;10} underwater_high={0;0;30} fly_low={0;0;10} fly_high={0;-30;30} float_low={0;0;10} float_high={0;-30;30} org_earshot=100 sight={0;0;2500;120;5} agro_range=1000 org_hp=24xx.xx818899627 org_mp=1345.8 base_defend=2xx.xx597408024 base_magic_attack=4xx.xx4627426724 base_magic_defend=2xx.xx8467292763 base_physical_attack=6xx.xx3725587608 physical_hit_modify=4.75 physical_avoid_modify=0 base_attack_speed=253 base_reuse_delay=0 base_critical=4 magic_use_speed_modify=0 status={normal} align=-4900 collision_radius=8 collision_height=25 category={} clan={@bodyguard_clan} clan_help_range=300 guild={} pledge={} pledge_leader=0 alliance={} alliance_leader=0 ignore_clan_list={} ruler=0 ruling_domain={} npc_ai={[default_npc]} corpse_time=7 no_sleep_mode=0 npc_end
ai.obj
class npc_bodyguard : ol_mahum_patrol
class_end
npc_pch.txt
[npc_bodyguard] = 1010224
npcpos.txt
Put it wherever u want
manual_pch.txt
[all_elemental_clan] = 1
[all_elemental2_clan] = 2
[ant_clan] = 3
[bugbear_clan] = 4
[demonic_clan] = 5
[dragon_clan] = 6
[elemental1_clan] = 7
[elemental2_clan] = 8
[elemental3_clan] = 9
[elemental4_clan] = 10
[goblin_clan] = 11
[lizardman_clan] = 12
[mandragora_clan] = 13
[neer_crawler_clan] = 14
[oel_mahum_clan] = 15
[ol_mahum_clan] = 16
[orc_clan] = 17
[scropio_clan] = 18
[serpent_clan] = 19
[silenos_clan] = 20
[skeleton_clan] = 21
[stakato_clan] = 22
[undead_clan] = 23
[wererat_clan] = 24
[werewolf_clan] = 25
[tyrant_clan] = 26
[q403_clan] = 27
[queen_ant_clan] = 28
[wolf_clan] = 29
[porta_clan] = 30
[torfe_clan] = 31
[giant_leech_clan] = 32
[cave_servant_clan] = 33
[succubus_clan] = 34
[gludio_siege_clan] = 35
[curma_core_clan] = 36
[ghost_clan] = 37
[monster_eye_clan] = 38
[partisan_clan] = 39
[bapuk_clan] = 40
[orfen_clan] = 41
[elemental_clan] = 42
[kobold_clan] = 43
[abyss_jewel_clan] = 44
[grave_guard_clan] = 45
[grave_keeper_clan] = 46
[malruk_clan] = 47
[mirrorforest_clan] = 48
[giant_clan] = 49
[hatar_clan] = 50
[dion_siege_clan] = 51
[giran_siege_clan] = 52
[oren_siege_clan] = 53
[aden_siege_clan] = 54
[mercenary_siege_clan] = 55
[door_clan] = 56
[bodyguard_clan] = 57