Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are
spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the
password reset link.
Due to spam on this forum, all posts now need moderator approval.
Entire forum
➜ MUSHclient
➜ Bug reports
➜ timer bug
It is now over 60 days since the last post. This thread is closed.
Refresh page
| Posted by
| Lxhd
(27 posts) Bio
|
| Date
| Fri 13 Feb 2015 04:14 AM (UTC) |
| Message
| | During using timer of muchclient, I found a problem, for example, I set a timer which will be ran at 12:00:00, now the local computer time is 11:30:00, the original remaining time of the timer is 30m, but when the same timer is changed to be ran at 13:00:00 by a trigger, the remaing tiem is now 23h, the timer will not be ran after one and half hour. | | Top |
|
| Posted by
| Nick Gammon
Australia (23,166 posts) Bio
Forum Administrator |
| Date
| Reply #1 on Fri 13 Feb 2015 04:36 AM (UTC) |
| Message
| Can you show the timer, and the trigger please?
 |
For advice on how to copy aliases, timers or triggers from within MUSHclient, and paste them into a forum message, please see Copying XML.
|
|
- Nick Gammon
www.gammon.com.au, www.mushclient.com | | Top |
|
| Posted by
| Lxhd
(27 posts) Bio
|
| Date
| Reply #2 on Fri 13 Feb 2015 04:44 AM (UTC) Amended on Fri 13 Feb 2015 04:57 AM (UTC) by Lxhd
|
| Message
| Please find below my trigger,timer,and script. Sorry, some content in the trigger is in Chinese, hope you could understand my intension.
_______________________________________________
<timer name="takedouble" enabled="y" hour="11" second="0.00" offset_second="0.00" send_to="12"
at_time="y" group="takedouble" >
<send>g_go_take_double=true;</send>
</timer>
__________________________________________________________
<trigger
group="takedouble"
lines_to_match="3"
match="^( |>)*你向李战打听有关『jobreward』的消息。\n\n^玩家可24小时领取一次任务额外奖励,持续时间6小时!!你(.+)个小时前领过!!$"
multi_line="y"
name="double_not_get"
regexp="y"
script="TakeDouble"
send_to="12"
sequence="100"
>
——————————————————————————————
if name=="double_not_get" then
Note(wilcards[2]);
g_go_take_double=false;
AppendToNotepad(player_enamel.."_record",line..os.date().."\r\n");
local _new_doule_time=tonumber(os.date("%H", os.time()))+(24-chinese_to_number(wilcards[2]));
if _new_doule_time>23 then
_new_doule_time=_new_doule_time-24;
end
SetTimerOption ("takedouble", "hour", _new_doule_time);
SetTimer("home",10);
wait.time(3);
ResetTimer("takedouble");---This added on 2015-02-13.
EnableTriggerGroup("takedouble",false);
Execute("move;#5(exert heal);exert recover1");
end
end) | | Top |
|
| Posted by
| Lxhd
(27 posts) Bio
|
| Date
| Reply #3 on Fri 13 Feb 2015 04:51 AM (UTC) |
| Message
| | now I changed the script, add "ResetTimer("takedouble")" in the function, now it is ok. | | Top |
|
| Posted by
| Nick Gammon
Australia (23,166 posts) Bio
Forum Administrator |
| Date
| Reply #4 on Fri 13 Feb 2015 06:06 AM (UTC) |
| Message
| |
| Posted by
| Lxhd
(27 posts) Bio
|
| Date
| Reply #5 on Fri 13 Feb 2015 06:39 AM (UTC) |
| Message
| |
The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).
To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.
21,443 views.
It is now over 60 days since the last post. This thread is closed.
Refresh page
top