2017-05-08 00:59:50 +02:00
|
|
|
|
using UnityEngine.Networking;
|
|
|
|
|
|
|
|
|
|
public class TextMessage : MessageBase {
|
|
|
|
|
|
2017-05-08 02:59:42 +02:00
|
|
|
|
public string Message;
|
2017-05-08 00:59:50 +02:00
|
|
|
|
|
|
|
|
|
public TextMessage(string message) {
|
2017-05-08 02:59:42 +02:00
|
|
|
|
this.Message = message;
|
2017-05-08 00:59:50 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public TextMessage() {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public override void Deserialize(NetworkReader reader) {
|
2017-05-08 02:59:42 +02:00
|
|
|
|
Message = reader.ReadString();
|
2017-05-08 00:59:50 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public override void Serialize(NetworkWriter writer) {
|
2017-05-08 02:59:42 +02:00
|
|
|
|
writer.Write(Message);
|
2017-05-08 00:59:50 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|