MUD-武林MUD资料站-武侠MUD游戏

 找回密码
 注册

QQ登录

只需一步,快速开始

开启左侧

新副本走路部分调整

 关闭 [复制链接]
是开碧落 发表于 2011-2-11 23:21:50 | 显示全部楼层 |阅读模式
指南针不再需要, 完全按照出口判断走
原来的变量 cstep(走的方向) 还有用, bstep(返回路径, 不再需要使用)
alias stepGo #IF (@leave<>0) {golist=%additem(@cstep,@golist);golist=%remove(|n|s,@golist);golist=%remove(|s|n,@golist);golist=%remove(|w|e,@golist);golist=%remove(|e|w,@golist)}
是找到从入口到出口的最短距离, 也没必要用了

增加触发
^    这里{唯一|明显}的出口是 (*)。
maze_exits=%1

alias stepNow
原来:#IF (@temp=w) {cstep=n;bstep=s};#IF (@temp=n) {cstep=e;bstep=w};#IF (@temp=e) {cstep=s;bstep=n};#IF (@temp=s) {cstep=w;bstep=e}
改成: cstep=0;#if (@temp=w) {#forall (north|west|south|east) {#if (%pos(%i,@maze_exits)>0 and @cstep=0) {cstep=%left(%i,1)}}};#if (@temp=n) {#forall (east|north|west|south) {#if (%pos(%i,@maze_exits)>0 and @cstep=0) {cstep=%left(%i,1)}}};#if (@temp=e) {#forall (south|east|north|west) {#if (%pos(%i,@maze_exits)>0 and @cstep=0) {cstep=%left(%i,1)}}};#if (@temp=s) {#forall (west|south|east|north) {#if (%pos(%i,@maze_exits)>0 and @cstep=0) {cstep=%left(%i,1)}}}

调整触发
^你找不到 move 这样东西。
原来: ddmove;ppp;#IF (%len(@target)>2) {#T+ PFM;ttt;er;kill @target;pfm;nact1="fight"} {#IF (@mark_tag=0) {stepGo;dropMark;temp=@cstep} {temp=@bstep};stepNow;@cstep};get x from @nact1
改成:ddmove;ppp;#IF (%len(@target)>2) {#T+ PFM;ttt;er;kill @target;pfm;nact1="fight"} {temp=@cstep;stepNow;@cstep};get x from @nact1

^战斗中还是好好的凝神对敌吧。
这种因为战斗拦路的继续走路处理也跟上面触发命令一样处理

迷宫出口 触发删掉, 因为一般会强行设置cstep=xx, 默认从入口出去

因为迷宫只有s,e,n,w 4个方向, 所以上面判断走的路径就比较简单, 如果有southup啦,northwest啦, 上面的判断就需要更换一下
MUD - MUD游戏 - 文字MUD - 武林MUD - 长期、稳定、高速、互助、活跃、更新的武侠MUD站点,一起MUD吧!
marvin 发表于 2011-2-23 20:56:35 | 显示全部楼层
夜天的机器人和这个差别较大。

找不到move 的触发

#wa 100;
#if (%len(@kill)>2) {kkk} {#if (@stay=0) {mgolist;
summon @diu_id;
yun refresh;
drop @diu_id;
temp=@cst} {temp=@bst};
minitdr;
@cst;
get x from move}


应该怎么改
是开碧落 发表于 2011-2-23 21:03:28 | 显示全部楼层
夜天的机器人和这个差别较大


增加触发
^    这里{唯一|明显}的出口是 (*)。
maze_exits=%1

alias minitdr
原来:#IF (@temp=w) {cst=n;bst=s};#IF (@temp=n) {cst=e;bst=w};#IF (@temp=e) {cst=s;bst=n};#IF (@temp=s) {cst=w;bst=e}
改成: cstep=0;#if (@temp=w) {#forall (north|west|south|east) {#if (%pos(%i,@maze_exits)>0 and @cst=0) {cst=%left(%i,1)}}};#if (@temp=n) {#forall (east|north|west|south) {#if (%pos(%i,@maze_exits)>0 and @cst=0) {cst=%left(%i,1)}}};#if (@temp=e) {#forall (south|east|north|west) {#if (%pos(%i,@maze_exits)>0 and @cst=0) {cst=%left(%i,1)}}};#if (@temp=s) {#forall (west|south|east|north) {#if (%pos(%i,@maze_exits)>0 and @cst=0) {cst=%left(%i,1)}}}

调整触发
^你找不到 move 这样东西。
原来: #wa 100;#if (%len(@kill)>2) {kkk} {#if (@stay=0) {mgolist;summon @diu_id;yun refresh;drop @diu_id;temp=@cst} {temp=@bst};minitdr;@cst;get x from move}
改成: #wa 100;#if (%len(@kill)>2) {kkk} {temp=@cst;minitdr;@cst;get x from move}

因为战斗拦路的继续走路处理也跟上面触发命令一样处理

迷宫出口 触发删掉, 因为一般会强行设置cst=xx, 默认从入口出去

Archiver|武林MUD资料站 ( 鲁ICP备17038480号 本站关键词:mud 武林mud mud游戏 文字mud

GMT+8, 2024-3-29 22:12

Powered by Discuz! X3.2

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表