Newbwc3's Help Thread

Status
Not open for further replies.

PurgeandFire

zxcvmkgdfg
Reaction score
509
There is no possible way to detect when an ability is activated unless you edit the functions. I don't know much about JASS so I don't know if there is another way to detect unless you detect something like buffs or effects. :D
 
T

thedude

Guest
There must be some way.

Edit: Do you have to have immolation? Or can you base it off of another ability (I don't know that many abilities, but isn't there one that has damage intervals too?)?
 

dragonhord

Knowledge is true opinion. - Plato
Reaction score
82
What event are you using? Starts the effect of an ability is the most effective in my opinion. Is that what you are using? That or you can make immolation add a buff to the caster "Which i believe it already does" and use the boolean that checks if a unit has your immolation buff, if it does run your trigger :D .
 

Newbwc3

Sephiroth_VII
Reaction score
157
Still need a event plz look at POST #100!!!!!!!!!!!(its up like 3 or so):D
SOLVED
 

SerraAvenger

Cuz I can
Reaction score
234
I'm really sorry I didn't put this earlier, but I forgot to tell you in my last post:
The normally used ability is "Phenixfire"
Just mod it and go ;)

Just create a dummy ability "flamethrower"
When that ability is used, wether
-Add phenixfire mod, remove your dummy ability and wait sometime then remove phenixfire mod, and add yor dummy
or
-Add phenixfire mod, remove dummy ability, add new dummy ability(lvl of ability dummy nr 1)
-When dummy abilty nr 2 is used, remove phenixfire mod, and add yor dummy ability nr 1

hope that helps ;)
Greets Serra
 
L

lordpredator

Guest
fire arrows

I need an auto-casting ability that can damage enemys... already tried using heal and changing some things in editor but doesn't work. What ability should I use as a base? I'll need some missile art to be fired at enemy and damage him.

Why dont you do this with the fire arrows as a base? yo can add splash damage, change cooldown and change the art to look like a flametrhower... and it will consume mana...

LP
 

Newbwc3

Sephiroth_VII
Reaction score
157
OMG I Finally figured out how to make my trigger fire! (It took so long mainly because I was working on other things in the map)

Here it is But it does need some minor changes/help from someone:
Base ability: IMMOLATION
*This ability has only 1 level and is not a hero ability!*
Code:
FlamethrowerON
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Flamethrower 
    Actions
        Set FT_caster = (Triggering unit)
        Special Effect - Create a special effect attached to the [B]hand,right [/B]of FT_caster using Abilities\Spells\Other\BreathOfFire\BreathOfFireDamage.mdl
        Set FT_Art = (Last created special effect)
        Trigger - Turn on FlamethrowerARTandDAMAGE <gen>

Code:
FlamethrowerOFF
    Events
        [B]Time - Every 0.01 seconds of game time[/B]
    Conditions
        (FT_caster has buff Immolation (Caster)) Equal to False
    Actions
        Special Effect - Destroy FT_Art
        Trigger - Turn off FlamethrowerARTandDAMAGE <gen>

Code:
FlamethrowerARTandDAMAGE (initially off)
    Events
        Unit - A unit Is issued an order targeting an object
    Conditions
    Actions
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Issued order) Equal to (Order([B]Right-Click[/B]))
                (Triggering unit) Equal to FT_caster
            Then - Actions
                Unit - Create 1 FT_Dummy for (Owner of FT_caster) at (Position of FT_caster) facing Default building facing degrees
                Unit - Add a 3.00 second Generic expiration timer to (Last created unit)
                Unit - Order (Last created unit) to [B]Right-Click [/B](Target unit of issued order)
                Unit - Cause FT_caster to damage (Target unit of issued order), dealing 10.00 damage of attack type Chaos and damage type Fire
            Else - Actions
I have put in bold the stuff that im asking about.

1) Im using GoblinShredder model. I need the Special effect to be look like its attached to the shredders cannonhand(which is his righthand) But obviously he doesnt have a attachment point for righthand. So what attachment point should I type in?
SOLVED It just so happens that u have to type in "right hand"

