Proposal: Always-shown "Purchased Units" panel


  • Moderators

    @Alexei-Svitkine said in Proposal: Always-shown "Purchased Units" panel:

    There's also additional open questions:

    • Does it work well on all maps, especially with a lot of units? I welcome suggestions on which to test - or when we get a prerelease build out with this change, people can try it out too.
    • How does it work with large unit icons? Something to also try out once we have a prerelease build with it.

    I already suggested this, did you try it?

    @Cernel said in Proposal: Always-shown "Purchased Units" panel:

    p.s.: You can use this map (not available in download list) to test with a unit much bigger than the usual 48x48 pixels.
    https://github.com/triplea-maps/conquest_of_the_world

    It shouldn't be an issue here, as you don't purchase, but place right when you get the units (I assume you know Risk), but it may give you an idea, or should I say I've no idea how this feature would display, as all the space is already filled with only 1 move.

    20191015_02.png

    Anyways, I suppose you can test by changing (modding) the game as to not destroying unplaced units, then just skipping placement, if I'm guessing correctly that by "purchased units" you actually mean "unplaced units".



  • @Cernel said in Proposal: Always-shown "Purchased Units" panel:

    @Alexei-Svitkine Any games I tried that is available in download list. The situation is just as I pictured.
    20191015_01.png
    (I purchased 3 infantries and 3 armours)

    That's very strange. It's not supposed to be empty. What version of Java are you using?

    After enabling beta features, did you restart triplea?


  • Moderators

    @Alexei-Svitkine said in Proposal: Always-shown "Purchased Units" panel:

    What version of Java are you using?

    It says 11.0.4.

    After enabling beta features, did you restart triplea?

    I had it already enabled.



  • Hmm, very strange. I wonder if it's some platform-specific difference.

    Has anyone else had a chance to test it? Does it work for other people on Windows?

    EDIT: Hmm, I had a chance to try it on Windows and am seeing the same thing. Ugh.


  • Moderators

    @Alexei-Svitkine Yeah, I immediately guessed it was because I'm on Windows and you are on Macintosh, but, then, I've been a little dubious since nobody else said anything or anyways confirmed the bug.



  • Actually, looks like I can reproduce the issue on Mac if I change the look and feel to Subspace, which is what TripleA uses on Windows. So I should be able to debug.



  • I figured out what's wrong and will be sending a fix. Stay tuned - I'll post an update when we have a prerelease build with the fix.



  • @Cernel said in Proposal: Always-shown "Purchased Units" panel:

    @Alexei-Svitkine said in Proposal: Always-shown "Purchased Units" panel:

    • How does it work with large unit icons? Something to also try out once we have a prerelease build with it.

    I already suggested this, did you try it?

    I didn't before, but I did now. The panel doesn't show up because as you say, there's no purchase. (I did get an exception with the UnitScroller on it, but this seems unrelated to my change.)


  • Moderators

    @Alexei-Svitkine Well, anyways what I said is that I believe it should not be called "Purchased Units". Like you could have a game that gives you whatever units based on something, also already having some at start game, that you'll place at some point. The matter is not that the units may be purchased, but that you have them still unplaced.



  • @Cernel said in Proposal: Always-shown "Purchased Units" panel:

    @Alexei-Svitkine Well, anyways what I said is that I believe it should not be called "Purchased Units". Like you could have a game that gives you whatever units based on something, also already having some at start game, that you'll place at some point. The matter is not that the units may be purchased, but that you have them still unplaced.

    Sorry I didn't reply to this. I agree that naming it something different like "Units to Place" would be better - and China on WW2v3 is a good example of this. Feedback noted and will keep it in mind when I iterate on the UI.

    Still hoping to get the first UI out for people to try before I go about changing it.


  • Moderators

    @Alexei-Svitkine I think it can be just "To Place", as not like you can place something else but units (besides, also PUs (the main "resource" in the game) are nominally "units", as the meaning is "Production Units").

    Alternatives to "To Place" may be "Unplaced", "Under Production", "Mobilizing", "Held" ("heldUnits" is the xml way of calling units in a player's inventory).



  • Okay, so I think we have a prerelease out with the fix here:
    https://github.com/triplea-game/triplea/releases/tag/2.0.16244

    Please try it out, thanks! Sorry for the fact the previous one did not work right on Windows.


  • Moderators

    @Alexei-Svitkine Works for me, but this additional feature rates as an additional problem, in my tracker.

    I guess here it is being generally assumed that TripleA maps are all maps with 48x48 pixel units. If so, I hope that is a wrong assumption.

    Not a map available anywhere, but an example of what you may get with 64x64 pixels units images on Full HD:

    20191018_01.png

    This image confirms my expectations, based on what I already explained.

    Here, I cannot even acces the actual actions tab, meaning I'm unable to even undo the single move I made, unless I expand the right bar, of course (actually, I can also do it if I go in Settings/Testing and set Show Beta Features = False, then save and reload the game).

    I suggest deleting this feature (if not moving it out of the "Actions" tab). Otherwise, at least assuring the actual actions space is never cut so much as being impossible to undo any or all of them (rather cutting the purchased units space).


  • Admin

    Scrollbars look like a must. IMO we'd always probably want to see at least 4 of the purchased units, more than that behind scrollbars perhaps (largely need to account for cases where as @Cernel has tested there are a pretty decent number of different units pruchased. Some maps could get more extreme and we'd need to handle it)

    IIRC the unit scroller was a bit debatable for taking up too much space. Unit scroller is move related, so it makes sense. We could try to cut down the space it takes, though I'm not sure if there is an obvious solution.

    The fly-out tab I still think is the ultimate solution, until we get there moving the purchase panel is probably 2nd rate but at least gets the feature in. The 'resources' tab could make sense to have it. We could help the navigation issue between tabs by ensuring there are hotkeys to the tabs and that the hotkey is displayed on hover. Potentially and in addition to that, we could explore if there is a way to get tabs to show in rows on Mac so that they are all always visible.


  • Moderators

    It is not even that, actually. I have this "Purchased Units" thing everywhere, even if I go to the Notes tab!

    Is this a bug, and this feature is actually supposed to stay only on the actions tab?

    Anyways, movements are made based on a number of information. It is not feasible putting all such information right into the Actions tab, and I don't see why the units you have in your inventory (or, as some boardgames call it, your "mobilization zone") should have the privilege.


  • Moderators

    @LaFayette said in Proposal: Always-shown "Purchased Units" panel:

    (largely need to account for cases where as @Cernel has tested there are a pretty decent number of different units pruchased. Some maps could get more extreme and we'd need to handle it)

    That (unreleased) game of mine is not extreme, about this matter: there, I bought 11 units types, only 1 unit type more than what you can buy in "World War II Classic" and less than what you can buy in "World War II Revised"!

    And 64x64 pixels units is only 33% wider and higher than the usual 48x48 pixels units.



  • Perhaps we should resize the units shown in this panel to be smaller, regardless of their source image size. Or only do that if there happens to be enough of them to actually take up a significant amount of space.

    I actually think it looks quite good on standard WW2 maps where the typical purchase won't be more than say 6 unique types at a time. So perhaps by default we still show the current unit size - but resize them when they get too large/too many.

    Can folks try it on a normal WW2 map (e.g. play as you would normally) and tell me how it feels for them there? As I said, in my opinion, it is actually working quite nice there - but would love to hear from others. I'd like to make sure we build something that works well for such a case, and not just for edge cases.

    (The other option is to still have the split pane as discussed earlier in the thread or have it tabbed with the unit scroller. I'm not saying we shouldn't pursue those either - just trying to reason about the sizing first.)

    I also have a change out to address the suggestion that it should be shown for non-local players too. When testing it myself, I was surprised how useful that is. I'll post a link to a prerelease build with that once it's available.



  • @Cernel

    By the way, in the existing code for this, it's already asking for the non-"large" version of the icons. Whereas, for example, the standard unit placement panel asks for the "large" versions. I assume for your map (and maybe most other maps), you only have one size. So you may be able to just fix this for your map by having both "large" and non-"large" icons. For reference, the "large" icons should have an extra "_large" suffix in the filename.



  • For reference, this is how it looks like for Global 40 2nd edition if the US buys nothing in the first turn and then uses its 104 PUs to buy as many different unit types as possible on the 2nd turn (13 distinct units, of which it is only allowed to place 9). And this is on my laptop screen.

    So even with such a ridiculous scenario on a WW2 map, it still looks OK:

    Screen Shot 2019-10-18 at 8.52.06 AM.jpg


  • Moderators Admin

    Cool feature, but it seems as though a solution is definitely needed as space is at a premium. Not being able to see the move history is a bigger detractor than being able to see the purchased units is a benefit. Only being able to see one or perhaps 2 moves would make playing sheer anguish. It can already be hard to isolate moves you made in order to undo them. I shudder to think what the experience would be like if you could only see 2 moves in the window.

    I think something along the lines of a floating window would be ideal that opens and expands when you hover your cursor over an icon which is added to the game screen when you have purchased units...

    New Purchased Unit window.png

    I just pieced this together quickly as an example.


Log in to reply