Commit graph

53 commits

Author SHA1 Message Date
TheSnoozer
3393e7e402 report the full path when loading any files which might help in troubleshooting files not found properly 2019-09-23 22:32:28 +02:00
TheSnoozer
f209130464 https://github.com/ORelio/Minecraft-Console-Client/issues/729: allow to use GetServerPort/GetServerHost/GetUsername/GetUserUUID in MCC scripts 2019-09-21 14:42:00 +02:00
ORelio
a6e660c974 Enable/Disable TerrainAndMovements while logged in
Feature requested in #705
2019-04-28 21:32:03 +02:00
TheSnoozer
33edd15c9b https://github.com/ORelio/Minecraft-Console-Client/issues/625: add GetOnlinePlayersWithUUID() which allows to retrive a UUID <-> playerName relation 2019-04-22 14:22:14 +02:00
ORelio
80d51ede31 Chat Format: increase priority of custom regex
If a custom regex is defined in config, process it first.
Previous behavior was to process builtins first.
Should reduce issues with custom regex and builtins=true
2019-04-17 05:32:31 +02:00
ORelio
dc09896959 Allow access to raw JSON messages from ChatBot
See #275
2017-05-31 20:54:16 +02:00
ORelio
dda2ce293c Add LogDebugToConsole() ChatBot API method
Allows printing debug messages.
Debug messages are shown only if the "debugmessages" setting is enabled.

See #223
2017-03-14 22:04:35 +01:00
ORelio
76beb31eaf ChatBot: Add exception on constructor API call
See #220
2017-03-13 22:11:04 +01:00
ORelio
59b12ff900 ChatBot: Allow delay in ReconnectToTheServer()
See #252
2017-03-13 21:15:36 +01:00
ORelio
b1d5d0b32e Add GetOnlinePlayers() in ChatBot API
Suggestion by mattjbenson
2016-10-14 21:14:26 +02:00
ORelio
f5575d7f8b Update bot making documentation in ChatBot.cs
+ Add GetVarAsDouble in Script API (See #200)
2016-09-11 20:11:01 +02:00
ORelio
461385d057 Ignore tab list items not containing a valid name
For cleaner /list output without "???tab"
placeholders eg from TabListPlus.
2016-08-22 23:15:19 +02:00
ORelio
67fc431d4a Add location getter and setter location in ChatBot
See #146
2016-05-04 23:47:08 +02:00
ORelio
a52fb61358 lastMessageSentTime does not needs to be optional 2016-02-27 17:59:08 +01:00
ORelio
7ff9d3bb37 IsPrivateMessage(): Case insensitive 'me' for PM 2016-02-27 17:56:47 +01:00
Pokechu22
6d4ec86619 Add an "AfterGameJoined" method to ChatBot.cs.
Since messages can't be sent in Initialize(), a method that's called when the chat bot can first send messages is needed.  This method is called when the login completes or when the bot is loaded if the login is already been completed.
2016-02-07 14:55:29 -08:00
Pokechu22
1ea8f119d9 Give ChatBots access to plugin channels.
Chatbots may find it useful to send messages over plugin channels.  This allows REGISTERing, UNREGISTERing, and sending over plugin channels, with built-in checking if the server also registered the channel (which can be disabled by the bot if needed). Unused channels are UNREGISTERed when a bot is disabled.
2016-02-07 14:55:10 -08:00
ORelio
bdbd8ab0b8 Remove debug printing line in ChatParser
See #107
2016-01-31 19:09:08 +01:00
Pokechu22
207732cd86 Add an option to add a delay between bot message
Because bots can send several messages quickly, this adds an option to slow down the rate at which messages are produced (to avoid issues with antispam plugins).  This should help solve part of the troubles @mobdon was having in #105.

Right now the default time is 2 seconds per message.  However, messages are sent imediately if the bot doesn't need to delay (so if it's a bot that only outputs one or two messages, those will still happen imediately).  Also, note that it's limited per-bot right now.

I also added an optional parameter to the SendText method so that bots can avoid this behavior if they need to.  In some cases, they'll want to send multiple messages.
2016-01-29 16:18:59 -08:00
ORelio
ba41268aca Add setting for setting private msg command
So that the /tell command can be changed into eg /msg.
Suggested by _initsuj
2016-01-27 00:23:29 +01:00
ORelio
67939774ba Chat formats : Catch Argument out of range
Whas happening for chat messages starting with '<' but never
ending with '>'. Bug report by Aderpace.
2016-01-26 10:35:49 +01:00
ORelio
d36647af3e Add GetWorld() API method for ChatBots 2016-01-16 17:52:09 +01:00
ORelio
72bd485e67 Add basic location handling
- Retrieve player location from the server
- Send back player location from the server
- Requires that a specific setting is enabled
- Should allow items to be picked up by the player
- May also trigger some anti chead plugins
2015-11-27 17:16:37 +01:00
ORelio
e5364566c3 Catch IndexOutOfRangeException for IsChatMessage 2015-10-26 23:19:06 +01:00
ORelio
5038c3d475 Add regex settings for parsing chat messages
Allows user-defined regexes to be used instead of built-in chat
detection routines for matching messages on server using a non-standard
chat format. Built-in detection routines can be disabled using a single
setting, based on a contribution by ZizzyDizzyMC.
2015-10-22 22:17:15 +02:00
ZizzyDizzyMC
385a1f99b1 Added another setting.
Added
vanillaandfactionsmessages setting that enables / disables detection of
vanilla / factions public chat messages.
Setting has been added to the auto-generated MinecraftClient.ini and has
been commented with respective chat format of "<user> message" and
"<*faction user>: message"
Clause added to ChatBot.cs that makes use of the new setting.
2015-09-04 09:16:28 -04:00
ZizzyDizzyMC
1abb46b8ca Added / Cleaned Enable features of Chat Messages 2015-09-04 00:00:02 -04:00
ZizzyDizzyMC
cdec34d5ca I messed up and put the herochat *back* into a faulty position.
Removed my mistake and updated the location of the
Hero_Chat_Messages_Enabled clause that keeps it disabled unless needed.
2015-09-03 23:59:57 -04:00
BuildTools
35365a4b80 Revert "Revert "Added a new PM regex""
This reverts commit 450cb4c6b9.
2015-09-02 23:01:46 -04:00
BuildTools
450cb4c6b9 Revert "Added a new PM regex"
This reverts commit 88c9605e94.
2015-09-02 23:01:30 -04:00
BuildTools
88c9605e94 Added a new PM regex
Added
[someone @ me] message
so that remote control could be used on more servers.

