I want to send NSString form another one to another one iPhone/iPad via Gamecenter but it crash with EXC_BAD_ACCESS
here in .h file
typedef enum {
kM
try this:
To encode:
NSData *data = [stringToEncode dataUsingEncoding:NSUTF8Encoding];
which you can send using Game Center
To decode:
NSString *recievedString = [NSString stringWithUTF8String:[recievedData bytes]];
Edit: Now I think you can even put this data in one of your message structs and do the same [NSData dataWithBytes:&message length:sizeof(MessageSubmit)]
trick and send it.