Jump to content
Sign in to follow this  
iceman77

GUI Editor & Dialogs

Recommended Posts

Just recently I've started to use the BI GUI EDITOR. I've created a dialog layout using the tool, I just don't know how to get it into the game. All's I get is CTD. This is my first attempt at a dialog & I realize that some things may be missing, so please be gentle :p. The dialog is a yes/no dialog for a SP campaign.

GUI Editor Format, for anyone interested in importing it into the GUI Tool to take a look (for w/e reason).

$[1.03,[[0,0,1,1],0.03125,0.05],[1600,"",[1,"YES",["0.408929 * safezoneW + safezoneX","0.534286 * safezoneH + safezoneY","0.0583333 * safezoneW","0.07 * safezoneH"],[-1,-1,-1,-1],[-1,-1,-1,-1],[-1,-1,-1,-1],""],[]],[1601,"",[1,"NO",["0.531548 * safezoneW + safezoneX","0.535238 * safezoneH + safezoneY","0.0583333 * safezoneW","0.07 * safezoneH"],[-1,-1,-1,-1],[-1,-1,-1,-1],[-1,-1,-1,-1],""],[]],[1800,"",[1,"Side Objective",["0.38988 * safezoneW + safezoneX","0.216189 * safezoneH + safezoneY","0.220833 * safezoneW","0.404762 * safezoneH"],[-1,-1,-1,-1],[-1,-1,-1,-1],[-1,-1,-1,-1],""],[]],[1200,"",[1,"#(argb,8,8,3)color(1,1,1,1)",["0.427381 * safezoneW + safezoneX","0.246667 * safezoneH + safezoneY","0.144643 * safezoneW","0.170952 * safezoneH"],[-1,-1,-1,-1],[-1,-1,-1,-1],[-1,-1,-1,-1],""],[]],[1000,"",[1,"Objective: Destroy The Shilka",["0.40238 * safezoneW + safezoneX","0.430476 * safezoneH + safezoneY","0.191666 * safezoneW","0.0280952 * safezoneH"],[-1,-1,-1,-1],[-1,-1,-1,-1],[-1,-1,-1,-1],""],[]],[1001,"",[1,"Do You Accept?",["0.401786 * safezoneW + safezoneX","0.497143 * safezoneH + safezoneY","0.105357 * safezoneW","0.0290477 * safezoneH"],[-1,-1,-1,-1],[-1,-1,-1,-1],[-1,-1,-1,-1],""],[]]]

Description.ext - This is what I'm not understanding. The CT,ST, ... Defines. Are these constants (what exactly is a constant?) names built into the game that must be used? Or are they just an example or just good naming practice? Also, I'm sure the file is missing some things. Any help is greatly appeciated.

//Copy and pasted from the wiki
// Control types 
#define CT_STATIC           0 
#define CT_BUTTON           1 
#define CT_EDIT             2 
#define CT_SLIDER           3 
#define CT_COMBO            4 
#define CT_LISTBOX          5 
#define CT_TOOLBOX          6 
#define CT_CHECKBOXES       7 
#define CT_PROGRESS         8 
#define CT_HTML             9 
#define CT_STATIC_SKEW      10 
#define CT_ACTIVETEXT       11 
#define CT_TREE             12 
#define CT_STRUCTURED_TEXT  13 
#define CT_CONTEXT_MENU     14 
#define CT_CONTROLS_GROUP   15 
#define CT_SHORTCUT_BUTTON  16 // Arma 2 - textured button  
#define CT_XKEYDESC         40 
#define CT_XBUTTON          41 
#define CT_XLISTBOX         42 
#define CT_XSLIDER          43 
#define CT_XCOMBO           44 
#define CT_ANIMATED_TEXTURE 45 
#define CT_OBJECT           80 
#define CT_OBJECT_ZOOM      81 
#define CT_OBJECT_CONTAINER 82 
#define CT_OBJECT_CONT_ANIM 83 
#define CT_LINEBREAK        98 
#define CT_USER             99 
#define CT_MAP              100 
#define CT_MAP_MAIN         101 
#define CT_List_N_Box       102 // Arma 2 - N columns list box   
// Static styles 
#define ST_POS            0x0F 
#define ST_HPOS           0x03 
#define ST_VPOS           0x0C 
#define ST_LEFT           0x00 
#define ST_RIGHT          0x01 
#define ST_CENTER         0x02 
#define ST_DOWN           0x04 
#define ST_UP             0x08 
#define ST_VCENTER        0x0c 
#define ST_TYPE           0xF0 
#define ST_SINGLE         0 
#define ST_MULTI          16 
#define ST_TITLE_BAR      32 
#define ST_PICTURE        48 
#define ST_FRAME          64 
#define ST_BACKGROUND     80 
#define ST_GROUP_BOX      96 
#define ST_GROUP_BOX2     112 
#define ST_HUD_BACKGROUND 128 
#define ST_TILE_PICTURE   144 
#define ST_WITH_RECT      160 
#define ST_LINE           176  
#define ST_SHADOW         0x100 
#define ST_NO_RECT        0x200 // this style works for CT_STATIC in conjunction with ST_MULTI 
#define ST_KEEP_ASPECT_RATIO  0x800 
#define ST_TITLE          ST_TITLE_BAR + ST_CENTER  
// Slider styles 
#define SL_DIR            0x400 
#define SL_VERT           0 
#define SL_HORZ           0x400  
#define SL_TEXTURES       0x10  
// Listbox styles 
#define LB_TEXTURES       0x10 
#define LB_MULTI          0x20 
#define FontM             "Zeppelin32"

