Giter Site home page Giter Site logo

genazt / cloudchat Goto Github PK

View Code? Open in Web Editor NEW
12.0 12.0 8.0 13.11 MB

This Chat for BungeeCord opens up your Chat to all Servers!Including a IRC Bot and Private Messages!Also this Chat supports multiple Channels and custom NicknamesYou also can use CloudChatBukkit for Prefix/Suffix out of Bukkit !

License: Other

Java 100.00%

cloudchat's People

Contributors

hatventures avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

cloudchat's Issues

Support for MultiVerse aliases

21:51 <BotName> [World Alias]<PlayerName> this is the message

Instead of

21:51 <BotName> [world]<PlayerName> this is the message

Exception in AffixMessage.java:29

I see these guys regularly in my logs:

[11:24:40 WARN]: [CloudChatBukkit] Task #29 for CloudChatBukkit v0.5.1 generated an exception
java.lang.NullPointerException
    at net.cubespace.CloudChatBukkit.Message.AffixMessage.send(AffixMessage.java:29) ~[?:?]
    at net.cubespace.CloudChatBukkit.Listener.PlayerJoin$1.run(PlayerJoin.java:33) ~[?:?]
    at org.bukkit.craftbukkit.v1_7_R1.scheduler.CraftTask.run(CraftTask.java:67) ~[spigot.jar:git-Spigot-1216]
    at org.bukkit.craftbukkit.v1_7_R1.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:345) [spigot.jar:git-Spigot-1216]

    at net.minecraft.server.v1_7_R1.MinecraftServer.u(MinecraftServer.java:583) [spigot.jar:git-Spigot-1216]
    at net.minecraft.server.v1_7_R1.DedicatedServer.u(DedicatedServer.java:259) [spigot.jar:git-Spigot-1216]
    at net.minecraft.server.v1_7_R1.MinecraftServer.t(MinecraftServer.java:540) [spigot.jar:git-Spigot-1216]
    at net.minecraft.server.v1_7_R1.MinecraftServer.run(MinecraftServer.java:446) [spigot.jar:git-Spigot-1216]
    at net.minecraft.server.v1_7_R1.ThreadServerApplication.run(SourceFile:617) [spigot.jar:git-Spigot-1216]

Config option to turn off debug logging

There are some debug logging of the jdbc stuff, is there a hidden config/option to turn them off?

13:52:26 [INFO] 2014-01-08 13:52:26,044 [DEBUG] JdbcPooledConnectionSource reusing connection #225184797
13:52:26 [INFO] 2014-01-08 13:52:26,047 [DEBUG] BaseMappedStatement insert data with statement 'INSERT INTO `chatmessage ` (`nick` ,`channel` ,`message` ,`date` ,`source` ,`ircChannel` ) VALUES (?,?,?,?,?,?)' and 6 args, changed 1 rows
13:52:26 [INFO] 2014-01-08 13:52:26,048 [DEBUG] BaseMappedStatement assigned id '145208' from keyholder to 'id' in ChatMessage object
13:52:26 [INFO] 2014-01-08 13:52:26,048 [DEBUG] JdbcPooledConnectionSource cache released connection #225184797
13:52:32 [INFO] 2014-01-08 13:52:32,466 [DEBUG] JdbcPooledConnectionSource tested connection #225184797, got 1

cc:report on/off stops something

There are no error messages or exceptions in any logs.
What I do to reproduce:

cc:report on

20:44:24 [INFO] [CloudChat] CONSOLE emitted command: cc:report with args on
20:44:24 [INFO] §6Reporting has been enabled and the Report will be saved to CloudChat-1389383064402. Type §c/cc:report§6 off to stop or it will automaticly stop after §a10§6 Minutes
wait a few seconds and verify it writes report lines to console and file...

cc:report off

20:44:52 [INFO] [CloudChat] CONSOLE emitted command: cc:report with args off
20:44:52 [INFO] [CloudChat] Invoking command with arguments off
20:44:52 [INFO] §6Reporting is now §aoff
it stopped :-)

last lines in report file are:

10.01.2014 21:07:49  [Logger/INFO] CONSOLE emitted command: cc:report with args off
10.01.2014 21:01:49  [Logger/DEBUG] Invoking command with arguments off
null

cc:report on

21:07:10 [INFO] [CloudChat] CONSOLE emitted command: cc:report with args on
... no more info about reporting

cc:report off

21:07:15 [INFO] [CloudChat] CONSOLE emitted command: cc:report with args off
21:07:15 [INFO] §6Reporting is now §aoff

There are no error messages or exceptions in any logs.

support for /mute

  • as global command

    /mute < player> [time to be muted]

  • per server; the CloudChatBukkit could inform CloudChat when players are being muted/unmuted, or the command could be

    /mute < player> [time to be muted] [on] < server>

  • maybe extend it to the IRCchannels by either muting the IRCentity or not delivering Messages from it

