Maaaaark 3 Report post Posted October 2, 2015 Can anyone please point me in the right direction on how to do this? I would like hourly messages that tell people to read the rules etc. Thanks! Share this post Link to post Share on other sites
fat 13 Report post Posted October 2, 2015 Using the scheduler function of BEC is probably the easiest and most common way to do it. Share this post Link to post Share on other sites
ShootingBlanks 48 Report post Posted October 7, 2015 (edited) /****************************************************************** Advertise.sqf ver 1.0 (from a wasteland release, sorry, cant recall which one) Waits 3 minutes for server to be running for first message then writes a message on players screen every X seconds (_delay) List each message on a separate line [your message], and end with a comma EXCEPT the last message, no comma for last element of an array. Include this file in your mission folder and in your init.sqf add this line if (!isserver) then {[]execvm "advertise.sqf";}; *******************************************************************/ _delay = 300;//5 minutes sleep 180; // 3 minutes delay until first message _messageArray = [ ["The fasted way to contact an admin is to join our teamspeak and ask for help."], ["Join up on our website and take part in the discussions"], ["Dont be a victim, Shoot First and SURVIVE!"], ["The server restarts every 6 hours"] ]; while {true} do { sleep _delay; _msg = _messageArray select (random (count _messageArray - 1)); titleText [_msg, "PLAIN DOWN", 3]; }; Edited October 7, 2015 by ShootingBlanks 2 Share this post Link to post Share on other sites
ka0s 457 Report post Posted October 7, 2015 /****************************************************************** Advertise.sqf ver 1.0 (from a wasteland release, sorry, cant recall which one) Waits 3 minutes for server to be running for first message then writes a message on players screen every X seconds (_delay) List each message on a separate line [your message], and end with a comma EXCEPT the last message, no comma for last element of an array. Include this file in your mission folder and in your init.sqf add this line if (!isserver) then {[]execvm "advertise.sqf";}; *******************************************************************/ _delay = 300;//5 minutes sleep 180; // 3 minutes delay until first message _messageArray = [ ["The fasted way to contact an admin is to join our teamspeak and ask for help."], ["Join up on our website and take part in the discussions"], ["Dont be a victim, Shoot First and SURVIVE!"], ["The server restarts every 6 hours"] ]; while {true} do { sleep _delay; _msg = _messageArray select (random (count _messageArray - 1)); titleText [_msg, "PLAIN DOWN", 3]; }; Can you post a screenshot of how it looks? Would be much appreciated! Share this post Link to post Share on other sites
ShootingBlanks 48 Report post Posted October 7, 2015 (edited) i dont know why you wanted a screenshot. it looks the same as the written code just trolling some. i am at work. when i get home i will install this script on a server and take a few shots with different display configurations. Edited October 7, 2015 by ShootingBlanks 4 Share this post Link to post Share on other sites
ShootingBlanks 48 Report post Posted October 7, 2015 Okay, I tested the script by going into the editor and creating a radio alpha trigger and pasting the code into the activation box. the text is centered but a bit small,So I changed the text to bis_fnc_dynamictext and tested that outThis is probably the best because you can control the color, font, size, location, fadein .... [ "<t size='.65' color='1cee09' align='left' font='PuristaSemibold'>'This is an example message'<br /></t>", -1,-1,4,1,0,789 ] spawn BIS_fnc_dynamicText;And then there is the HINT boxhint "this is an example message"; Share this post Link to post Share on other sites
EDG 47 Report post Posted October 7, 2015 Now how would you goes about adding this to Exile? Share this post Link to post Share on other sites
ShootingBlanks 48 Report post Posted October 7, 2015 (edited) this bit of text was in the top of the code I postedInclude this file in your mission folder and in your init.sqf add this line if (!isserver) then {[]execvm "advertise.sqf";};So create a file named advertise.sqf, paste the code into the file, and in the initplayerlocal.sqf add execvm "advertise.sqf". Or something like this at your preference. Edited October 7, 2015 by ShootingBlanks Share this post Link to post Share on other sites
Tuna 36 Report post Posted October 7, 2015 where would we add this in [ "<t size='.65' color='1cee09' align='left' font='PuristaSemibold'>'This is an example message'<br /></t>", -1,-1,4,1,0,789 ] spawn BIS_fnc_dynamicText; Share this post Link to post Share on other sites
ShootingBlanks 48 Report post Posted October 7, 2015 in the sqf code i pasted. that is the line to display the text which would replace the titletext line.the code randomizes the messages and puts it into a local variable named _msgso to use the dynami text replacetitleText [_msg, "PLAIN DOWN", 3];with [ "<t size='.65' color='1cee09' align='left' font='PuristaSemibold'>_msg<br /></t>", -1,-1,4,1,0,789 ] spawn BIS_fnc_dynamicText screen positioning is something i have never fully grasped, what i do is use the dialog editor to create an object and then just use those coordinates in my text display. later (at work again) i can make a full file with options for different placements easily selectable. i will include a jpg showing the placements. 1 Share this post Link to post Share on other sites