I need help with triggers!

Posted by Zevren on Sat 23 Jun 2018 01:10 AM — 3 posts, 15,039 views.

#0
I need to make a trigger to assess the amount of herbs there are, and pick as many as I can, while leaving 20 there. Each herb I pick requires me to regain balance before entering PICK <herb> again.
For example, I type HERBS (to see how many are in my location) I get this:
You forage around for wild herbs.
There are thirty-eight batches of siriena here.

I want to pick 18 Siriena, since that would leave 20 unpicked.

How would I do this????
Australia Forum Administrator #1
See the "wait" module as mentioned here:

http://www.gammon.com.au/modules




Also see:

http://www.gammon.com.au/forum/?id=10155

There is a module that comes with MUSHclient that converts word to numbers, eg.


require "words_to_numbers"

number = convert_words_to_numbers ("thirty-eight")

print (number)  --> 38
#2
This case only shows how Gammon works for good! Awesome!