That one worked, but was a little slow.... here's another.
Untested
set %bonetypes LNF_QNF_WNF_PNF_KNF_MNF_JNF_YNF_VNF
set %bladetypes BNF_HSF_INF_GMH_RRH_MTF_GUO_XRH_CUO_OPO_XTH_BUO_ZTO_
+UOH_LPH_RMH_ZRF_NSF_BSF_LSF_BPH_SOH_JTF_VRH_NMH_TSF_JPH_NPO_ATF_FUO_
finditem %bladetypes C_ , #backpackID
if #findCnt < 1
gosub FindBlade
set %cutter #findid
gosub pausebuttonmenu
menu hideEUO
SUO:
repeat
if #MENUBUTTON = pause
gosub pause_script
gosub bones
;gosub dispel_rev
until #CharGhost = YES
while #CharGhost = YES
wait 0
GoTo SUO
sub bones
if #targCurs = 1 || #lLiftedKind = 1
return
finditem %bonetypes G_15
if #findkind <> -1
{
event property #findid
if corpse in #property
{
ignoreItem #findid
wait 5
return
}
menu delete pause
menu Font BGColor Red
menu Button pause 0 0 115 45 Cutting...
set #lobjectid %cutter
set #ltargetid #findid
set #ltargetkind 1
event macro 17 0
target
event macro 22 0
if you_may_not in #sysmsg || that_is in #sysmsg
ignoreitem #findid
wait 15
menu delete pause
menu Font BGColor Lime
menu Button pause 0 0 115 45 Pause
}
return
sub FindBlade
set #targcurs 1
display OK Please target your bladed weapon
while #targcurs = 1
wait 0
set %cutter #ltargetid
return
sub dispel_rev
if #targCurs = 1 || #lLiftedKind = 1
return
finditem HS_IS_ G_6
if #findrep = 6
{
set #LTargetID #findid
set #LTargetKind 1
event macro 15 40
target 3s
wait 5
event macro 22
wait 2s
}
return
sub pause_script
set %script paused
set #MENUBUTTON N/A
menu delete pause
menu Font BGColor Red
menu Button pause 0 0 115 45 UnPause #followers / #maxfol
while %script = paused
{
if #MENUBUTTON = pause
{
set %script unpaused
menu delete pause
menu Font BGColor Lime
menu Button pause 0 0 115 45 Pause #followers / #maxfol
set #MENUBUTTON N/A
}
}
return
;--------- EasyUO Menu Designer Code Begin ---------
sub pausebuttonmenu
menu Clear
menu Window Title
menu Window Color BtnFace
menu Window Size 113 44
menu Font Transparent #true
menu Font Align Right
menu Font Name MS Sans Serif
menu Font Size 16
menu Font Style
menu Font Color WindowText
menu Font BGColor Lime
menu Button pause 0 0 115 45 Pause
menu Show 421 270
return
;--------- EasyUO Menu Designer Code End ---------