Added back Hero Chat Messages with a default config option of;
herochatmessagesenabled=false
which safely disables it for everyone and has to be explicitly enabled
for it to goof anything up.
How this happened was me downloading the "source" from minecraft forums
and modifying that source then trying to merge it back to the main
github fork of mine.
2015-09-02 23:01:01 -04:00
ORelio
3e2622fbb7 Various C# Script improvements
Move handling code in a separate file
Add caching ability for low-power devices (rpi..)
Use a distinct API with MCC.MethodName()
Stop script execution only on specific API calls
2015-08-23 18:51:29 +02:00
ORelio
12b94996c7 Add joshbean39's chat formats 2015-07-31 12:23:13 +02:00
ORelio
e29b4ee545 Add support for C# script extensions
- Allow defining function for use into the script
- Allow defining a ChatBot for loading it into MCC
- Improve sample script and add more examples
- Todo add new documentation into the readme file
2015-06-21 18:45:43 +02:00
ORelio
a6b3bf0481 AutoRespond tests and fixes
- Automatically add [BotName] tags to log lines
- Fix case handling and actionPrivate used for public messages
- Add a sample file for basic and regex matches
2015-06-21 16:40:13 +02:00
ORelio
3ce91188c7 Add support for C# scripts in scripting bot
- Now scripts can also be written in C#
- C# scripts can access ChatBot API
- Add more methods in ChatBot API
- Add an example of C# script file
- Coding style fixes: method names ucfirst
2015-06-20 22:58:18 +02:00
ORelio
53156bdf98 Normalize AutoRespond bot
Move FromFile method from bots to ChatBot class
Rename file and class, removing space and underscore.
2015-05-26 19:17:37 +02:00
ORelio
5b662e2d07 Fix HeroChat public messages treated as private
See issue #63 - Also includes minor fixes and optimizations
2015-05-18 16:15:58 +02:00
ORelio
72c2ff5ef0 Handle HeroChat chat messages
Fix #63 and rewrite PMsend
Suggestion and PMsend v1 by JamieSinn
2015-02-26 12:45:24 +01:00
Jamie Sinn
89ccc9d22d Add Herochat/Essentials PM Check 2015-02-21 13:42:58 -05:00
ORelio
c53a696ffd Fixed %vars% not handled in chatbotlogfile
Bug report by TorchRJ_
2014-09-07 15:17:47 +02:00
ORelio
5fd32828c7 Fix chatbotlogfile not creating/writing to logfile
Bug report by TorchRJ_
2014-08-27 17:19:33 +02:00
ORelio
774043fddb Fix for previous commit
Tried to handle two syntaxes at the same time. Bad idea.
Handling the two different syntaxes separately.
2014-07-29 17:08:24 +02:00
ORelio
e56d504067 Add more syntax compatibility for private messages
Added '[Someone [rank] -> me] message' syntax support
Improvement for fuckofftwice's server with [Donator] tag
2014-07-29 16:59:20 +02:00
ORelio
162a1414bf Add ChatBot logging to file and 'log' command
- log <text> will print '[BOT] text' to the console
- logged [BOT] lines can be written to a logfile
- chatbotlogfile INI setting is used to set the log file
2014-07-20 12:02:17 +02:00
ORelio
2907b9c587 Account list file support
Accounts can be stored in a file and used while (re)connecting
+ Check that the server IP is valid (avoid /connect <player>)
+ Fix command prompt not exiting while exiting the server
+ SendChatMessage() -> SendText() method name change
2014-06-19 19:24:03 +02:00
ORelio
36690b8b34 Commands as separate classes
Each command is now in its own class in the 'Commands' namespace, and
loaded through reflection.
2014-06-18 13:32:17 +02:00
ORelio
87d4687394 Add set varname=value MCC command
- Allow to use vars declared in scripts or directly by the user
- Commands my now use %variable% as well
- Moved "help" command from RemoteControl to inner MCC command manager
- The only special command is "wait", which is only available in scripts
Todo: Solve ambiguity between MCC help and Server help commands
Note: Auto accept tpa suggested by MousePak
Note: Manually choosing MC version suggested by ZizzyDizzyMC
2014-06-14 18:48:43 +02:00
ORelio
f0b071ddea Remote Control : Auto accept tpa and tpahere
- Added Essentials teleportation request in bot api
- Used the api in remote control to auto accept
2014-06-14 13:51:30 +02:00
ORelio
9456e82923 Handle all internal MCC commands in one place
- MCC internal commands for command prompt, remote control and scripts
are handled in one place, thus it's no more needed to add them in 3
different places.
- "exit" command in scripts is not equivalent to "/quit"
- removed "disconnect" command in scripts /!\
- bots can now easily perform internal MCC commands.
2014-06-14 13:20:15 +02:00