SF Script Stalls 12/16/2018 01:46 AM CST
I'm looking for some help working out an issue with my SF script stalling. I've been writing a blindside script for my Thief which includes the following section:

melee:
put hide
match backstab Roundtime
match melee …wait
matchwait

The section is set up to run after my character closes to melee. After doing so he hides and either goes on to back stab the target or attempts to hide again. 99% of the time it runs start to finish without issue. Around once every 10 or 15 minutes the script executes the "hide" command and my character will successfully hide with a Roundtime: 6 sec. but then the script stalls and won't continue. It doesn't actually terminate or give an error. It just stops running right at that point. Nothing seems to be able to fix it. The repair also seems times based as I've tried logging out and back in, restarting the script, making sure no other events or text is happening etc. Other times I've just walked away for a few minutes and come back. Regardless of what I try it just seems like the script will "fix" itself after a couple of minutes and run fine again for another 10 or 15. Can anyone help?

Thanks!
Reply
Re: SF Script Stalls 12/16/2018 06:58 AM CST
melee:
match backstab Roundtime
match melee …wait
put hide
matchwait


Good practice is tell the script what to look for (match) before you do the action that will generate text (put). I don't know that this will fix the problem but it's good practice.

I can't use SF, but does it have a debug mode? Turn that on if so and see what the script engine is expecting when the script hangs.

~Hunter Hanryu
>Everything Rangers have is just a lame version of something cool.~Morkim
Reply
Re: SF Script Stalls 12/16/2018 01:46 PM CST
Sauva,

Thank you for your suggestion. I made the structural change to all of my arguments and may have discovered the cause while testing them. I ran into a new stall point when the script tells my character to skin the target. The script stalled twice and I noticed it happened when the target decayed away between the script telling my character to skin the target and the actual execution. The text is below:

advance rat
The ship's rat is already quite dead.
>skin rat
A ship's rat decays away.
>
You can't skin something that's not dead!

Even though I have a trigger set to handle the event "A ship's rat decays away." the script stalled. I'm guessing it's because the target of the original command disappeared and SF couldn't handle transitioning to a new one in the middle of executing the action.
Reply
Re: SF Script Stalls 12/16/2018 04:18 PM CST

Interesting workaround I use is instead of using the advance command, I use feint or jab. They automatically transition/turn you to the next critter or advance on the one you're currently facing if not already at melee. On top of that you get the 'turn to face' messaging that you can also use in your match tables to indicate that you might need to then skin/loot/etc.

-Nsar
Reply