Private Mode

Let CloudChat pass all Chats without handling them. If a / command comes in let this be handled via CloudChat.

This is meant for Staff Chats which should be based upon CloudChat but bukkit should handle the Chat itself.

Moving between bungee-servers

When moving between bungee servers I get the player joined event each time I get back to the "lobby", there is never a player left:

IRC ouput:

[11:07] <CitaborgBot> [Citaborg] [VIP]NoenAndre{click:playerMenu} joined the Server
[11:08] <CitaborgBot> [Citaborg] [VIP]NoenAndre{click:playerMenu} joined the Server
[11:08] <CitaborgBot> [Citaborg] [VIP]NoenAndre{click:playerMenu} joined the Server
[11:09] <CitaborgBot> [Citaborg] [VIP]NoenAndre{click:playerMenu} joined the Server
[11:09] <CitaborgBot> [Citaborg] [VIP]NoenAndre: asdf
[11:09] <CitaborgBot> [Citaborg] [VIP]NoenAndre{click:playerMenu} joined the Server
[11:09] <CitaborgBot> [Citaborg] [VIP]NoenAndre: asdf

11:07 I joined the server Citaborg
then I moved to a hunger-games server and back during 11:08
11:09 I joined the gunger-games server again and wrote "asdf"
then left for the lobby (Citaborg)

Also the 2 retries of joining the channel (#41) are printed as "You can't join this Channel. You don't have enough Permissions"

Channel join on player join

Seems its trying to join the same channel a couple of times on player join.

11:01:36 [INFO] [Citaborg] <-> ServerConnector [citaworld] has connected
11:01:36 [INFO] [CloudChat] Loading PlayerDatabase for Citaborg
11:01:36 [INFO] [CloudChat] Citaborg tried to join Channel citaworld
11:01:36 [INFO] [CloudChat] Player Citaborg entered Channel citaworld
11:01:36 [INFO] [CloudChat] Citaborg tried to join Channel citaworld
11:01:36 [INFO] [CloudChat] Player Citaborg is already in the Channel citaworld

[Enhancement] Use the server.properties server-name and server-id

Add some placeholders for the "server-name" and "server-id" form the server.properties. Leter they can be used as a prefix.

Server A:
server-id: A
server-name alpha

Server B:
server-id: B
server-name beta

So a message from a player who is on server b could like this:
-B- Player: Why is snow white ?
or like this
[Beta] Player: What happend to the sun its a squere ?

Typo in AFK messages

I just found a typo:

[G] [$$$]Magnes no longer is afk

instead of

[G] [$$$]Magnes is no longer afk

Auto complete for some of the commands

At the moment i cant use:

/m frd Hey whats up?

I have to use:

/m frdmn Hey whats up?

An auto complete feature would be pretty nice (Auto complete, not tab complete).

Exception: Unknown column 'channel' in 'field list'

Plugin: CloudChat; Version: 2.8.1
BungeeCord: git-BungeeCord-Bootstrap-1.7-SNAPSHOT-"80caa2b"-783; Java: 1.7.0_40

18:20:03 [INFO] 2014-01-04 18:20:03,807 [DEBUG] JdbcPooledConnectionSource reusing connection #1759821582
18:20:03 [INFO] 2014-01-04 18:20:03,832 [DEBUG] BaseMappedStatement insert data with statement 'INSERT INTO `chatmessage` (`nick` ,`channel` ,`message` ,`date` ,`source` ,`ircChannel` ) VALUES (?,?,?,?,?,?)' and 6 args, threw exception: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Unknown column 'channel' in 'field list'
18:20:03 [INFO] 2014-01-04 18:20:03,833 [DEBUG] JdbcPooledConnectionSource cache released connection #1759821582
18:20:03 [SEVERE] [CloudChat] Error in AsyncDatabaseLogger
java.sql.SQLException: Unable to run insert stmt on object net.cubespace.CloudChat.Module.Logging.Entity.ChatMessage@4c1802de: INSERT INTO `chatmessage` (`nick` ,`channel` ,`message` ,`date` ,`source` ,`ircChannel` ) VALUES (?,?,?,?,?,?)
    at net.cubespace.vendor.com.j256.ormlite.misc.SqlExceptionUtil.create(SqlExceptionUtil.java:22)
    at net.cubespace.vendor.com.j256.ormlite.stmt.mapped.MappedCreate.insert(MappedCreate.java:135)
    at net.cubespace.vendor.com.j256.ormlite.stmt.StatementExecutor.create(StatementExecutor.java:438)
    at net.cubespace.vendor.com.j256.ormlite.dao.BaseDaoImpl.create(BaseDaoImpl.java:308)
    at net.cubespace.CloudChat.Module.Logging.AsyncDatabaseLogger$1.run(AsyncDatabaseLogger.java:40)
    at net.md_5.bungee.scheduler.BungeeTask.run(BungeeTask.java:58)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
    at java.lang.Thread.run(Thread.java:724)
Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Unknown column 'channel' in 'field list'
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
    at com.mysql.jdbc.Util.handleNewInstance(Util.java:411)
    at com.mysql.jdbc.Util.getInstance(Util.java:386)
    at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1054)
    at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4237)
    at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4169)
    at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2617)
    at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2778)
    at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2825)
    at com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:2156)
    at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2441)
    at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2366)
    at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2350)
    at net.cubespace.vendor.com.j256.ormlite.jdbc.JdbcDatabaseConnection.insert(JdbcDatabaseConnection.java:175)
    at net.cubespace.vendor.com.j256.ormlite.stmt.mapped.MappedCreate.insert(MappedCreate.java:91)
    ... 7 more  18:20:03 [INFO] 2014-01-04 18:20:03,807 [DEBUG] JdbcPooledConnectionSource reusing connection #1759821582
