Bug - Not A Bug Monster ID and Fax

fronobulax

Developer
Staff member
Using the GUI I ask easyfax for a Knob Goblin Embezzler. It lists the monster as "Knob Goblin Embezzler<!-- monsterid: 530 --> [Knob Goblin Embezzler&lt;!-- monsterid: 530 --&gt;]" in the GUI, asks, and then times out. I expected a faxed monster.

The chat window shows

[08:23] fronobulax: Knob Goblin Embezzler&lt;!-- monsterid: 530 --&gt;

After it times out I type "Knob Goblin Embezzler" and one is received almost immediately.
[08:23] fronobulax: Knob Goblin Embezzler&lt;!-- monsterid: 530 --&gt;
[08:24] fronobulax: Knob Goblin Embezzler
[08:24] Easyfax: Your fax is ready.

It is quite likely the problem was introduced with r27923. It could be argued that easyfax needs to accommodate the change or that KoLmafia needs to change and send easyfax what was expected.
 
I expect it was reading the monster name from the photocopy, and thus it's the KoL change, not the Mafia change. But yes, I expect it's automated.
 
Yes, Not a Bug. It is automated and yes it should have automatically handed this KoL change. However, easyfax has one and only one special character. The colon ( : ) is not allowed in monster names. This is why messages are being dropped with no response. I'll switch characters.
 
Okay, switching characters got things working right again. As more faxes are looked at the problem with ambiguous monster names should be fixed.
 
Okay, switching characters got things working right again. As more faxes are looked at the problem with ambiguous monster names should be fixed.

I'm not seeing any fixes. Maybe it is because I only look at the first few monsters displayed as options?
 
I never use the fax GUI, but I just brought it up and I see monster ids for most (not all monsters).
This is the file mafia uses to populate that list and it also has monster ids.
 
I never use the fax GUI, but I just brought it up and I see monster ids for most (not all monsters).
This is the file mafia uses to populate that list and it also has monster ids.

See the first post.

Compare the GUI renditions for EasyFax and OnlyFax if desired.

Using
<name>1335 HaXx0r&amp;lt;!-- monsterid: 141 --&amp;gt;</name>
<actual_name>1335 HaXx0r&amp;lt;!-- monsterid: 141 --&amp;gt;</actual_name>
<command>1335 HaXx0r&amp;lt;!-- monsterid: 141 --&amp;gt;</command>
<category>None</category>

as an example, mafia appears to display <actual name> in the GUI. When <actual name> is requested mafia sends <command> and the request fails.

When I eliminated the GUI and typed <command> I got nothing but when I stripped out the monster id and typed the command I got a fax.

So my observations are two - there are cases when sending <command> do not return a fax AND it is difficult to compare monsters across faxbots and Monster Manual when the monster ID in present.

This is not a big deal in that I don't think EasyFax has any monster than Only Fax doesn't.

There could be some impatience on my part since I'm pretty sure a month ago all monsters had IDs and now some of them don't, i.e. actual orcish frat boy, so things are perhaps gradually changing.
 
In the GUI I noticed some duplication today. Adventurer echo was one, but not the only. There were entries both with and without the monster id. I confirmed that there were two entries in the JSON.
 
I noticed that Easyfax was not accepting my request. I tested this manually:

In Easyfax chat tab

Code:
Veracity: pumpkin spice wraith<!-- monsterid: 2486 -->
Easyfax: I couldn't find that monster. Please look here [link] http:// sourceforge.net/p/ easyfax/code/HEAD/ tree/list for a list of monster names.
[code]
Looked at the file at that link. I see this:
[code]
pumpkin spice wraith&lt;!-- monsterid: 2486 --&gt;

OK. Perhaps it really wants the entity encoding.
Back in chat:

Code:
Veracity: pumpkin spice wraith&lt;!-- monsterid: 2486 --&gt;
Easyfax: Your fax is ready.
Veracity: pumpkin spice wraith
Easyfax: Your fax is ready.

