Lunchbox 87 Report post Posted April 30, 2016 (edited) This is a small script that announces when territory payments are due. The script is in American format currently, if you're European, flip %2 and %3 around in the _dueDate = format. Under _dueDate the format is like this: %1 = Year %2 = Month %3 = Day This doesn't count for ["TaskCreated",["",format["<t color='#E48A36'>%2</t> territory payment due: <t color='#E48A36'>%1</t>",_dueDate,_name]]] call BIS_fnc_showNotification; They are just calling the variable present in the event notification. %2 is calling the territory name and %1 is calling the due date. Installation: 1. Add the file announcepay.sqf to your mission folder. /* Created by Lunchbox for use with Exile mod for Arma 3. Copyright 2016, Lunchbox, All rights reserved. */ _playerUID = getPlayerUID player; { _flag = _x; _buildRights = _flag getVariable ["ExileTerritoryBuildRights", []]; if (_playerUID in _buildRights) then { _nextDueDate = _flag getVariable ["ExileTerritoryMaintenanceDue", [0, 0, 0, 0, 0]]; _name = _flag getVariable ["ExileTerritoryName", ""]; _dueDate = format [ "%2/%3/%1", _nextDueDate select 0, _nextDueDate select 1, _nextDueDate select 2 ]; ["TaskCreated",["",format["<t color='#E48A36'>%2</t> territory payment due: <t color='#E48A36'>%1</t>",_dueDate,_name]]] call BIS_fnc_showNotification; }; } forEach (allMissionObjects "Exile_Construction_Flag_Static"); 2. Add this line at the bottom of your InitPlayerLocal.sqf: waitUntil {!isNull findDisplay 46 && !isNil 'ExileClientLoadedIn' && getPlayerUID player != ''}; uiSleep 1; execVM "announcepay.sqf"; 3. Done. Screenshots (This is what the user will see when they log in): v1.1 - Added color - Changed the way due dates were delivered. I couldn't get the exile messages to work correctly, no matter what I tried. Edited May 3, 2016 by Lunchbox 24 Share this post Link to post Share on other sites
John 540 Report post Posted April 30, 2016 Nifty, EXILE should have something to this end as standard. 1 Share this post Link to post Share on other sites
kuplion 1785 Report post Posted April 30, 2016 Loving this. Out of interest, what happens for players who don't have a territory? Share this post Link to post Share on other sites
second_coming 836 Report post Posted April 30, 2016 nothing, they get no notification 1 Share this post Link to post Share on other sites
kuplion 1785 Report post Posted April 30, 2016 (edited) 8 minutes ago, second_coming said: nothing, they get no notification Cheers for the clarification. EDIT: I really should have read the code before posting. My bad.. Edited April 30, 2016 by kuplion 1 Share this post Link to post Share on other sites
Lunchbox 87 Report post Posted April 30, 2016 8 hours ago, kuplion said: Cheers for the clarification. EDIT: I really should have read the code before posting. My bad.. Yeah, if the playerid isn't found in a territory, the if statement doesn't get run. 1 Share this post Link to post Share on other sites
Mezo 1264 Report post Posted April 30, 2016 Just a small tip, it might be nice to have a check for the player to be on the ground. I know some clients have some lag issues when parachuting in and the notifications really don't help Share this post Link to post Share on other sites
Lunchbox 87 Report post Posted May 1, 2016 (edited) On 4/30/2016 at 3:41 PM, Taylor Swift said: Just a small tip, it might be nice to have a check for the player to be on the ground. I know some clients have some lag issues when parachuting in and the notifications really don't help On my personal server, I have a uiSleep30; run before it runs the check. Edit: I added a post on the next page of a check that will probably work. Edited May 1, 2016 by Lunchbox Share this post Link to post Share on other sites
zombietop 33 Report post Posted May 1, 2016 This is great. The little things man, the little things. Share this post Link to post Share on other sites
Lunchbox 87 Report post Posted May 1, 2016 5 minutes ago, zombietop said: This is great. The little things man, the little things. Exactly, those QoL changes are what I am after. 2 Share this post Link to post Share on other sites