Mails

Gamespark Framework documentation:

This module will let your player exchange mails between them, attach currencies in the mails and receive mails from the server on special events.

GsfMail: Core of the mail system which send request to get list of emails, delete & send new email then dispatch result to Ui, it also catch event relate to Ui emails, and send notification when a new email is received.

UiMail: Display the result of request to email on an Ui Panel. Send the input from Ui to GsfMail.

Note: Both components share no dependencies, so its very easy to integrate your own Ui system by creating a new script based on UiMail.

How to send email from server?

How to add new fields into the email?

You will need to add fields in MailContent class first:

Then when sending data to server code need to store that new field:

Then in unity you need to add one line to extract this data: