如果您想要实现从“初级属性探索一”到“初级属性探索五”的兑换功能,可以按照以下步骤进行操作:
创建一个名为explore_record.txt的文件,用于记录每个角色已经完成的探索等级。
在机器人脚本中添加以下内容:
#AutoRun NPC RUNONWEEK 1:00:00 @初级属性探索一
#AutoRun NPC RUNONWEEK 1:01:00 @初级属性探索二
#AutoRun NPC RUNONWEEK 1:02:00 @初级属性探索三
#AutoRun NPC RUNONWEEK 1:03:00 @初级属性探索四
#AutoRun NPC RUNONWEEK 1:04:00 @初级属性探索五
#初级属性探索一
#act
#if (getarg(1) == 1)
#if (chkcond(CHECKNAMELIST “explore_record.txt” “%charname%”))
sendmsg 1 抱歉,您已经完成了初级属性探索一的兑换,请进行其他操作。
#else
#if (chkcond(HAVEITEM 10001 5))
#addprop 1 5001 1
#addprop 1 5002 1
#addprop 1 5003 1
#addprop 1 5004 1
#delitem 10001 5
#set @filename “explore_record.txt”
#appendto @filename “%charname%:1”
sendmsg 1 恭喜您完成了初级属性探索一的兑换,获得攻、道、魔、防属性各加1点。
#endif
#endif
#endif
#初级属性探索二
#act
#if (getarg(1) == 2)
#if (chkcond(CHECKNAMELIST “explore_record.txt” “%charname%:2”))
sendmsg 1 抱歉,您已经完成了初级属性探索二的兑换,请进行其他操作。
#else
#if (chkcond(HAVEITEM 10002 5))
#addprop 1 5001 2
#addprop 1 5002 2
#addprop 1 5003 2
#addprop 1 5004 2
#delitem 10002 5
#set @filename “explore_record.txt”
#appendto @filename “%charname%:2”
sendmsg 1 恭喜您完成了初级属性探索二的兑换,获得攻、道、魔、防属性各加2点。
#endif
#endif
#endif
#初级属性探索三
#act
#if (getarg(1) == 3)
#if (chkcond(CHECKNAMELIST “explore_record.txt” “%charname%:3”))
sendmsg 1 抱歉,您已经完成了初级属性探索三的兑换,请进行其他操作。
#else
#if (chkcond(HAVEITEM 10003 5))
#addprop 1 5001 3
#addprop 1 5002 3
#addprop 1 5003 3
#addprop 1 5004 3
#delitem 10003 5
#set @filename “explore_record.txt”
#appendto @filename “%charname%:3”
sendmsg 1 恭喜您完成了初级属性探索三的兑换,获得攻、道、魔、防属性各加3点。
#endif
#endif
#endif
#初级属性探索四
#act
#if (getarg(1) == 4)
#if (chkcond(CHECKNAMELIST “explore_record.txt” “%charname%:4”))
sendmsg 1 抱歉,您已经完成了初级属性探索四的兑换,请进行其他操作。
#else
#if (chkcond(HAVEITEM 10004 5))
#addprop 1 5001 4
#addprop 1 5002 4
#addprop 1 5003 4
#addprop 1 5004 4
#delitem 10004 5
#set @filename “explore_record.txt”
#appendto @filename “%charname%:4”
sendmsg 1 恭喜您完成了初级属性探索四的兑换,获得攻、道、魔、防属性各加4点。
#endif
#endif
#endif
#初级属性探索五
#act
#if (getarg(1) == 5)
#if (chkcond(CHECKNAMELIST “explore_record.txt” “%charname%:5”))
sendmsg 1 抱歉,您已经完成了初级属性探索五的兑换,请进行其他操作。
#else
#if (chkcond(HAVEITEM 10005 5))
#addprop 1 5001 5
#addprop 1 5002 5
#addprop 1 5003 5
#addprop 1 5004 5
#delitem 10005 5
#set @filename “explore_record.txt”
#appendto @filename “%charname%:5”
sendmsg 1 恭喜您完成了初级属性探索五的兑换,获得攻、道、魔、防属性各加5点。
#endif
#endif
#endif
Copy
保存并关闭文件,重新启动机器人,即可在每天凌晨1:00-1:04分分别完成初级属性探索一到初级属性探索五的兑换。
注意:
请将10001、10002、10003、10004、10005分别替换为您想要使用的物品ID,表示需要使用的物品。
请将5001、5002、5003、5004分别替换为您想要增加的属性ID,表示需要增加的属性。
完整脚本如上所示。