• 🏆 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!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Commanding Computers

Status
Not open for further replies.
Level 3
Joined
Apr 8, 2006
Messages
41
Hi all,
I want to command a group of units to move to a specific point (the units are controlled by a non-user player). When I set the player's controller to "Computer" the units will return to the place they were made except for 1. When I set the player's controller to "Neutral" they are commanded as I want them to be, but they don't auto-acquire targets nor do they attack when commanded to do so (unless they are ordered to attack one of my own units).

Anyway I can keep the auto-targeting but not have them go back?

Also, do worker units not auto-acquire targets?

Thanks
--NightfangII
 
Last edited:
Level 3
Joined
Apr 8, 2006
Messages
41
Weird... but useful to know. ^^

Also does anyone know if there's a way to have two players gather gold from the same gold mine?
And I've made a structure based off Town Hall and removed its abilities, but in-game the Call to Arms button is there. Any idea how to fix this?
 
Level 3
Joined
Apr 8, 2006
Messages
41
I noticed (after finally testing it again) that I hadn't fixed it.
I had accidentally switched it to computer control. The units still like to return to where they were first built. Neutral definitely will not work.
Anyone know a way to maybe completely disable all AI in the map?
 
Level 4
Joined
Jul 18, 2009
Messages
85
Ok, with the gold mine thing, go into Gameplay constants and turn the Gold mine ownership time buffer to 0 secs.

Then go to gameplay interface and remove the unable to use mine controlled by another player text, its near the bottom.

This doesnt work with computers but i was able to control red and blue and have them mine at the same time from same gold mine.
Hope that helps.
 
Last edited:
Level 4
Joined
Jul 18, 2009
Messages
85
Loads of information in this post. Ill post back tomorrow if you need anything else.

Ok, i fixed your Call to arms issue here use the trigger part

Events
Map Initialization

Actions
Player - Disable Call to Arms (Town Hall) for (your player)
Player - Disable Call to Arms (Peasant) for (your player)

The actions are found under player - enable/disable ability. Call to arms is under unit abilites.
Hope that helps.

Also with the shade, you can just change the model of say a footmen to shade and he will auto attack, but shades dont have attack animations, you might be able to find a modified shade on here somewhere... Here http://www.hiveworkshop.com/forums/models-530/abyssshade-50536/?prev=search=Shade&d=list&r=20

Also if you want peasants/peons etc to auto aquire targets, just uncheck the worker classification, its the last thing listed under stats in the object editor.

Is this what you want with the computer stuff maybe?

Action
AI - Ignore the guard positions of all (AI player) units

This action tells the AI for the given player to neither use nor replace any of its preplaced units. Basically it will not order its units to do go back to where they were originally, I.E. you spawn 5 footmen and order them to attack move to region 01. They attack move there and stay there unless ordered to go else where. They will NOT go back to where they were when the order was issued. If this isnt what you want, please be more specific.

Disregard bottom half of post :p
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Ok, with the townhall, what i would do is just base it off of a different model, example orc townhall, and just change the model and icon, and make it train peasants. Be sure to take away the ability from peasants. Make sure to also change it to upgrade into the keep and castle, note you will have to pass keep and castle off of the orc ones too. Their might be another way but i can't find it.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
Last edited:
Level 3
Joined
Apr 8, 2006
Messages
41
Thanks a lot Hinte!
I've tried the AI - Ignore Guard Positions and it didn't seem to work sadly. However I found a workaround using wards.
Also I found that if I disabled the "town hall" setting on the town hall it would lose the call to arms.
Quite honestly I'm much more interested in finding out how to make other units not auto-acquire targets than finding out how to make the Shade acquire targets.
The problem with disabling the worker field is that it will then not appear as an idle worker.
The only other thing I'd like to know is if there is anyway to let a player build a building which can take resources from peasants and such right next to a gold mine?

Thanks again!
 
Level 4
Joined
Jul 18, 2009
Messages
85
Also with your sharing goldmine thing, you can edit the gold mine ability so you can have say 2 people in the gold mine at a time might make sharing smoother.

~~~~~~~~~~~~~~~~

So you want to make units not auto acquire targets?

~~~~~~~~~~~~~~~~

And the second part, you want basically a town hall right next to a goldmine?

Ok Better way.
Event
Unit - A unit finishes construction

Condition
(Unit type of (constructed unit)) equal to (your unit) * pick a unit that doesnt have return gold and lumber and isnt townhall:note you can
change the model to a townhall if you want i used a farm for example.
Action
Unit - Add Return Gold (and lumber) to constructed unit.

This will let you place units closes than your normally could to goldmines and they work as returns for gold and lumber if you set it to. Make sure the building doesnt have return gold and lumber or this wont work, the trigger adds the ability for you. If you have return gold already on the unit you cant place it this close to gold mines. Hope that helps! If you need anything else just ask.
~~~~~~~~~~~~~~~~~~~~~~~
Disregard bottom half
~~~~~~~~~~~~~~~~~~~~~~~