18:20:03 [INFO] 2014-01-04 18:20:03,832 [DEBUG] BaseMappedStatement insert data with statement 'INSERT INTO `chatmessage` (`nick` ,`channel` ,`message` ,`date` ,`source` ,`ircChannel` ) VALUES (?,?,?,?,?,?)' and 6 args, threw exception: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Unknown column 'channel' in 'field list'
18:20:03 [INFO] 2014-01-04 18:20:03,833 [DEBUG] JdbcPooledConnectionSource cache released connection #1759821582
18:20:03 [SEVERE] [CloudChat] Error in AsyncDatabaseLogger
java.sql.SQLException: Unable to run insert stmt on object net.cubespace.CloudChat.Module.Logging.Entity.ChatMessage@4c1802de: INSERT INTO `chatmessage` (`nick` ,`channel` ,`message` ,`date` ,`source` ,`ircChannel` ) VALUES (?,?,?,?,?,?)
    at net.cubespace.vendor.com.j256.ormlite.misc.SqlExceptionUtil.create(SqlExceptionUtil.java:22)
    at net.cubespace.vendor.com.j256.ormlite.stmt.mapped.MappedCreate.insert(MappedCreate.java:135)
    at net.cubespace.vendor.com.j256.ormlite.stmt.StatementExecutor.create(StatementExecutor.java:438)
    at net.cubespace.vendor.com.j256.ormlite.dao.BaseDaoImpl.create(BaseDaoImpl.java:308)
    at net.cubespace.CloudChat.Module.Logging.AsyncDatabaseLogger$1.run(AsyncDatabaseLogger.java:40)
    at net.md_5.bungee.scheduler.BungeeTask.run(BungeeTask.java:58)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
    at java.lang.Thread.run(Thread.java:724)
Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Unknown column 'channel' in 'field list'
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
    at com.mysql.jdbc.Util.handleNewInstance(Util.java:411)
    at com.mysql.jdbc.Util.getInstance(Util.java:386)
    at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1054)
    at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4237)
    at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4169)
    at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2617)
    at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2778)
    at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2825)
    at com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:2156)
    at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2441)
    at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2366)
    at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2350)
    at net.cubespace.vendor.com.j256.ormlite.jdbc.JdbcDatabaseConnection.insert(JdbcDatabaseConnection.java:175)
    at net.cubespace.vendor.com.j256.ormlite.stmt.mapped.MappedCreate.insert(MappedCreate.java:91)
    ... 7 more

Does not run whois when players join channel after bot(?)

15:59:40 [INFO] [CloudChat] Citaborg joined IRC
16:07:59 [INFO] [CloudChat] geNAZt joined IRC

no entries for "Whois got resolved" for any of them...

Players in the channel on join (like the bot itself) gets resolved
15:58:48 [INFO] [CloudChat] Bot joined #citaborg
15:58:49 [INFO] [CloudChat] Whois got resolved: CitaborgBot -> null

Error whilst passing packet to listener class net.cubespace.CloudChat.Module.PlayerManager.Listener.Plug

