Hydric
Member-
Content Count
4 -
Joined
-
Last visited
-
Medals
Community Reputation
1 NeutralAbout Hydric
-
Rank
Rookie
-
Hydric started following Set task state through add action with "Create Task" module and How to make a custom text HUD
-
Question So, I was wondering if it was possible to potentially make a custom text Heads Up Display that looks kind of like the Antistasi HUD. The Antistasi HUD includes things like Covertness, Balance of money, Following, etc... I was wondering how I would be able to do something like this with minimal effort involved. Possible Solutions I've tried using the titleText in order to display a variable from my "Variables.sqf" file, however; this isn't a good idea because I use the titleText for dialogue between the player and AI characters. <Variables.sqf> balance = 1200; <buildingtutorial.sqf> params ["_object", "_caller", "_actionId", "_args"]; _jeep = _args param [0]; _transporttruck = _args param [1]; ["TASK1", "SUCCEEDED"] call BIS_fnc_taskSetState; titleText[format["<t color='#00FF00'>Commander Petros</t>: Welcome to the new camp, newbie."], "PLAIN DOWN", -1, true, true]; sleep 5; titleText[format["<t color='#00FF00'>Commander Petros</t>: Go over to that workbench over there and build the vehicle depot, then come back to me and I'll purchase some vehicles for it."], "PLAIN DOWN", -1, true, true]; titleFadeOut 7; _object removeAction _actionId; _object addAction ["Buy Vehicles", "buyVehicle.sqf", [_jeep, _transporttruck]]; exit; I haven't actually found anything useful regarding a custom GUI or HUD in ArmA 3 quite yet so this would be really helpful. Thanks in advance for potential solution/help in the comments.
-
Set task state through add action with "Create Task" module
Hydric replied to Hydric's topic in ARMA 3 - MISSION EDITING & SCRIPTING
yeah, it took me a little bit more to understand this little bit of code, mainly because I had never seem something like it before (at the beginning and stuffs). But I've been doing my research and this has helped a LOT while I worked on my mission. I'm gonna try using external SQF files instead of using the trigger "OnActivation" field from now on, mainly due to the fact that I feel I can do a lot more with SQF files instead of using the on board activation system. Anyways, have a great day and thanks for the wonderful help! (EDIT) For future reference, how would I do the code highlighting for the SQF you put in there? -
Set task state through add action with "Create Task" module
Hydric replied to Hydric's topic in ARMA 3 - MISSION EDITING & SCRIPTING
hey! Thanks for the help, this solution helped. I'll be sure to keep this in mind for later. Have a good one! -
Set task state through add action with "Create Task" module
Hydric posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
Overview I was trying to create an ArmA 3 OPTRE mission, where the player needs to trace data from a communications relay/tower and get the locations of two additional objectives they need to complete in order to extract and complete the mission. The mission is single-player (so far) but will have multiplayer integration in the future. I have the addAction set up to remove itself once the player interacts and executes the code inside the addAction as well, not only that but I also have markers, and a diary record get created when the player interacts with the addAction command. Problem I have a task created whenever the player clears out the communications relay of hostiles (Eridanus Rebel Insurrectionists), the task ID and variable name are both TASK2 (because it's the second task in the scenario) and it's position is also synchronized with the communications tower. The problem that I've been having is an "Expected Task, Got Object" Error from the code in the addAction. The code is listed below. communications_relay addAction ["Learn Objective Locations", {player createDiaryRecord ["Diary", ["Objective Locations", "Intel Recovery: <br />Convoy Assault:]]; "intel_recovery" setMarkerType "hd_objective"; communications_relay removeAction 0; TASK2 setTaskState "Succeeded"}]; Post Now, I'm pretty new to ArmA 3 scripting, so I didn't particularly feel like putting all of the code inside of an external SQF file, mainly because of the fact I didn't wanna deal with passing all of the variables to the script file and then doing it that way. Also, if it's not too much to ask for, I ask for you to please explain what the code solution you send does so I can understand it better. Thanks in advance for the help!