LordGolias / antistasi

Antistasi improved, a mod for the game Arma 3.
BSD 3-Clause "New" or "Revised" License
31 stars 18 forks source link

Supply lines to locations #114

Open Warhammer47 opened 6 years ago

Warhammer47 commented 6 years ago

Objective: Implement supply lines (ammo/fuel/repair) between bases/airfields and other locations.

Idea: Once a day a supply truck or heli drop deploys support for the other locations (resources/outpost/factory/powerplant). If this supply reaches the location it rearms, repairs/heals and refuel all units in that location. If destroyed before reaching it's destination, that location maintains the same levels of ammo, health and fuel.

The idea is to provide a more realistic and rich environment.

LordGolias commented 6 years ago

supply lines for the FIA or for the AAF? xD

I like the idea.

Warhammer47 commented 6 years ago

Both :D but the player receives info when their supply line is leaving the HQ

SomethingSimpl commented 5 years ago

Maybe let the resistance steal the resupply as a second option to destroying it? I think supplies for player should be triggered by players and delivered by players as well. Also incorporating this as one of the "intel" pieces of information you can get from interrogating / capturing bases: a time when the convoy is leaving and where is it going from and to (ambushes!)

LordGolias commented 5 years ago

I like the idea.

How do we simulate a supply line without actually running it (running trucks around in the map cost CPU). E.g. we can simulate it via a hidden marker that runs from location A to B, and only instantiate it when needed.

We do a similar things for AAF patrols, but we only move them between locations that are close to FIA locations.

SomethingSimpl commented 5 years ago

I would actually imagine the closest one would be the QRF force that comes from a base to a location where the player just assaulted.

Large portions of that code could actually be reused as it functions in the same way: Spawns in the truck full of infantry at the nearest base, gives it a waypoint to the location where player just attacked. This would obviously need to be changed to:

1. Pick a random location that will receive the supplies 2. Select the closest base to make the delivery - This is already in the QRF script, it spawns from the closest place to the attacked location. 3. Create a group of convoy vehicles/troops - We would probably have to set up different templates/compositions. 4. Spawn it in once it enters the radius around the player, give it a waypoint to drive to the location, despawn when it leaves it but continue to simulate all the way to the location. 5. Despawn once it reaches the location

Not sure from memory if the QRF script is currently instantiated though. I believe its just spawned in and in drives so the virtualization would need to be implemented from scratch.