• 🏆 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!

If a player leaves the game is there a way to change the slot controller to computer?

Status
Not open for further replies.
Level 2
Joined
Jun 8, 2009
Messages
10
Say you're playing online with several players on a custom map, and one player gets bored/ his mum forces him off the computer so he leaves the game. Is there an "action" part of a trigger that can change the ownership of the player slot into computer? I know what to enter for the condition and events part. I looked through the actions several times but couldn't find the right one. I seem to remember being able to do this a long time ago but can't remember how...
Sorry for the newbie question. :smile:
 
Last edited:
Level 2
Joined
Jun 8, 2009
Messages
10
Computer must be an AI right ?
It has something to do with AI Editor though
However, there IS a way
A player leaves a game, Triggering player equals to Leaving Player, Run AI Scripts

Well, all I really wanted was for the leaver's units to use their spells automatically, like if you set them as computer without custom AI scripts before you begin the game. Would this work for that?
 
Level 33
Joined
Mar 27, 2008
Messages
8,035
You can set Regions for later use in commanding the computer slot
BUT you can't make the computer slot acts like true AI (like in DotA's) because you didn't use the AI Scripts...
However, the use of "Ordering the computer slot to use spells" can be done in triggers along with "Ordering the computer slot to Attack-Move-To along Regions"
Let's say enemy base is on Location C
You can create Region A , Region B, Region C
Order the computer slot unit to move to Region A -> B -> C using triggers (depends on what action you want the unit to perform, casting spells etc)
But this can be done in AoS-style map, other than that, you have to create a situational trigger
Btw, what is your map type ?
 
Level 2
Joined
Jun 8, 2009
Messages
10
Thanks for the help!
it's a custom quest. But I also want to be able to use the maps from it on their own as scenarios where you can choose which player you want to be.
 
Level 7
Joined
May 18, 2010
Messages
264
try this
Leave
Events
Time - Every 0.10 seconds of game time
Conditions
Actions
Player Group - Pick every player in (All players matching (((Picked player) slot status) Equal to Has left the game)) and do (AI - Start melee AI script for (Picked player): map.ai)
 
Status
Not open for further replies.
Top