17:22:24 [INFO] Error whilst passing packet to listener class net.cubespace.CloudChat.Module.PlayerManager.Listener.Plug
inMessageListener#onWorldMessage
17:22:24 [SEVERE] java.lang.reflect.InvocationTargetException
17:22:24 [SEVERE]     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
17:22:24 [SEVERE]     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
17:22:24 [SEVERE]     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
17:22:24 [SEVERE]     at java.lang.reflect.Method.invoke(Method.java:606)
17:22:24 [SEVERE]     at net.cubespace.vendor.com.iKeirNez.PluginMessageApiPlus.PacketManager.doPacket(PacketManager.jav
a:188)
17:22:24 [SEVERE]     at net.cubespace.vendor.com.iKeirNez.PluginMessageApiPlus.PacketManager.dispatchIncomingPacket(Pac
ketManager.java:136)
17:22:24 [SEVERE]     at net.cubespace.vendor.com.iKeirNez.PluginMessageApiPlus.implementations.BungeeCordPacketManager.
onPluginMessage(BungeeCordPacketManager.java:33)
17:22:24 [SEVERE]     at sun.reflect.GeneratedMethodAccessor21.invoke(Unknown Source)
17:22:24 [SEVERE]     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
17:22:24 [SEVERE]     at java.lang.reflect.Method.invoke(Method.java:606)
17:22:24 [SEVERE]     at net.md_5.bungee.event.EventHandlerMethod.invoke(EventHandlerMethod.java:19)
17:22:24 [SEVERE]     at net.md_5.bungee.event.EventBus.post(EventBus.java:47)
17:22:24 [SEVERE]     at net.md_5.bungee.api.plugin.PluginManager.callEvent(PluginManager.java:338)
17:22:24 [SEVERE]     at net.md_5.bungee.connection.DownstreamBridge.handle(DownstreamBridge.java:197)
17:22:24 [SEVERE]     at net.md_5.bungee.protocol.packet.PluginMessage.handle(PluginMessage.java:43)
17:22:24 [SEVERE]     at net.md_5.bungee.netty.HandlerBoss.channelRead(HandlerBoss.java:75)
17:22:24 [SEVERE]     at io.netty.channel.DefaultChannelHandlerContext.invokeChannelRead(DefaultChannelHandlerContext.ja
va:338)
17:22:24 [SEVERE]     at io.netty.channel.DefaultChannelHandlerContext.fireChannelRead(DefaultChannelHandlerContext.java
:324)
17:22:24 [SEVERE]     at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:153)
17:22:24 [SEVERE]     at io.netty.channel.DefaultChannelHandlerContext.invokeChannelRead(DefaultChannelHandlerContext.ja
va:338)
17:22:24 [SEVERE]     at io.netty.channel.DefaultChannelHandlerContext.fireChannelRead(DefaultChannelHandlerContext.java
:324)
17:22:24 [SEVERE]     at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:153)
17:22:24 [SEVERE]     at io.netty.channel.DefaultChannelHandlerContext.invokeChannelRead(DefaultChannelHandlerContext.ja
va:338)
17:22:24 [SEVERE]     at io.netty.channel.DefaultChannelHandlerContext.fireChannelRead(DefaultChannelHandlerContext.java
:324)
17:22:24 [SEVERE]     at io.netty.handler.timeout.ReadTimeoutHandler.channelRead(ReadTimeoutHandler.java:149)
17:22:24 [SEVERE]     at io.netty.channel.DefaultChannelHandlerContext.invokeChannelRead(DefaultChannelHandlerContext.ja
va:338)
17:22:24 [SEVERE]     at io.netty.channel.DefaultChannelHandlerContext.fireChannelRead(DefaultChannelHandlerContext.java
:324)
17:22:24 [SEVERE]     at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:785)
17:22:24 [SEVERE]     at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:126)

17:22:24 [SEVERE]     at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:485)
17:22:24 [SEVERE]     at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:452)
17:22:24 [SEVERE]     at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:346)
17:22:24 [SEVERE]     at io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:101)
17:22:24 [SEVERE]     at java.lang.Thread.run(Thread.java:724)
17:22:24 [SEVERE] Caused by: java.lang.NullPointerException
17:22:24 [SEVERE]     at net.cubespace.CloudChat.Module.PlayerManager.Listener.PluginMessageListener.onWorldMessage(Plug
inMessageListener.java:43)
17:22:24 [SEVERE]     ... 34 more
17:22:26 [INFO] [/89.162.57.62:51490] <-> InitialHandler has connected
17:22:26 [INFO] [/80.202.57.6:50315] <-> InitialHandler has connected   

Spambot detection (AntiBot example)

Let a User not write for a configurable Time. After that time "unlock" the User so he can write.

This should prevent most Spambots since they join => write => leave in 1-2 Seconds.

Another option should be to disable chat completly in some Servers (like lobbies).

[Enhancement] Don´t overwrite the bukkit Chat

Hey,

I would like to use herochat for the per server chat with pwn filter. As I have a nice setup with it. But the problem ist that CloundChat overwrites it. So it would need a enhancement that it is possible to focus none chat. Is this something you might add ?

Exception in PlayerQuitListener (when player never joined a server)

