AZCoder 921 Posted May 19, 2018 On 5/9/2018 at 5:24 AM, HazJ said: Uhh. Are you using the stringtable.xml which is included? If you are then... Not sure about saving stuff. Will need to look into it. Sorry I didn't see your reply until today. It's easy to verify. Just load your sample mission in the VR, put this in the debug console: ["New notification", "This is a notification!", [0, 0, 0, 1], [1, 1, 0, 1]] spawn Haz_fnc_createNotification; and the message appears fine. Save the game. Load the save. Open the debug and execute that code again, nothing happens. Share this post Link to post Share on other sites
AZCoder 921 Posted May 19, 2018 I have a working solution. Note the 2 sec delay. It doesn't work without a delay. "layer_notifications" cutRsc ["rsc_notifications", "PLAIN"]; addMissionEventHandler ["Loaded",{ [] spawn { sleep 2; "layer_notifications" cutRsc ["rsc_notifications", "PLAIN"]; }; }]; 1 Share this post Link to post Share on other sites
HazJ 1288 Posted May 20, 2018 Weird. I don't ever use save so never notice this shit. I'll add that to next release. Thanks for sharing! 1 Share this post Link to post Share on other sites
AZCoder 921 Posted May 20, 2018 Yeah that's a single player problem. I added your scripts to my upcoming campaign and the first time I died and had to reload during testing, I was like "where are the notifications!?" 1 Share this post Link to post Share on other sites
HazJ 1288 Posted May 20, 2018 I was like "where are the notifications!?" Then you were like... Oh yeah. ArmA 2 Share this post Link to post Share on other sites
HazJ 1288 Posted May 29, 2018 This bug has been fixed. It will be released in the next patch along with @AZCoder's code snippet for load save fix and config options. 2 Share this post Link to post Share on other sites
HazJ 1288 Posted May 29, 2018 Quote 0.3 Added load save fix (thanks AZCoder) Added functionality for the inactive customisable config options that were added last version (for example: positionOnScreen) Fixed the bug with the key press toggle (expand/shrink control elements) Fixed queue counter https://github.com/HazJ/notificationSystem.VR @foxhound 3 1 Share this post Link to post Share on other sites
Guest Posted May 29, 2018 Thanks for sending us the updated version! The Armaholic mirror has been updated with the new version: Notification System v0.3 Share this post Link to post Share on other sites
jts_2009 96 Posted May 31, 2018 On 20.05.2018 at 12:24 AM, AZCoder said: I have a working solution. Note the 2 sec delay. It doesn't work without a delay. Thats because the main interface is not initialized. In multiplayer the 2 sec delay may fail if the main interface is not initialized (low fps, much objects, long loading time). It's better to wait for main interface with: waitUntil {!isNull finddisplay 46}; addMissionEventHandler ["Loaded",{ [] spawn { waitUntil {!isNull finddisplay 46}; "layer_notifications" cutRsc ["rsc_notifications", "PLAIN"]; }; }]; 1 Share this post Link to post Share on other sites
AZCoder 921 Posted May 31, 2018 Thanks for posting that. The sleep was rather arbitrary "fix" I admit :) I forgot about the display 46. Excellent. Share this post Link to post Share on other sites
Tankbuster 1733 Posted June 23, 2018 I'm pushing this into my mission now :) First two of many questions then; How does the expand notification work? I've looked over your code and see actionkeys "help". but don't understand that at all I see it needs to be run on the client. Any guidance as to how I might best remote exec it from the server? 1 Share this post Link to post Share on other sites
Tankbuster 1733 Posted June 23, 2018 6 minutes ago, Tankbuster said: I see it needs to be run on the client. Any guidance as to how I might best remote exec it from the server? ["New notification", "This is a notification!", [0, 0, 0, 1], [1, 1, 0, 1]] remoteexec ["haz_fnc_createnotification", 0, false]; Run on the server appears to work. I'm just wondering if it's the best way to achieve this? Share this post Link to post Share on other sites
Tankbuster 1733 Posted June 23, 2018 Can the top yellow line be made any bigger so that it can fit my mission logo, seen here in the lower box? Share this post Link to post Share on other sites
HazJ 1288 Posted June 24, 2018 remoteExec example from one of my projects: [localize "STR_mission_captureVehicleTitle", format [localize "STR_mission_captureVehicleDescription", _vehicleDisplayName]] remoteExec ["client_fnc_createNotification", ([0, -2] select isDedicated), false]; drunk from club - Yes, it can - Adjust h value... Will reply tomorrow! 2 Share this post Link to post Share on other sites
Tankbuster 1733 Posted June 24, 2018 Sober from home - Thanks! Lol 2 Share this post Link to post Share on other sites
Tankbuster 1733 Posted June 24, 2018 18 hours ago, HazJ said: remoteExec example from one of my projects: [localize "STR_mission_captureVehicleTitle", format [localize "STR_mission_captureVehicleDescription", _vehicleDisplayName]] remoteExec ["client_fnc_createNotification", ([0, -2] select isDedicated), false]; drunk from club - Yes, it can - Adjust h value... Will reply tomorrow! I changed the h value, assuming its line 42 of rsc_notifications.hpp but the yellow part didn't change size. Am I changing the wrong bit? Share this post Link to post Share on other sites
AZCoder 921 Posted June 24, 2018 21 minutes ago, Tankbuster said: I changed the h value, assuming its line 42 of rsc_notifications.hpp but the yellow part didn't change size. Am I changing the wrong bit? It's in fn_createNotification, line 86. Try something like this: _title ctrlSetPosition [ _safeZoneX, (0.185 + (_position * 0.16)) * safezoneH + safezoneY, 0.2125 * safezoneW, 0.0495 * safezoneH ]; The .185 line is the lower box size and the 495 line is the title bar. 1 Share this post Link to post Share on other sites
HazJ 1288 Posted June 24, 2018 Fine now lol! Yes, as @AZCoder said. Also remember to take into consideration the expand thing... You'll need to change that accordingly as well. See _posW I think it is. As for the expand. It is based off the key you use in your controls, "Help". Feel free to change it! I might add an configurable option in next patch, whenever that is... EDIT: Fixed the issue with black image showing in title bar. Fix: color='#ffffff' I think the cause of it is because image has no alpha channel or is not setup correctly. @Tankbuster 1 1 Share this post Link to post Share on other sites
Tankbuster 1733 Posted June 24, 2018 Yes. You're a gent! :) Many thanks. 1 Share this post Link to post Share on other sites
HazJ 1288 Posted June 24, 2018 New bug. When using position right, the expand feature shrinks. Will patch soon and release update. Noticed and reported by @Tankbuster ! Share this post Link to post Share on other sites
HazJ 1288 Posted June 26, 2018 Update pushed to GitHub. Quote 0.3.1 Fixed expand/shrink positioning when using RIGHT config option (thanks to Tankbuster for reporting) Added config option for expand/shrink key Minor code tweaks @foxhound @Tankbuster - Sorry it is late and thanks again for reporting the bug. expandShrinkKey = "help"; // The key which is used to expand/shrink notifications - https://community.bistudio.com/wiki/DIK_KeyCodes (you can also use action key names: https://community.bistudio.com/wiki/Category:Key_Actions) Remember to update all files! 2 Share this post Link to post Share on other sites
Guest Posted June 26, 2018 The Armaholic mirror has been updated with the new version: Notification System v0.3.1 Share this post Link to post Share on other sites
HazJ 1288 Posted June 27, 2018 Quote 0.3.2 Fixed positioning issues Added config option for expand display time which will show the notification on screen for longer if expanded Code tweaks and fixes Remember to replace all files, including macros and everything else! Thanks again to @Tankbuster for bug report and feature request! @foxhound 1 1 Share this post Link to post Share on other sites
Guest Posted June 28, 2018 The Armaholic mirror has been updated with the new version: Notification System v0.3.2 Share this post Link to post Share on other sites
HazJ 1288 Posted July 5, 2018 Taking feature requests, etc.. Anyone? I want the next update to be a big one. Share this post Link to post Share on other sites