Jump to content

Is it possible to make two players take control over a single army?

Recommended Posts


I was wondering about if it is possible to allow two players take control over a single army and battle against an enemy duo in C&C 3. Like in StarCraft 2's Archon Mode. May anyone help me about this?


Edited by Luvaskot

Share this post

Link to post

In the strict sense of it, probably not.

Each map has a PLAYER count to it. So if you want 2 people playing you will need a PLAYER_1 and PLAYER_2 on that map. That means they control a army each.

what you could do , and this is from the top of my head:

Make 3 players on that map.

Player 1 and 2 control a dummy/fake army. The cpu controls a 3th army (the real army). these 3 sides are allied.

Through some lua and map scripting you could possibly let the following happen:

human players own dummy/invisible barracks , warfactories etc. Whenever they build from their queu's they build dummy units that broadcast the actual build orders to the cpu side and it builds the actual units, then again through scripting transfers control to the human player side.

That way you could possibly mimic 2 human players sharing a single side?

Like i said from the top of my head, there might be better ways, but strictly speaking you cant have 2 PLAYERS share 1 army by default iirc.

  • Downvote 1

Share this post

Link to post

Yes it's possible in many variants I can think of (mostly lua heavy solutions):

1. Variant - AI Co-Control: This let's an hard ai co control the human players faction side by side. Change MakeAllSkirmishSidesAIControlled = No to Yes in skirmishaidata.ini. You can also make it toggleable e.g. via a playerpower button and with help of lua so that the ai only becomes active if the player wishes to. That's something I had running in the past and it worked great but not for custom factions unfortunately (crashes) that's why I needed to disable it in MetaMod. You could also make an ability to select certain buildings/units during game that the ai then won't control anymore if you wish (via lua)

2. Variant - One basebuilder and one Unit controller: Units get transfered immediately to the other player on creation via lua. A "victory condition dummy" and custom victory condition lua scipts ensure correct win/lose conditions as one player doesn't own any buildings. The sides can even be made switchable and if both players are humans you can even implement an accept/deny button.

3. Variant - see MetaMod diplomacy options menu: "temporary switch sides", "temporary give control to another player", "temporary take control of another player" (with accept/deny button in case of human player). All these options are toggleable. New units created will still belong to the player who created them but that could also be changed if needed.

4. Variant - not recommended: A lua co routine checks every x ms if a player has selected a unit or building of the allied player. If so the unit gets immidiately transfered and tranfereed back after unselect so that it's not noticeable. Downside: Short selection keys (q,w...) need to be replaced by an additonal selection menu. But these menu entries can have keys assigned themselves. Group assignment won't work here except if you also make menu entries that trigger lua selection scripts for that.

5. Everything inbetween - mixture of thes variants.

1 hour ago, Ravendark said:

Each map has a PLAYER count to it. So if you want 2 people playing you will need a PLAYER_1 and PLAYER_2 on that map. That means they control a army each.

Just as an interesting sidennote: We can use 4 more players/teams that are always available regardless of the playercount:

Lua Team Names:


I use the CreepsTeam (always enemy to all) e.g. for my art of defense gamemodes, so we don't need another dummy ai player. CivilianTeam,NeutralTeam or ObserverTeam could be used as an artificiall ally. You could totally program an independent lua ai for these to support the player too. But it's a loooot of work.

  • Downvote 1

Share this post

Link to post

Some group just made something like that for RA3 and released it week ago, afaik RA3 use similar map rules and whatsoever, With lua I think it more than possible

Edited by Egozi44

Share this post

Link to post

Thank you all for your kind asnwers. Also about RA3, yea Egozi I heard that but in RA3 mod one player only can build another take control of the units I want both can build and control armies.

@Mjjstral I just looked the Meta Mod of yours. That was just amazing, well done :) Lots of interesting stuff inside it.

Share this post

Link to post

Oh I see, never played that mod in SC2 and thought that the RA3 mod mimic it the exact same way~

Share this post

Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.