//GUI EDITOR STUFF
class RscButton_1600: RscButton
{
   idc = 1600;
   text = "YES";
   x = 0.408929 * safezoneW + safezoneX;
   y = 0.534286 * safezoneH + safezoneY;
   w = 0.0583333 * safezoneW;
   h = 0.07 * safezoneH;
};
class RscButton_1601: RscButton
{
   idc = 1601;
   text = "NO";
   x = 0.531548 * safezoneW + safezoneX;
   y = 0.535238 * safezoneH + safezoneY;
   w = 0.0583333 * safezoneW;
   h = 0.07 * safezoneH;
};
class RscFrame_1800: RscFrame
{
   idc = 1800;
   text = "Side Objective";
   x = 0.38988 * safezoneW + safezoneX;
   y = 0.216189 * safezoneH + safezoneY;
   w = 0.220833 * safezoneW;
   h = 0.404762 * safezoneH;
};
class RscPicture_1200: RscPicture
{
   idc = 1200;
   text = "#(argb,8,8,3)color(1,1,1,1)";
   x = 0.427381 * safezoneW + safezoneX;
   y = 0.246667 * safezoneH + safezoneY;
   w = 0.144643 * safezoneW;
   h = 0.170952 * safezoneH;
};
class RscText_1000: RscText
{
   idc = 1000;
   text = "Objective: Destroy The Shilka";
   x = 0.40238 * safezoneW + safezoneX;
   y = 0.430476 * safezoneH + safezoneY;
   w = 0.191666 * safezoneW;
   h = 0.0280952 * safezoneH;
};
class RscText_1001: RscText
{
   idc = 1001;
   text = "Do You Accept?";
   x = 0.401786 * safezoneW + safezoneX;
   y = 0.497143 * safezoneH + safezoneY;
   w = 0.105357 * safezoneW;
   h = 0.0290477 * safezoneH;
};


---------- Post added at 15:55 ---------- Previous post was at 14:06 ----------

Okay, got my first dialog into the game!! :dancehead:

call

0 = createdialog "RscIceDialog"

Description.ext

///////////////////////////////////////////////////////////////////////////
/// Styles
///////////////////////////////////////////////////////////////////////////

// Control types
#define CT_STATIC           0
#define CT_BUTTON           1
#define CT_EDIT             2
#define CT_SLIDER           3
#define CT_COMBO            4
#define CT_LISTBOX          5
#define CT_TOOLBOX          6
#define CT_CHECKBOXES       7
#define CT_PROGRESS         8
#define CT_HTML             9
#define CT_STATIC_SKEW      10
#define CT_ACTIVETEXT       11
#define CT_TREE             12
#define CT_STRUCTURED_TEXT  13
#define CT_CONTEXT_MENU     14
#define CT_CONTROLS_GROUP   15
#define CT_SHORTCUTBUTTON   16
#define CT_XKEYDESC         40
#define CT_XBUTTON          41
#define CT_XLISTBOX         42
#define CT_XSLIDER          43
#define CT_XCOMBO           44
#define CT_ANIMATED_TEXTURE 45
#define CT_OBJECT           80
#define CT_OBJECT_ZOOM      81
#define CT_OBJECT_CONTAINER 82
#define CT_OBJECT_CONT_ANIM 83
#define CT_LINEBREAK        98
#define CT_USER             99
#define CT_MAP              100
#define CT_MAP_MAIN         101
#define CT_LISTNBOX         102