2) On the FlamethrowerOFF code the event is leaky but its the only one that will work I think. I tested the ability and if you spam click the activate/deactivate button it makes it so the Art that was created stays attached to his hand forever. Also If u have more than one selected of the unit-type and activate the ability then the same thing will happen.how to fix?
SOLVED

3)about the order "Right-Click" it seems as tho that doesnt work cause when I right click on an enemy the trigger doesnt fire. And when i had the order changed to "Attack" the trigger would work if u pressed "a" on the keyboard and then selected target. I need an order that would recognize when u right-click on an enemy but obviously the order "Right-Click" doesnt recognize that. Or maybe it does I just typed it in wrong?? Maybe I should use Attack-Move?
SOLVED

+REP rewarded! If u help
 

Farplane

New Member
Reaction score
8
1) Im using GoblinShredder model. I need the Special effect to be look like its attached to the shredders cannonhand(which is his righthand) But obviously he doesnt have a attachment point for righthand. So what attachment point should I type in?

What are ya talking about? The strings aren't THAT technical..
Code:
Event - Whatever
Condition - Whatever
Action - Special Effect - Create a special effect attached to the hand, right of Goblin Shredder 0000 <gen> (or whatever hes called) using Environment\LargeBuildingFire\LargeBuildingFire2.mdl
 
L

lordpredator

Guest
2) On the FlamethrowerOFF code the event is leaky but its the only one that will work I think. I tested the ability and if you spam click the activate/deactivate button it makes it so the Art that was created stays attached to his hand forever. Also If u have more than one selected of the unit-type and activate the ability then the same thing will happen.how to fix?
you can make a variable of type boolean "flamethrower_active", when the ability is activated the variable is make TRUE and when deactivated the variable is FALSE... you add in the conditionals of the ability activated, ability deactivated and ability damage to check if the ability is ON or OFF, so the code of the deactivation don´t run every 0.1 second (you have to limit the times a trigger run when you give it a periodic event of less of 5 seconds, or it will be leaky)
3)about the order "Right-Click" it seems as tho that doesnt work cause when I right click on an enemy the trigger doesnt fire. And when i had the order changed to "Attack" the trigger would work if u pressed "a" on the keyboard and then selected target. I need an order that would recognize when u right-click on an enemy but obviously the order "Right-Click" doesnt recognize that. Or maybe it does I just typed it in wrong?? Maybe I should use Attack-Move?
the order a unit is given when you right-click is "smart", but the order system is messy... so you have to make there a conditional with "or - multiple conditions", to catch the orders "attack" "smart" "right-click", you have to check if the target unit is a enemy too, if you don´t want the unit to attack a ally unit when you right click on it (instead of following it). Other thing about the orders and order-strings is that they are not recogniced well, or they are different, when you select in the GUI the order you can select by "preset" or "convert string to order", well, in my experience... the orders are different, i have made some triggers checking the order as PRESET - RIGHT-CLICK and it work, but the same order as string is "smart", so "right-click doesn´t work (at less for me):nuts: . I strongly recommend you make a catch for every possible order with a OR conditional, with all possible orders (remember to add a conditional for "friend or enemy")
 

Attachments

  • order.jpg
    order.jpg
    50.5 KB · Views: 234

Newbwc3

Sephiroth_VII
Reaction score
157
you can make a variable of type boolean "flamethrower_active", when the ability is activated the variable is make TRUE and when deactivated the variable is FALSE... you add in the conditionals of the ability activated, ability deactivated and ability damage to check if the ability is ON or OFF, so the code of the deactivation don´t run every 0.1 second (you have to limit the times a trigger run when you give it a periodic event of less of 5 seconds, or it will be leaky)
U mean like this?

Code:
FlamethrowerON
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Flamethrower 
        flamethrowerON Equal to False
    Actions
        Set flamethrowerON = True
        Set FT_caster = (Casting unit)
        Special Effect - Create a special effect attached to the left hand of FT_caster using Abilities\Spells\Other\BreathOfFire\BreathOfFireDamage.mdl
        Set FT_Art = (Last created special effect)
        Trigger - Turn on FlamethrowerARTandDAMAGE <gen>

