Re: [建議] 副本相關

作者: laechan (揮淚斬馬雲)   2014-04-30 11:42:29
instance -analyze 已經寫好了,這東西可產生副本的核心區段,
底下以 bdlen 的龍潭為例:
> instance -analyze
解析你所在的目錄 /d/ppl/bdlen/dragon/ 中...
instance_paths="/d/ppl/bdlen/dragon/room/"; // 副本實際區域目錄
// 副本區域房間範圍
instance_files=({
"01","02","03","04","05","06","07","08","09","10","11","12","13",
"14","15","16","17","18","19","20","21","22","23","24","25","26",
"27","28","29","30","31","32","33","34","35","36","37","38","39",
"40","41","42","43",
});
// 底下固定
foreach(tmp in instance_files)
instance_files[i++]=instance_paths+tmp;
// 怪物資料 files 必備, 其它就是 short, long, ... 等可自訂
instance_mob_datas=([
"dragon2":(["files":"/d/ppl/bdlen/dragon/mob/dragon2",]),
"dragon1":(["files":"/d/ppl/bdlen/dragon/mob/dragon1",]),
"dragon5":(["files":"/d/ppl/bdlen/dragon/mob/dragon5",]),
"dragon3":(["files":"/d/ppl/bdlen/dragon/mob/dragon3",]),
"dragon4":(["files":"/d/ppl/bdlen/dragon/mob/dragon4",]),
]);
// 副本各房間生怪資料, 所生的怪在 instance_mob_datas 都要有定義
instance_mobs=([
"01":({"dragon2","dragon1","dragon1",}),
"02":({"dragon2","dragon5","dragon5",}),
"04":({"dragon2","dragon2","dragon1",}),
"05":({"dragon3","dragon5","dragon5",}),
"06":({"dragon4","dragon1","dragon1",}),
"07":({"dragon4","dragon2","dragon2",}),
"08":({"dragon3","dragon3","dragon2",}),
"10":({"dragon1","dragon1","dragon1",}),
"11":({"dragon4","dragon4","dragon5",}),
"12":({"dragon4","dragon4","dragon2","dragon2",}),
"13":({"dragon3","dragon1","dragon1",}),
"15":({"dragon4","dragon4","dragon5",}),
"16":({"dragon2","dragon2","dragon5",}),
"17":({"dragon3","dragon3",}),
"18":({"dragon3","dragon2","dragon2",}),
"19":({"dragon3","dragon3","dragon2",}),
"21":({"dragon3","dragon2","dragon2",}),
"22":({"dragon3","dragon3","dragon5","dragon5",}),
"23":({"dragon4","dragon4","dragon2","dragon2",}),
"24":({"dragon4","dragon4","dragon5",}),
"26":({"dragon3","dragon3","dragon1",}),
"27":({"dragon4","dragon4","dragon1",}),
"28":({"dragon2","dragon1","dragon1",}),
"30":({"dragon3","dragon3","dragon5","dragon5",}),
"31":({"dragon3","dragon3",}),
"33":({"dragon4","dragon4","dragon3",}),
"34":({"dragon4","dragon3","dragon3",}),
"35":({"dragon4","dragon1","dragon1",}),
"36":({"dragon1","dragon5","dragon5",}),
"37":({"dragon4","dragon4","dragon3",}),
"38":({"dragon3","dragon3","dragon5",}),
"40":({"dragon2","dragon2","dragon5",}),
"41":({"dragon1","dragon1","dragon5",}),
"42":({"dragon4","dragon4","dragon3","dragon3",}),
"43":({"dragon2","dragon2","dragon1","dragon1","dragon5",}),
]);
==============================================================
它所產生的副本區域,會跟原先的區域幾乎一模一樣。
用這個指令測試八卦的結果亦令我滿意:
解析你所在的目錄 /d/ppl/ina/dinah/blood/ 中...
instance_paths="/d/ppl/ina/dinah/blood/room/"; // 副本實際區域目錄
// 副本區域房間範圍
instance_files=({
"00","1","10","100","1000","101","102","103","104","105","106",
.
.
"99","990","991","992","993","994","995","996","997","998","999",
});
// 底下固定
foreach(tmp in instance_files)
instance_files[i++]=instance_paths+tmp;
// 怪物資料 files 必備, 其它就是 short, long, ... 等可自訂
instance_mob_datas=([
"a1":(["files":"/d/ppl/ina/dinah/blood/mob/a1",]),
.
.
]);
// 副本各房間生怪資料, 所生的怪在 instance_mob_datas 都要有定義
instance_mobs=([
"10":({"a1","a1","a1",}),
.
.
"999":({"c5","c5","c5",}),
]);
===========================================================
不過實際上它是無法載入的,我記得 mapping 的 main_key 數量
有限制。(這就是為何要刪減技能數的原因)
這裡也預留了 instance_mobs 可分區的伏筆,只要依開頭的字母
做分區即可,分區宣告下 1000 個房間就可打散為 10 x 100。
(而且理論上不需要預設分區,預設也是可以的)
最後,instance -analyze 目前只適用於以標準目錄配置方式的舊
型區域,新型態區域目前還無法使用,-analyze2 以後才會寫。
Laechan

Links booklink

Contact Us: admin [ a t ] ucptt.com