Форум · Полнота восстановления · Каталог вариантов

adding npcs to new area — Digital — #1415

Сообщение в форуме

Снимок 2008-02-05 07:05 UTC

Имя в снимке: Digital · Источник Wayback

【共享】在2章新地图比如"海因城"新增商人.传送师等NPC的方法!!!


大家都用的1章服务器端..然而对2章的新增地图..比如"海因城"没有商人NPC 怎么办???


在这里为大家贡献了,,,,,,,,分享吧!!!!哈哈!!!


首先 先找各NPC來改

在ai.obj 我找了哈莫妮來複製 我定了400%的稅來賣 B C D套餐


class trader_yen : merchant

property_define_begin

buyselllist_begin SellList0

{1463; 400 }

{1464; 400 }

{1465; 400 }

{2510; 400 }

{2511; 400 }

{2512; 400 }

{3948; 400 }

{3949; 400 }

{3950; 400 }

buyselllist_end

property_define_end

class_end


class trader_harmony : merchant

property_define_begin

buyselllist_begin SellList0

{1370; 20 }

{1401; 20 }

{1411; 20 }

{1372; 20 }

{1513; 20 }

{1399; 20 }

{1386; 20 }

{1856; 20 }

{1377; 20 }

{1383; 20 }

{1514; 20 }

{1405; 20 }

{1403; 20 }

{1371; 20 }

{1515; 20 }

{1667; 20 }

{1669; 20 }

{1671; 20 }

{1512; 20 }

{1379; 20 }

{1402; 20 }

{1517; 20 }

{1415; 20 }

{1391; 20 }

{1398; 20 }

{1389; 20 }

{1388; 20 }

{1410; 20 }

{1404; 20 }

{1417; 20 }

{1400; 20 }

{1418; 20 }

{1668; 20 }

{1670; 20 }

{3038; 20 }

{1378; 20 }

{1516; 20 }

{1414; 20 }

{1385; 20 }

{1394; 20 }

{1412; 20 }

{3944; 20 }

{1392; 20 }

{1407; 20 }

{1416; 20 }

{1397; 20 }

{1406; 20 }

{1408; 20 }

{1390; 20 }

{1387; 20 }

{1409; 20 }

{1413; 20 }

{1381; 20 }

{1382; 20 }

{1384; 20 }

{1380; 20 }

{1535; 20 }

{1521; 20 }

{1523; 20 }

{1534; 20 }

{1537; 20 }

{1533; 20 }

{1536; 20 }

{1532; 20 }

{1528; 20 }

{1519; 20 }

{1518; 20 }

{1520; 20 }

{1530; 20 }

buyselllist_end

property_define_end

class_end


之後在 npc_pch.txt 新增NPC代號

[trader_yen]   =   1012374


再到 npcdata 用了哈莫妮的對話檔 當然也可以改別的 也可以新增

npc_begin   merchant   12374   [trader_yen]   level=70   exp=429634524.325   acquire_exp_rate=0.3   undying=1   can_be_attacked=0   acquire_sp=30   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=[shining_bow]   slot_lhand=[]   base_attack_type=bow   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=2444.46818899627   org_mp=1345.8   base_defend=295.91597408024   base_magic_attack=470.404627426724   base_magic_defend=216.538467292763   base_physical_attack=688.863725587608   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=7   collision_height=23   category={}   clan={}   clan_help_range=300   guild={}   pledge={}   pledge_leader=0   alliance={}   alliance_leader=0   ignore_clan_list={}   ruler=0   ruling_domain={}   npc_ai={[trader_harmony];{[fnHi] = [trader_harmony001.htm]};{[fnSell] = [trader_harmony002.htm]};{[fnBuy] = [trader_harmony003.htm]};{[fnUnableItemSell] = [trader_harmony005.htm]};{[fnYouAreChaotic] = [trader_harmony006.htm]};{[fnNowSiege] = [trader_harmony007.htm]}}   corpse_time=7   no_sleep_mode=0   npc_end


再到npcpos.txt 加入NPC的位置

npc_begin   [trader_yen]   pos = {-14694;124205;-3114;61440}   total = 1   respawn = 1min   npc_end     

npc_begin   [trader_harmony]   pos = {-14934;124468;-3114;61440}   total = 1   respawn = 1min   npc_end


伺服器端完成

X   Y   Z   ???

pos = {-14694;124205;-3114;61440} 不過最後一個不知道代表什麼意義


到npcgrp.txt 加入


npc_begin   npc_id=12374   npc_name=[trader_yen]   npc_speed=1   class_name=[LineageNPC.a_traderA_FHuman]   mesh_name=[LineageNPCs.a_traderA_FHuman_m00]   texture_name={[LineageNPCsTex.a_traderA_FHuman_m00_t00_b00];[LineageNPCsTex.a_traderA_FHuman_m00_t00_b01];[LineageNPCsTex.a_traderA_FHuman_m00_t00_f];[LineageNPCsTex.a_traderA_FHuman_m00_t00_h]}   collision_radius=7   collision_height=23   attack_sound1={[ItemSound.fist_1];[ItemSound.fist_2];[ItemSound.fist_3]}   defense_sound1={[ItemSound.armor_leather_1];[ItemSound.armor_leather_3];[ItemSound.armor_leather_4];[ItemSound.armor_leather_5];[ItemSound.armor_leather_7]}   damage_sound={[ChrSound.FNpc_Lady_Dmg_1];[ChrSound.FNpc_Lady_Dmg_2];[ChrSound.FNpc_Lady_Dmg_3]}   sound_vol=250   sound_radius=50   sound_random=70   attack_effect=[LineageEffect.p_u002_a]   npc_end


再到 npcname-tw.txt 加入

npc_begin   id=12374   nickcolor=default   nick=[秘密商人]   name=[Yen]   npc_end

客戶端也完成了