MXP and snooping

Posted by TDM on Tue 18 May 2004 04:54 PM — 2 posts, 11,254 views.

#0
After getting MXP to successfuly install on my windows version of ROM (compiled in MSVC6) It works as it should for everyone, the only problem I have is when a player is being snooped the diffrent symbols aren't displayed properly. The <, >, and & Show up as &lt, &gt, &amp
And the mxp tags are fully shown instead of being hidden and ignored.

Any ideas, or pointers as to what and where I would need to tweak these?
Australia Forum Administrator #1
Sounds like they are being converted twice.

Judging by the SMAUG source, which is probably similar in the output area, the snooping is done at the "flush_buffer" stage, which is *after* < becomes &lt;.

This makes things a bit messy because you have four possibilities here:

  1. Neither of you are using MXP
  2. The snoopee is using MXP but not the snooper
  3. The snooper is using MXP but not the snoopee
  4. You are both using MXP


I think in the last case you would see tags converted twice, (eg. < becomes &lt; ) and in the first case it wouldn't matter.

I think the solution is to move the snoop code from flush_buffer, to write_to_buffer.

That way the decision about how to process MXP tags is done for the target of the write, and not done twice.