help with fear spell

CrazyWolf

New Member
Reaction score
4
Hi everyone i want to make a spell named fear and its purpose is to instill fear to a unit and make it unable to attack but also cause it to move around in fear while it can receive damage from its enemies.

I tried to do that by adding the ability Tornado Wander(tornado) into the unit but its owner could still move it and attack.I also cleared selection for its owner but that's not enough cuz he may select it again.I cant add the locust ability to the unit from triggers but even if i could enemies would not be able to attack the unit as long as it would have fear....
PLZ HELP!!
 

ayumilove

Youtube account suspended! youtube.com/ayumilove8
Reaction score
110
you will need to use a trigger to add locust into the unit,
add wander ability (which can be found from critters)

its something like poly morph or hex o_O
 

Exide

I am amazingly focused right now!
Reaction score
448
Locust wouldn't work?
You can't attack a Locust unit, right?
Also, you might want to remove the attack ability for the unit (if it's possible. :p)
Maybe if you gave control of the unit to Neutral Extra or something, while it's affected by fear.
 

Darius34

New Member
Reaction score
30
you will need to use a trigger to add locust into the unit,
add wander ability (which can be found from critters)

its something like poly morph or hex o_O
He already said he couldn't do that.

The best solution would be to disable spellcasting and attacking with Drunken Haze. Make the spell silence everything (even attacks, there is a checkbox for that). Then, transfer ownership of the unit to Neutral Extra or something, and periodically order the unit to run around, say every 0.5 seconds. The only issue is where you'd want the unit to run to though; I would suggest having another trigger to randomly generate locations every 3 seconds or so.

For the DoT, many spells will do; Soul Burn, Shadowstrike, etc or make your own.
 

Exide

I am amazingly focused right now!
Reaction score
448
"Then, transfer ownership of the unit to Neutral Extra or something, and periodically order the unit to run around, say every 0.5 seconds."

Easiest way would be to simply give it the 'Wander' ability. -But I guess that Wander doesn't move the unit quick enough..
 

Darius34

New Member
Reaction score
30
"Then, transfer ownership of the unit to Neutral Extra or something, and periodically order the unit to run around, say every 0.5 seconds."

Easiest way would be to simply give it the 'Wander' ability. -But I guess that Wander doesn't move the unit quick enough..
I don't think you can control the distance moved or the interval with Wander. Wander has a periodic pause between movement and it only moves the unit short distances. If you want the unit to be faster, you can increase it's movement speed, but that would look pretty weird.

The triggered method simply gives more flexibility.
 
K

Kevin

Guest
If the player only controls 1 unit, then disable control for user, then make an issue order trigger for target unit that lasts a duration. It should look like this:

Code:
Event -
Unit is the target of a spell
Conditions
Spell is = to "Such and Such" spell (or something to that effect)
Actions
Remove player control (or disable control) for Owner of Targeted Unit
Issue order to targeted unit - move unit to random position in playable area
wait 1 second
Issue order to targeted unit - move unit to random position in playable area
wait 1 second
Issue order to targeted unit - move unit to random position in playable area
wait 1 second
Issue order to targeted unit - move unit to random position in playable area
wait 1 second
Issue order to targeted unit - move unit to random position in playable area
wait 1 second
Issue order to targeted unit - move unit to random position in playable area
Enable player control for owner of targeted unit

You don't really want to be changing the hero to neutral passive if it dies you may have resurrection problems.

Also, you might want to increase speed for the targeted unit, granting it a + speed ability or using some other method to temporarily increase speed.
 
I

IKilledKEnny

Guest
Here is the fear Ability I did, you may do whatever you want with it. :)

Code:
Fear
    Events
        Unit - A unit Begins casting an ability
    Conditions
        (Ability being cast) Equal to Fear 
        (Unit-type of (Casting unit)) Equal to Illusion Creator 
    Actions
        Set FearAbilityCount = 0
        Set FearUnitGroup = (Units within 600.00 of (Position of (Casting unit)) matching (((((Matching unit) is A structure) Equal to False) and (((Matching unit) belongs to an enemy of (Owner of (Casting unit))) Equal to True)) and (((Matching unit) is alive) Equal to True)))
        Unit Group - Pick every unit in FearUnitGroup and do (Actions)
            Loop - Actions
                Set FearAbilityCount = (FearAbilityCount + 1)
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    If - Conditions
                        FearAbilityCount Less than or equal to 10
                    Then - Actions
                        Set FearPoint = (Position of (Picked unit))
                        Set FearSEI = (FearSEI + 1)
                        Unit - Set the custom value of (Picked unit) to (Player number of (Owner of (Picked unit)))
                        Unit - Change ownership of (Picked unit) to Player 12 (Brown) and Change color
                        Unit - Make (Picked unit) face (Random real number between 0.00 and 360.00) over 0.00 seconds
                        Unit - Order (Picked unit) to Move To (FearPoint offset by 1000000000.00 towards (Facing of (Picked unit)) degrees)
                        Unit Group - Add (Picked unit) to FearUnitGroup2
                        Special Effect - Create a special effect attached to the overhead of (Picked unit) using Abilities\Spells\Undead\DeathCoil\DeathCoilMissile.mdl
                        Set FearSE[FearSEI] = (Last created special effect)
                        Floating Text - Create floating text that reads Feared!! above (Picked unit) with Z offset 0.00, using font size 8.00, color (10.00%, 10.00%, 100.00%), and 0.00% transparency
                        Floating Text - Change (Last created floating text): Disable permanence
                        Floating Text - Change the lifespan of (Last created floating text) to 2.50 seconds
                    Else - Actions
        Wait 7.00 seconds
        Unit Group - Pick every unit in FearUnitGroup2 and do (Actions)
            Loop - Actions
                Unit - Order (Picked unit) to Stop
                Unit - Change ownership of (Picked unit) to (Player((Custom value of (Picked unit)))) and Change color
                For each (Integer A) from 1 to 10, do (Actions)
                    Loop - Actions
                        Special Effect - Destroy FearSE[(Integer A)]
        Unit Group - Remove all units from FearUnitGroup
        Unit Group - Remove all units from FearUnitGroup2
        Custom script:   call RemoveLocation (udg_FearPoint)
 