15:27:46 [WARNING] [CloudChat] Listener net.cubespace.CloudChat.Module.ChannelManager.Listener.PlayerQuitListener.onPlayerQuit has thrown an Exception java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at net.cubespace.lib.EventBus.AsyncEventBus.handleEvent(AsyncEventBus.java:138)
at net.cubespace.lib.EventBus.AsyncEventBus.access$3(AsyncEventBus.java:96)
at net.cubespace.lib.EventBus.AsyncEventBus$2.run(AsyncEventBus.java:78)
at net.md_5.bungee.scheduler.BungeeTask.run(BungeeTask.java:58)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.NullPointerException
at java.util.ArrayList.<init>(Unknown Source)
at net.cubespace.CloudChat.Module.ChannelManager.ChannelManager.remove(ChannelManager.java:193)
at net.cubespace.CloudChat.Module.ChannelManager.Listener.PlayerQuitListener.onPlayerQuit(PlayerQuitListener.java:25)
... 11 more

NullPointerException in CloudChatFormattedListener

Exception occurs in CloudChat (1.7.0) on BungeeCord 776
It may seem it occurs once for each player - but not certain.

16:48:21 [SEVERE] des 28, 2013 4:48:21 PM net.md_5.bungee.event.EventBus post
WARNING: Error dispatching event net.cubespace.CloudChat.Event.CloudChatFormattedChatEvent@4229c1eb to listener net.cube
space.CloudChat.Listener.CloudChatFormattedListener@2f64c34d
java.lang.NullPointerException
at net.cubespace.CloudChat.Listener.CloudChatFormattedListener.onFormattedChat(CloudChatFormattedListener.java:38)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at net.md_5.bungee.event.EventHandlerMethod.invoke(EventHandlerMethod.java:19)
at net.md_5.bungee.event.EventBus.post(EventBus.java:47)
at net.md_5.bungee.api.plugin.PluginManager.callEvent(PluginManager.java:338)
at net.cubespace.CloudChat.Listener.PlayerQuitListener$1$1.run(PlayerQuitListener.java:44)
at net.md_5.bungee.scheduler.BungeeTask.run(BungeeTask.java:58)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:724)

IRC bot disconnects (and does not reconnect)

I left it on yesterday and today it was gone. No server or Proxy restarts. My internet Connection network and the normal IRC Client (mIRC) has not been disconnected.

IRC this morning at about 06:30

* CitaBot ([email protected]) Quit (*.net *.split�)

And in the log

06:30:49 [INFO] [CloudChat] Trying to reconnect to IRC
06:31:10 [SEVERE] [CloudChat] Could not reconnect IRC Bot
java.net.ConnectException: Connection timed out: connect
    at java.net.TwoStacksPlainSocketImpl.socketConnect(Native Method)
    at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339)
    at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200)
    at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182)
    at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172)
    at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
    at java.net.Socket.connect(Socket.java:579)
    at java.net.Socket.connect(Socket.java:528)
    at java.net.Socket.<init>(Socket.java:425)
    at java.net.Socket.<init>(Socket.java:208)
    at net.cubespace.vendor.org.jibble.pircbot.PircBot.connect(PircBot.java:140)
    at net.cubespace.vendor.org.jibble.pircbot.PircBot.reconnect(PircBot.java:248)
    at net.cubespace.CloudChat.Module.IRC.Bot.Bot.onDisconnect(Bot.java:243)
    at net.cubespace.vendor.org.jibble.pircbot.InputThread.run(InputThread.java:141)

This Block of retry -> timeout keeps repeating until I get the next error, then it seems it "gave up"

06:35:11 [SEVERE] [CloudChat] Could not reconnect IRC Bot
java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.read(SocketInputStream.java:152)
    at java.net.SocketInputStream.read(SocketInputStream.java:122)
    at sun.nio.cs.StreamDecoder.readBytes(StreamDecoder.java:283)
    at sun.nio.cs.StreamDecoder.implRead(StreamDecoder.java:325)
    at sun.nio.cs.StreamDecoder.read(StreamDecoder.java:177)
    at java.io.InputStreamReader.read(InputStreamReader.java:184)
    at java.io.BufferedReader.fill(BufferedReader.java:154)
    at java.io.BufferedReader.readLine(BufferedReader.java:317)
    at java.io.BufferedReader.readLine(BufferedReader.java:382)
    at net.cubespace.vendor.org.jibble.pircbot.PircBot.connect(PircBot.java:174)
    at net.cubespace.vendor.org.jibble.pircbot.PircBot.reconnect(PircBot.java:248)
    at net.cubespace.CloudChat.Module.IRC.Bot.Bot.onDisconnect(Bot.java:243)
    at net.cubespace.vendor.org.jibble.pircbot.InputThread.run(InputThread.java:141)

