the_ideal
user title
- Reaction score
- 61
This is a system that makes spell casting in Warcraft a lot more dynamic. Any spells you choose can have a casting time during which a bar fills up. When the bar is full, the spell is cast. (If you have played WoW or similar games you know what I'm talking about.) The system is fairly customizable, with many things that can be adjusted:
Features:
-- Color/length/height of casting bar.
-- Different casting times for different spells
-- Casting times can be adjusted according to spell level or if a hero has a custom item that does so
-- You can choose which abilities have casting bars. If you only want to use this system for one ability in your map, that works. If you want all the abilities in your map to use casting bars, that works too... (with some limitations)
-- MPI; each player can have one main spellcasting unit. This makes the system useful for AoSs and RPGs, and less useful for other maps, such as Melee.
-- Fully GUI; very noob friendly, especially once you get the hang of it.
-- Leakless, Lagless (note: has not been tested with large numbers of players)
-- Customizable animation for each spell (different colored glowing hands! :shades
-- Choose who can see whose spell bars.
-- When a unit casting a spell takes damage, the spell progress is reduced. You can determine how much it is reduced with your own formula, and determine whether or not heroes reduce progress more.
-- Doesn't require any other systems or modified World Editors!
Limitations:
-- Some spells, by their nature, cannot be implemented into this system. The spell has to be something that a dummy unit can cast. For example, Life Drain cannot be implemented into this system easily, (you could probably trigger it if you worked hard enough) because it requires that your hero is casting it.
-- Not MUI. Each player can only have one spellcaster.
-- Triggering is not as efficient as it could be if it were in JASS
-- Every new spell you want to have a casting bar requires a new trigger to be added, and a line added to another trigger. It's not a big drawback, but it does mean adding a new spell is going to take a minute or two longer than usual.
-- System works best for units with "channel" animation. Otherwise the unit is just standing there while the spell is being cast. (Can be adjusted by changing animation names of spells.)
Screenshots
Implementation
Copy triggers and variables from attached map into your map. Every spell requires:
-- A base spell, based on channel. This is the spell your hero will cast. In the demo map there are many examples. All of these spells have the suffix (caster). This spell icon/tooltip will look just like the actual spell that is going to be cast.
-- The spell the dummy will cast. This will actually have the effect of the spell you want. These spells are marked in the demo map as (dummy)
-- A trigger that sets up the spell, when the base spell is cast. This lets the game know that a spell is being cast, sets the target unit or point, sets the casting time, and sets a variable to the spell that you want your dummy to cast when the spell is complete.
For example:
-- A line added to the trigger that fires when the spell is done casting that orders the dummy to cast the spell that has been added to it.
NOTE: This system is incomplete. I still haven't implemented the necessary triggers for channeled spells (like Death and Decay or Tranquility), and the triggers in my map are still not polished. The purpose of this post is to see if anyone is interested and to help out anyone who might want to use this. I will update this thread later with a better test map, and a much more detailed explanation of the triggers in the system and how they all work.
Enjoy! Comment!
Features:
-- Color/length/height of casting bar.
-- Different casting times for different spells
-- Casting times can be adjusted according to spell level or if a hero has a custom item that does so
-- You can choose which abilities have casting bars. If you only want to use this system for one ability in your map, that works. If you want all the abilities in your map to use casting bars, that works too... (with some limitations)
-- MPI; each player can have one main spellcasting unit. This makes the system useful for AoSs and RPGs, and less useful for other maps, such as Melee.
-- Fully GUI; very noob friendly, especially once you get the hang of it.
-- Leakless, Lagless (note: has not been tested with large numbers of players)
-- Customizable animation for each spell (different colored glowing hands! :shades
-- Choose who can see whose spell bars.
-- When a unit casting a spell takes damage, the spell progress is reduced. You can determine how much it is reduced with your own formula, and determine whether or not heroes reduce progress more.
-- Doesn't require any other systems or modified World Editors!
Limitations:
-- Some spells, by their nature, cannot be implemented into this system. The spell has to be something that a dummy unit can cast. For example, Life Drain cannot be implemented into this system easily, (you could probably trigger it if you worked hard enough) because it requires that your hero is casting it.
-- Not MUI. Each player can only have one spellcaster.
-- Triggering is not as efficient as it could be if it were in JASS
-- Every new spell you want to have a casting bar requires a new trigger to be added, and a line added to another trigger. It's not a big drawback, but it does mean adding a new spell is going to take a minute or two longer than usual.
-- System works best for units with "channel" animation. Otherwise the unit is just standing there while the spell is being cast. (Can be adjusted by changing animation names of spells.)
Screenshots
Implementation
Copy triggers and variables from attached map into your map. Every spell requires:
-- A base spell, based on channel. This is the spell your hero will cast. In the demo map there are many examples. All of these spells have the suffix (caster). This spell icon/tooltip will look just like the actual spell that is going to be cast.
-- The spell the dummy will cast. This will actually have the effect of the spell you want. These spells are marked in the demo map as (dummy)
-- A trigger that sets up the spell, when the base spell is cast. This lets the game know that a spell is being cast, sets the target unit or point, sets the casting time, and sets a variable to the spell that you want your dummy to cast when the spell is complete.
For example:
Trigger:
- Entangle
- Events
- Unit - A unit Starts the effect of an ability
- Conditions
- (Ability being cast) Equal to Entangle (caster)
- Actions
- Set CCB_IntTemp = (Player number of (Owner of (Triggering unit)))
- Set CastTargetUnit[CCB_IntTemp] = (Target unit of ability being cast)
- Set CCB_CastingProgress[CCB_IntTemp] = 0.01
- Set CastSpellLevel[CCB_IntTemp] = (Level of (Ability being cast) for (Triggering unit))
- Set CastingSpell[CCB_IntTemp] = 1
- Set CCB_CastingTimeTotal[CCB_IntTemp] = 1.50
- Set CastAbilityDummy[CCB_IntTemp] = Entangle (dummy)
- Events
-- A line added to the trigger that fires when the spell is done casting that orders the dummy to cast the spell that has been added to it.
NOTE: This system is incomplete. I still haven't implemented the necessary triggers for channeled spells (like Death and Decay or Tranquility), and the triggers in my map are still not polished. The purpose of this post is to see if anyone is interested and to help out anyone who might want to use this. I will update this thread later with a better test map, and a much more detailed explanation of the triggers in the system and how they all work.
Enjoy! Comment!