|
hpoonis2010 Adept
Joined: 18 Jun 2019 Posts: 279
|
Posted: Tue Apr 13, 2021 6:57 pm
Failed GMCP trigger |
This has been working perfectly, even through this morning. This afternoon, different story, I am getting "failed to compile" errors. I can see nothing amiss.
Code: |
<trigger name="dquest_check" type="GMCP" param="201" priority="6810" id="84">
<pattern>comm.quest*</pattern>
<value>#LOCAL $object
#LOCAL $dqKey
$target=%gmcp.comm.quest.targ
$status=%gmcp.comm.quest.action
$room=%gmcp.comm.quest.room
$zone=%gmcp.comm.quest.area
#SWITCH ($status)
("start") {
#VAR D_VARS/dq_key %time("yyyymmddhhmm")
#ADDKEY $object charlev @qCharlev
#ADDKEY $object target $target
#ADDKEY $object room $room
#ADDKEY $object zone $zone
#ADDKEY $object status $status
#ADDKEY D_VARS/d_quests @dq_key $object
$dqKey=@dq_key
}
("comp") {
$object=%db(@d_quests,@dq_key)
#ADDKEY $object totqp %gmcp.comm.quest.totqp
#ADDKEY $object status $status
#ADDKEY D_VARS/d_quests @dq_key $object
$dqKey=@dq_key
#VAR D_VARS/dq_key ""
}
("fail") {
$object=%db(@d_quests,@dq_key)
#ADDKEY $object status $status
#ADDKEY D_VARS/d_quests @dq_key $object
$dqKey=@dq_key
#VAR D_VARS/dq_key ""
}
("killed") {
$object=%db(@d_quests,@dq_key)
#ADDKEY $object killed_in %roomnum()
#ADDKEY $object status $status
$dqKey=@dq_key
#ADDKEY D_VARS/d_quests @dq_key $object
}
("ready") {
#WIN QUESTS @dquest_time "Ready to Quest."
}
("timeout") {
$object=%db(@d_quests,@dq_key)
#ADDKEY $object status $status
#ADDKEY D_VARS/d_quests @dq_key $object
$dqKey=@dq_key
#VAR D_VARS/dq_key ""
}
("warning") {#WIN QUESTS @dquest_time "Daily:"@dq_key %gmcp.comm.quest.time "MINUTES REMAIN!"}
#IF ($status!="ready") {#WIN QUESTS @dquest_time "Daily:"$dq_key": "$target", "$room", "$zone" - "$status}
</value>
</trigger>
|
|
|
|
|
hpoonis2010 Adept
Joined: 18 Jun 2019 Posts: 279
|
Posted: Fri Apr 16, 2021 9:29 am |
Well,
First, I completely rem'd the switch block. Still failed. Then I rem'd everything else. No error. So I re-instated the trailing #IF at the end of the script and used permanent vars. Didn't like that either so I figured that here was the problem.
I rem'd this out and re-instated the switch block. Failed again. Seems that now, after months of use, scrpt engine was unhappy with spaces between each switch option block
() {}
() {}
How strange! After removing the blank lines (I have other switch commands which seem happy with spaces) all seems fine. I did drop the entire script into an external editor to see if there were any 'invis' formatting, white space, etc but nothing.
Thus, I have no idea why it should have given up after working without a hitch for some time. |
|
|
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|