// Static styles
#define ST_POS            0x0F
#define ST_HPOS           0x03
#define ST_VPOS           0x0C
#define ST_LEFT           0x00
#define ST_RIGHT          0x01
#define ST_CENTER         0x02
#define ST_DOWN           0x04
#define ST_UP             0x08
#define ST_VCENTER        0x0C

#define ST_TYPE           0xF0
#define ST_SINGLE         0x00
#define ST_MULTI          0x10
#define ST_TITLE_BAR      0x20
#define ST_PICTURE        0x30
#define ST_FRAME          0x40
#define ST_BACKGROUND     0x50
#define ST_GROUP_BOX      0x60
#define ST_GROUP_BOX2     0x70
#define ST_HUD_BACKGROUND 0x80
#define ST_TILE_PICTURE   0x90
#define ST_WITH_RECT      0xA0
#define ST_LINE           0xB0

#define ST_SHADOW         0x100
#define ST_NO_RECT        0x200
#define ST_KEEP_ASPECT_RATIO  0x800

#define ST_TITLE          ST_TITLE_BAR + ST_CENTER

// Slider styles
#define SL_DIR            0x400
#define SL_VERT           0
#define SL_HORZ           0x400

#define SL_TEXTURES       0x10

// progress bar 
#define ST_VERTICAL       0x01
#define ST_HORIZONTAL     0

// Listbox styles
#define LB_TEXTURES       0x10
#define LB_MULTI          0x20

// Tree styles
#define TR_SHOWROOT       1
#define TR_AUTOCOLLAPSE   2

// MessageBox styles
#define MB_BUTTON_OK      1
#define MB_BUTTON_CANCEL  2
#define MB_BUTTON_USER    4


///////////////////////////////////////////////////////////////////////////
/// Base Classes
///////////////////////////////////////////////////////////////////////////
class RscText
{
   access = 0;
   type = 0;
   idc = -1;
   colorBackground[] = {0,0,0,0};
   colorText[] = {0.8784,0.8471,0.651,1};
   text = "";
   fixedWidth = 0;
   x = 0;
   y = 0;
   h = 0.037;
   w = 0.3;
   style = 0;
   shadow = 2;
   font = "Zeppelin32";
   SizeEx = 0.03921;
};

class RscPicture
{
   access = 0;
   type = 0;
   idc = -1;
   style = 48;
   colorBackground[] = {0,0,0,0};
   colorText[] = {1,1,1,1};
   font = "TahomaB";
   sizeEx = 0;
   lineSpacing = 0;
   text = "";
   fixedWidth = 0;
   shadow = 0;
   x = 0;
   y = 0;
   w = 0.2;
   h = 0.15;
};

class RscButton
{
   access = 0;
   type = 1;
   text = "";
   colorText[] = {0.8784,0.8471,0.651,1};
   colorDisabled[] = {0.4,0.4,0.4,1};
   colorBackground[] = {1,0.537,0,0.5};
   colorBackgroundDisabled[] = {0.95,0.95,0.95,1};
   colorBackgroundActive[] = {1,0.537,0,1};
   colorFocused[] = {1,0.537,0,1};
   colorShadow[] = {0.023529,0,0.0313725,1};
   colorBorder[] = {0.023529,0,0.0313725,1};
   soundEnter[] = {"\ca\ui\data\sound\onover",0.09,1};
   soundPush[] = {"\ca\ui\data\sound\new1",0,0};
   soundClick[] = {"\ca\ui\data\sound\onclick",0.07,1};
   soundEscape[] = {"\ca\ui\data\sound\onescape",0.09,1};
   style = 2;
   x = 0;
   y = 0;
   w = 0.095589;
   h = 0.039216;
   shadow = 2;
   font = "Zeppelin32";
   sizeEx = 0.03921;
   offsetX = 0.003;
   offsetY = 0.003;
   offsetPressedX = 0.002;
   offsetPressedY = 0.002;
   borderSize = 0;
};


class RscFrame
{
   type = 0;
   idc = -1;
   style = 64;
   shadow = 2;
   colorBackground[] = {0,0,0,0};
   colorText[] = {1,1,1,1};
   font = "Zeppelin32";
   sizeEx = 0.02;
   text = "";
};



class RscIceDialog
{
   idd = 3000;
   movingenable = 0;