Running irc:reconnect command (much later :-)) the bot connected normally.

PircBot auto-rejoin after disconnect

Don't know why it disconnects, but it disconnects With: (~[email protected]) Quit (Read error: Connection reset by peer)
(No Messages in any logs)

if I reconnect using irc::reconnect, it rejoins the IRC-channel but Messages are starting to be duplicated like issue#9: #9

Whois resolve for private channel commands

If you don't join the channel, but open a pm-"channel" with the bot it would be nice to be whois-resolved when trying to send .scmd

(works fine after joining the channel once)

Change permission System to also use Bukkit Permission

Most server dont have a BungeeCord permission setup. Enable CloudChatBukkit to read the Bukkit Permissions and tell CloudChat the permissions needed.

This will enable any Permission plugin in Bukkit to function with CloudChat.

IRC commands not working (read: probably need help with permissions)

From report:

04.01.2014 17:26:52  [Logger/DEBUG] Got IRC Message from #citaborg: .players
04.01.2014 17:26:52  [Logger/DEBUG] Got a new relay Message from IRC: Citaborg: .players
04.01.2014 17:26:52  [Logger/DEBUG] Got Minecraft Message sending it to #citaborg: Citaborg: You have not enough Permissions to execute this

My ircPerm file:

Groups:
  default:
    Rank: 1
    Permissions:
    - command.players
    Inherits: []
Users:  
  Citaborg:
    Groups:
    - default
    Permissions:
    - command.players
    - command.mute
    - command.unmute
    - command.message

Citaborg is a registered nick With espernets NickServ

/msg NickServ Acc Citaborg
-NickServ- Citaborg ACC 3

/whois Citaborg
Citaborg is [email protected] * Skattefuten
Citaborg on #citaborg #md_5 #spigot 
Citaborg using availo.esper.net We've got the most recently updated description!
Citaborg has been idle 14secs, signed on Sat Dec 28 13:43:26
Citaborg is logged in as Citaborg
Citaborg End of /WHOIS list.

Still getting NullPointerException in PlayerQuitListener from time to time

16:16:32 [WARNING] [CloudChat] Listener net.cubespace.CloudChat.Module.ChannelManager.Listener.PlayerQuitListener.onPlayerQuit has thrown an Exception
java.lang.reflect.InvocationTargetException
at sun.reflect.GeneratedMethodAccessor30.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at net.cubespace.lib.EventBus.AsyncEventBus.handleEvent(AsyncEventBus.java:189)
at net.cubespace.lib.EventBus.AsyncEventBus.access$300(AsyncEventBus.java:22)
at net.cubespace.lib.EventBus.AsyncEventBus$2.run(AsyncEventBus.java:85)
at net.md_5.bungee.scheduler.BungeeTask.run(BungeeTask.java:58)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:724)
Caused by: java.lang.NullPointerException
at net.cubespace.CloudChat.Module.ChannelManager.ChannelManager.leave(ChannelManager.java:212)
at net.cubespace.CloudChat.Module.ChannelManager.ChannelManager.remove(ChannelManager.java:199)
at net.cubespace.CloudChat.Module.ChannelManager.Listener.PlayerQuitListener.onPlayerQuit(PlayerQuitListener.java:25
)
... 10 more

Spam config error (dev build)

Running a clean setup, start bungee, stop bungee and start bungee again, this error occurs:
(I am running a build from latest commit, so I know its "unsupported" :-) )

15:15:19 [SEVERE] Cannot load plugins\CloudChat\spam.yml
net.craftminecraft.bungee.bungeeyaml.bukkitapi.InvalidConfigurationException: could not determine a constructor for the tag tag:yaml.org,2002:net.cubespace.Clou
dChat.Config.Sub.SpamEntry
 in 'string', line 2, column 3:
- !!net.cubespace.CloudChat.Config ...
  ^

at net.craftminecraft.bungee.bungeeyaml.bukkitapi.file.YamlConfiguration.loadFromString(YamlConfiguration.java:113)
at net.craftminecraft.bungee.bungeeyaml.bukkitapi.file.FileConfiguration.load(FileConfiguration.java:151)
at net.craftminecraft.bungee.bungeeyaml.bukkitapi.file.FileConfiguration.load(FileConfiguration.java:118)
at net.craftminecraft.bungee.bungeeyaml.bukkitapi.file.YamlConfiguration.loadConfiguration(YamlConfiguration.java:233)
at net.cubespace.lib.Configuration.Config.reload(Config.java:38)
at net.cubespace.lib.Configuration.Config.init(Config.java:109)
at net.cubespace.lib.Configuration.ConfigManager.initConfig(ConfigManager.java:38)
at net.cubespace.CloudChat.CloudChatPlugin.onEnable(CloudChatPlugin.java:38)

