Home » MODDING HQ 1.13 » Flugente's Magika Workshop » New feature: move equipment via assignment
New feature: move equipment via assignment[message #323880]
|
Sun, 11 August 2013 18:40
|
|
Flugente |
|
Messages:3507
Registered:April 2009 Location: Germany |
|
|
Move equipment via assignment
While it feels good to conquer liberate a huge town and then posess tons of loot, I am no stranger to the dread feeling of 'How the fuck do I move all this to my HQ?'. Especially with 'Drop All' turned on, the game produces lots of items, and moving them from city sector to city sector takes a long time: equip merc, move to other sector, drop all gear, send back, repeat... this becomes tedious (I have stopped some invasions because I didn't want to deal with that). :heavy: Militia equipment eases that somewhat, but the main problem remains.
For this reason, I created a new assignment: move items from A to B.
As we dont want to send Laura and Meltdown to pick up stuff in the airport and move it to the mine manually, we assign them to MOVEITEM. We then select the sector from which they should move stuff to their current sector. Only sectors in the town we currently are in can be selected, and only if they are free of enemies.
On Meltdown's portrait, the sector she is taking stuff from is shown, and the symbol, well, shows that she's moving stuff.
Perhaps we don't want to move abolutely everything. In this case, we want to leave weapons, ammo an armour for 4 militia. We can therefore mark items via TAB + CTRL + Leftclick. Marked items will not be moved by your mercs. You can toggle this display with the new button on top of the inventory.
This marking also works even if none of your mercs are in this sector.
At 8.00, the assignment was evaluated. The two mercs moved quite a lot of stuff, but not all (it was too much for one hour), and none of the marked items.
Your 'movers' will move up to
30 * number of movers * 6 / distance to sector
items, or up to
40 * number of movers * 6 / distance to sector
kilos of equipment. Depending on the weight they moved, they can also train strength and health a bit.
You might notice that moving stuff manually might be a bit more effective (ingame :whistle: ), as you can move a bit more with the right LBE gear. That is intentional. If you really want to move thousands upon thousands of items per hand, then by all means, do so. You will be more effective, but lose valuable time in real life. Which you could spend creating more loot in virtual life. Or whatever it is you do. This feature merely aims to save time for the player (moving the entire sector inventory instantly would have been a lot easier, but would break balance/immersion/traditionalists temper).
The current equipment, LBE gear, fatigue or health of the mercs doing the moving has no influence on this.
There are no options for this feature. If you don't want to use it, just don't.
This does not break savegame compatibility. However, you WILL need a GameDir revision >= 1723. The game will crash otherwise, as it won't find the new button and icon images.
This was committed to the trunk in r6280 and GameDir r1723.
Edit: r6282 greatly increases calculation speed on huge sectors (> 5k items).
Edit2: r6288 fixes inaccessible items and CTDs in certain circumstances.
[Updated on: Sun, 18 August 2013 21:27] by Moderator Report message to a moderator
|
|
|
|
|
Re: New feature: move equipment via assignment[message #323887]
|
Sun, 11 August 2013 20:02
|
|
Flugente |
|
Messages:3507
Registered:April 2009 Location: Germany |
|
|
Good question. No. Equipped items, LBE gear, fatigue, weight, and health all have no influence on this. The only thing influencing how much stuff gets moved is distance to the sector. Items are moved in the order they are stored internally, which is FIFO.
And, to be very precise: As we stop moving stuff only once max number of items or max weigth has been exceeded, it is possible to move a bit more... if we already moved 179 items and can move 180, we would still move a stack of 16 armours, as only then we are above our 180. Simply because I have no intention to split stacks.
Report message to a moderator
|
|
|
|
|
|
Re: New feature: move equipment via assignment[message #323891]
|
Sun, 11 August 2013 20:40
|
|
deknegt |
|
Messages:140
Registered:June 2007 Location: Doetinchem, Netherlands |
|
|
Flugente, it must be asked...
Are you a goverment created super computer capable of conquering the world and/or making awesome mods without breaking a sweat?
Because you are a fucking machine, this stuff is awesome. I ask for it 2 days ago and you create it like it's nothing, I wish I had your talents man. The day you stop modding for 1.13 we will all lose one of the best modders around.
Awesome, finally my MERC noobs have more to do than sit on their asses whilst my main team goes around shooting people in the face.
[Updated on: Sun, 11 August 2013 20:42] by Moderator Report message to a moderator
|
Sergeant
|
|
|
|
|
|
Re: New feature: move equipment via assignment[message #323903]
|
Sun, 11 August 2013 23:21
|
|
Sam Hotte |
|
Messages:1965
Registered:March 2009 Location: Middle of Germany |
|
|
Gorro der Gr
[Updated on: Sun, 11 August 2013 23:22] by Moderator Report message to a moderator
|
Sergeant Major
|
|
|
Re: New feature: move equipment via assignment[message #323906]
|
Sun, 11 August 2013 23:26
|
|
Flugente |
|
Messages:3507
Registered:April 2009 Location: Germany |
|
|
With the proper equipment (TIMS and other LBE with a lot of bags, or even MOLLE) manually equipping empty mercs is more efficient. In a way, this also costs money, as you still need mercs to do the assignment.
I'll probably do an update soon, I'm not satisfied with speed in sectors with > 6K items.
As the question came up on IRC: This also does not work for underground sectors. The reason is that coding the menu entries for the assignment took me at least 8 times longer than the movement stuff itself. The UI is a horrible place. It would be hard to make it less useable. Some stuff is so awful that I think it was done on purpose. Like having 2 BOOLEANS called fShowAssignmentMenu and fShownAssignmentMenu in the same functions. Underground sectors would need another popup. The movement part is trivial.
Edit: Update in r6282 increases speed of calculation, reducing the 'hiccup' on full hour if the sector you move stuff to has many items.
[Updated on: Mon, 12 August 2013 00:33] by Moderator Report message to a moderator
|
|
|
|
|
|
|
|
|
|
|
Re: New feature: move equipment via assignment[message #324015]
|
Thu, 15 August 2013 22:31
|
|
Flugente |
|
Messages:3507
Registered:April 2009 Location: Germany |
|
|
It is easily possible to expand this to any sector (underground is a bit more tricky). Theoretically, moving stuff from Meduna swamps to Drassen is as easy to do as moving inside Drassen - the code is in place, this would be a change of ~3lines.
However, I will not allow that and not even offer the option for this. This is simply there to save time when moving equipment, while still using roughly the same resources (=manpower) that manual moving of items would. For this reason, I won't allow item movement if the 'real' action it replaces it would take longer than one hour (the assignment update time), which movement outside town would. Especially as outside town you could get into fights etc., which this cannot simulate. Also, this would mean that the assignment also 'blocks' the heli or a car, which will be quite tricky with assignments.
Item movement can only happen if the merc used for it is conscious and had enough time for that assignment (just like all other assignemnt). If his sector and the sector he takes stuff from are yours and peaceful the moment the clock hits :00, items will be moved. Otherwise not.
For simplicity reasons, I do not check sectors in between. So you could move Drassen airport items to Drassen mine even if the Drassen middle sector is still ocupied by the enemy. Otherwise I would have to code full-blwon topology checks (in case some makes a 20-tile city just to make my life hard ).
Report message to a moderator
|
|
|
|
|
|
|
|
Re: New feature: move equipment via assignment[message #324240]
|
Thu, 22 August 2013 20:03
|
|
Uriens |
|
Messages:345
Registered:July 2006 |
|
|
FlugenteIt is easily possible to expand this to any sector (underground is a bit more tricky). Theoretically, moving stuff from Meduna swamps to Drassen is as easy to do as moving inside Drassen - the code is in place, this would be a change of ~3lines.
However, I will not allow that and not even offer the option for this. This is simply there to save time when moving equipment, while still using roughly the same resources (=manpower) that manual moving of items would. For this reason, I won't allow item movement if the 'real' action it replaces it would take longer than one hour (the assignment update time), which movement outside town would. Especially as outside town you could get into fights etc., which this cannot simulate. Also, this would mean that the assignment also 'blocks' the heli or a car, which will be quite tricky with assignments.
Item movement can only happen if the merc used for it is conscious and had enough time for that assignment (just like all other assignemnt). If his sector and the sector he takes stuff from are yours and peaceful the moment the clock hits :00, items will be moved. Otherwise not.
For simplicity reasons, I do not check sectors in between. So you could move Drassen airport items to Drassen mine even if the Drassen middle sector is still ocupied by the enemy. Otherwise I would have to code full-blwon topology checks (in case some makes a 20-tile city just to make my life hard ).
I just had an idea. While this feature is great and will help reduce micromanagement it would be so much better if it would indeed include moving items in between towns. This usually comes handy when you move your base from Drassen to Cambria or when you take some of the corner towns and want to ferry the loot back to base. I have a few ideas (or brainfarts, I'll leave decision to you :crazy:) that you may find handy:
1) Abstracting item movement and calling it for example - 'organizing supply convoy' where you assign a merc(s) to that task, charges you a sum of money (probably configurable by distance, total weight and ini settings) and takes some time (probably again set by distance. It would work only in between 2 cities you completely control.
2) Expanding on this, you may add a xml with sector list that have to be clear of enemy troops in order for convoy to be available. For example, some of the roadblocks in between Alma and Drassen should be clear before the convoy task becomes available for those 2 cities.
3) This one could be best IMHO; using facilities for town to town item transfer. Have a post office, or small airfield facilities to ferry stuff between them. If you say, have control of post office in Cambria and post office in Drassen, you could ferry stuff in between them. It would of course require mercs to be assigned to both facilities and it would cost money and take time. This way a modder or player can fully control what locations would be connected and how much it would require to operate them. Even set some hazards for them to make things even more risky, like all facilities can have.
Report message to a moderator
|
Master Sergeant
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Re: New feature: move equipment via assignment[message #340958 is a reply to message #335775]
|
Mon, 11 May 2015 20:27
|
|
Flugente |
|
Messages:3507
Registered:April 2009 Location: Germany |
|
|
As I will very soon sit upon the combined gear of 383 dead soldiers and 63 dead militiamen in Cambria SAM (epic battle!!!11elf!!!) and want that mountain of gear in my HQ without taking time off, I am altering this feature a bit:
As of r7857, this assignment now also works on sectors adjacent to town sectors. Travel time calculations would be somewhat tricky for reasons I won't list here, so we assume traveling to a sector next of a town takes 2 hours, this extra time is taken into account. As a result, only very few items will be moved per hour.
This allows us to, say, park Squad Vulture with this assignment in Cambria SAM for a day and have them move stuff silently without that constant clicking, (un-)packing and movement ordering.
I know now that it could never work between us, as much as we wanted to, it could never be! Not because you're a rabbit, but because you're black.
If you want, you can donate to me. This will not affect how and what I code, and I will not code specific features in return. I will be thankful though.Report message to a moderator
|
|
|
|
|
Re: New feature: move equipment via assignment[message #340964 is a reply to message #340961]
|
Tue, 12 May 2015 13:49
|
|
Flugente |
|
Messages:3507
Registered:April 2009 Location: Germany |
|
|
What happens if you edit the 1.13 xml to include A1 and B1 and temporarily remove all other instances of that xml?
Chitzena SAM is not adjacent, so no. Cambria SAM is adjacent, so yes.
Calculating travel time for mercs that aren't in a GROUP is not possible atm, and coding it would either require code violations or recoding separate travel time calculations. Which is both a lot of work for a feature that has the goal of actually simplifying things. Due to that, I just assume travel takes 2 hours. Whether there is a road, grounbdbarrier or warp rift between the two sectors is simply irrelevant.
I know now that it could never work between us, as much as we wanted to, it could never be! Not because you're a rabbit, but because you're black.
If you want, you can donate to me. This will not affect how and what I code, and I will not code specific features in return. I will be thankful though.Report message to a moderator
|
|
|
|
Goto Forum:
Current Time: Mon Dec 02 15:31:46 GMT+2 2024
Total time taken to generate the page: 0.03941 seconds
|