   class Controls
   {
       class ICE_YesButton: RscButton
               {
                     idc = 1600;
                     text = "YES";
                     x = 0.408929 * safezoneW + safezoneX;
                     y = 0.534286 * safezoneH + safezoneY;
                     w = 0.0583333 * safezoneW;
                     h = 0.07 * safezoneH;
               };
               class ICE_NoButton: RscButton
               {
                    idc = 1601;
                    text = "NO";
                    x = 0.531548 * safezoneW + safezoneX;
                    y = 0.535238 * safezoneH + safezoneY;
                    w = 0.0583333 * safezoneW;
                    h = 0.07 * safezoneH;
               };
               class Ice_Frame: RscFrame
               {
                    idc = 1800;
                    text = "Side Objective";
                    x = 0.38988 * safezoneW + safezoneX;
                    y = 0.216189 * safezoneH + safezoneY;
                    w = 0.220833 * safezoneW;
                    h = 0.404762 * safezoneH;
               };
               class ICE_Picture: RscPicture
               {
                    idc = 1200;
                    text = "#(argb,8,8,3)color(1,1,1,1)";
                    x = 0.427381 * safezoneW + safezoneX;
                    y = 0.246667 * safezoneH + safezoneY;
                    w = 0.144643 * safezoneW;
                    h = 0.170952 * safezoneH;
               };
               class ICE_ObjDesc: RscText
               {
                    idc = 1000;
                    text = "Objective: Destroy The Shilka";
                    x = 0.40238 * safezoneW + safezoneX;
                    y = 0.430476 * safezoneH + safezoneY;
                    w = 0.191666 * safezoneW;
                    h = 0.0280952 * safezoneH;
               };
               class ICE_Choice: RscText
               {
                    idc = 1001;
                    text = "Do You Accept?";
                    x = 0.401786 * safezoneW + safezoneX;
                    y = 0.497143 * safezoneH + safezoneY;
                    w = 0.105357 * safezoneW;
                    h = 0.0290477 * safezoneH;
               };

   };
};

Edited by Iceman77

Share this post


Link to post
Share on other sites

Ive tried dialogs before a gave up after the CTD's, but now Ive seen your other post about dialog tutorials. was wondering what tutorial you used? or did you just mess with the BI GUI EDITOR

Share this post


Link to post
Share on other sites
Defines. Are these constants (what exactly is a constant?) names built into the game that must be used? Or are they just an example or just good naming practice?

Re: Defines:

They are just values you set yourself to assist with building dialogs.

If you wanted, you could set it to:

#define OMG_NOT_MOVING                                                                 0 
#define THIS_IS_A_BUTTON                                                                1 
#define edit_style_note_how_this_is_in_lower_case                               2 
#define woooooooooooooo_slider_MIXING_CAPS_wItH_nOn_capS           3 
#define check_OUT_ThiS_comBo                                                           4

instead of:

#define CT_STATIC                                                                              0 
#define CT_BUTTON                                                                             1 
#define CT_EDIT                                                                                  2 
#define CT_SLIDER                                                                               3 
#define CT_COMBO                                                                               4

and every time you needed to refer to a static dialog, you would then use OMG_NOT_MOVING to represent the value 2

The numbers on the right are important, not the define. You can use them without the defines. Defining values makes it easier down the line when you have to refer to it in other code. For a good lesson on how defines are better than typing "1" or "7" every time you build a dialog, check out the code in DayZ. There's some beautiful use of defines ( if that's your thing ;) )

Share this post


Link to post
Share on other sites

here's what I have so far. I used the Bi GUI Editor and the awesomely vague wiki. Unfortunately no tutorials. I'm still trying to find a good one.

http://img4.imageshack.us/img4/2729/icedialog.jpg (387 kB)

---------- Post added at 21:31 ---------- Previous post was at 21:29 ----------

Okay thanks das, that clarifies some things.

Share this post


Link to post
Share on other sites

I've got an annoying error when I create the dialog.No entry 'bin\config.bin/CfgFontFamilies.'. The dialog works fine , and shows the text. Though I'm not sure why it shows the error, or if it shows the correct font. What is wrong here? No addons what so ever are loaded.

Current Description.ext


///////////
//Styles//
///////////