at net.md_5.bungee.api.plugin.PluginManager.loadAndEnablePlugins(PluginManager.java:200)
at net.md_5.bungee.BungeeCord.start(BungeeCord.java:200)
at net.md_5.bungee.Bootstrap.main(Bootstrap.java:67)

And config looks like this:

SpamRules:
- !!net.cubespace.CloudChat.Config.Sub.SpamEntry
  ActionIfReached: MUTE
  AmountOfMessages: 1000
  CommandToDispatch: ban %player Dont spam so much
  ExcludePermission: cloudchat.spam.rule1
  HowLongToMuteInSeconds: 30
  InHowMuchSeconds: 10
  KickMessage: You have been kicked for Spamming
  MuteMessage: You have been muted for %amount seconds due to spamming

Duplicate messages

Running 1.7* and 0.5.1 all Messages are duplicated

capture

It almost feels like the CloudChatBukkit is not there (apart from the Message being transmitted to IRC)

Chat bungee config:

MaxChannelsPerChatter: 4
DoNotBind: []

Announce:
  PlayerJoin: true
  PlayerJoinMessage: '&8[&2%channel_short&8]&r %prefix%nick%suffix&r joined the Server'
  PlayerQuit: true
  PlayerQuitMessage: '&8[&2%channel_short&8]&r %prefix%nick%suffix&r left the Server'
  PlayerGotAfk: '&8[&2%channel_short&8]&r %prefix%nick%suffix&r is afk'
  PlayerGotOutOfAfk: '&8[&2%channel_short&8]&r %prefix%nick%suffix&r no longer is afk'

DontHandleForServers: []
FactionServers: []

Chat bukkit config:

BlockPlayerJoin: false
BlockPlayerQuit: false
HandleAFK: false
AutoAFK: 0

(Reverting to previous Version (1.6.1) With untouched config Works)

cutoff in .players message to IRC

Issuing .players works fine most of the time. But just now it started acting strangely...

This is the cc:reports line for the event - which has all players

10.01.2014 20:44:35  [Logger/DEBUG] IRC PM to bot from Citaborg|away: .players
10.01.2014 20:44:35  [Logger/DEBUG] Getting Config for messages: net.cubespace.CloudChat.Config.Messages@52f70305
10.01.2014 20:44:35  [Logger/DEBUG] Got Minecraft Message sending it to Citaborg|away: �01Current Players online (25): 
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for Sofie_13
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for Herry202
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for triux
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for mellembygd
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for ormeredet
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for DerpyWood
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for matslyder
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for silent5nipes
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for Capaccio
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for BmxMathias
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for HavardBE
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for kaska02
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for minifredrik
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for NbtPokk01
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for xhavard123
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for jonasjba
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for Larsgjerst
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for xXProJumperXx
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for Kemal05
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for heddamisha
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for Joakim0805
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for mica2003
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for sansor03
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for Aleh2003
10.01.2014 20:44:35  [Logger/DEBUG] Getting PlayerDatabase for thomas4141
10.01.2014 20:44:35  [Logger/DEBUG] Got Minecraft Message sending it to Citaborg|away: �09[Mod]Sofie_13�01, �03[Medlem]Herry202�01, �03[�02V�01I�04P�03]�02triux�01, �03[Medlem]mellembygd�01, �03[�02V�01I�04P�03]�02ormeredet�01, �03[�02V�01I�04P�03]�02DerpyWood�01, �03[Medlem]matslyder�01, �03[Medlem]silent5nipes�01, �03[Medlem]Capaccio�01, �03[Medlem]BmxMathias�01, �03[Medlem]HavardBE�01, �03[Medlem]kaska02�01, �03[Medlem]minifredrik�01, �11[Admin]NbtPokk01�01, �03[�02V�01I�04P�03]�02xhavard123�01, �03[�02V�01I�04P�03]�02jonasjba�01, �03[Medlem]Larsgjerst�01, �09[Mod]xXProJumperXx�01, �03[Medlem]Kemal05�01, �03[Medlem]heddamisha�01, �03[�02V�01I�04P�03]�02Joakim0805�01, �03[Medlem]mica2003�01, �03[Medlem]sansor03�01, �03[�02V�01I�04P�03]�02Aleh2003�01, �03[�02V�01I�04P�03]�02thomas4141�01

This is the IRC output (cut off at the beginning of player 15). I have the same issue with different number of players (and different players), so it doesn't feel like a length-of-the-message-problem:

