Jump to content

LOzan

Member
  • Content Count

    50
  • Joined

  • Last visited

  • Medals

Posts posted by LOzan


  1. Hello all,

    I got some fantastic help for my last dialog question so I figured I'd ask another that I have. I have a dialog with several Listboxes for assembling squads of units and I am using drag and drop to simplify the deal so there aren't tons of buttons for moving troops around. The problem is that I want to impose a limit on how big a squad can get to force the player to make compromises in their squad lineups. So far, I have no problem seeing how the canDrag = 1 line in the dialogs.hpp works but as far as I can tell it can't be disabled through a script. Is there any way to disable the dragging operation when the list has a certain number of units in it?

    Thanks,

    LOzan

    EDIT: Another possibility I just thought of but would still be outside my current GUI skill level, I could cap the list length by using the OnLBDrag and OnLBDrop event handlers and check the list's length; if it is already at maximum capacity, I could return the dragged entry to its original position. Actually I realized that this would have to be the way to do it because disabling the drag operation for the entire listbox would mean entries can't be dragged out of it to open up space. Any thoughts?


  2. That all makes sense to me, I've got it working on that level. Thanks again for all your help.

    On a somewhat related note, I'm kicking around the idea of adding a progress bar to the dialog. There are plenty of examples of the defines.hpp and dialogs.hpp entries, but not much on how to make it in the GUI Editor. Advice? Right now I'm thinking of dropping an RscText control with the desired position and dimensions of the progress bar and changing it in the header files, but do you know of any more direct methods?


  3. @Lecks,

    Are you talking about in the defines.hpp or in dialogs.hpp? The base classes are all called RscListbox, RscText, etc. in defines.hpp and #include - ed in the description.ext, but every control in dialogs.hpp has its own class name. Is that what you mean, or is there anything else to consider? This is all part of a campaign I have been and will be working on for a while.


  4. @Dr Death JM,

    Take your time, I'm taking a few months off of college for illness so I'll need something to do to keep myself busy. I'm actually working on a platoon manager (three squads and a "reserve" of inactive troops) but I imagine the core principles are much the same. I'm sure you know much more on this than I do so any help would be fantastic. If you'd be willing to help me out I can post up a screenshot of what I'm working with from the GUI Editor and have a few specific questions before too long.

    Thanks!


  5. Thank you so much! You all have no idea how helpful this is.

    A few questions, Fight9:

    1) What do I have to place in the defines.hpp to define the base class for RscListbox? I have a template from SpencerArma but is there anything specific I need?

    2) For lbAdd and lbSetData, which is displayed in the listbox?

    3) Can lbSetData be used to store an object such as a unit and its associated namespace, or only variables?

    I'd test these things myself but my apartment is in mid-move and my gaming rig is packed up. Regardless, this is all going a long way toward helping me figure out this rather nebulous side of ARMA editing. Thank you for your help.

    EDIT: I also don't quite get why we need the event handler and test_dialog_variable. I see it in the scripts line with the displayCtrl command, but I'm not getting why we need to go through that variable when, as it appears to my uneducated eye, we could just go directly for the listbox control. What's the reasoning behind the variable?


  6. What about things like idc, access, and all that kind of stuff in the defines.hpp and dialogs.hpp files? I understand that some of it will be relevant but nothing really explains what it does or how to choose it to the uninitiated. I also see references to the "listbox or combobox with id idc of topmost user dialog" and have no idea what that means, any pointers?


  7. Maybe you can help me then. I'm trying to make a squad/platoon management dialog where the player can select a unit, I'm thinking from a listbox, and then use different buttons to perform actions with that unit through a script. How do I take the player's selection from RscListbox and bring it into the script? There will be multiple lists and buttons in the dialog.


  8. Hello all,

    I'm working on a scenario involving several dialogs and I've hit the infamous poor documentation roadblock. I've found several EXCELLENT tutorials for the basics and simple dialogs but they tend to end around using RscButton to run a script and contain nothing further from there while advanced guides on the wiki are mostly HUD elements and necessary parameters for class definitions; there's nothing covering the middle.

    Specifically, I'm trying to create a dialog allowing the player to modify the compositions of several squads from a list of units; the squad compositions are stored in arrays and displayed in RscListbox and can be modified through the dialog from there. From the guides I've found, I know how to place the dialog controls and Ctrl-Shift-S to copy them into my dialogs.hpp but I have no idea what to do from there. Can anyone point me at some guides or tutorials that may be able to help me?


  9. **Potential spoilers depending on your personal sensitivity to such things, although I don't think this really counts**

    I've got a major problem in the first mission where, after getting in the truck with Petrovic, the car spontaneously explodes once driving away from the beach. This is making it literally impossible to advance the campaign, and using ENDMISSION doesn't make the next part available. I've tried it with and without mods and I still have the same problem. Advice?


  10. Dear members of the Arma community,

    I'm working on a (relatively ambitious, but isn't the journey the whole point?) scenario in which the player can recruit, train, and outfit units and assign them to squads through a Troop Manager dialog, sort of similar to the officers' dialog from DUWS. To store the characteristics of each unit, I am storing each set of characteristics in a variable generated when the unit is recruited, such as the unit's experience to date and the squad the unit is a part of.

    However, I've run into a problem: I have no idea how to identify the variable attached to each unit and ensure it is unique. This means that the entire plan falls apart: there is nothing to place in the arrays determining platoon organization, there is no way to store unit capabilities, etc. What I need is a system for generating each variable as the units are recruited, i.e. the first unit is associated with a variable like unit1, the next is unit2... automatically with each new unit.

    Does anybody know how to get past this hurdle, or know of an alternative method of achieving what I've set out to do? The idea is to create an EndWar-style sense of ownership of each unit and record persistent improvements a unit receives, making unit permadeath all the harsher... :cool:


  11. Hey there everyone,

    I'm planning out an open-world RPG sort of mission and something I would like to add are various groups all vying for control of Altis. The way I see it now, there can only be three different sides in participating in any given mission, not including civilians. My question is, is there any way to add new sides for a mission so there could be five or six or more groups all fighting each other on one map?

    Thanks!


  12. My googling has turned up nothing, so it's time to ask the forums.

    How do you set an AI unit's fire mode (semi, burst, auto, etc.) through scripting commands? I've got units using Toadie's AK Pack, but the default fire mode is automatic and I need them shooting single-fire. These are trained soldiers, after all.

    Anybody know the answer?

×