Hi - I'm another programmer working on the project with XandY.
Our code currently doesn't use the mn create key command, since it creates a different key each time we ran the server, and we hadn't added in a means for the server to send this key to the client yet.
Instead, we just defined a key (created by using the mn Create Key 256 command) and kept it the same.
This code shows some lines of our server source which handles encryption. It is the same for the other parts of the code in which we encrypt a packet.
#constant OP_LEFTPLAYER 1
key1# = 46214288
mn Add Int SendPacket,OP_LEFTPLAYER
mn Add Int SendPacket,Left
SendPacketSize = mn get memory size (SendPacket)
if SendPacketSize > 0
mn encrypt SendPacket,Key1#
SendEncryptSize = mn get memory size (SendPacket)
mn change memory size SendPacket,SendEncryptSize
mn Send TCP All 0,SendPacket,0,0,Left
endif
Thank you,