Make it easy to create a UserMessage for tells.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4252 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -50,4 +50,15 @@ public class UserMessage extends ChatMessage
|
|||||||
this.speaker = speaker;
|
this.speaker = speaker;
|
||||||
this.mode = mode;
|
this.mode = mode;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Constructs a user message for a player originated tell (which has no
|
||||||
|
* bundle and is in the default mode).
|
||||||
|
*/
|
||||||
|
public UserMessage (String message, Name speaker)
|
||||||
|
{
|
||||||
|
super(message, null);
|
||||||
|
this.speaker = speaker;
|
||||||
|
this.mode = ChatCodes.DEFAULT_MODE;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -263,8 +263,7 @@ public class ChatProvider
|
|||||||
*/
|
*/
|
||||||
protected UserMessage createTellMessage (BodyObject source, String message)
|
protected UserMessage createTellMessage (BodyObject source, String message)
|
||||||
{
|
{
|
||||||
return new UserMessage(
|
return new UserMessage(message, source.getVisibleName());
|
||||||
message, null, source.getVisibleName(), DEFAULT_MODE);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user