HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Custom Hero Abilities - Adding

12-10-2006, 10:13 PM#1
Centreri
I'm a complete mapping novice, so go easy on me.

I'm trying to create a new one of those Custom Hero Arena games - they're popular, they see relatively easy to make, and they'll give me practice with GUI triggers.

Right now I'm just testing the ground for giving abilities - it works like you buy the item from the nice shop, and the instant you do, the item is removed from your inventory and the spell is added to the hero. Here's the trigger:

Events:
Unit - A unit Acquires an item

Conditions:
(Item being manipulated) Equal to (Item carried by (Triggering unit) of type Fireball)

Actions:
Item - Remove (Item being manipulated)
Unit - Add Fireball to (Triggering unit)

I would do it using the standard trigger tags, but the 'tutorial' on them neglects how to use them and there's nothing to help with that in the posting menu. Anyway,

I made sure that Fireball is a hero spell (10 levels), and when the hero buys the item everything works except that the spell is counted as a regular spell. It's not added in nonexistant-because-of-no-hero-spell 'research spell' menu and has no way to upgraded. It's counted as a regular unit ability. I need it to not be researched to give the person a chance to select this ability in-game, not have level 1 of each spell available at level 1.
12-10-2006, 10:17 PM#2
Captain Griffen
You cannot add abilities as hero abilities by triggers. You'll need a work around.
12-10-2006, 10:22 PM#3
Centreri
I've seen it done before in Custom Hero Line Wars. First the heroes buy the items, they get teleported somewhere to wait for others, then when the game starts you have your hero with the abilities you chose. Don't tell me every combination was pre-made . I tried looking at how it was made, but everything except for the terrain was absent when the map opened. Protected.
12-10-2006, 10:25 PM#4
Vexorian
Nope not like that please. (Edit: I started to type this message before griffen's was there)

Look! a demo:
Engineering Upgrade Test.w3x

---
Other method is to have dummy abilities that upgrade Skill 1 Skill 2 etc and then set levels of the actual spells. But the engineering upgrade method is cooler.
Attached Files
File type: w3xEngineering Upgrade Test.w3x (20.6 KB)
12-10-2006, 10:28 PM#5
Centreri
Thank you, Vexorian. It also seems easier then the dummy ability method.

I checked it, copy/pasted the Setup trigger and started looking through the Limit Check trigger, which apparently just makes sure that you don't get more then 5 spells. Without that trigger it didn't work; can someone just 'walk me through' adding and implementing this system with custom settings? I'm planning on letting the host choose in game whether the abilities in-game will be divided into categories and only one of each is allowed or if the people can reach maximum effectiveness by combining abilities from the same categories.
12-11-2006, 12:44 AM#6
Anopob
Just make copies of the Limit Check trigger, and in your trigger which detects if the host wants a type turn the Limit Check triggers off....or I think that's what you're trying to say.
12-11-2006, 02:35 AM#7
Pyrogasm
I know it's primitive, but couldn't you also do it by disabling all abilities that you can buy from items at map initilization and then enabling them when heroes buy the items? Example:
Trigger:
Collapse Start of Map Disable
Collapse Events
Map Initilization
Conditions
Collapse Actions
Player Group - Pick every player and do (Actions)
Collapse Loop - Actions
Player - Disable (Fireball) for (Picked Player)
Comment ---- Just repeat the above action for all abilities that can be bought from items ----
Collapse Item Buy
Collapse Events
A unit buys an item
Conditions
Collapse Actions
If (Item-type of (Item being manipulated) equal to (Fireball)) then do (Player - Enable (Fireball) for (Owner of (Triggering Unit))), Else (Do Nothing)
Comment ---- Add the above action for each item that can be bought ----
12-11-2006, 02:36 AM#8
Vexorian
A hero can only have up to 5 learnable hero skills.