Muting warning messages while executing ash-script

ereinion

Member
Is there any simple way of muting the "Conditions not satisfied after * adventure(s)." message when using ash's adventure-function and having a goal?
 

Theraze

Active member
Well, you could run cli_execute("cls") to wipe your entire screen, but that would wipe everything, not just the one bit. And if you're noticing the legitimate fail message, you're probably wanting to see the rest of the messages.
 

Bale

Minion
Are you having a problem with a script actually aborting, or is it just that you don't like the message. If the script is actually aborting there is a way to fix that, but you'll still see the message.
 

ereinion

Member
Thanks for your replies. I don't have any trouble with getting the script to actually adventure, but having it output the red line for every adventure bugs me a litte bit.

The relevant bit of code is this:
Code:
while (get_effect(specialItem[current_property].how_to_get_effect, specialItem[current_property].needed_effect) && is_goal($item[filthy lucre])) {
  if (adventure(1, specialItem[current_property].where_to_go)) {}
}
 

Bale

Minion
If you don't like that, then rewrite the relevant line to use the number of turns of the effect remaining instead of 1. That would probably be (I'm guessing at how your script works):

Code:
while (get_effect(specialItem[current_property].how_to_get_effect, specialItem[current_property].needed_effect) && is_goal($item[filthy lucre])) {
  if (adventure(have_effect(specialItem[current_property].needed_effect), specialItem[current_property].where_to_go)) {}
}
 
Top