You can use Create unit goldmine at region, and the goldmine will appear as close to a town hall as the region is, but this only works if you have the building in question on the map at start... looking into more ways.
 
Last edited:
Level 3
Joined
Apr 8, 2006
Messages
41
I found that out. ^^ I have a type of gold mine where 3 people can mine at once.

~~~~

Well... idk. I mean, making a Spy which can fight, but won't automatically attack (thereby alerting the enemy to it's presence) might be cool. ^^
I figure I can just base it off the Shade.

~~~~

I tried that. The building gets there, and gold and lumber can be returned to it, but when a peasant is told to mine gold from the gold mine, the peasant will ignore the building right there and go to a farther away one. To be precise, the closest one outside of the gold mine radius.

Thanks a lot!

A few more things:
I read somewhere that a unit with both "Ghost" and "Permanent Invisibility" will remain invisible when it attacks (like starcraft Ghosts, except always invisible). Is that the case?
Also in a research/upgrade there is an option "Apply to All Units". Does that mean apply to all of the players units? Or all the units in the entire game, players and enemies?
 
Level 4
Joined
Jul 18, 2009
Messages
85
Hmm, the trigger worked perfectly for me with the goldmine...

~~~~~~~~~~~~~~~~~

Just give a unit ghost and he will be invisible while attacking/moving.

I dunno about rest
 
Level 3
Joined
Apr 8, 2006
Messages
41
So a unit will be invisi while moving and attack just with Ghost? No need for permanent invisi?

I'll try the gold mine again. Maybe it was my mac being weird XP

@Hordeon: Do you mean that the gold mine thing works with 1.24? I got 1.24 on my mac and have been too scared to get it on my PC because it made my WE not work.
 
Level 3
Joined
Apr 8, 2006
Messages
41
Is there a way to check if the player or the game issued the order with "Unit is issued an Order" events?
Like... I have a trigger which, when a player issues an order, it orders one of his units to attack. But usually it will then go into a loop and wc3 will crash.
 
Level 3
Joined
Apr 8, 2006
Messages
41
So I have a trigger like the following:
Events
----Unit - A unit is issued an order with no target
Actions
----Unit - Order (Ordered Unit) to Stop

Is there a way I can make a trigger doing the same thing without creating an infinite loop?

Hopefully that makes more sense.
 
Level 11
Joined
May 11, 2008
Messages
830
I think he's saying he wants a trigger that will start up when they see if someone ordered a unit to target something, but his problem is the trigger looped and crashed WC3, so a 1 time thing I guess.

Stupid thing but, do a wait for about 1 second, then do a turn off trigger, the make a new trigger, to reactivate it 1 second later.
 
Level 4
Joined
Jul 18, 2009
Messages
85
Oh, ok yea just do what Tau said. I'm curious though as to what this trigger is for o_O. Also try not to double (or triple /cough ^.^) post, just use the edit button. That is unless you are bumping which you should only do if 48 hours have passed and no one has responded.
 
Level 3
Joined
Apr 8, 2006
Messages
41
tyvm tau!

@Hinte: It's for a squad system I (hopefully) have now finished. ^^
Sorry about the triple post. (Looks like I've had some double posts before). I'll remember to edit instead in the future. ^^
 
Level 4
Joined
Jul 18, 2009
Messages
85
Alright, If you finished it gratz and good job, if not if you need anything else you know where to find me o_O
Also did the ghost thing work? And i added you as a friend i hope you dont mind.. (if you do just dont accept it >.>)
 
Level 3
Joined
Apr 8, 2006
Messages
41
Tau's suggestion didn't actually work... (just noticed)
If the player orders two units at once, only one will register.

Any other ways by any chance? ^^
 
Level 4
Joined
Jul 18, 2009
Messages
85
I'm really sleepy, but off the top of my head (i havent tested this) i would suggest using a unit group variable and use the action order unit group to do your order. I'd give you one of those epic 3-4 section with the ~~~~ dividers and stuff with a working trigger, but i'm really tired, and i dont know what exactly you want the trigger to do but judging by what you said i would say use unit groups and order unit group. Good nightzzzzz
 
Level 3
Joined
Apr 8, 2006
Messages
41
I found a way to fix my problem so ignore the last post.

Is there a way to make artillery units be inaccurate? Like, the Meat Wagon shoots at a unit, and the shot goes somewhere in an area near the unit. I'm not sure I'm being clear enough for me to understand... like Basilisks in DoW. Hopefully that gets the idea across XP
 
Level 3
Joined
Apr 8, 2006
Messages
41
It's ok. I had the exact same feeling and couldn't find it out. =(

Is there a maximum unit group size?
To be precise: 10 units?
 
Last edited:
Status
Not open for further replies.
Top