Login

russian armor

Random spawning from the production buildings

27 Sep 2016, 18:12 PM
#1
avatar of TheWise

Posts: 31

Actually, topic.

I'd like to implement the random spawning (pretty much like Partisans used to do) spawning of squads from the production buildings. For instance:

- German HMG teams randomly spawned with MG-34 or MG-42;

- one of two variants of US Riflemen Squads - with M1 Garand and M1 Carbine - are randomly spawned from the base building;

And so effing on :-))

Does anyone know, how to do this in the current Mod Tools?
27 Sep 2016, 19:16 PM
#2
avatar of Planet Smasher
Senior Modmaker Badge

Posts: 632 | Subs: 1

Partisans were called in with an ability, using a reinforcement action. There were several types of Partisan squads with different loadouts, and one of them would been spawned randomly. That functionality isn't available for individual squad members, though.

What you can do:
- Make a new soldier entity.
- Leave hardpoint 1 empty.
- In action_apply_ext, add a random_action.
- As subactions, use several copies of add_weapon with different weapons.

That would not be possible with team weapons like HMGs, though. No idea how to do that!
27 Sep 2016, 19:26 PM
#3
avatar of SneakEye
Senior Modmaker Badge

Posts: 813 | Subs: 5

The US Lieutenant, Captain and Major are abilities when you buy them for the first time. You can make such an ability and use the random_action to choose between different squads.
27 Sep 2016, 20:01 PM
#4
avatar of TheWise

Posts: 31

Partisans were called in with an ability, using a reinforcement action. There were several types of Partisan squads with different loadouts, and one of them would been spawned randomly. That functionality isn't available for individual squad members, though.

What you can do:
- Make a new soldier entity.
- Leave hardpoint 1 empty.
- In action_apply_ext, add a random_action.
- As subactions, use several copies of add_weapon with different weapons.

That would not be possible with team weapons like HMGs, though. No idea how to do that!


I, actually, don't need it for individual squad members. What I need is: for instance, I've got two types of the Riflemen squads: one armed mostly with M! Garand rifles, while another has mostly M! Carbines. And I want them to be spawned randomly, 50/50 or 60/40.

The US Lieutenant, Captain and Major are abilities when you buy them for the first time. You can make such an ability and use the random_action to choose between different squads.


TBA, these are upgrades, not abilities. But kinda yes, they do contain the reinforcement_action.
28 Sep 2016, 16:38 PM
#5
avatar of Contrivance

Posts: 165 | Subs: 2

Problem is that the spawner extension on a building points to specific squads, not a randomized container of squads.

Agameanx on the old CoH1 modding forums at relicnews came up with a solution back then that was heavy on SCAR, wherein you would place dummy squads into the spawner, and the SCAR would detect them being bought and replace them with one or more different squads.

Aside from that complex solution, an ability on the building that randomly spawns your squads is the only way.
1 user is browsing this thread: 1 guest

Ladders Top 10

  • #
    Steam Alias
    W
    L
    %
    Streak
Data provided by Relic Relic Entertainment

Replay highlight

VS
  • U.S. Forces flag cblanco ★
  • The British Forces flag 보드카 중대
  • Oberkommando West flag VonManteuffel
  • Ostheer flag Heartless Jäger
uploaded by XXxxHeartlessxxXX

Board Info

498 users are online: 498 guests
0 post in the last 24h
30 posts in the last week
142 posts in the last month
Registered members: 44954
Welcome our newest member, Mtbgbans
Most online: 2043 users on 29 Oct 2023, 01:04 AM