[20:44] <CitaborgBot> Current Players online (25): 
[20:44] <CitaborgBot> [Mod]Sofie_13, [Medlem]Herry202, [VIP]triux, [Medlem]mellembygd, [VIP]ormeredet, [VIP]DerpyWood, [Medlem]matslyder, [Medlem]silent5nipes, [Medlem]Capaccio, [Medlem]BmxMathias, [Medlem]HavardBE, [Medlem]kaska02, [Medlem]minifredrik, [Admin]NbtPokk01, [VIP]xhavard123, [VI                         

And the bungee log file:

20:44:35 [INFO] [CloudChat] IRC PM to bot from Citaborg|away: .players
20:44:35 [INFO] [CloudChat] Getting Config for messages: net.cubespace.CloudChat.Config.Messages@52f70305
20:44:35 [INFO] [CloudChat] Got Minecraft Message sending it to Citaborg|away: �01Current Players online (25): 
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for Sofie_13
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for Herry202
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for triux
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for mellembygd
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for ormeredet
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for DerpyWood
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for matslyder
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for silent5nipes
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for Capaccio
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for BmxMathias
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for HavardBE
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for kaska02
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for minifredrik
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for NbtPokk01
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for xhavard123
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for jonasjba
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for Larsgjerst
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for xXProJumperXx
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for Kemal05
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for heddamisha
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for Joakim0805
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for mica2003
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for sansor03
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for Aleh2003
20:44:35 [INFO] [CloudChat] Getting PlayerDatabase for thomas4141
20:44:35 [INFO] [CloudChat] Got Minecraft Message sending it to Citaborg|away: �09[Mod]Sofie_13�01, �03[Medlem]Herry202�01, �03[�02V�01I�04P�03]�02triux�01, �03[Medlem]mellembygd�01, �03[�02V�01I�04P�03]�02ormeredet�01, �03[�02V�01I�04P�03]�02DerpyWood�01, �03[Medlem]matslyder�01, �03[Medlem]silent5nipes�01, �03[Medlem]Capaccio�01, �03[Medlem]BmxMathias�01, �03[Medlem]HavardBE�01, �03[Medlem]kaska02�01, �03[Medlem]minifredrik�01, �11[Admin]NbtPokk01�01, �03[�02V�01I�04P�03]�02xhavard123�01, �03[�02V�01I�04P�03]�02jonasjba�01, �03[Medlem]Larsgjerst�01, �09[Mod]xXProJumperXx�01, �03[Medlem]Kemal05�01, �03[Medlem]heddamisha�01, �03[�02V�01I�04P�03]�02Joakim0805�01, �03[Medlem]mica2003�01, �03[Medlem]sansor03�01, �03[�02V�01I�04P�03]�02Aleh2003�01, �03[�02V�01I�04P�03]�02thomas4141�01
20:44:35 [INFO] [CloudChat] Handled 0 Events, 0 new Events had been added
20:44:35 [INFO] [CloudChat] Checking for Spam Rule violations
20:44:35 [INFO] [CloudChat] Got server Message: 301 CitaborgBot Citaborg|away :zzz
20:44:36 [INFO] [CloudChat] Removing a Message for Herry202
20:44:36 [INFO] [CloudChat] Handled 0 Events, 0 new Events had been added
20:44:36 [INFO] [CloudChat] Checking for Spam Rule violations
20:44:36 [INFO] [CloudChat] Got server Message: 301 CitaborgBot Citaborg|away :zzz

Also after running cc:report on to record this and then setting cc:report off, it seems to break down. The .players just lists the number of players on-line, like below, and I cannot re-enable cc:report (it says issued with arg on, but doesn't start #45). This last behavior is not consistently reproducible (happens about 1 of 5 times)

[20:52] <Citaborg|away> .players
[20:52] <CitaborgBot> Current Players online (28): 
[20:54] <Citaborg|away> .players
[20:54] <CitaborgBot> Current Players online (25): 
[20:56] <Citaborg|away> .players
[20:56] <CitaborgBot> Current Players online (26): 

(sorry to all players for not masking out the names...)

[Bug] Click Menu in Factions chat

If you switch to Factions chat using /fchat you will see the %nick{ClickMenu} or whatever the syntax show up in actual chat rather than parsing correctly.

[Feature] Reload

Hey,

I miss a reload command that reloads all configs. As it runs on Bungeecord which I don´t like to restart.

"Strange" default messages

What is the {click} stuff in the Messages? Like

PlayerJoin: '&8[&2%channel_short&8]&r %prefix%nick{click:playerMenu}%suffix&r joined the Server'

In my setup it makes Things look like this (on IRC)

capture
(see the player joined Message)

IRC relay doesn't work when bot joins existing channel(s)

When joining existing IRC channel Messages from IRC are not relayed (server to IRC is fine). Joining new channels or disconnecting users and running irc:reconnect it Works correctly again

Also would be Nice With a status/reply for the bungeecord window when the irc Client has reconnected after running irc:reconnect

(this does not work in version 1.6.1 either)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.