Code:
FlamethrowerOFF
    Events
        Time - Every 0.01 seconds of game time
    Conditions
        (FT_caster has buff Immolation (Caster)) Equal to False
        flamethrowerON Equal to True
    Actions
        Set flamethrowerON = False
        Special Effect - Destroy FT_Art
        Trigger - Turn off FlamethrowerARTandDAMAGE <gen>

Code:
FlamethrowerARTandDAMAGE
    Events
        Unit - A unit Is issued an order targeting an object
    Conditions
    Actions
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                flamethrowerON Equal to True
                (Issued order) Equal to (Order(smart))
                (Triggering unit) Equal to FT_caster
            Then - Actions
                Unit - Create 1 Dummy for (Owner of FT_caster) at (Position of FT_caster) facing ((Center of (Playable map area)) offset by (0.00, 0.00))
                Unit - Add FlameThrow  to (Last created unit)
                Unit - Order (Last created unit) to Human Mountain King - Storm Bolt (Target unit of issued order)
                Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
            Else - Actions
I dont really understand why this would help it not fire so quickly.why?
SOLVED
 
L

lordpredator

Guest
the solution...

while i write the answer i come to another idea... a lot more simple... Make 2 units one with the standart attack, and the other with the flamethrower attack, the one with the flamethrower with a dummy ability passive (to show the flametrhower on) and mana regeneration negative (or an ability based on brillance aura with range 1, other icon and regeneration negative), the flamethrower can have any aditional ability as "incinerate" to make it more interesting. Both units have a Morph based ability, so the standart unit morph into the flamethrower unit and the flamethrower unit into the standart unit. the flamethrower will have as attack the flame, so you don´t have to bother with triggers, orders, right-click, coooldowns...

Good luck.. and i wanna se that flametrhower burning some units
LP
 

Newbwc3

Sephiroth_VII
Reaction score
157
Sry but im already to far into this method. plus an ablility that triggers when u turn it on/off with immolation is way cool.
I've done everything U said and everything works just fine. Just need one more little thing and it will be perfect.

When u use the ability it doesn't work when u get real close because then the unit uses his melee attack. I need an action that takes away his attack, and then ofcourse an action to give back his melee attack...:confused:
SOLVED
 

PurgeandFire

zxcvmkgdfg
Reaction score
509
In the ability editor, there should be something like:
Code:
Art - Animation Names
Add something like:
Code:
"Spell" or "Stand" or "Attack"
This should make the unit perform an animation whenever it is cast, thus, causing the unit to stop to cast it. :D

I hope this helps and workz! :D
 

ArmedCitizen

Kisses Cats
Reaction score
198
Code:
[B]Events[/B]

Unit is attacked

[B]Conditions[/B]

Attacking unit is owned by (set a player variable and set the variable to the 
owner of casting ability)

[B]Actions
[/B]
Ordering attacking unit to stop.

Just turn that on and off.
 

Newbwc3

Sephiroth_VII
Reaction score
157
Removing leaks if any

Armedcitizen ===> +REP
PurgeandFire====> +REP
lordpredator=====> +REP
Among the few abilitys I have made, this was the Most complex one..lol. Thx for helping.

Code:
FlamethrowerON
    Events
        Unit - A unit Starts the effect of an ability
    Conditions
        (Ability being cast) Equal to Flamethrower 
        flamethrowerON Equal to False
    Actions
        Set flamethrowerON = True
        Set FT_caster = (Casting unit)
        Special Effect - Create a special effect attached to the left hand of FT_caster using Abilities\Spells\Other\BreathOfFire\BreathOfFireDamage.mdl
        Set FT_Art = (Last created special effect)
        Trigger - Turn on FlamethrowerARTandDAMAGE <gen>

Code:
FlamethrowerOFF
    Events
        Time - Every 0.01 seconds of game time
    Conditions
        (FT_caster has buff Immolation (Caster)) Equal to False
        flamethrowerON Equal to True
    Actions
        Set flamethrowerON = False
        Special Effect - Destroy FT_Art
        Trigger - Turn off FlamethrowerARTandDAMAGE <gen>
        Trigger - Turn off DisableMeleeAttack <gen>

