Skip to content

Mobile Notifiaction

VirtueSky edited this page Sep 4, 2024 · 8 revisions

Use

Create scriptable Mobile Notification Chanel

  • Open tab Notification Chanel in Magic Panel > Create Notification Chanel

Screenshot 2024-09-04 174019

  • 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

Screenshot 2024-02-28 104933

  • Identifier : Id of chanel
  • Minute : After time Minute, a notification will be sent
  • Repeat : With true, notification sending will be repeated
  • Big Picture : With true, notification use pig picture.

(note: File big picture must be place in folder StreamingAsset, Name Picture must contains file extension ex .jpg)

mJSRu

  • Name Picture : Name of pig picture
  • Datas: Is a list containing notification tiles and notification messages

Send notification

  • If use pic picture, you need add component Notification Prepare

Screenshot 2024-02-28 111535

  • 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 in Notification 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();
        }
    }
Clone this wiki locally