//还在打怪 KeyPressH 53,1 //补红小红 Delay 200 IfColor hong1/100*((x-616)-(x-733))+(x-733),y+11,color(0),2 //血少于hong1%检测 Delay 10 Else KeyPressH 118,1 //加大红保护 Delay 200 //------------------- Gosub 死亡检测 //------------------ EndIf Else Delay 100 KeyPressH 55,1 //没怪,打坐回红 Delay 10 t(6)=now //初始化 Rem 补满血 Delay 200 IfColor x-316,y+7,0C0E10,0 //补怪攻击 Goto 打坐中断 EndIf Delay 200 IfColor 99/100*((x-616)-(x-733))+(x-733),y+11,color(0),2 //已满血 Delay 10 Goto 打坐中断 EndIf //--------------------------------- Gosub 打坐时间检测 Delay 10 Gosub 死亡检测 //-------------------------------------------------- Delay 300 Goto 补满血 EndIf EndIf If H=0 Delay 10 KeyPressH 53,1 //补红小红 Delay 200 IfColor hong1/100*((x-616)-(x-733))+(x-733),y+11,color(0),2 //血少于hong1%检测 Delay 10 Else KeyPressH 118,1 //加大红保护 Delay 200 //-------------------------------- Gosub 死亡检测 //------------------------- EndIf EndIf Rem 打坐中断 Return 补红打坐 //****************************************************** Sub 补蓝 Delay 10 KeyPressH 54,1 //补蓝 Delay 200 Return 补蓝 //***************************************************** Sub 捡起物品 Delay 10 For 3 KeyPressH 52,3 //捡起物品 Delay 50 EndFor Return 捡起物品 //****************************************************** // 技能时间判断 //****************************************************** Sub [判断时间] Delay 10 If IsNumeric(sj(m))=True //< IsNumeric 函数:返回 Boolean 值指明表达式的值是否为数字> s(r)=CInt(sj(m)) //< CInt 函数:返回已被转换为整形子类型的变体的表达式> Else Goto 时间 EndIf m=m+1:r=r+1 Rem 时间 Return [判断时间] //******************************************* // 放时间技能 //******************************************** Sub 时间技能 Delay 10 If DateDiff("s",t(1),now)>=s(0) //< DateDiff 函数:返回两个日期之间的时间间隔>