M

Mythic Fr0st

Guest
Hmm

Ok

Variables:

Loc, point, array 1
X, integer, no array
C_Value, integer, no array
Unit_C_Value, integer, no array
A, unit, no array
TheUnit, unit, array 1


FIRST, we must mark all units with an ID (custom value)
Code:
Event
   - Map init
Conditions
Actions - pick every unit in units in playable map area
     loop
       - set Custom value of picked unit to C_Value+1
       - set Unit_C_Value = Unit_C_Value + 1
Code:
Event
   - A unit starts the effects of an ability
Conditions ability being cast equal to Fear
Actions
   - set A = target unit of ability being cast
   - set C_Value = Custom value of A
   - set Loc[0] = center of region (a region WAY!!!! out of sight)
   - create 1 (custom unit with no image) at Loc[0] for owner of A
   - set TheUnit[C_Value] = A
   - add a 3 second generic timer to last created unit
  - call RemoveLocation(udg_Loc[0])

Code:
Event 
   - Every 3.00 seconds
Conditions
Actions
   - For each Integer A from 1 to Unit_C_Value
      loop
        if TheUnit[Integer A] is alive equal to true
        then - set Loc[1] = position of TheUnit[Integer A]
        - set Loc[2] = Loc[1] offset by random number between 20 and 75 towards random angle
        - order TheUnit[Integer A] to move to Loc[2]
        - call RemoveLocation(udg_Loc[1])
        - call RemoveLocation(udg_Loc[2])

NOTE if you have TO many units it may / may not crash (I havent tested)

Anyway, it should work, and I dont think theres any leaks (brb chores)

But, put a region way out of sight, and make a custom unit with no image, (and 0.10 death time)
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • WildTurkey WildTurkey:
    is there a stephen green in the house?
    +1
  • The Helper The Helper:
    What is up WildTurkey?
  • The Helper The Helper:
    Looks like Google fixed whatever mistake that made the recipes on the site go crazy and we are no longer trending towards a recipe site lol - I don't care though because it motivated me to spend alot of time on the site improving it and at least now the content people are looking at is not stupid and embarrassing like it was when I first got back into this like 5 years ago.
  • The Helper The Helper:
    Plus - I have a pretty bad ass recipe collection now! That section of the site is 10 thousand times better than it was before
  • The Helper The Helper:
    We now have a web designer at my job. A legit talented professional! I am going to get him to redesign the site theme. It is time.
  • Varine Varine:
    I got one more day of community service and then I'm free from this nonsense! I polished a cop car today for a funeral or something I guess
  • Varine Varine:
    They also were digging threw old shit at the sheriff's office and I tried to get them to give me the old electronic stuff, but they said no. They can't give it to people because they might use it to impersonate a cop or break into their network or some shit? idk but it was a shame to see them take a whole bunch of radios and shit to get shredded and landfilled
  • The Helper The Helper:
    whatever at least you are free
  • Monovertex Monovertex:
    How are you all? :D
    +1
  • Ghan Ghan:
    Howdy
  • Ghan Ghan:
    Still lurking
    +3
  • The Helper The Helper:
    I am great and it is fantastic to see you my friend!
    +1
  • The Helper The Helper:
    If you are new to the site please check out the Recipe and Food Forum https://www.thehelper.net/forums/recipes-and-food.220/
  • Monovertex Monovertex:
    How come you're so into recipes lately? Never saw this much interest in this topic in the old days of TH.net
  • Monovertex Monovertex:
    Hmm, how do I change my signature?
  • tom_mai78101 tom_mai78101:
    Signatures can be edit in your account profile. As for the old stuffs, I'm thinking it's because Blizzard is now under Microsoft, and because of Microsoft Xbox going the way it is, it's dreadful.
  • The Helper The Helper:
    I am not big on the recipes I am just promoting them - I use the site as a practice place promoting stuff
    +2
  • Monovertex Monovertex:
    @tom_mai78101 I must be blind. If I go on my profile I don't see any area to edit the signature; If I go to account details (settings) I don't see any signature area either.
  • The Helper The Helper:
    You can get there if you click the bell icon (alerts) and choose preferences from the bottom, signature will be in the menu on the left there https://www.thehelper.net/account/preferences
  • The Helper The Helper:
    I think I need to split the Sci/Tech news forum into 2 one for Science and one for Tech but I am hating all the moving of posts I would have to do
  • The Helper The Helper:
    What is up Old Mountain Shadow?

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top