Servers

Supported servers

Pokemon Online is the most supported simulator for Technical Machine. It can log in and complete battles. Pokemon Lab is experiencing some regressions currently that are preventing logging on entirely, but it is likely just accidentally sending PO data instead of PL data. Other simulators are not supported yet. Technical Machine can also load data from Pokemon Lab or Pokemon Online team formats.

Technical Machine has plans to support Pokemon Online version 2 and Pokemon Showdown. I also have some partial support for NetBattle teams to help give Technical Machine some starter teams for older generations.

Philosophy

Different servers have support for different things. Wherever possible, Technical Machine attempts to abstract away those differences to provide a single consistent interface. However, if a server does not support something useful that another server does, Technical Machine will take advantage of that useful thing rather than playing to the least-common-denominator of all simulators. For instance, Technical Machine has the ability to randomly select a team in a given directory rather than just a specific team. This seems like a feature that could work on any simulator, but there are pitfalls to doing this right.

On Pokemon Lab, this works fine because you send teams at the moment of accepting a challenge. Pokemon Online requires users to register their team with the server, and that team is used for all challenges until a new team is sent. This limits the ability to load new teams. When Technical Machine is the challenger, it registers a new team with the server with each challenge to support the random teams feature. However, when challenged, it is impossible to do this. As a slight work-around, Technical Machine immediately registers a new team with the server at the start of every battle. If I did not do this, then even if you were using the random team in a directory feature, a user could watch Technical Machine battle and then attempt to challenge it with a counter team based on the team it just saw, and Technical Machine's only options would be to refuse the challenge or else to accept the challenge with the team it just used. I decided to try to work around the shortcomings of each simulator as much as possible.

Controlling the bot

Setup

After Technical Machine is built, there is a file called trusted_users.txt in the settings directory. This determines the users that can send commands to Technical Machine. There is currently no concept of authority levels; anyone who can send any command can send all commands. Commands are sent to Technical Machine via PM only (it does not watch any channels for commands). Potential additions to this in the future include allowing all users with authority of at least some level (such administrators on the server) to send commands to the bot, in addition to listed usernames.

List of commands

!challenge
Format is !challenge username
!depth
Format is !depth # (where # represents the new depth as an integer). Sets Technical Machine's depth of search to #. This only applies to future challenges / battles. Existing battles are set in their depth.
!join
Format is !join channel_name (with no '#' symbol)
!message
Sends a message to a channel. Format is !message channel_name msg where channel is a one word channel name (with no '#' symbol) and message is any number of words. For channels that may contain spaces, format is !message "channel name" msg
!part
Format is !part channel_name (with no '#' symbol)
!pm
Format is !pm username message where username is a one word username. For usernames that may contain spaces, format is !pm "user name" message
!reload
Reloads all relevant text files. This allows updating TM's set of canned responses, how often it uses those responses, and evaluation constants, for instance.