Jump to content
Sign in to follow this  
columdrum

Advanced editor modules

Recommended Posts

Firt of all a bit of background:

After years of been part of this comunity i have always noticed that there is a bit gap between some mission makers and scripters/addon makers. Obviously the perfect situation would be that someone that edits a mision knows about everything else in the game(scripting/config/addons) so they can do anything they want and do it the best way it can be done.

To fill this gap i already posted some suggestion that i would love to see implemented on arma3, that would allow script/addon makers make their work abvaliable to mission makers on a more user friendly way: http://forums.bistudio.com/showthread.php?125819-ArmA-3-Community-wishes-amp-ideas-NO-DISCUSSION&p=2054977#post2054977

But some weeks ago i just thought to myself: "why would i need to wait for arma3 if i can do it myself, it may be possible to do on arma2", so i started this just as a proof of concept and before i noticed it i had it working, so thats why i am creating this post ;). Maybe its not everything i wanted but its something ;)

Info about the addon itself:

"Advanced modules" its just a small editor GUI modification that adds the ability to easy configure extra parameters on editor modules. As most of the modules that are out there weren't thought with this addon in mind, there isn't many configurable options on most of the released modules, still this addon its able to configure all the default BIS modules that are documenten con the wiki.

But the true potential of this addon would be modules created with this configuration method in mind.

Right now the features are:

-For mission makers:

Easy configure all the parameters of BIS modules without needing to constantly search on the wiki.

Also added options to 2 ACE modules( air refueling and EASA)

In the future i will add any other addon/module that its documented, or addon makers could do themselves ;) (UNS 2.5 will include at least one of those :) )

-For addon makers:

You can easy create mision editor modules with configurable parameters.

Also for advanced addon makers, you can create your own custom configuration dialog(i have planned to add some API funtions to make it easier on the future)

Small video from the mission editor point of view:

edit: seems that the audio didnt make it. If i have time i will create another one

For addon makers here a small example of the config of a configurable parameteres for and addon(spoiler fucks up indentation :P but its to long):

class CfgPatches

{

class colum_advanced_modules

{

units[] = {};

weapons[] = {};

requiredVersion = 1.59;

requiredAddons[] = {"colum_advanced_modules"}; //require advanced modules so you keep the class inheritance intact

};

};

class Colum_AdvancedModule // Main class for modules config

{

class Test_advanced_Logic // this must be the same classname as your logic

{

dialogName="default"; // Use default dialog(auto generates on execution depending on the parameters), change to your custom dialog name to use your custom dialog

diagParamsNum=7; // Total number of parameters

DialogInitScript=""; // Path to the script that would be executed after advanced dialog options creation, only apicable if you are using a custom dialog

class Params

{

class Param_1 // Important first parameter its 1 not 0

{

ParamVarName="Name_text"; // Variable name that would be set on your logic on init field: this setvariable ["VARIABLENAME",value]

ParamTextName="Write your Name"; // Name shown on the config dialog

ParamType="Text"; //param type, avaliable types are: TEXT,NUMBER,ARRAY,OBJVAR,SLIDER,COMBOBOX . Most selfexplanatory, keep reading for furder explanations

DefaultValue=""; //Default value for the parameter, must be the same type of the parameter( for example this one that its a text, must be a string)

ParamInfo="Extra parameter info"; //Extra info that would be displayed can be an extructured text

};

class Param_2 // second param

{

ParamVarName="Last_Name_text"; // Should be unique and a valid variable name, if not variables would override

ParamTextName="Last Name";

ParamType="Text";

DefaultValue="";

ParamInfo="Extra parameter info";

DoNotSetDefault=1; // If set to 1 the value would be only writen on the init if its not the default value. If not, the value its always added to the init line even if its the default one.

};

class Param_3

{

ParamVarName="number_test";

ParamTextName="Write a number";

ParamType="Number"; // As it name implies, the parameter must be a number, if the user tries to imput anything else the imput resets to 0

DefaultValue="0"; //Must be a number

ParamInfo="Extra parameter info";

DoNotSetDefault=0;

};

class Param_4

{

ParamVarName="Slider_text";

ParamTextName="test Slider";

ParamType="Slider"; // The user can see an slider that allows to chose a value between configured max and min values

MinValue=1; // minimum slider value

MaxValue=50; // Maximum slider value

RoundValue=1; // If set to 1 it forces to integer values. If set to 0 the slider would return float values.

DefaultValue=5;

ParamInfo="Extra parameter info";

DoNotSetDefault=1; //can be used on any kid of parameter if not set, default value its 0

};

class Param_5

{

ParamVarName="Prueba array";

ParamTextName="Prueba array";

ParamInfo="otro mas a lo mejor es sin las putas barras hehehe asi si q va, mejor pongo un texto largo del <br>copon a ver que cojones pasa con esto y si sale el puto salnto de linea";

ParamType="array"; //Array type. The value that the user input would be check for array type, if isn't an array default value would be set

DefaultValue[]={1,2}; //must be an array, note that in config the config entry name has a [] at the end and {} are used instead of [] for the values

};

class Param_6

{

ParamVarName="Name_text2";

ParamTextName="prueba mierda";

ParamType="OBjvAR"; //Object /variable, this type its thoug for variablenames or any other type of value, tecnically it could be used to imput any of the previous param types, but without the spefici checks that they have

DefaultValue="fracaso";

};

class Param_7

{

ParamVarName="combo_Test1";

ParamTextName="test combo";

ParamType="comboBox"; //Allows the user to select a value from a list

ParamInfo="Extra parameter info";

NumOptions=4; // total number of avaliable options

DefaultIndex=0; //default option, note that its the number on the list, not te value itself

class Option_1

{

Text="texto 1"; // text displayed must be a string

Value="value 1"; // string as its a Text value type

ValueType="Text"; // Text type. Posible values are all the previous ones escept slider.

};

class Option_2

{

Text="texto 2";

Value=2;

ValueType="NUMBER"; //Number type

};

class Option_3

{

Text="texto 3";

Value[]={3,3,3}; //Note again that it must be an array

ValueType="ARRAY"; //array type

};

class Option_4

{

Text="opcion fail";

Value="trikitri";

ValueType="objvar"; // object/variable type

};

};

};

};

};