Code:
FlamethrowerARTandDAMAGE
    Events
        Unit - A unit Is issued an order targeting an object
    Conditions
        flamethrowerON Equal to True
        (Triggering unit) Equal to FT_caster
        ((Triggering player) is an enemy of (Owner of (Target unit of issued order))) Equal to True
    Actions
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                Or - Any (Conditions) are true
                    Conditions
                        (Issued order) Equal to (Order(smart))
                        (Issued order) Equal to (Order(attack))
                        (Issued order) Equal to (Order(move))
            Then - Actions
                Special Effect - Create a special effect attached to the left hand of FT_caster using Objects\Spawnmodels\Other\FlameThrower\FlameThrowerSpawnObj.mdl
                Unit - Create 1 FT_Dummy for (Owner of FT_caster) at (Position of FT_caster) facing (Position of (Target unit of issued order))
                Unit - Order (Last created unit) to Human Mountain King - Storm Bolt (Target unit of issued order)
                Unit - Add a 3.00 second Generic expiration timer to (Last created unit)
                Special Effect - Destroy (Last created special effect)
            Else - Actions

Code:
DisableMeleeAttack
    Events
        Unit - A unit Is attacked
    Conditions
        (Attacking unit) Equal to FT_caster
    Actions
        Unit - Order FT_caster to Stop

Request leak fixer:
1)Anyone who knows all about leaks plz look thru this and see if there are any and tell me what to change.

2)Oyea, can I post this in the spell section even tho its not a hero ability???
SOLVED
 

dragonhord

Knowledge is true opinion. - Plato
Reaction score
82
Looks leak free to me :D .

Edit - I need to pay more attention :D . I cant read through these threads like you guys... I love to help people but sometimes I dont feel I have the patience... Ill try me best though :D .
 

Doom-Angel

Jass User (Just started using NewGen)
Reaction score
167
1) not so leak free as said above u have 2 leaks.
Code:
Unit - Create 1 FT_Dummy for (Owner of FT_caster) at [U][B](Position of FT_caster)[/B][/U] facing [B][U](Position of (Target unit of issued order))[/U][/B]
(bolded and lined.....)
here's how to fix:
Code:
Set Point = (Position of FT_caster)
Set Point2 = (Position of (Target unit of issued order))
Unit - Create 1 FT_Dummy for (Owner of FT_caster) at Point facing Point2
Custom script:   call RemoveLocation(udg_Point)
Custom script:   call RemoveLocation(udg_Point2)
i hope u got it clear :p

2) well u can't submit it anyway on the spell section without SFilip's permission so u first gotta make the spell thread on the world edit zone with a spell tag (e.g: [Spell] Flame Thrower) or in case of a few spell u put spellpack tag instead and u just need to go to the thread "Spells Awaiting Approval" and wait for SFilip to confirm and move it to the spell section

in case u want more information about making a spell read the Rules & Guidelines Thead
 

SerraAvenger

Cuz I can
Reaction score
234
I still have 2 questions:

1. About the spell: how do you make it if 2 players/Heros use this ability -.-

2. Why should these be leaks?
I thought a leak would be if memory that is no longer needed would not be
released, such as the memory used by a unit. When that unit dies, all that has to do with this specific unit is released, like the variables that store life, mana, buffs, and so on. If they would not be released, this would be a memory leak. Or are we talking about different leaks?
 

Oninuva

You can change this now in User CP.
Reaction score
221
I still have 2 questions:

1. About the spell: how do you make it if 2 players/Heros use this ability -.-

2. Why should these be leaks?
I thought a leak would be if memory that is no longer needed would not be
released, such as the memory used by a unit. When that unit dies, all that has to do with this specific unit is released, like the variables that store life, mana, buffs, and so on. If they would not be released, this would be a memory leak. Or are we talking about different leaks?

1. Using an Array for the variables would work most of the time.

2. I don't know what leaks you are talking about. Too lazy to read all pages of thread.

Note: Why not make your own help thread?
 

Newbwc3

Sephiroth_VII
Reaction score
157
Ok is there some way to make the dummy unit attached to the left hand when created.

Because the dummy shoots this flame thingy and it doesnt look like its coming out of the shredders cannon....

Or maybe even some way to create the dummy at the location of the left hand of the shredder. I tried to make it create the dummy at the location of last created special effect but I Can't do that.?
SOLVED
 
Status
Not open for further replies.
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top