用于战神引擎的装备回收经验的NPC脚本,脚本上面有元宝和经验2个回收选项,如果不要元宝,可以直接在脚本里面隐藏元宝回收的文字就行了,脚本里面自带了十套装备,注释了六套,明文版的文件,可以任意修改里面的回收装备名字和玩家获得的经验值。
部分脚本
procedure _wangzhe1_all; var ZMnum , i : integer; Iname : string; begin ZMnum := 0; for i := 1 to 40 do begin Iname := getZBnameById(700 + i); if Iname <> '' then begin if This_Player.GetBagItemCount(Iname) > 0 then begin ZMnum := ZMnum + This_Player.GetBagItemCount(Iname); end; end; end; This_NPC.NpcDialog(This_Player, '你的包裹中有' + inttostr(ZMnum) + '件王者装备,回收可获得:' + inttostr(getGoldNum(7) div 1 * ZMnum) + '个元宝,你确定回收所有王者装备吗?\|' +'|{cmd}<确认回收所有王者装备/@wangzhe1_True>' +'|{cmd}<返回/@zhuangDlg_22>'); end; procedure _wangzhe1_True; var ZMnum , i , j , itemNum : integer; Iname : string; begin ZMnum := 0; for i := 1 to 40 do begin Iname := getZBnameById(700 + i); if Iname <> '' then begin itemNum := This_Player.GetBagItemCount(Iname); if itemNum > 0 then begin ZMnum := ZMnum + itemNum; This_Player.Take(Iname, itemNum); for j := 1 to itemNum do This_Player.ScriptRequestAddYBNum(getGoldNum(7)); end; end; end; This_NPC.NpcDialog(This_Player, '恭喜你获得:' + inttostr(getGoldNum(7) div 1 * ZMnum) + '个元宝!\|' +'|{cmd}<返回/@zhuangDlg_22>'); end; procedure _tianlong1_all; var ZMnum , i : integer; Iname : string; begin ZMnum := 0; for i := 1 to 40 do begin Iname := getZBnameById(800 + i); if Iname <> '' then begin if This_Player.GetBagItemCount(Iname) > 0 then begin ZMnum := ZMnum + This_Player.GetBagItemCount(Iname); end; end; end; This_NPC.NpcDialog(This_Player, '你的包裹中有' + inttostr(ZMnum) + '件天龙装备,回收可获得:' + inttostr(getGoldNum(8) div 1 * ZMnum) + '个元宝,你确定回收所有天龙装备吗?\|' +'|{cmd}<确认回收所有天龙装备/@tianlong1_True>' +'|{cmd}<返回/@zhuangDlg_22>'); end; procedure _tianlong1_True; var ZMnum , i , j , itemNum : integer; Iname : string; begin ZMnum := 0; for i := 1 to 40 do begin Iname := getZBnameById(800 + i); if Iname <> '' then begin itemNum := This_Player.GetBagItemCount(Iname); if itemNum > 0 then begin ZMnum := ZMnum + itemNum; This_Player.Take(Iname, itemNum); for j := 1 to itemNum do This_Player.ScriptRequestAddYBNum(getGoldNum(8)); end; end; end; This_NPC.NpcDialog(This_Player, '恭喜你获得:' + inttostr(getGoldNum(8) div 1 * ZMnum) + '个元宝!\|' +'|{cmd}<返回/@zhuangDlg_22>'); end; //主宰 procedure _zhuzai1_all; var ZMnum , i : integer; Iname : string; begin ZMnum := 0; for i := 1 to 40 do begin Iname := getZBnameById(900 + i); if Iname <> '' then begin if This_Player.GetBagItemCount(Iname) > 0 then begin ZMnum := ZMnum + This_Player.GetBagItemCount(Iname); end; end; end; This_NPC.NpcDialog(This_Player, '你的包裹中有' + inttostr(ZMnum) + '件主宰装备,回收可获得:' + inttostr(getGoldNum(9) div 1 * ZMnum) + '个元宝,你确定回收所有主宰装备吗?\|' +'|{cmd}<确认回收所有主宰装备/@zhuzai1_True>' +'|{cmd}<返回/@zhuangDlg_22>'); end; procedure _zhuzai1_True; var ZMnum , i , j , itemNum : integer; Iname : string; begin ZMnum := 0; for i := 1 to 40 do begin Iname := getZBnameById(900 + i); if Iname <> '' then begin itemNum := This_Player.GetBagItemCount(Iname); if itemNum > 0 then begin ZMnum := ZMnum + itemNum; This_Player.Take(Iname, itemNum); for j := 1 to itemNum do This_Player.ScriptRequestAddYBNum(getGoldNum(9)); end; end; end; This_NPC.NpcDialog(This_Player, '恭喜你获得:' + inttostr(getGoldNum(9) div 1 * ZMnum) + '个元宝!\|' +'|{cmd}<返回/@zhuangDlg_22>'); end; //传奇 procedure _chuanqi1_all; var ZMnum , i : integer; Iname : string; begin ZMnum := 0; for i := 1 to 40 do begin Iname := getZBnameById(1000 + i); if Iname <> '' then begin if This_Player.GetBagItemCount(Iname) > 0 then begin ZMnum := ZMnum + This_Player.GetBagItemCount(Iname); end; end; end; This_NPC.NpcDialog(This_Player, '你的包裹中有' + inttostr(ZMnum) + '件传奇装备,回收可获得:' + inttostr(getGoldNum(10) div 1 * ZMnum) + '个元宝,你确定回收所有传奇装备吗?\|' +'|{cmd}<确认回收所有传奇装备/@chuanqi1_True>' +'|{cmd}<返回/@zhuangDlg_22>'); end; procedure _chuanqi1_True; var ZMnum , i , j , itemNum : integer; Iname : string; begin ZMnum := 0; for i := 1 to 40 do begin Iname := getZBnameById(1000 + i); if Iname <> '' then begin itemNum := This_Player.GetBagItemCount(Iname); if itemNum > 0 then begin ZMnum := ZMnum + itemNum; This_Player.Take(Iname, itemNum); for j := 1 to itemNum do This_Player.ScriptRequestAddYBNum(getGoldNum(10)); end; end; end; This_NPC.NpcDialog(This_Player, '恭喜你获得:' + inttostr(getGoldNum(10) div 1 * ZMnum) + '个元宝!\|' +'|{cmd}<返回/@zhuangDlg_22>'); end; //天神 procedure _tianshen1_all; var ZMnum , i : integer; Iname : string; begin ZMnum := 0; for i := 1 to 40 do begin Iname := getZBnameById(1100 + i); if Iname <> '' then begin if This_Player.GetBagItemCount(Iname) > 0 then begin ZMnum := ZMnum + This_Player.GetBagItemCount(Iname); end; end; end; This_NPC.NpcDialog(This_Player, '你的包裹中有' + inttostr(ZMnum) + '件天神装备,回收可获得:' + inttostr(getGoldNum(11) div 1 * ZMnum) + '个元宝,你确定回收所有天神装备吗?\|' +'|{cmd}<确认回收所有天神装备/@tianshen1_True>' +'|{cmd}<返回/@zhuangDlg_22>'); end; procedure _tianshen1_True; var ZMnum , i , j , itemNum : integer; Iname : string; begin ZMnum := 0; for i := 1 to 40 do begin Iname := getZBnameById(1100 + i); if Iname <> '' then begin itemNum := This_Player.GetBagItemCount(Iname); if itemNum > 0 then begin ZMnum := ZMnum + itemNum; This_Player.Take(Iname, itemNum); for j := 1 to itemNum do This_Player.ScriptRequestAddYBNum(getGoldNum(11)); end; end; end; This_NPC.NpcDialog(This_Player, '恭喜你获得:' + inttostr(getGoldNum(11) div 1 * ZMnum) + '个元宝!\|' +'|{cmd}<返回/@zhuangDlg_22>'); end; Begin domain; end.