// Control types
#define CT_STATIC           0
#define CT_BUTTON           1
#define CT_EDIT             2
#define CT_SLIDER           3
#define CT_COMBO            4
#define CT_LISTBOX          5
#define CT_TOOLBOX          6
#define CT_CHECKBOXES       7
#define CT_PROGRESS         8
#define CT_HTML             9
#define CT_STATIC_SKEW      10
#define CT_ACTIVETEXT       11
#define CT_TREE             12
#define CT_STRUCTURED_TEXT  13
#define CT_CONTEXT_MENU     14
#define CT_CONTROLS_GROUP   15
#define CT_SHORTCUTBUTTON   16
#define CT_XKEYDESC         40
#define CT_XBUTTON          41
#define CT_XLISTBOX         42
#define CT_XSLIDER          43
#define CT_XCOMBO           44
#define CT_ANIMATED_TEXTURE 45
#define CT_OBJECT           80
#define CT_OBJECT_ZOOM      81
#define CT_OBJECT_CONTAINER 82
#define CT_OBJECT_CONT_ANIM 83
#define CT_LINEBREAK        98
#define CT_USER             99
#define CT_MAP              100
#define CT_MAP_MAIN         101
#define CT_LISTNBOX         102

// Static styles
#define ST_POS            0x0F
#define ST_HPOS           0x03
#define ST_VPOS           0x0C
#define ST_LEFT           0x00
#define ST_RIGHT          0x01
#define ST_CENTER         0x02
#define ST_DOWN           0x04
#define ST_UP             0x08
#define ST_VCENTER        0x0C

#define ST_TYPE           0xF0
#define ST_SINGLE         0x00
#define ST_MULTI          0x10
#define ST_TITLE_BAR      0x20
#define ST_PICTURE        0x30
#define ST_FRAME          0x40
#define ST_BACKGROUND     0x50
#define ST_GROUP_BOX      0x60
#define ST_GROUP_BOX2     0x70
#define ST_HUD_BACKGROUND 0x80
#define ST_TILE_PICTURE   0x90
#define ST_WITH_RECT      0xA0
#define ST_LINE           0xB0

#define ST_SHADOW         0x100
#define ST_NO_RECT        0x200
#define ST_KEEP_ASPECT_RATIO  0x800

#define ST_TITLE          ST_TITLE_BAR + ST_CENTER

// Slider styles
#define SL_DIR            0x400
#define SL_VERT           0
#define SL_HORZ           0x400

#define SL_TEXTURES       0x10

// progress bar 
#define ST_VERTICAL       0x01
#define ST_HORIZONTAL     0

// Listbox styles
#define LB_TEXTURES       0x10
#define LB_MULTI          0x20

// Tree styles
#define TR_SHOWROOT       1
#define TR_AUTOCOLLAPSE   2

// MessageBox styles
#define MB_BUTTON_OK      1
#define MB_BUTTON_CANCEL  2
#define MB_BUTTON_USER    4


////////////////
//Base Classes//
////////////////
class RscText
{
   access = 0;
   type = CT_STATIC;
   linespacing = 1;
   idc = -1;
   colorBackground[] = {0,0,0,0};
   colorText[] = {0.8784,0.8471,0.651,1};
   text = "";
   fixedWidth = 0;
   x = 0;
   y = 0;
   h = 0.037;
   w = 0.3;
   style = ST_MULTI;
   shadow = 2;
   font = "Zeppelin32";
   SizeEx = 0.02300;
};
class RscStructuredText
{
   access = 0;
   type = 13;
   idc = -1;
   style = 0;
   colorText[] = {0.8784,0.8471,0.651,1};
   class Attributes
   {
       font = "Zeppelin32";
       color = "#e0d8a6";
       align = "Left";
       shadow = 1;
   };
   x = 0;
   y = 0;
   h = 0.035;
   w = 0.1;
   text = "";
   size = 0.01921;
   shadow = 2;
};
class RscPicture
{
   access = 0;
   type = 0;
   idc = -1;
   style = ST_PICTURE;
   colorBackground[] = {0,0,0,0};
   colorText[] = {1,1,1,1};
   font = "TahomaB";
   sizeEx = 0;
   lineSpacing = 0;
   text = "";
   fixedWidth = 0;
   shadow = 0;
   x = 0;
   y = 0;
   w = 0.2;
   h = 0.15;
};

