Packet: RequestDestroyMessage

* Add RequestDestroyMessage packet

* Add RequestDestroyMessage test

* Add RequestDestroyMessage handler stub
This commit is contained in:
tfarley 2016-07-23 23:00:46 -07:00 committed by pschord
parent 7ecbe203f8
commit 427429b34c
4 changed files with 43 additions and 1 deletions

View file

@ -349,5 +349,25 @@ class GamePacketTest extends Specification {
pkt mustEqual string
}
}
"RequestDestroyMessage" should {
val string = hex"2D A49C"
"decode" in {
PacketCoding.DecodePacket(string).require match {
case RequestDestroyMessage(object_guid) =>
object_guid mustEqual PlanetSideGUID(40100)
case default =>
ko
}
}
"encode" in {
val msg = RequestDestroyMessage(PlanetSideGUID(40100))
val pkt = PacketCoding.EncodePacket(msg).require.toByteVector
pkt mustEqual string
}
}
}
}