• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

Change Players in-game

Status
Not open for further replies.
Level 3
Joined
Mar 23, 2015
Messages
32
There was a custom campaign featuring the Scourge and Forsaken. After a cutscene, you stop playing as the Lich King and instead played as Slyvanas. This is all in the same map.

How does one change players/faction the user play's during the game?
 

Chaosy

Tutorial Reviewer
Level 40
Joined
Jun 9, 2011
Messages
13,183
Depends on how you want it. You could remove all units owned by player 1 and then spawn new ones with triggers.
You could have Sylvanas with preplaced units owned by player 2 and then you just change owner of player 2's units to player 1.
Lastly it could be the camera bounds, the player wont be able to control units outside the camera bounds. Add Locust to all units outside the camera bounds to make heroes unselectable. Then switch it around after the cinematic.

edit: though the last idea got downsides and I would not suggest using it.
 
Last edited:
Level 25
Joined
May 11, 2007
Messages
4,651
You set tempGroup1 = units owned by player X.
You set tempGroup2 = units owned by player Y.

You pick every unit in tempGroup1 and change ownership to Player Y.
You pick every unit in tempGroup2 and change ownership to Player X.

Done.
 
Status
Not open for further replies.
Top