- 积分
- 9246091
- 威望
- 181
- 魅力
- 183
- 经验
- 9232839
- 热心度
- 17
- 注册时间
- 2005-11-5
- 最后登录
- 2025-4-4
- 主题
- 568
- 回帖
- 5783
- 精华
- 42
- 阅读权限
- 200
成长值: 32455
TA的每日心情 | 无聊 2020-5-27 00:09 |
---|
签到天数: 24 天 连续签到: 2 天 [LV.4]狂狼人

管理员
精灵奇侠
  
- 积分
- 9246091
   
|
发表于 2008-3-14 16:21:47
|
显示全部楼层
请将下面的脚本拷贝入你的地图,触发天数要大于500天
城镇可以招募[wiki]8级兵[/wiki],这个脚本我暂时找不到,无法合成给你——这个不是现在wog的官方脚本。以下的脚本,请你按照下面给出的顺序将脚本引入地图,即可正常使用。
1、地图选项-- ZVSE
- !#UN:P5/0;禁止wog化地图
- !#UN:P0/1;启用8级兵生物巢穴
- !#UN:P1/0;箭塔经验累积
- !#UN:P2/0;怪物可以放置在地图上
- !#UN:P3/0;启用指挥官系统
- !#UN:P6/0;英雄初始拥有指挥官,如果需要雇佣指挥官,把0改成1
- !#UN:P7/1;生物巢穴积累生物,如果不需要,把1改成0
- !#UN:P8/1;生物巢穴累积守卫(如果有的话),不需要,把1改成0
- !#UN:P900/1;启用生物经验系统,不需要,把1改成0
- !#UN:P124/1;英雄获得10个技能
- !#UN:P169/1;城镇可以改名
- !#UN:P187/1;英雄可以改名
- !#UN:V?y1/?y2;
- !#VRy3|y1<358/y2<281:Sy1 :100;
- !#VRy4|y1<358/y2<281:Sy1 %100;
- !#VRy5|y1<358/y2<281:Sy2 :100;
- !#VRy6|y1<358/y2<281:Sy1 %100;
- !#VRz10|y1<358/y2<281:S^你的 ERM 版本 : %Y5.%Y6
- 你的 WOG 版本 : %Y3.%Y4
- 此地图必须要求WOG版本 3.58 和ERM版本 2.81
- 你的WOG或者ERM不是最新版,请升级你的WOG^;
- !#IF|y1<358/y2<281:D5/10;
- !#IF|y1<358/y2<281:E1/5;
复制代码 2、GB修改加强版的第一追随者脚本(该脚本较大,需要分两部分引入地图),第一部分-- ZVSE
- !#VRv7206:S0; [initialize "done" flag]
- !#VRv7181:S1;
- ** Timer routines
- !#TM19:S1/1/1/255;
- !?TM19&1000/v7181=1; [continue if enabled day 1 only ]
- !!VRv7218:S0; 经验调整
- !!VRv7220:S0; 进化开关
- !!DO7105/0/155/1&v7206=0:P; [iterate through all heroes]
- ** start of hero screen mouse trigger **
- !?CM2&v7181=1; [continue if enabled]
- !!CM:I?y-3 F?y-4 S?y-5; [get mouse click, flag, subtype]
- !!IF&y-3=141/y-4=512:Q2/-1/-1/1^HENCHMAN BONUS STATS AT LEVEL 1 :
- +1 Attack
- +1 Defense
- +1 Speed
- +2-5 Base Damage
- +10 Base Health
- At every 3rd level : +1 Attack, +1 Defense
- At every 10th level : +1 Speed
- Henchmen gain {Status} for each battle fought and gain levels (indicated by increased stack quantity). They also benefit from a {Status Bonus} based on hero level and current day.
- Henchmen will die after one of the stack is lost, they may offer one last retaliation before doing so.
- Lower level/un-upgraded creatures level up faster than higher level/upgraded creatures.
- The "Disguise" spell is applied to color their quantity tag to help separate them from normal creatures.
- Dead henchmen can be resurrected in a town for a fee based on creature cost and level.
- AI heroes have a (good) chance of having a henchman of random level ({Status} based on hero level). The creature type is chosen randomly each battle and may even be of a type not in the hero's army.
- ^;
- !!FU|y-3<>141/y-4<>0/y-5<>12:E; [continue if player banner (141) was left clicked only, else exit]
- !!CM:H?y-1/?y-2; [get hero number]
- !!IF&y-1>-1:Wy-1; [enable hero variable]
- !!FU7106&w118>-1:Py-1; [if a henchman, display henchman info]
- !!FU7102&w118<0:P; [if no henchman, select one]
- !!UN:R3/-1; [redraw]
- ** end of hero screen mouse trigger **
- ** start of object trigger - towns **
- !?OB98&1000/v7181=1;
- !!OW:I-1/?y-2; [check if human hero]
- !!CA998&y-2=0:O?y-4; [get town owner]
- !!HE-1&y-2=0:N?y-1 O?y-3; [get hero number, owner]
- !!IF&y-2=0/y-1>-1:Wy-1; [enable hero variable]
- !!FU7108&y-2=0/w118>-1/w119=0/y-3=y-4:Py-1; [if dead henchman, display resurrection info]
- *!FU7109&y-2=0/w118=-1/y-3<>y-4:P; [function for reminder message]
- ** end of object trigger - towns **
- ** start of object trigger - monsters **
- !?OB54&1000/v7181=1; [object trigger - monsters]
- !!FU7109:P; 测试时最好关闭 [function for reminder message]
- ** end of object trigger - monsters **
- !?FU7109;
- !!OW:I-1/?y-2; [check if human hero]
- !!HE-1&y-2=0:N?y-1 O?y-3; [get hero number, owner if human]
- !!IF&y-2=0/y-1>-1:Wy-1; [enable hero variable]
- !!IF&y-2=0/w118=-1:Q2/10/y-3/2^You have not yet chosen a Henchman.
- Do you wish to look over your troops and see if any are worthy of the honor?
- (Selecting NO will disable future reminders for this hero.)
- {To open Henchman screen : Left Click on color banner on hero screen}
- {To view Henchman help : Right Click on color banner on hero screen}^;
- !!FU7102&2/y-2=0/w118=-1:P; [if yes select henchman]
- !!VRw118&-2/y-2=0/w118=-1:S-2; [if no set to disable future messages]
- ** end of function **
- ** start of battlefield trigger **
- !?BF&1000/v7181=1; [continue if enabled]
- !!VRv7207:C-1/-1/-1/-1/-1/-1; [initialize variables]
- !!VRy-1:S-2; [initialize variable]
- !!BU:E2/?y-7; [check for enemy creature at position 2 for banks]
- !!BA:H0/?y-1; [get hero number - attacker]
- !!HEy-1&y-1>-1:O?y-3; [get attacker's owner]
- !!OW:Iy-3/?y-6; [check if AI]
- !!FU7103&y-6=1/y-1>-1:Py-1; [choose henchman for AI]
- !!IF&y-1>-1:Wy-1; [enable hero variable - attacker]
- !!VRy-8&y-7<21:S20; [set position - normal]
- !!VRy-8&y-7>20:S25; [set position - bank]
- !!FU7117&v7220=1/y-6<>1:Py-1; 进攻者的追随者进化
- !!VRy18&v7220=1/y-6<>1:Sw118; 临时保存变量
- !!VRw118&v7220=1/y-6<>1/v7221>0:Sv7221; 变更追随者
- !!BU&w118>-1/w119=1/y-1>-1:Sw118/1/y-8/0/-1/0; [add a creature to attacker's army at position y-8]
- !!BU&w118>-1/w119=1/y-1>-1:Ey-8/?v7207; [get stack]
- !!VRv7216:S0;
- !!VRv7216&y-1=144:S1; hero144 henchman spec
- !!FU7101&w118>-1/w119=1/y-1>-1/v7207>-1:Pv7207/0/y-1;[add stat increases - attacker]
- !!BMv7207&w118>-1/w119=1/y-1>-1/v7221>0:M8/100/1; 添加异次门标志
- !!VRw118&v7220=1/y-6<>1/v7221>0:Sy18; 重置追随者类型
- !!VRy-2:S-2; [initialize variable]
- !!BA:H1/?y-2; [get hero number - defender]
- !!FU&y-2<0:E;
- !!HEy-2:O?y-3; [get defender's owner]
- !!OW:Iy-3/?y-6; [check if AI]
- !!FU7103&y-6=1:Py-2; [choose henchman for AI]
- !!IF:Wy-2; [enable hero variable - defender]
- !!FU7117&v7220=1/y-6<>1:Py-2; 防守者,电脑英雄不会有可变追随者
- !!VRy18&v7220=1/y-6<>1:Sw118; 不然,一个不小心计算出圣龙级追随者
- !!VRw118&v7220=1/y-6<>1/v7221>0:Sv7221; 玩家就要倒霉了
- !!BU&w118>-1/w119=1:Sw118/1/30/1/-1/0; [add a creature to defender's army at position 30]
- !!BU&w118>-1/w119=1:E30/?v7208; [get stack]
- !!VRv7217:S0;
- !!VRv7217&y-1=144:S1; hs
- !!FU7101&w118>-1/w119=1/v7208>-1:Pv7208/1/y-2;[add stat increases - defender]
- !!BMv7207&w118>-1/w119=1/v7221>0:M8/100/1;
- !!VRw118&v7220=1/y-6<>1/v7221>0:Sy18;
- ** end of battlefield trigger **
- ;-------------------------------------------------------------------------------
- *由英雄的7支部队计算新追随者的ID
- !?FU7117;
- !!VRv7221:S-1;
- !!VRy30:S0;
- !!HEx1:C0/0/?y11/d;
- !!VRy30&y11<0:+1;
- !!HEx1:C0/1/?y12/d;
- !!VRy30&y12<0:+1;
- !!HEx1:C0/2/?y13/d;
- !!VRy30&y13<0:+1;
- !!HEx1:C0/3/?y14/d;
- !!VRy30&y14<0:+1;
- !!HEx1:C0/4/?y15/d;
- !!VRy30&y15<0:+1;
- !!HEx1:C0/5/?y16/d;
- !!VRy30&y16<0:+1;
- !!HEx1:C0/6/?y17/d;
- !!VRy30&y17<0:+1;
- !!VRy20:S0 +y11 +y12 +y13;
- !!VRy20:+y14 +y15 +y16 +y17;
- !!VRy20&y30>0:+y30; 负补
- !!VRy21:S0;
- !!VRy21&y11>-1:+1;
- !!VRy21&y12>-1:+1;
- !!VRy21&y13>-1:+1;
- !!VRy21&y14>-1:+1;
- !!VRy21&y15>-1:+1;
- !!VRy21&y16>-1:+1;
- !!VRy21&y17>-1:+1;
- !!VRv7221&y20>0/y21>0:Sy20 :y21;
- *!IF:M^1-7:%Y11,%Y12,%Y13,%Y14,%Y15,%Y16,%Y17,all=%Y20,num=%Y21,new=%V7221^;
- ;-------------------------------------------------------------------------------
- ** pre-action trigger
- *v7207为进攻方追随者的堆栈,v7208防守追随者
- !?BG&v7181=1; [continue if enabled]
- !!BMv7207&v7207>-1:N?v7211; [get quantity and health of henchman - attacker]
- !!BMv7208&v7208>-1:N?v7212; [get quantity and health of henchman - defender]
- !!BG&v7207=v7210/v7211=0:A3; [if dead henchman is next set to defend - attacker]
- !!BG&v7208=v7210/v7212=0:A3; [if dead henchman is next set to defend - defender]
- ** end of pre-action trigger
- ** post-action trigger
- *v7211是动作发生前的进攻方追随者数量,y-2是发生后的数量
- *v7216,v7217是追随者特长英雄144的标志,其追随者不受死亡规则影响
- !?BG1&v7181=1; [continue if enabled]
- !!BG:N?v7210; [get current stack #]
- *进攻
- !!BMv7207&v7207>-1:N?y-2 T?y-3; [get quantity, type of henchman stack - attacker]
- !!BMv7207&v7207>-1/y-2<v7211/v7216<>1:K100000; [kill henchman stack if any were killed - attacker]
- !!FU7107&v7207>-1/y-2<v7211/v7216<>1:P0/0/v7207; [set dead - attacker]
- !!BMv7207&v7207>-1/y-2>v7211/y-3<>159/v7216<>1:Nv7213 L0; [reset quantity of henchman stack if resurrected (unless ghost) - attacker]
- !!FU7107&v7207>-1/y-2>v7211/y-3<>159/v7216<>1:P0/1/v7207; [set alive (unless ghost) - attacker]
- !!BU&v7207>-1/y-2<v7211/y-3<>159/v7216<>1:R; [redraw screen (unless ghost)]
- *防守
- !!BMv7208&v7208>-1:N?y-2 T?y-3; [get quantity, type of henchman stack - defender]
- !!BMv7208&v7208>-1/y-2<v7212/v7217<>1:K100000; [kill henchman stack if any were killed - defender]
- !!FU7107&v7208>-1/y-2<v7212/v7217<>1:P1/0/v7208; [set dead - defender]
- !!BMv7208&v7208>-1/y-2>v7212/y-3<>159/v7217<>1:Nv7214 L0; [reset quantity of henchman stack if resurrected (unless ghost) - defender]
- !!FU7107&v7208>-1/y-2<v7212/y-3<>159/v7217<>1:P1/1/v7208; [set alive (unless ghost) - defender]
- !!BU&v7208>-1/y-2<v7212/y-3<>159/v7217<>1:R; [redraw screen (unless ghost)]
- ** end of post-action trigger
- ** function to get monster names
- !?FU7100; x1= Z index
- !!HE-1:C0/x16/?y1/?y2; [get monster in slot x16 type, quantity]
- !!UN&x16=0/y1>-1:N3/2/y1/0; [get monster name]
- !!UN&x16=1/y1>-1:N3/3/y1/0; [get monster name]
- !!UN&x16=2/y1>-1:N3/4/y1/0; [get monster name]
- !!UN&x16=3/y1>-1:N3/5/y1/0; [get monster name]
- !!UN&x16=4/y1>-1:N3/6/y1/0; [get monster name]
- !!UN&x16=5/y1>-1:N3/7/y1/0; [get monster name]
- !!UN&x16=6/y1>-1:N3/8/y1/0; [get monster name]
- ** end of function
- ** function to give stat increases x1=stack x2=attacker/defender x3=hero number
- !?FU7101;
- !!BMx1:T?y6; [get stack type]
- !!FU7104&y6>-1:Py6; [get monster level]
- !!VRy7&y6>-1:Sv7215; [copy monster level]
- !!IF&y6>-1:Wx3; [enable hero variable]
- !!HEx3:E?y1/?y2/1; [get hero exp, level]
- !!VRy10:Sy2 -1 *10 +w117 +c; [experience points = (hero level -1) x10 +earned xp + current day]
- !!VRv7213&x2=0/y6>-1:Sy10 :y7 +1; [level = experience points / monster level + 1 - attacker]
- !!VRv7214&x2=1/y6>-1:Sy10 :y7 +1; [level = experience points / monster level + 1 - defender]
- !!VRy8&x2=0/y6>-1:Sv7213; [copy attacker level to y8]
- !!VRy8&x2=1/y6>-1:Sv7214; [copy defender level to y8]
- !!VRy4&y6>-1:Sy8 :10 +1; [bonus = level / 10 + 1]
- !!BMx1&y6>-1:Sdy4; [give +1 speed per 10 levels]
- !!BMx1&y6>-1:U1/d2; [give +2 min damage]
- !!BMx1&y6>-1:U2/d5; [give +5 max damage]
- !!VRy4&y6>-1:Sy8 :3 +1; [bonus = level / 3 + 1]
- !!BMx1&y6>-1:Ady4 Ddy4; [give +1 attack and +1 defense per 3 levels]
- !!BMx1&y6>-1:H?y4; [get health]
- !!VRy5&y6>-1:Sy4 +10 *y8; [health - add 10, multiply by level]
- !!BMx1&y6>-1:Hy5; [set health]
- **参考nf_xp的"帐篷导致追随者死亡Bug修正"一帖,Thank
- !!BMx1&y6>-1:Ny8 By8; [set quantity to level]
- *!BMx1|y6=63/y6=154:By8; [if vampire lord or blood dragon set starting quantity to level]
- !!BMx1&y6>-1/v7221<=0:M4/100/1; [give disguise dummy spell to make tag yellow]
- ;由v7218的内容选择执行下面其中一条.
- !!VRw117&v7218=0:+6 T4; [After win,gain 6-10 points per battle]
- !!VRw117&v7218=1:+10 T5; 10-15
- !!VRw117&v7218=2:+20 T10; 20-30
- !!VRw117&v7218=3:+50; 50
- ;由英雄等级确定追随者的经验等级
- !!VRy11:Sy2 :2; 英雄级别/2
- !!VRy11&y11>10:S10; 限制最高10级
- !!VRy12:Sx1 *-1 -1; 计算经验堆栈值
- !!EAy12:Ey11/12/d/d; 按英雄级别给予追随者经验等级
- !!FU7118&y11>=5/y5>999:Px3/x1; 5级+1000生命以上的追随者获得英雄奖励特技
- *tactics speed boost if enabled*
- !!UN:P218/?y1; [check if tactics is enabled in WoG options]
- !!FU&y1<>1:E; [exit if it isn't]
- !!VRy3:S0; [initialize y3]
- !!VRy4:S0; [initialize y4]
- !!BH0:N?y1; [attacking hero #]
- !!BH1:N?y2; [defending hero #]
- !!HEy1&y1>=0:S19/?y3; [get attacker's tactics]
- !!HEy2&y2>=0:S19/?y4; [get defender's tactics]
- !!FU&y3=0/y4=0:E; [exit if no one has tactics]
- !!FU&y3=y4:E; [exit if equal tactics level]
- !!FU&y3<y4/x2=0:E; [exit if defender's tactics superior - attacker]
- !!FU&y3>y4/x2=1:E; [exit if attacker's tactics superior - defender]
- !!VRy5&y3>y4/x2=0:S0 +y3 -y4; [set bonus if attackers tactics superior - attacker]
- !!VRy5&y3<y4/x2=1:S0 +y4 -y3; [set bonus if defenders tactics superior - defender]
- !!BMx1&y6>-1:Sdy5; [give tactics speed boost]
- ** end of function
复制代码 GB修改加强版的第一追随者脚本(该脚本较大,需要分两部分引入地图),第二部分-- ZVSE
- *各族英雄的追随者给予相应奖励
- !?FU7118;
- !!BMx2:F?y72;
- !!HEx1:B2/?y70;
- !!VRy70::2;
- !!VRy71&y70=0:Sy72|65536; 人,无反击
- !!VRy71&y70=1:Sy72|32768; 森,2连击
- !!VRy71&y70=2:Sy72|1024; 雪,免疫精神
- !!VRy71&y70=3:Sy72|16384; 恶,免疫火
- !!VRy71&y70=4:Sy72|262144; 鬼,亡灵
- !!VRy71&y70=5:Sy72|8; 龙,龙息
- !!VRy71&y70=6:Sy72|524288; 野,环击
- !!VRy71&y70=7:Sy72|2; 泽,飞行
- !!VRy71&y70=8:Sy72|131072; 元,无士气
- !!BMx2:Fy71;
- ** function to pick henchman
- !?FU7102; x1=
- !!VRz1:S^你需要选择一个新的追随者吗?^;
- !!VRz2:S^^;
- !!VRz3:S^^;
- !!VRz4:S^^;
- !!VRz5:S^^;
- !!VRz6:S^^;
- !!VRz7:S^^;
- !!VRz8:S^^;
- !!VRz9:S^解散追随者^;
- !!VRz10:S^取消^;
- !!VRz11:S^进入追随者ERM加强菜单>>^;
- !!DO7100/0/6/1:P2;
- !!IF&1000:G1/1/256/1/2/3/4/5/6/7/8/9/11/10; [give choice to human]
- !!FU&v1=512:E;
- !!VRy2&v1=1:S0;
- !!VRy2&v1=2:S1;
- !!VRy2&v1=4:S2;
- !!VRy2&v1=8:S3;
- !!VRy2&v1=16:S4;
- !!VRy2&v1=32:S5;
- !!VRy2&v1=64:S6;
- !!HE-1&v1<256:N?y3; [get hero number]
- !!HE-1&v1<128:C0/y2/?y1/d-1; [get monster type, reduce quantity by 1]
- !!IF&v1<256/y3>-1:Wy3; [enable hero variable]
- *!VRw117&v1<256:S0; [reset experience]
- *!VRw117&v1<128::2; 更换则经验值减半.
- !!VRw120&v1<128:S1; 更换则追随天数=1.
- !!VRw118&v1<128:Sy1; [store monster type]
- !!VRw119&v1<128:S1; [set to alive]
- !!IF&v1<128:Q2/21/w118/1^Be worthy of the honor,
- my hero.^; 追随者回应,这句话是"非常荣幸受此殊荣,我的英雄"的意思?
- !!VRw118&v1=128:S-2; [reste monster type if dismissed]
- !!VRw117&v1=128:S0; 解雇则经验值为零
- !!VRw120&v1=128:S0; 解雇则追随天数归零.
- !!MA&v1<128/w118>-1/y3=62:Lw118/?y14; 恶魔泽达
- !!VRy15&v1<128/w118>-1/y3=62:Sy14 +1; 每次更换追随者则增加相应级别的经验
- !!VRw117&v1<128/w118>-1/y3=62:+y15;
- !!FU7115&v1=256:P;
- ;-------------------------------------------------------------------------------
- !?FU7115;
- !!HE-1:N?y3;
- !!FU&y3<0:E;
- !!IF:Wy3;
- !!VRz1:S^追随者ERM加强菜单^;
- !!VRz2:S^^;
- !!VRz2&v7220=0:S^启动 追随者融合进化!迈向终极最强生物!^;
- !!VRz3:S^^;
- !!VRz3&v7220=1:S^禁断 追随者融合进化^;
- !!VRz4:S^消耗魔法点来复活追随者^;
- !!VRz5&w121=0:S^停止该追随者的自动转职^;
- !!VRz5&w121=1:S^^;
- !!VRz6&w121=1:S^启用该追随者的自动转职^;
- !!VRz6&w121=0:S^^;
- !!VRz7&w121=1:S^手动转职^;
- !!VRz7&w121=0:S^^;
- !!VRz8:S^查看该英雄的追随者奖励特技^;
- !!VRz9:S^重新设定经验获得值^;
- !!VRz10:S^取消^;
- !!IF&1000:G1/1/256/1/2/3/4/5/6/7/8/9/10;
- !!FU&v1=256:E;
- !!VRv7220&v1=1:S1; 进化
- !!VRv7220&v1=2:S0; 无进化
- !!IF&w118<0/v1<64:M^Where is your Henchmen?^; 容错处理
- !!IF&w118>-1/w119=1/v1=4:M^Your Henchman alive.Dont need to resurrect.^;
- !!FU7116&w118>-1/w119=0/v1=4:Py3; 魔法复活函数
- !!VRw121&w118>-1/v1=8/w121=0:S1; 停止自动转职w121=1
- !!VRw121&w118>-1/v1=16/w121=1:S0; 启用手动转职w121=1
- !!FU7111&w118>-1/v1=32/w119=1:Py3/200; 转职函数
- !!FU7119&v1=64:Py3;
- !!FU7110&v1=128:P; 经验点增加函数
- ;---------------------------------------------------------------------
- **魔法复活函数
- !?FU7116;
- !!IF:Wx1;
- !!MA:Lw118/?y14;
- !!VRy15:Sy14 +1;
- !!VRy16:Sv7213 *y15;
- !!HEx1:I?y17/1;
- !!IF&y17<y16:M^Need %Y16 MP to resurrect.^;
- !!FU&y17<y16:E;
- !!UN&y17>=y16:N3/2/w118/0; [get monster name]
- !!IF&y17>=y16:Q2/21/w118/2^Resurrect %Z2 for %Y16 MP?^;
- !!VRw119&2:S1;
- !!VRy17&2:-y16;
- !!HE-1&2:Iy17;
- ** end of function
- ;---------------------------------------------------------------------
- ** 重新设定经验点-函数
- !?FU7110;
- !!VRz1:S^请选择每次战斗后获得的经验范围:^;
- !!VRz2:S^6-10,默认.^;
- !!VRz3:S^10-15,标准.^;
- !!VRz4:S^20-30,加强.^;
- !!VRz5:S^50-50,超快.^;
- !!VRz6:S^不选择,退出^;
- !!IF&1000:G1/1/16/1/2/3/4/5/6;
- !!VRv7218&v1=1:S0; 变量v7218保存选择结果
- !!VRv7218&v1=2:S1;
- !!VRv7218&v1=4:S2;
- !!VRv7218&v1=8:S3;
- !?FU7119;
- !!HEx1:B2/?y-70;
- !!VRy-70::2;
- !!VRz1&y-70=0:S^人族英雄追随者: 无反击
- =天佑我军,誓死追随!=^;
- !!VRz1&y-70=1:S^女巫族英雄追随者: 二连击
- 暗夜,出击.^;
- !!VRz1&y-70=2:S^精灵族英雄追随者: 免疫精神魔法
- 绝对服从,永远追随.^;
- !!VRz1&y-70=3:S^恶魔族英雄追随者: 免疫火魔法
- 追随到地狱的最深处!^;
- !!VRz1&y-70=4:S^亡灵族英雄追随者: 不死属性
- 和平,我们最大的敌人^;
- !!VRz1&y-70=5:S^男巫族英雄追随者: 龙息攻击
- 宝物,财富,还是死亡?^;
- !!VRz1&y-70=6:S^野蛮人族英雄追随者: 环击
- 吼吼!杀啊!^;
- !!VRz1&y-70=7:S^驯兽师族英雄追随者: 飞行
- 啊!哦,嗯.^;
- !!VRz1&y-70=8:S^元素族英雄追随者: 无士气
- 无^;
- !!IF:D19/1;
- !!IF:E2/19;
- ** 完
- ;---------------------------------------------------------------------
- !?TM1&1000/v7181=1;
- !!DO7112/0/155/1:P; 追随天数每天加一
- *每天自动检查是否能转职,仅限于玩家的8个可见英雄.
- !!OW:O-1/?y9/?y1/?y2/?y3/?y4/?y5/?y6/?y7/?y8/?y10;
- !!IF&y1>-1:Wy1;
- !!FU7111&y1>-1/w121=0:Py1;
- !!IF&y2>-1:Wy2;
- !!FU7111&y2>-1/w121=0:Py2;
- !!IF&y3>-1:Wy3;
- !!FU7111&y3>-1/w121=0:Py3;
- !!IF&y4>-1:Wy4;
- !!FU7111&y4>-1/w121=0:Py4;
- !!IF&y5>-1:Wy5;
- !!FU7111&y5>-1/w121=0:Py5;
- !!IF&y6>-1:Wy6;
- !!FU7111&y6>-1/w121=0:Py6;
- !!IF&y7>-1:Wy7;
- !!FU7111&y7>-1/w121=0:Py7;
- !!IF&y8>-1:Wy8;
- !!FU7111&y8>-1/w121=0:Py8;
- !?FU7112;
- !!IF:Wx16;
- !!VRw120&w119=1:+1;
- !!VRw117&x16=106:+20; Dessa's HENCHMAN DAY DAY UP
- *升级提示
- !!FU&w118<0:E;
- !!MA&w118>-1:Lw118/?y44;
- *!IF&y44=5/w120=7:M^6to7^;
- *!IF&y44=6/w120=8:M^7to7^;
- !!FU|w120<>13/y44<6:E;
- !!IF|w118=13/w118=27/w118=41/w118=131/w118=97:M^Tomorrow,Holy!Light!Victory!
- 8th henchman coming.^;
- !!IF|w118=83/w118=69/w118=111/w118=55:M^Tomorrow,Evil!Darkness!Kill!
- 8th henchman coming.^;
- ;-------------------------------------------------------------------------------
- ** 转职函数 **
- !?FU7111;
- !!IF:Wx1;
- !!FU|w118<0/w119=0:E; 追随者不存在或死亡则退出
- !!FU7113:Pw118; 检查该兵种的最低追随天数
- !!IF&w120<v7219/x2=200:M^Follow days too low.^; 少于最低天数则退出
- !!FU&w120<v7219:E;
- !!VRy18:Sw118;
- !!VRw118:+1; 在原追随者类型上+1来获得转职对象的类型
- *7级兵另外处理
- !!VRw118&y18=158:S150; 8级兵循环转职
- !!VRw118&y18=13:S150;
- !!VRw118&y18=27:S151;
- !!VRw118&y18=41:S152;
- !!VRw118&y18=55:S153;
- !!VRw118&y18=69:S154;
- !!VRw118&y18=83:S155;
- !!VRw118&y18=97:S156;
- !!VRw118&y18=111:S157;
- !!VRw118&y18=131:S158;
- *元素城的非线性处理,真麻烦
- !!VRw118&y18=119:S112;
- !!VRw118&y18=112:S127;
- !!VRw118&y18=113:S125;
- !!VRw118&y18=114:S129;
- !!VRw118&y18=115:S123;
- !!VRw118&y18=127:S115;
- !!VRw118&y18=123:S114;
- !!VRw118&y18=129:S113;
- !!VRw118&y18=125:S120;
- !!VRw118&y18=121:S130;
- *中立兵种的转职重排,trouble..
- !!VRw118&y18=117:S173; 钻石人到圣诞小鬼
- !!VRw118&y18=139:S138;
- !!VRw118&y18=138:S143;
- !!VRw118&y18=143:S140;
- !!VRw118&y18=140:S142;
- !!VRw118&y18=142:S141;
- !!VRw118&y18=141:S144;
- !!VRw118&y18=136:S193;
- !!VRw118&y18=137:S170;
- !!VRw118&y18=135:S132;
- !!VRw118&y18=168:S133;
- !!VRw118&y18=167:S169;
- !!VRw118&y18=148:S164; 禁止箭塔出现,转向到火使者164
- !!VRw118&y18=196:S0; 龙巫妖到枪兵(196>>0),循环处理
- !!VRy12:Sw120;
- !!VRw120&x2<>200:S0; 追随天数置一
- **手动转职的提问,真FC,以前同样的代码竟然写了两次.
- !!IF&x2=200:Q5/21/y18/21/w118/2^Fellow days OK,upgrade?^; 提问是否转职
- !!VRw118&-5/x2=200:Sy18;
- !!VRw120&5/x2=200:S0;
- ** 转职函数结束 **
- ;---------------------------------------------------------------------
- ** 检查最低追随天数
- !?FU7113;
- !!MA:Lx1/?y10; 检查该追随者的等级
- !!VRv7219&y10=0:S3; 一级兵为3天,每级+1
- !!VRv7219&y10=1:S4;
- !!VRv7219&y10=2:S5;
- !!VRv7219&y10=3:S6;
- !!VRv7219&y10=4:S7;
- !!VRv7219&y10=5:S8;
- !!VRv7219&y10=6:S9; 未升级的7级兵转升级的需9天
- ;高级七级兵到八级兵需要14天
- !!VRv7219|x1=13/x1=27/x1=41/x1=55/x1=69/x1=83/x1=97/x1=111/x1=131:S14;
- ;---------------------------------------------------------------------
- ** function to pick henchman for AI
- !?FU7103; x1= hero # x16= slot #
- !!IF:Wx1; [enable hero variable]
- *!HEx1&y1<7:C0/y1/?y2/?y3; [get monster type, quantity in slot y1]
- !!VRy2:S0 T173; [random 0 to 199]
- !!VRy2&y2>=132/y2<=135:S105; [random 0 to 173 (reroll if super dragons were selected)]
- !!VRy2&y2>=150/y2<=158:S136; [random 0 to 173 (reroll if 8th levels were selected)]
- !!VRy2&y2>=145/y2<=149:S172; [random 0 to 131 (reroll if war machines were selected)]
- !!VRy2&y2>=160/y2<=163:S63; [random 0 to 131 (reroll if emissaries were selected)]
- !!VRy2&y2=122:S192; [set NOT USED 1 to sylvan centaur]
- !!VRy2&y2=124:S193; [set NOT USED 2 to sorceress]
- !!VRy2&y2=126:S194; [set NOT USED 3 to werewolf]
- !!VRy2&y2=128:S195; [set NOT USED 4 to hell steed]
- !!VRy2&y2>173:S196; Dracolich
- !!VRy2&y2<0:S132; xixi
- !!MA:Ly2/?y11;
- !!VRy2&y11=6:S121; 7级兵替换为魔法元素
- !!HEx1&y2>-1:E?y6/?y7/1; [get hero exp, level]
- !!VRy4&y2>-1:S25 T10 *y7; [random # 25-35 x hero level]
- !!VRw118&y2>-1:Sy2; [set henchman type]
- !!VRw117&y2>-1/w118>-1/y4>w117:Sy4; [set AI experience if greater than previous]
- !!VRw117&y7>=15/y7<=19:+250; 高等级电脑英雄每次有更多经验奖励
- !!VRw117&y7>=20/y7<=25:+500;
- !!VRw117&y7>=26:+1000;
- !!VRw119&y2>-1:S1; [set to alive]
- *!VRw119&y2=-1:S0; [set to dead]
- ** end of function
- ** function to get creature level x1=type
- !?FU7104;
- !!MA:Lx1/?y7; [get monster level (0-6)]
- !!VRy8:S0; [set to 0]
- !!VRy8&x1<112:Sx1 %2; [check if upgraded]
- !!VRv7215&y7=0/y8=0:S20; [if level 1 = 20]
- !!VRv7215&y7=1/y8=0:S25; [if level 2 = 25]
- !!VRv7215&y7=2/y8=0:S35; [if level 3 = 35]
- !!VRv7215&y7=3/y8=0:S50; [if level 4 = 50]
- !!VRv7215&y7=4/y8=0:S75; [if level 5 = 75]
- !!VRv7215&y7=5/y8=0:S115; [if level 6 = 115]
- !!VRv7215&y7=6/y8=0:S180; [if level 7 = 180]
- !!VRv7215&y7=0/y8=1:S22; [if level 1 = 22 (upgrade)]
- !!VRv7215&y7=1/y8=1:S28; [if level 2 = 28 (upgrade)]
- !!VRv7215&y7=2/y8=1:S40; [if level 3 = 40 (upgrade)]
- !!VRv7215&y7=3/y8=1:S58; [if level 4 = 58 (upgrade)]
- !!VRv7215&y7=4/y8=1:S88; [if level 5 = 88 (upgrade)]
- !!VRv7215&y7=5/y8=1:S136; [if level 6 = 136 (upgrade)]
- !!VRv7215&y7=6/y8=1:S250; [if level 7 = 250 (upgrade)]
- !!VRv7215&x1=112:S35; [make air elemental = 35]
- !!VRv7215&x1=127:S40; [make storm elemental = 40]
- !!VRv7215&x1=113:S50; [make earth elemental = 50]
- !!VRv7215&x1=121:S58; [make magma elemental = 58]
- !!VRv7215&x1=119:S22; [make sprite = 22]
- !!VRv7215&x1=121:S136; [make magic elemental = 136]
- !!VRv7215&x1=123:S40; [maker ice elemental = 40]
- !!VRv7215&x1=129:S58; [make energy elemental = 58]
- !!VRv7215&x1=131:S225; [make phoenix = 225]
- !!VRv7215&x1=132:S550; [make azure dragon = 550]
- !!VRv7215&x1=133:S450; [make crystal dragon = 450]
- !!VRv7215&x1=134:S350; [make faerie dragon = 350]
- !!VRv7215&x1=135:S400; [make rust dragon = 400]
- !!VRv7215&x1>=150/x1<=158:S400; [make level 8 creatures = 400]
- !!VRv7215&x1=63:S80; [make vampire lord = 80]
- !!VRv7215&x1=159:S25; [make ghost = 25]
- !!VRv7215&x1=172:S136; [make nightmare = 136]
- !!VRv7215&x1=196:S500; [make dracolich = 500]
- ** end of function
- ** function to initialize hero variable w118
- !?FU7105;
- !!IF:Wx16; [enable hero variable]
- !!VRw117:S0; 经验清零
- !!VRw118:S-1; 追随者无
- !!VRw120:S0; 追随天数清零
- !!VRw121:S0; 默认为自动转职
- !!VRw117&x16>=145:S256; 特殊战役英雄开始有经验奖励
- **给予追随者
- !!VRw118&x16=146:S12; 女王的天使追随者
- !!VRw118&x16=149:S96; 独眼龙的小白
- !!VRw118&x16=150:S67; 哈特的黑骑
- !!VRw118&x16=152:S139; 地主的农民
- !!VRw118&x16=153:S82; 龙女的红龙
- !!VRw118&x16=155:S54; X的小恶魔
- !!VRw119|x16=146/x16=149/x16=150/x16=152/x16=153/x16=155:S1;
- !!VRv7206:S1; [set "done" flag]
- ** end of function
- ** function to display henchman x1 = hero number
- !?FU7106;
- !!IF&x1>-1:Wx1; [enable hero variable]
- !!VRz1:S^^;
- !!VRz1&w119=0:S^<<<<{DEAD}>>>>^;
- !!FU7104&w118>-1:Pw118; [function to get monster level]
- !!HEx1:E?y1/?y2/1; [get hero exp, level]
- !!VRy2:-1 *10 +c -1; [bonus status = (hero level -1) x10 + current day -1]
- !!VRy11:Sw117 +y2; [total status points = earned status + bonus status]
- !!VRy3:Sy11 :v7215 +1; [henchman level = status points / level rate + 1]
- !!VRy4:Sy11 %v7215 -v7215 *-1; [calculate status needed for next level]
- !!MA&w118>-1:Aw118/?y1; [get base attack]
- !!VRy5:Sy3 :3 +1 +y1; [attack = level / 10 + 1 + base]
- !!MA&w118>-1:Dw118/?y1; [get base defense]
- !!VRy6:Sy3 :3 +1 +y1; [defense = level / 3 + 1 + base]
- !!MA&w118>-1:Pw118/?y1; [get base health]
- !!VRy7:Sy1 +10 *y3; [health = base + 2 x level]
- !!MA&w118>-1:Mw118/?y1; [get base damage min]
- !!VRy8:Sy1 +2 *y3; [damage min = base + 2 x level]
- !!MA&w118>-1:Ew118/?y1; [get base damage max]
- !!VRy9:Sy1 +5 *y3; [damage max = base + 5 x level]
- !!MA&w118>-1:Sw118/?y1; [get base speed]
- !!VRy10:Sy3 :10 +1 +y1; [speed = level / 3 + 1 + base]
- !!FU7113:Pw118;
- !!IF:Q2/21/w118/2^{Henchman level} : %Y3
- {Level Rate} : %V7215 {Status for next level} : %Y4
- {Status Total} : %Y11 {Earned} : %W117 {Bonus} : %Y2
- Attack : %Y5 Defense : %Y6
- Health : %Y7 Damage : %Y8-%Y9
- Speed : %Y10
- Follow : %W120 days
- (Follow Rate=%V7219 days)
- %Z1
- {Do you wish to select a new Henchman?}^;
- !!FU7102&2:P; [if yes, select henchman]
- ** end of function
- ** function to handle dead/alive status
- !?FU7107; x1=attacker/defender x2= dead/alive
- !!BA&x1=0:H0/?y1; [get hero number - attacker]
- !!BA&x1=1:H1/?y1; [get hero number - defender]
- !!IF:Wy1; [enable hero variable]
- !!VRw119:Sx2; [set to x2 0=dead,1=alive]
- !!BMx3&x2=0:V15 V80; 追随者死亡时动画
- !!BMx3&x2=1:V20 V51; 追随者复活时动画
- !!BMx1&x2=1/v7221<=0:M4/100/1; 标志
- !!BMx1&x2=1/v7221>0:M8/100/1;
- ** end of function
- ** function to resurrect dead henchman
- !?FU7108;
- !!IF&x1>-1:Wx1; [enable hero variable]
- !!FU7104&w118>-1:Pw118; [get monster level]
- !!HEx1:E?y6/?y7/1; [get hero exp, level]
- !!IF&x1>-1:Wx1; [enable hero variable]
- !!VRy10:Sy7 -1 *10 +w117 +c; [experience points = (hero level -1) x10 +earned xp + current day]
- !!VRy3:Sy10 :v7215 +1; [henchman level = experience points / level rate + 1]
- !!MA:Cw118/6/?y8; [get base creature cost]
- !!VRy4:Sy8 *y3 :5; [resurrection cost = base cost x henchman level / 5]
- !!IF:Q2/21/w118/2^{Henchman level = %Y3}
- Do you wish to resurrect this Henchman?
- It will cost %Y4 gold.^;
- !!OW:R-1/6/?y5; [get current gold amount]
- !!VRy8&2/y5>=y4:Sy5 -y4; [calculate gold transaction]
- !!OW&2/y5>=y4:R-1/6/y8; [if yes and player has enough gold,set new gold amount]
- !!VRw119&2/y5>=y4:S1; [if yes and player has enough gold, set to alive]
- !!IF&2/y5<y4:M^Sorry, you can't afford to pay for the resurrection.^; [if yes and player does not have enough gold, display message]
- ** end of function
- ***END***
复制代码 3.城镇、英雄可以改名、重排-- ZVSE
- !?CM1&999;
- !!UN:P169/?v1; [Check if town renaming option is enabled]
- !!CM:A?v2/?v3 F?v4 S?v5; [Get x/y position, mode and flags of click]
- !!FU10813&v1=1/v2>=79/v2<=240/v3>=387/v3<=405/v4=0/v5=12:P; [Call renaming function if town name is left-clicked]
- -------------------------------------------------------------------------------
- [Hint Text trigger: Display new hint text for Town Name field]
- !?MM1&999;
- !!UN:P169/?v1; [Check if town renaming option is enabled]
- !!FU&v1<>1:E; [Exit if Town Renaming isn't enabled]
- !!VRz-1:Sz125000;
- !!CM:A?v2/?v3; [Get x/y position of mouse pointer (v2/v3)]
- !!CM&v2>=79/v2<=240/v3>=387/v3<=406:Mz-1; [Display hint text]
- -------------------------------------------------------------------------------
- [Town renaming function]
- !?FU10813;
- !!CA-1:N?z1; [Store name of town in z-1]
- !!VRz2:Sz125001;
- !!VRz3:Sz125002;
- !!VRz4:S^^;
- !!IF:D17/2/3/4/4/4/4/4/4/4/4/4/4/4/4/4; [Set up dialogue box]
- !!IF:E1/17; [Display dialogue box]
- !!VRz1:H1; [Set flag 1 to true if text entered, false if no text entered]
- !!FU|-1/v1<1:E; [Exit if no text entered]
- !!UN:U98/-1/?y1; [Number of towns on map: y1]
- !!VRv1:S-1; [Initialize v1 to -1 for fast UN:U looping: v1]
- !!IF:V2/0; [Initialize Flag 2 to False]
- !!DO10808/1/y1/1:P; [Loop through all towns to check for duplicate names]
- !!CA-1&-2:Nz1; [Change town name if text entered and not a duplicate]
- !!IF&-2:M1/z125003; [Display message that name will be updated]
- !!IF&2:M1/z125087; [Display message that duplicate name was found]
- -------------------------------------------------------------------------------
- [Check for duplicate town name - set Flag 2 to True if duplicate found]
- !?FU10808;
- !!UN:U98/-1/-1/1; [Next town coordinates at v1/v2/v3]
- !!CAv1/v2/v3:N?z5; [Town name: z5]
- !!IF&z1=z5:V2/1; [Set Flag 2 to TRUE if duplicate town is found]
- !!VRx16&2:S999; [Exit loop if duplicate town name found]
- -------------------------------------------------------------------------------
- [End of Town Renaming]
- ZVSE
- !?CM2&999;
- !!UN:P187/?y-1; [Check if script is enabled: y-1]
- !!FU&y-1<>1:E; [Exit if script isn't enabled]
- !!CM:A?v1/?v2 F?v3 S?v4; [x/y location clicked, v3 = flags, v4 = type of click]
- !!VRv3:S0; [Initialize v3 to 0]
- !!VRv3&v1>=146/v2>=27/v1<=362/v2<=60/v3=0/v4=12:S1; [Set v3 to 1 if Hero's name is clicked on]
- !!FU&v3<>1:E; [Exit if Hero's name isn't clicked]
- !!HE-1:B0/?z9; [Store name of Hero in z9]
- !!VRz2:Sz125019;
- !!VRz3:Sz125020;
- !!VRz4:S^^;
- !!IF:D17/2/3/4/4/4/4/4/4/4/4/4/4/4/4/4; [Set up dialogue box]
- !!IF:E1/17; [Display dialogue box]
- !!VRz1:H1; [Set flag 1 to true if text entered, false if no text entered]
- !!FU|-1/v1<1:E; [Exit if nothing entered]
- !!VRy-9:S0; [Initialize y-9 to 0]
- !!DO10815/0/155/1:P; [Check for a duplicate hero name: set y-9 to 99 if duplicate]
- !!FU&y-9=99:E; [Exit if duplicate name found]
- !!VRz2:Sz9; [Store old name in z2]
- !!VRz2:M4/?y-2; [Length of old name: y-2]
- !!VRz1:M5/?y-6; [1st non-space character position of new name: y-6]
- !!VRz1:M6/?y-7; [Last non-space character position of new name: y-7]
- !!VRy-8:Sy-7 +1 -y-6; [Length of new name string to copy: y-8]
- !!VRy-8&y-8>12:S12; [Maximum 12 characters: y-8]
- !!VRz3:M1/z1/y-6/y-8; [Store up to first 12 characters of new name in z3]
- !!VRz3:M4/?y-3; [Length of new name: y-3]
- !!HE-1:B0/z3; [Change hero's name if text entered: z3]
- !!HE-1:B1/?z1; [Read custom bio (if any): z1]
- !!VRz1:H1; [Set flag 1 to True if custom bio exists, false if no custom bio yet]
- !!HE-1&-1:B3/?z1; [Read hero's default bio if no custom bio: z1]
- !!VRz1:M4/?y-1; [Length of bio: y-1]
- !!VRy-4:Sy-1 +200; [Add 200 to bio length: y-4]
- !!VRy-5:S-1; [Initialize y-5 to -1]
- !!DO10937/0/y-4/1&y-1>0:P; [Replace old name with new name in hero's bio]
- !!UN:R3/-1; [Redraw Hero screen]
- ------------------------------------------------------------------------------------------------------------------
- [Loop through all heroes to check for a duplicate]
- [hero name: Set y-9 to 99 if duplicate found]
- !?FU10815;
- !!HEx16:B0/?z8; [Hero x16's name: z8]
- !!VRy-9&z8=z1:S99; [Set y-9 to 99 if duplicate found]
- !!VRx16&z8=z1:S999; [Set x16 to 999 to exit loop if duplicate found]
- !!IF&z8=z1:M1/z125088; [Display message that a duplicate hero name was found]
- ------------------------------------------------------------------------------------------------------------------
- [Replace old name with new name in hero's bio]
- !?FU10937;
- !!VRz-1:M1/z1/x16/y-2; [Get a substring of old name-length: z-1]
- !!FU&z-1<>z2:E; [Skip to next loop number if old name not found yet]
- !!VRy-5:Sx16; [If old name found, set y-5 to start position: x16]
- [Build new bio string: z-2]
- !!VRz-2:M1/z1/0/x16; [1st part of string: z-2]
- !!VRy1:Sx16 +y-2; [Start of 2nd part of string after name: y1]
- !!VRy2:Sy-1 -y1; [Length of 2nd part of string after name: y2]
- !!VRz-3:M1/z1/y1/y2; [2nd part of string: z-3]
- !!VRz1:S^%Z-2%Z3%Z-3^; [New string: z1]
- !!HE-1:B1/z1; [Set new bio: z1]
- !!VRz1:M4/?y-1; [Update length of bio: y-1]
- ------------------------------------------------------------------------------------------------------------------
- [End of Hero Renaming]
- !?CM5&999;
- !!CM:F?y-1 I?y-2; [Type of click (1=shift): y-1, Location clicked: y-2]
- !!CM:S?y-3; [Subtype of click (12 if left click, 13 if left click-release): y-3]
- !!FU&y-1<>1:E; [Exit if not a shift-click]
- !!FU41&y-2>=39/y-2<=43:P; [Call Function 41 if a Hero slot is shift-clicked]
- !!FU42&y-2>=32/y-2<=36:P; [Call Function 42 if a Town slot is shift-clicked]
- [Move Hero shift-clicked to first slot]
- !?FU41;
- !!VRy1:Sy-2 -39; [Hero slot that's shift-clicked (0..4): y1]
- !!OW:O-1/y1/?y2; [Hero that's shift-clicked in Hero list: y2]
- !!OW:A-1/?y3; [Active hero: y3]
- !!CM&y2=y3/y-3<>13:R0; [Cancel normal click operation if active hero shift-clicked]
- !!FU|y2<0/y-3<>13:E; [Exit if no hero in hero slot or if not shift-click release]
- !!OW:O-1/1/y1/0; [Move hero to top of list]
- !!OW:A-1/y2; [Set active hero to hero shift-clicked: y2]
- !!CM:R0; [Cancel normal click operation for shift click-release]
- !!UN:R1; [Redraw screen]
- [Move town shift-clicked to first slot]
- !?FU42;
- !!VRy1:Sy-2 -32; [Town slot that's shift-clicked (0..4): y1]
- !!OW:N-1/y1/?y2; [Real Town number of Town shift-clicked in Town list: y2]
- !!OW:N-1/?y3; [Active town number: y3]
- !!CM&y2=y3/y2>=0/y-3<>13:R0; [Disabled standard click response if active town clicked]
- !!FU|y2<0/y-3<>13:E; [Exit if no town in town slot or if not shift-click release]
- !!OW:N-1/1/y1/0; [Move town to top of list]
- !!UN:R1; [Redraw screen]
- !?CM5&999;
- !!CM:F?y-1 I?y-2; [Type of click (1=shift): y-1, Location clicked: y-2]
- !!CM:S?y-3; [Subtype of click (12 if left click, 13 if left click-release): y-3]
- !!FU&y-1<>1:E; [Exit if not a shift-click]
- !!FU41&y-2>=39/y-2<=43:P; [Call Function 41 if a Hero slot is shift-clicked]
- !!FU42&y-2>=32/y-2<=36:P; [Call Function 42 if a Town slot is shift-clicked]
- [Move Hero shift-clicked to first slot]
- !?FU41;
- !!VRy1:Sy-2 -39; [Hero slot that's shift-clicked (0..4): y1]
- !!OW:O-1/y1/?y2; [Hero that's shift-clicked in Hero list: y2]
- !!OW:A-1/?y3; [Active hero: y3]
- !!CM&y2=y3/y-3<>13:R0; [Cancel normal click operation if active hero shift-clicked]
- !!FU|y2<0/y-3<>13:E; [Exit if no hero in hero slot or if not shift-click release]
- !!OW:O-1/1/y1/0; [Move hero to top of list]
- !!OW:A-1/y2; [Set active hero to hero shift-clicked: y2]
- !!CM:R0; [Cancel normal click operation for shift click-release]
- !!UN:R1; [Redraw screen]
- [Move town shift-clicked to first slot]
- !?FU42;
- !!VRy1:Sy-2 -32; [Town slot that's shift-clicked (0..4): y1]
- !!OW:N-1/y1/?y2; [Real Town number of Town shift-clicked in Town list: y2]
- !!OW:N-1/?y3; [Active town number: y3]
- !!CM&y2=y3/y2>=0/y-3<>13:R0; [Disabled standard click response if active town clicked]
- !!FU|y2<0/y-3<>13:E; [Exit if no town in town slot or if not shift-click release]
- !!OW:N-1/1/y1/0; [Move town to top of list]
- !!UN:R1; [Redraw screen]
复制代码 |
|