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

Suggestion:

Level 7
Joined
Sep 27, 2016
Messages
70
i try to make a trigger that i can force a computer player to cast spells in Spell Book ability ..

but the computer cant cast any spell in the spell book..

any suggestion to make this happened?

i tried to using "Game - Player Force UI Key" but it doesnt work, because the player must select the unit and computer player cannot select any unit.

i tried to create items with a spell in the Spell Book each of them and force the computer player to use the items.. it also doesnt worked.
 
Last edited:
Level 7
Joined
Sep 27, 2016
Messages
70
Can't the spells simply be added to the unit itself?
yes .. but i have a bunch of skills for every unit .. 7 slots in the unit are just no enough 😫


Just guessing - perhaps it needs to be done in two phases? Like cast Spell Book then cast Roar?

I vaguely recall seeing a thread on this but can't find it.

btw, i also added some ability that doesn't have an Order ID to the Spell Book (or can't find it in "Unit - Issue order ...")

so i think, the best way is creating a dummy item for each spell and give it to the computer's unit then order the unit to use the item.. but they dont want to use the item .. i think computer also cannot using any item ..
 
Level 18
Joined
Mar 16, 2008
Messages
721
The CPU will use items. If it's a .ai script it will use the item depending what the base item is, like what the items default settings are, and on certain conditions. Like it will use Rod of Necromancy when there is a skelleton around and it is attacking an enemy (not sure if that condition is true but just an example).

If the CPU isn't using an .ai script then you could simply order it with triggers - I'd guess.

You could probably do
  • custom script: call Order...
Hope I'm not being too vague, lmk if that makes sense?
 
Level 7
Joined
Sep 27, 2016
Messages
70
The CPU will use items. If it's a .ai script it will use the item depending what the base item is, like what the items default settings are, and on certain conditions. Like it will use Rod of Necromancy when there is a skelleton around and it is attacking an enemy (not sure if that condition is true but just an example).

If the CPU isn't using an .ai script then you could simply order it with triggers - I'd guess.

You could probably do
  • custom script: call Order...
Hope I'm not being too vague, lmk if that makes sense?
i see but im not yet learning about this .ai script .. how i can use it actually?.. because i checked the AI Editor at WE but the conditions is limited if it is what's you mean..

You can give a Unit any number of abilities. Plus, a Computer won't have issues with an overused command card since it's controlled by AI which doesn't use hotkeys/manually click buttons.

so.. i just move the abilities in the spell book into the unit it self then i can order any ability from the unit without to open the spell book first like i have to do with my hero? sorry for my english..
 
Top