类 ClientChatEvent
java.lang.Object
net.minecraftforge.eventbus.api.Event
net.minecraftforge.client.event.ClientChatEvent
public class ClientChatEvent
extends net.minecraftforge.eventbus.api.Event
Fired when the client is about to send a chat message to the server.
This event is cancellable, and does not have a result. If the event is cancelled, the chat message will not be sent to the server.
This event is fired on the main Forge event bus, only on the logical client.
-
嵌套类概要
从类继承的嵌套类/接口 net.minecraftforge.eventbus.api.Event
net.minecraftforge.eventbus.api.Event.HasResult, net.minecraftforge.eventbus.api.Event.Result
-
字段概要
字段 -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明返回 the message that will be sent to the server, if the event is not cancelled. This can be changed by mods。返回 the original message that was to be sent to the server. This cannot be changed by mods。void
setMessage
(String message) Sets the new message to be sent to the server, if the event is not cancelled.从类继承的方法 net.minecraftforge.eventbus.api.Event
getListenerList, getPhase, getResult, hasResult, isCancelable, isCanceled, setCanceled, setPhase, setResult
-
字段详细资料
-
message
-
originalMessage
-
-
构造器详细资料
-
ClientChatEvent
-
-
方法详细资料
-
getMessage
返回 the message that will be sent to the server, if the event is not cancelled. This can be changed by mods。- 返回:
- the message that will be sent to the server, if the event is not cancelled. This can be changed by mods
-
setMessage
Sets the new message to be sent to the server, if the event is not cancelled.- 参数:
message
- the new message to be sent
-
getOriginalMessage
返回 the original message that was to be sent to the server. This cannot be changed by mods。- 返回:
- the original message that was to be sent to the server. This cannot be changed by mods
-