Quote
Python isn't really the best language to use since it is slow enough to introduce measurable latency when you have some
degree of load from actions/highlights/triggers etc.
The only time I've had issues with this in python3+ is when it was poorly designed logic - using newer versions of python (3.x+) haven't really had performance issues for anything network constrained - the only time I've ran into performance problems that were noticeable were IO or memory constrained work like reading and processing large files, etc.
Quote
Your msg handler doesn't match prompts. Matching prompts is the fundamental operation that has to
be correct in every MUD client, otherwise you can't do reliable per-line operations (like actions/triggers/highlights etc).
You need to take into account that server output can arrive in batches that are completely arbitrary / not neatly
terminated by a complete prompt or even new line.
I'll have to add a new layer for this - I've been starting to see issues with it occasionally during that interrupt period in between receiving - but I think I should be able to solve this relatively easy with a bit of thought. More context on the prompt thing would be helpful - I haven't ever really gotten into the scripting stuff via zmud and mud (Mostly just color triggers, eat/drink, and some aliases for targeting and shortcuts). Is the prompt recognition just used to segregate the "events" that have happened when you're scripting things out?
Quote
This doesn't work because regular expressions can not be used to model state machines, which is really what you need here.
I didn't realize it, but the only reason it's working right now is because it's not often that you hit a color change mid-message (Most of the message colors are already reset by the time you get to another message/line). I'll have to think of a good color state system - that's great input, thanks!
Quote
Making something that sort-of-works, some of the time, is easy.
But making something that's robust is all about understanding the problem and its cornercases
Would love more feedback - it's been really fun to learn the ins and outs of writing a MUD client, and I'll likely be poking at this for a few years, since I use it fairly consistently right now to play casual stuff.