Search Unity

  1. The Unity Pro & Visual Studio Professional Bundle gives you the tools you need to develop faster & collaborate more efficiently. Learn more.
    Dismiss Notice
  2. Want more efficiency in your development work? Sign up to receive weekly tech and creative know-how from Unity experts.
    Dismiss Notice
  3. Participate with students all over the world and build projects to teach people. Join now!
    Dismiss Notice
  4. Build games and experiences that can load instantly and without install. Explore the Project Tiny Preview today!
    Dismiss Notice
  5. Improve your Unity skills with a certified instructor in a private, interactive classroom. Watch the overview now.
    Dismiss Notice
  6. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice

[RELEASED] Android Notification Plugin

Discussion in 'Assets and Asset Store' started by Takohi, Nov 14, 2015.

  1. Takohi

    Takohi

    Joined:
    May 14, 2014
    Posts:
    58
    We are glad to present you our Android plug-in that enhances control over Android notification system.

    Easily trigger some notifications from your game!
    Working on all available Unity versions, it also does not require Unity PRO version.

    With this plugin, you can display one or several notifications at the same time with a lot of customisations:
    • Small and large icons of your choice from a Texture2D or colors array;
    • Title and content texts;
    • Vibration pattern;
    • Light/LED color and the blink timing;
    • Using the default notification sound or not;
    • Making the notification being removed when the user clicks on it or setting the notification as sticky (can't be removed by the user);
    • Other options...

    When the user clicks on the notification, it will automatically bring him back to your game. You can also update and clear the notifications from your source code.

    You can check how easy it is to use this plugin by checking the documentation and all available functions here:
    http://www.takohi.com/data/unity/assets/android_notification/documentation/

    You can also download and run a demo on your Android device by downloading this APK:
    http://www.takohi.com/data/unity/assets/android_notification/unity-android-notification-plugin-demo.apk
    The source code of this demo is included in the package.

    The price: 2$.
    The asset is available on the asset store here.

    If you have any suggestion or any question, please feel free to ask!

    Also, check our other assets:
     
    Last edited: Nov 14, 2015
  2. akbay

    akbay

    Joined:
    Mar 23, 2015
    Posts:
    3
    Hi,

    I want to create scheduled different notifications. For example, 10 notification with one hour interval. But, I only get one of them at 10 hours later and title and content is belongs to first notification. How can I solve this?

    for (int i = 0; i < 10; i++)
    {
    Notification notification = new Notification("Title " + i.ToString(), "Content " + i.ToString());
    .
    .
    .
    System.DateTime notificationTime = System.DateTime.Now.AddHours(i+1);
    NotificationManager.ShowNotification(i, notification, notificationTime);
    }

    // Title 0 - Content 0

    Please I need to solve this as soon as possible.
     
  3. Takohi

    Takohi

    Joined:
    May 14, 2014
    Posts:
    58
    It should work. Is there any code missing?
    Can you also try this following way too?

    Code (CSharp):
    1. {
    2.     Notification notification = new Notification("Title " + i.ToString(), "Content " + i.ToString());
    3.     NotificationManager.ShowNotification(i, notification, i * 1000 * 60 * 60); // 1000 * 60 * 60 number of ms in hour.
    4. }
    See documentation here:
    http://www.takohi.com/data/unity/as...anager.html#ac25032bebccbf55164ba4453e08ff804
     
  4. akbay

    akbay

    Joined:
    Mar 23, 2015
    Posts:
    3
    You can try same thing with demo scene ("notification_scene").

    1) hit "Show Notification with 10s delay"
    2) wait for notification
    3) change title
    4) hit "Show Notification with 10s delay"

    shows same notification every time.

    I tried on android 4.3(s3) and 5.1.1(s6).

    ps I have tried your suggestion. It does't work ether.
     
  5. Takohi

    Takohi

    Joined:
    May 14, 2014
    Posts:
    58
    Did you change the Notification ID each time?
     
  6. akbay

    akbay

    Joined:
    Mar 23, 2015
    Posts:
    3
    Yep, I did.
     
  7. Takohi

    Takohi

    Joined:
    May 14, 2014
    Posts:
    58
    Ok, thank you. I will take a look and keep you posted.
     
    akbay likes this.
  8. Takohi

    Takohi

    Joined:
    May 14, 2014
    Posts:
    58
    I could confirm the problem. It only occurs with notification with delay.
    I'm now trying to find why it happens and fix it as soon as possible. When it's ready, I will send to you the updated file.

    Please be patient, I hope it will be done before this week-end.
     
    akbay likes this.
  9. Takohi

    Takohi

    Joined:
    May 14, 2014
    Posts:
    58
    Hello akbay, I found the problem and made a fix. I will contact you by MP with the update. Sorry for any inconvenience.
     
  10. parker87tinh

    parker87tinh

    Joined:
    Jun 5, 2015
    Posts:
    5
    Hi Takohi.
    Can you post the solution for Notification with delay? i am having the same proplem with notification delay.
    Thanks.
     
  11. Takohi

    Takohi

    Joined:
    May 14, 2014
    Posts:
    58
  12. kathode

    kathode

    Joined:
    Jan 15, 2013
    Posts:
    63
    Hi there,
    Hoping that this plug-in is still supported here. I am having a similar issue with delayed notifications as reported above. In my case, immediate notifications show up and work fine, but delayed notifications never arrive. They do work in the sample APK. But in my app, only showing notifications with no delay parameters works. I even copied the code from Notify.cs and applied it to two buttons in my game.

    I just bought the asset today so I assume I'm on 1.2. Any idea what might cause delay to not work?

    Thank you!

    Edit: Clarified problem.
     
    Last edited: Nov 12, 2016
  13. solid_

    solid_

    Joined:
    Jul 10, 2015
    Posts:
    5
    Hi. Scheduled notification appears after device restart? Thank you!