To access to the values, on your init script just use :

_this getvariable "variablename"; //Note _this must be the logic object, and variablename its the configured "ParamVarName" of each parameter

I will expand the documentation a bit when i have some free time

Download link:

http://www.mediafire.com/?8z9qubhdd6a5ccm

http://www.armaholic.com/page.php?id=17429

No signatures included since it's only needed for editing, but i may include them on the next release(well if people really like the idea obviously :P).

Edited by columdrum

Share this post


Link to post
Share on other sites

Simply awesome bro! I haven't had a chance to try yet but would love to see advanced options for secops, acm and wf :D

Thanks for doing this, would be awesome if bis looked at this as a viable editor enhancement.

Share this post


Link to post
Share on other sites

And life just got a little easier !

Thanks columdrum.

Share this post


Link to post
Share on other sites

A really appreciated piece of work, thank you..

:)

Share this post


Link to post
Share on other sites

How it should have been from the start; this is a life-saver for mission-making. Thank you!

EDIT: There appears to be some issues with different UI sizes. Not a big deal, can easily be rectified by choosing a smaller UI size, but thought I'd bring it to your attention.

Edited by Laqueesha

Share this post


Link to post
Share on other sites
How it should have been from the start; this is a life-saver for mission-making. Thank you!

EDIT: There appears to be some issues with different UI sizes. Not a big deal, can easily be rectified by choosing a smaller UI size, but thought I'd bring it to your attention.

Thx will look into that for the next update (probably next month), i will try to make it look nicer on bigger UI sizes. I think that i may forgotten to use UI safe zones somewhere :S

Simply awesome bro! I haven't had a chance to try yet but would love to see advanced options for secops, acm and wf :D

Thanks for doing this, would be awesome if bis looked at this as a viable editor enhancement.

Im afraid that ACM and specops and others that havent options enabled with this addon, are configured by functions or init lines on the players and things like that, and that would need major and specific changes, that wont be usefull for future modules would be just for those modules. The main goal of this addon was never add support to the BIS modules or any other existing modules, main goal have been always just offer addon makers a easy way to offer mission makers configuration for their modules in a user friendly way.

Said that... i may consider implementing that on future versions, but will be never the main goal ;)

Share this post


Link to post
Share on other sites

gj.

tnx alot.

thats what im expected 4om BIS last 10 yrs - improving BUILT-in editing stuff[ease of use&caps], not anything else :/

Share this post


Link to post
Share on other sites

Hi Columdrum. I find this module very useful indeed, for the reasons you already mentioned :)

Sometimes though I like to put some statements in place of values, so for example instead of putting >400< in the town construction size field, I might decide to put >ceil(random 100) + 300<, to give some randomisation. There are two problems with this:

1. I cannot put such statements in a field.

2. When I manually adjust the displayed module statement with the above example, it works fine, But as soon as I need to adjust any other field using this addon, it removes the statement and places a number.

So as a feature request can you either:

Allow for statements in fields or

NOT have the addon replace statements with numbers on re-edit.

Thanks :)

Share this post


Link to post
Share on other sites
Hi Columdrum. I find this module very useful indeed, for the reasons you already mentioned :)

Sometimes though I like to put some statements in place of values, so for example instead of putting >400< in the town construction size field, I might decide to put >ceil(random 100) + 300<, to give some randomisation. There are two problems with this:

1. I cannot put such statements in a field.

2. When I manually adjust the displayed module statement with the above example, it works fine, But as soon as I need to adjust any other field using this addon, it removes the statement and places a number.

So as a feature request can you either:

Allow for statements in fields or

NOT have the addon replace statements with numbers on re-edit.

Thanks :)

Never thought about that one. The problem there its that i forced that field to be a number, so if you write anything else it turns to 0, same goes for the array input fields, is just an way to avoid people to enter wrong values. But its true that you could always enter expresions instead of numbers, so i will take that on account when i release the addon update

Share this post


Link to post
Share on other sites

Small update, i added some more parameters that where missing and also removed the limitation of some fields, now you can enter statements not limited to numbers like before as DMarkwick suggested.

Download link:

http://www.mediafire.com/?8z9qubhdd6a5ccm

Still need some fixes so it can be used on all dialog sizes, i hope i can fix that on the future.

Share this post


Link to post
Share on other sites

this is great, how can something like this fly under the radar :P this needs to get more attention

Share this post


Link to post
Share on other sites
this is great, how can something like this fly under the radar :P this needs to get more attention

Your right, its a great little addon. I use it alot, its quick and easy, towns can be built in seconds to the size you want.:)

Share this post


Link to post
Share on other sites

This is awesome. Though the only module I see an advanced option for is the town construction set. Are there any others? I'd love to see ambient combat and secop modules included.

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  

×