class RscButton
{
   access = 0;
   type = 1;
   text = "";
   colorText[] = {0.8784,0.8471,0.651,1};
   colorDisabled[] = {0.4,0.4,0.4,0};
   colorBackground[] = {0.75,0.75,0.75,0.8};
   colorBackgroundDisabled[] = {0,0.0,0};
   colorBackgroundActive[] = {0.75,0.75,0.75,1};
   colorFocused[] = {0.75,0.75,0.75,.5};
   colorShadow[] = {0.023529,0,0.0313725,1};
   colorBorder[] = {0.023529,0,0.0313725,1};
   soundEnter[] = {"\ca\ui\data\sound\onover",0.09,1};
   soundPush[] = {"\ca\ui\data\sound\new1",0,0};
   soundClick[] = {"\ca\ui\data\sound\onclick",0.07,1};
   soundEscape[] = {"\ca\ui\data\sound\onescape",0.09,1};
   style = 2;
   x = 0;
   y = 0;
   w = 0.055589;
   h = 0.039216;
   shadow = 2;
   font = "Zeppelin32";
   sizeEx = 0.03921;
   offsetX = 0.003;
   offsetY = 0.003;
   offsetPressedX = 0.002;
   offsetPressedY = 0.002;
   borderSize = 0;
};


class RscFrame
{
   type = 0;
   idc = -1;
   style = 64;
   shadow = 2;
   colorBackground[] = {0,0,0,0};
   colorText[] = {1,1,1,1};
   font = "Zeppelin32";
   sizeEx = 0.03;
   text = "";
};
class BOX
{ 
   type = 0;
   idc = -1;
   style = ST_CENTER;
   shadow = 2;
   colorText[] = {1,1,1,1};
   font = "";
   sizeEx = 0.02;
   colorBackground[] = { 0.2,0.2,0.2, 0.9 }; 
   text = ""; 

};


class RscIceDialog
{
   idd = 3000;
   movingenable = true;

   class Controls
   {

              class Ice_BOX: BOX

               {
               idc = -1;
               text = "";
               x = 0.348572 * safezoneW + safezoneX;
           y = 0.209525 * safezoneH + safezoneY;
           w = 0.302857 * safezoneW;
           h = 0.588571 * safezoneH;
               };

              class ICE_FRAME: RscFrame

               {
           idc = 1800;
           text = "Secondary Ops";
           x = 0.353572 * safezoneW + safezoneX;
           y = 0.209525 * safezoneH + safezoneY;
           w = 0.292857 * safezoneW;
           h = 0.578571 * safezoneH;
               };

               class ICE_YESBUTTON: RscButton

               {
           idc = 1600;
           text = "Accept";
           x = 0.367856 * safezoneW + safezoneX;
           y = 0.724762 * safezoneH + safezoneY;
           w = 0.0595237 * safezoneW;
           h = 0.0490476 * safezoneH;
               action = "closeDialog 0;_nil=[]ExecVM ""objective.sqf""";
               };

              class ICE_NOBUTTON: RscButton

               {
           idc = 1601;
           text = "Decline";
           x = 0.441666 * safezoneW + safezoneX;
           y = 0.724762 * safezoneH + safezoneY;
           w = 0.0595237 * safezoneW;
           h = 0.0490476 * safezoneH;
               action = "closeDialog 0";
               };

             class ICE_PICTURE: RscPicture

               {
           idc = 1200;
           text = "shilka.paa";
           x = 0.37262 * safezoneW + safezoneX;
           y = 0.247619 * safezoneH + safezoneY;
           w = 0.254167 * safezoneW;
           h = 0.276667 * safezoneH;
               };

            class ICE_STEXT: RscStructuredText

               {
           idc = 1100;
           text = "Recon has spotted mobile AA, along with a small platoon of TKA in your area. They're nested up pretty high, on a hill, you'll Flank around and get behind the platoon to minimize casualties. If you can neutralize the shilka so we can send air support your way to deal with remaining hostiles. ";
           x = 0.372619 * safezoneW + safezoneX;
           y = 0.567619 * safezoneH + safezoneY;
           w = 0.254762 * safezoneW;
           h = 0.152858 * safezoneH;
               };

           class ICE_STEXT1: RscStructuredText

               {
           idc = 1101;
           text = "OverView:";
           x = 0.372619 * safezoneW + safezoneX;
           y = 0.554619 * safezoneH + safezoneY;
           w = 0.254762 * safezoneW;
           h = 0.152858 * safezoneH;
               };

           class ICE_TEXT: RscText
               {
           idc = 1000;
           text = "Objective: Neutralize The Shilka";
           x = 0.367999 * safezoneW + safezoneX;
           y = 0.531429 * safezoneH + safezoneY;
           w = 0.25 * safezoneW;
           h = 0.03 * safezoneH;
               };



   };




};