OK. Easyfax will accept a verbatim entry from its data file and also the name with the HTML comment stripped out.
In the data file, I see:

Code:
Astronomer&lt;!-- monsterid: 184 --&gt;
Astronomer&lt;!-- monsterid: 354 --&gt;

That would be ambiguous without the HTML entity.

In the Request a Fax GUI, I see this entry:

Code:
pumpkin spice wraith<!-- monsterid: 2486 --> [pumpkin spice wraith&lt;!-- monsterid: 2486 --&gt;]

which looks like a monster with a monsterId comment and the "command" in [] to get it.
I requested a Fax vis the GUI with KoLmafia's chat window open.
gCLI says:

Code:
Visiting Fax Machine in clan VIP lounge
Asking Easyfax to send a fax of pumpkin spice wraith<!-- monsterid: 2486 -->: pumpkin spice wraith<!-- monsterid: 2486 -->
Receiving a fax.
You acquire an item: photocopied monster
You receive a photocopied pumpkin spice wraith from the fax machine.

chat GUI says this in the easyfax tab:

Code:
[15:17] Veracity: pumpkin spice wraith&lt;!-- monsterid: 2486 --&gt;
[15:17] Easyfax: Your fax is ready.

It appears that Easyfax is working fine.

What about via script?

Code:
> ash can_faxbot($monster[pumpkin spice wraith])

Returned: true

> ash can_faxbot($monster[pumpkin spice wraith], "Easyfax")

Returned: false

> ash can_faxbot($monster[pumpkin spice wraith], "OnlyFax")
Returned: true

> ash faxbot($monster[pumpkin spice wraith], "Easyfax")

Returned: false

So the issue is that although Easyfax advertises monsters - including monster Id - that it can send you, but the ASH function's can_faxbot and faxbot can't find them.

RuntimeLibrary:

Code:
  private static Value can_faxbot(MonsterData monster, String faxbot) {
...
    FaxBotDatabase.configure();

    String actualName = monster.getName();
...
      Monster monsterObject = bot.getMonsterByActualName(actualName);
      if (monsterObject == null) {
        continue;
      }
...
  }

Perhaps we want faxBot.getMonster(MonsterData) - which will allow access to both monster name and monsterId.
For requesting a fax:

Code:
  public static Value faxbot(
      ScriptRuntime controller, final Value monsterName, final Value botName) {
    MonsterData monster = (MonsterData) monsterName.rawValue();
...
    return DataTypes.makeBooleanValue(bot.request(monster));
  }

we can request a monster by MonsterData object.

I think FaxbotDatabase needs a little work.

How do the two working Faxbots configure monsters with ambiguous names?

Easyfax:

Code:
<name>Astronomer&amp;lt;!-- monsterid: 184 --&amp;gt;</name>
<actual_name>Astronomer&amp;lt;!-- monsterid: 184 --&amp;gt;</actual_name>
<command>Astronomer&amp;lt;!-- monsterid: 184 --&amp;gt;</command>
<category>None</category>
</monsterdata>
<monsterdata>
<name>Astronomer&amp;lt;!-- monsterid: 354 --&amp;gt;</name>
<actual_name>Astronomer&amp;lt;!-- monsterid: 354 --&amp;gt;</actual_name>
<command>Astronomer&amp;lt;!-- monsterid: 354 --&amp;gt;</command>
<category>None</category>
</monsterdata>

OnlyFax:

Code:
        <monsterdata>
            <name>Astronomer</name>
            <actual_name>Astronomer</actual_name>
            <command>[184]Astronomer</command>
            <category>Ambiguous</category>
        </monsterdata>
        <monsterdata>
            <name>Astronomer (obsolete)</name>
            <actual_name>Astronomer (obsolete)</actual_name>
            <command>[354]Astronomer (obsolete)</command>
            <category>Ambiguous</category>
        </monsterdata>
 
Back
Top