Here is the first MoModth functionality sneak peek – Local Notifications
TR_localNotifications module comes with MoModth package by default. As any other MoModth module TR_localNotifications can be enabled/disabeled while in the project or can be easily removed or added to the project whether you need it or not. Local Notifications functionality is one of most desired features for mobile apps. It’s one of the best marketing tools simply because it “calls” your players back to game for whatever reason you implement. Local Notifications work even when the game is closed!
What do I use it for?
You can use it to anything which requires to notify the player about. Commone usage examples:
- Come back to game – we miss you! – You can implement a notification which will ask player to visit the game if he did not play it for a week for instance.
- Your army is ready! – If your game has an army, buildings or any other feature which takes time to finish, you can set notification to tell player that it is ready and he can go back to game.
- We have a gift for you! – The best way to encourage someone to do something is to reward him. Notify your player that if he comes back to game he will be rewarded with 1000 gold coins!
- Happy New Year! – You can set notification to pops-up on the particular date. This is also a great opportunity to reward player with some coins.
See how it works
Sorry for the bad camera focus, I had bad light here. Next time I’ll try to do it somewere else. Anyway here it is.
Implementation of the example in the video
There is only one event line needed in order to send local notifications with MoModth and one to fetch notification data (if needed).
Those are examples of sending local notifications with data (first one) and without data (second).
As data you can send integer, string or even dictionary as JSON. So usage possibilities are unlimited.
And here is the part where we fetch incomming notification.