class RscIceDialog1
{
   idd = 3001;
   movingenable = true;

   class Controls
   {

              class Ice_BOX: BOX

               {
               idc = -1;
               text = "";
               x = 0.348572 * safezoneW + safezoneX;
           y = 0.209525 * safezoneH + safezoneY;
           w = 0.302857 * safezoneW;
           h = 0.588571 * safezoneH;
               };

              class ICE_FRAME: RscFrame

               {
           idc = 1800;
           text = "Secondary Ops";
           x = 0.353572 * safezoneW + safezoneX;
           y = 0.209525 * safezoneH + safezoneY;
           w = 0.292857 * safezoneW;
           h = 0.578571 * safezoneH;
               };

               class ICE_YESBUTTON: RscButton

               {
           idc = 1600;
           text = "Accept";
           x = 0.367856 * safezoneW + safezoneX;
           y = 0.724762 * safezoneH + safezoneY;
           w = 0.0595237 * safezoneW;
           h = 0.0490476 * safezoneH;
               action = "closeDialog 0;_nil=[]ExecVM ""objective2.sqf""";
               };

              class ICE_NOBUTTON: RscButton

               {
           idc = 1601;
           text = "Decline";
           x = 0.441666 * safezoneW + safezoneX;
           y = 0.724762 * safezoneH + safezoneY;
           w = 0.0595237 * safezoneW;
           h = 0.0490476 * safezoneH;
               action = "closeDialog 0";
               };

             class ICE_PICTURE: RscPicture

               {
           idc = 1200;
           text = "antenna.paa";
           x = 0.37262 * safezoneW + safezoneX;
           y = 0.247619 * safezoneH + safezoneY;
           w = 0.254167 * safezoneW;
           h = 0.276667 * safezoneH;
               };

            class ICE_STEXT: RscStructuredText

               {
           idc = 1100;
           text = "There's a radio antena in your area. Destroy the tower to cut out TKA communications in the area";
           x = 0.372619 * safezoneW + safezoneX;
           y = 0.567619 * safezoneH + safezoneY;
           w = 0.254762 * safezoneW;
           h = 0.152858 * safezoneH;
               };

           class ICE_STEXT1: RscStructuredText

               {
           idc = 1101;
           text = "OverView:";
           x = 0.372619 * safezoneW + safezoneX;
           y = 0.554619 * safezoneH + safezoneY;
           w = 0.254762 * safezoneW;
           h = 0.152858 * safezoneH;
               };

           class ICE_TEXT: RscText
               {
           idc = 1000;
           text = "Objective: Destroy The Antenna";
           x = 0.367999 * safezoneW + safezoneX;
           y = 0.531429 * safezoneH + safezoneY;
           w = 0.25 * safezoneW;
           h = 0.03 * safezoneH;
               };



   };




};

rpt

=====================================================================
== D:\Bohemia Interactive\arma2oa.exe
== "D:\Bohemia Interactive\arma2oa.exe" -nosplash -showscripterrors -mod=@GUI_EDITOR
=====================================================================
Exe timestamp: 2012/10/25 20:55:55
Current time:  2013/01/11 10:49:09

Version 1.62.95248
Warning: looped for animation: ca\anims\characters\data\anim\sdr\mov\erc\wlk\non\non\amovpercmwlksnonwnondf.rtm differs (looped now 0)! MoveName: amovpercmstpsnonwnondnon_amovpercmstpsraswpstdnon
Warning: looped for animation: ca\anims\characters\data\anim\sdr\mov\erc\wlk\non\non\amovpercmwlksnonwnondf.rtm differs (looped now 1)! MoveName: amovpercmrunsnonwbindf_rfl
Warning Message: No entry 'bin\config.bin/CfgFontFamilies.'.
Warning Message: No entry '.fonts'.
Warning Message: Size: '/' not an array

Edited by Iceman77

Share this post


Link to post
Share on other sites

not sure if this is of any use to you, password system i made - same principle

Edited by Mikie boy

Share this post


Link to post
Share on other sites

Thankyou Mikie.

---------- Post added at 12:50 ---------- Previous post was at 11:46 ----------

Okay the fontFamilies error has been fixed. Apparently, you can't set a font to an empty string. I noticed it was empty on the "background" or BOX class I had created. Figured I could leave it empty, as i wasn't using the box to create text. In short, font = "" is a no go.So I had to still define a font for BOX. I couldn't even take font out completely because that even threw up another error.

