Jump to content
Sign in to follow this  
thetrooper

Menu option

Recommended Posts

Hi all. Not sure how to do this. After a mission complete I'm thinking to get a menu option to chose a task? Used to get that through the series, but don't know if you can in arma 3, imagine so?

Voice asks what you want to do, menu option, select which ever and you get open up an new task which whatever task.

Obviously use of voices. Easiest way to explain in text.

Task complete

Hq Sidechat what you gonna do now?

- menu opens

#Kill something

#save something

Choose #kill something

Player sidechat want to kill something

Hq sidchat roger go kill something

Tsk opens go kill something

Thats only way i can explain it. Can anyone help?

Voices and description.ext i got that stuff, just not how to do the menu choice

Share this post


Link to post
Share on other sites

I would try using the new Strategic Map. Its really a cool feature for these kind of things. The modules only work for teleporting, I believe. But you can use it through scripting and make the different icons do what ever you want.

See this post about using the map: http://forums.bistudio.com/showthread.php?161340-Strategic-Map-Module&p=2553692&viewfull=1#post2553692

Where the red text is, you would put the codes and commands to create and assign different tasks. This can also include teleporting and changing times and running whole other scripts that create missions. Its really a cool feature not nearly used enough in missions.

I saw this one mission where the map gave you different options on how to execute the same task. For example, one was a night time scuba infiltration, the next was an aerial insertion with extra forces, and the third was a "create you own" style where you could do what ever you wanted to complete the task.

Share this post


Link to post
Share on other sites

If you don't want to use a map but instead want to do a "one-or-another" choice menu take a look at dialogs and controls

It may be a bit complex and the documentation isn't great but it is quite easy to create something nice once you have a hang on it.

Share this post


Link to post
Share on other sites

It's probably be a bit too much to aproach this problem with the relatively complex conversation system (kbTell, FSMs, etc.) but if you want to try your luck you might find some topics here around the forums explaining that stuff in detail.

For a quick and dirty yet working way just use addAction to create multiple actions the player can choose of. I always do simple decisions like in your example with addAction. But you can of course also create a fancy dialog. ;)

Share this post


Link to post
Share on other sites

Thanks for your answers. I'm thinking in this scenario I have the player is going to want something fairly quick and snappy. There's only two choices to make after a one line message (until I get brave and mess it up) so it's probably worth going the "Conversation system" rout. I'll be back on this one, don't worry lol

Share this post


Link to post
Share on other sites

Well, you can try your luck with the convo system but I would only use it if I had to implement a complex conversation with several multiple choice parts etc.

Easiest way is in my opinion still the addAction. Here's a cutout from one of my missions.

// some sidechat blah blah

_actYes = player addAction ["'Yes, we can go on.'", {IP_CHOICE= true;}];
_actNo = player addAction ["'Negative, we have to pull back.'", {IP_CHOICE= false;}];
hint "Use the action menu to decide whether you want to go on or quit. It's your choice!";

waitUntil{!isNil "IP_CHOICE"};

player removeAction _actYes;
player removeAction _actNo;

if (IP_CHOICE) then {
// Sidechat blah
} else {
       // Other Sidechat blah
};

Good luck anyway!

Share this post


Link to post
Share on other sites

Ok, now after having a look. I'm going for simple solution. Classic radio call.

In the campaign a speech bubble acts as a bit of a hint before talking. Any way I can fix that to this(not sure if possible) ?

titleText ["What you going to do now?", "PLAIN"];
sleep 1;

hint ">>OPEN RADIO menu 0-0<<";
hill106=createTrigger["EmptyDetector",getPos player]; _trg setTriggerArea[5,5,0,false];
hill106 setTriggerActivation["ALPHA","PRESENT",true];
hill106 setTriggerText "I Want to Attack hill 106";
hill106 setTriggerStatements["this", "execVM 'hill106.sqf'", " "];

hill98=createTrigger["EmptyDetector",getPos player]; _trg setTriggerArea[5,5,0,false];
hill98 setTriggerActivation["BRAVO","PRESENT",true];
hill98 setTriggerText "I Want to Assault hill 98";
hill98 setTriggerStatements["this", "execVM 'hill98.sqf'", " "]; 

However, now you got me thinking though IndeedPete. Hmm,

What about if there's three choices? true and false wouldn't work then I guess?

Edited by TheTrooper

Share this post


Link to post
Share on other sites

Simply use numbers?

// some sidechat blah blah

_actYes = player addAction ["'Yes, we can go on.'", {IP_CHOICE = 0;}];
_actNo = player addAction ["'Negative, we have to pull back.'", {IP_CHOICE = 1;}];
_actIDK = player addAction ["'I don't know.'", {IP_CHOICE = 2;}];
hint "Use the action menu to decide whether you want to go on or quit. It's your choice!";

waitUntil{!isNil "IP_CHOICE"};

removeAllActions player;

switch (IP_Choice) do {
case 0: {// Sidechat blah};
case 1: {// other Sidechat blah};
case 2: {// third Sidechat blah};
};

Share this post


Link to post
Share on other sites
It's probably be a bit too much to aproach this problem with the relatively complex conversation system (kbTell, FSMs, etc.) but if you want to try your luck you might find some topics here around the forums explaining that stuff in detail.

For a quick and dirty yet working way just use addAction to create multiple actions the player can choose of. I always do simple decisions like in your example with addAction. But you can of course also create a fancy dialog. ;)

I have a similar problem, however i'd like to know what i can do besides addaction. I've made an FSM but seem to have trouble with kbTell and kbAddtopic functions. Should added topics appear in something like the action menu, or a speech menu like in arma 2? If anyone has made a script in Arma 3 using FSMs and kbaddtopic to give the player multiple-choice dialogue i'd really appreciate some guidance.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×