Mobile Notifiaction - VirtueSky/sunflower GitHub Wiki
Use
Mobile Notification Chanel
Create scriptable - Open tab
Notification Chanel
inMagic Panel
>Create Notification Chanel
- If you haven't installed mobile notification yet, you can click
Install Mobile Notification
- If you haven't added define symbols yet, click
Add --> VIRTUESKY_NOTIFICATION
Notification Chanel Data
Identifier
: Id of chanelMinute
: After timeMinute
, a notification will be sentRepeat
: Withtrue
, notification sending will be repeatedBig Picture
: Withtrue
, notification use pig picture.
(note: File big picture must be place in folder StreamingAsset
, Name Picture must contains file extension ex .jpg
)
Name Picture
: Name of pig pictureDatas
: Is a list containing notificationtiles
and notificationmessages
Send notification
- If use pic picture, you need add component
Notification Prepare
-
Code demo send / schedule notification
- Send(): Send notification immediately when calling the function
- Schedule(): Schedule and will send notification after the time
Minute
set up inNotification Chanel
[SerializeField] private List<NotificationVariable> listNotificationVariable;
void Start()
{
foreach (var notification in listNotificationVariable)
{
notification.Schedule();
}
}
public void SendNotification()
{
foreach (var notification in listNotificationVariable)
{
notification.Send();
}
}