Edited by Iceman77

Share this post


Link to post
Share on other sites

yep just confirmed that - but its because you do use box, so im guessing thats why you had the error -

class Ice_BOX: BOX

by the way nice concept - shout me if you need any help with it :)

may find this useful (or not) i edited your scripts into the separate gui scripts - just easier to read and narrow down errors.

Edited by Mikie boy

Share this post


Link to post
Share on other sites

How come some styles don't have to be defined?

class RscFrame
{
   type = CT_STATIC;
   idc = -1;
   [color=#ff0000]style = 64;[/color]
   shadow = 2;
   colorBackground[] = {1,1,1,1};
   colorText[] = {1,1,1,0.9};
   font = "Bitstream";
   sizeEx = 0.03;
   text = "";
};

Regarding my dialog, style 64 is defined nowhere. See below if needed.

// Control types
#define CT_STATIC           0
#define CT_BUTTON           1
#define CT_EDIT             2
#define CT_SLIDER           3
#define CT_COMBO            4
#define CT_LISTBOX          5
#define CT_TOOLBOX          6
#define CT_CHECKBOXES       7
#define CT_PROGRESS         8
#define CT_HTML             9
#define CT_STATIC_SKEW      10
#define CT_ACTIVETEXT       11
#define CT_TREE             12
#define CT_STRUCTURED_TEXT  13
#define CT_CONTEXT_MENU     14
#define CT_CONTROLS_GROUP   15
#define CT_SHORTCUTBUTTON   16
#define CT_XKEYDESC         40
#define CT_XBUTTON          41
#define CT_XLISTBOX         42
#define CT_XSLIDER          43
#define CT_XCOMBO           44
#define CT_ANIMATED_TEXTURE 45
#define CT_OBJECT           80
#define CT_OBJECT_ZOOM      81
#define CT_OBJECT_CONTAINER 82
#define CT_OBJECT_CONT_ANIM 83
#define CT_LINEBREAK        98
#define CT_USER             99
#define CT_MAP              100
#define CT_MAP_MAIN         101
#define CT_LISTNBOX         102

// Static styles
#define ST_POS            0x0F
#define ST_HPOS           0x03
#define ST_VPOS           0x0C
#define ST_LEFT           0x00
#define ST_RIGHT          0x01
#define ST_CENTER         0x02
#define ST_DOWN           0x04
#define ST_UP             0x08
#define ST_VCENTER        0x0C
#define ST_GROUP_BOX       96
#define ST_GROUP_BOX2      112
#define ST_ROUNDED_CORNER  ST_GROUP_BOX + ST_CENTER
#define ST_ROUNDED_CORNER2 ST_GROUP_BOX2 + ST_CENTER

#define ST_TYPE           0xF0
#define ST_SINGLE         0x00
#define ST_MULTI          0x10
#define ST_TITLE_BAR      0x20
#define ST_PICTURE        0x30
#define ST_FRAME          0x40
#define ST_BACKGROUND     0x50
#define ST_GROUP_BOX      0x60
#define ST_GROUP_BOX2     0x70
#define ST_HUD_BACKGROUND 0x80
#define ST_TILE_PICTURE   0x90
#define ST_WITH_RECT      0xA0
#define ST_LINE           0xB0

#define ST_SHADOW         0x100
#define ST_NO_RECT        0x200
#define ST_KEEP_ASPECT_RATIO  0x800

#define ST_TITLE          ST_TITLE_BAR + ST_CENTER

// Slider styles
#define SL_DIR            0x400
#define SL_VERT           0
#define SL_HORZ           0x400

#define SL_TEXTURES       0x10

// progress bar 
#define ST_VERTICAL       0x01
#define ST_HORIZONTAL     0

// Listbox styles
#define LB_TEXTURES       0x10
#define LB_MULTI          0x20

// Tree styles
#define TR_SHOWROOT       1
#define TR_AUTOCOLLAPSE   2

// MessageBox styles
#define MB_BUTTON_OK      1
#define MB_BUTTON_CANCEL  2
#define MB_BUTTON_USER    4

Share this post


Link to post
Share on other sites

I see. I'm not sure I understand why though. Why not just use the more commonly known, number of 64? Anyhow, those were some base defines from the wiki, so I didn't bother to understand all of the 0x# stuff. So now I'll look into this hexadecimal business :j: << f**k that.

Thanks for helping me understand I appreciate that.

Edited by Iceman77

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  

×