Adding +1 damage for each attack

FannyShaver

Well-Known Member
Reaction score
31
Trigger:
  • Lightning Tower Attack
    • Events
      • Unit - A unit Is attacked
    • Conditions
      • (Unit-type of (Attacking unit)) Equal to Ultimate Lightning Tower
      • ((Attacked unit) belongs to an enemy of Player 1 (Red)) Equal to True
    • Actions
      • Unit - Add Ultimate Lightning Tower +1 dmg (+1) to (Attacking unit)
      • Unit - Set level of Ultimate Lightning Tower +1 dmg (+1) for (Attacking unit) to 2
      • Unit - Remove Ultimate Lightning Tower +1 dmg (+1) from (Attacking unit)


Ability was:

level 1 = 0dmg
level 2 = 1dmg

and

level 1 = 0dmg
level 2 = -1dmg

None worked. Any clue how to get that done?
 

hopy

Active Member
Reaction score
64
Trigger:
  • Lightning Tower Attack
    • Events
      • Unit - A unit Is attacked
    • Conditions
      • (Unit-type of (Attacking unit)) Equal to Ultimate Lightning Tower
      • ((Attacked unit) belongs to an enemy of Player 1 (Red)) Equal to True
    • Actions
      • Unit - Add Ultimate Lightning Tower +1 dmg (+1) to (Attacking unit)
      • Unit - Set level of Ultimate Lightning Tower +1 dmg (+1) for (Attacking unit) to 2
      • Unit - Remove Ultimate Lightning Tower +1 dmg (+1) from (Attacking unit)


Ability was:

level 1 = 0dmg
level 2 = 1dmg

and

level 1 = 0dmg
level 2 = -1dmg

None worked. Any clue how to get that done?

What exactly do you need? Cause I'm having a bit of trouble understanding what you want to achieve. :p

- If you want the tower to deal damage +1 just add a Item attack bonus ability to it.

- If you want the tower to deal +1 damage on each attack upgrade the level each attack using a trigger, or use Incinerate (Neutral Hostile).

- If you want it to have a chance to deal more damage use Bash or Critical Strike.

- If you want it to deal more damage only to player 1, you'd have to use waits or such, though I'd suggest you just use the "Cause attacking unit to damage Attacked unit for 1.

Why doesn't the trigger work?
Trigger:
  • Unit - A unit Is attacked

Works when the unit is about to attack, not when it attacks. So when it's about to attack it will: Get the ability but it'll get removed before the unit attacks.
- You Order the attack.
- Aim, Ready andd
- Gets ability
- Removes ability
- FIREEE!!!!
- BOOM!
Like that...
 

hopy

Active Member
Reaction score
64
Trigger:
  • Im overpowered at the end of the map
    • Events
      • Unit - A unit Is attacked
    • Conditions
      • (Unit-type of (Attacking unit)) Equal to Ultimate Lightning Tower
      • ((Attacked unit) belongs to an enemy of Player 1 (Red)) Equal to True
    • Actions
      • Unit - Set level of Ultimate Lightning Tower for (Attacking unit) to ((Level of Ultimate Lightning Tower for (Attacking unit)) + 1)


That should be ok, just make sure that the tower has the ability Ultimate Lightning Tower.
A small problem with this is that the ability would have a massive amount of levels... A way to avoid that is to use "Damage attacked unit for Intreger" and increase Intreger+1 every time he attacks, with an Array in case you'll have multiple of these units.
 

FannyShaver

Well-Known Member
Reaction score
31
This what you gave me requires even thousands of levels for this ability. I need another idea.
 

Nherwyziant

Be better than you were yesterday :D
Reaction score
96
You can use the upgrade. In trigger, upgrade's max can be increased. But this upgrade will affect other towers of this player that has this upgrade. There's no other way to make a bonus damage for a single tower if not using the bonus damage spell and leveling it to something high. But if it's only 1 per player then, you can use the upgrade :thup:

Trigger:
  • Actions
    • Set IntegerX = (IntegerX + 1)
    • Player - Set the max research level of Storm Hammers to (IntegerX + 1) for (Owner of (Triggering unit))
    • Player - Set the current research level of Storm Hammers to IntegerX for (Owner of (Triggering unit))
    • -------- The Storm Hammer should be the upgrade that gives bonus damage----------


NOTE: Also, do not use A Unit is Attacked event, cuz players can press "S" or stop to gain damage faster. Use damage detection
 

X-maul

AKA: Demtrod
Reaction score
201
You can use the upgrade. In trigger, upgrade's max can be increased. But this upgrade will affect other towers of this player that has this upgrade. There's no other way to make a bonus damage for a single tower if not using the bonus damage spell and leveling it to something high. But if it's only 1 per player then, you can use the upgrade :thup:

An upgrade would diffinitly be the solution, but you can just create a new upgrade, and aply it to that single tower, and give it.. 100 levels (think thats the max) and apply the bonus you like

then you increase it 1 level for every shot.
 

FannyShaver

Well-Known Member
Reaction score
31
I am trying now with providing an inventory slot, giving it a permament damage increase +1 tome, and removing inv slot. Problem is, that terrain around it might be pretty blocked. 100 levels is not enough ;) Erm well, I think I can get more than 100 levels...
 

FannyShaver

Well-Known Member
Reaction score
31
Well, I tried that:

Trigger:
  • Lightning Tower Attack
    • Events
      • Unit - A unit Is attacked
    • Conditions
      • (Unit-type of (Attacking unit)) Equal to Lightning Tower
      • ((Attacked unit) belongs to an enemy of Player 1 (Red)) Equal to True
    • Actions
      • Player - Set the max research level of Lightning Power to 200 for (Owner of (Attacking unit))
      • Player - Set the current research level of Lightning Power to ((Current research level of Lightning Power for (Owner of (Attacking unit))) + 1) for (Owner of (Attacking unit))


Doesn't work.
 

FannyShaver

Well-Known Member
Reaction score
31
The function:

Trigger:
  • Player - Set the max research level of Lightning Power to (dupa + 1) for (Owner of (Attacking unit))


Doesn't work at all.
 

Sgqvur

FullOfUltimateTruthsAndEt ernalPrinciples, i.e shi
Reaction score
62
Laiev:
Haha, welcome to the Warcraft World, wheres everything is limited without reason lol
Unfortunately its true...

Gotta be mad at blizzard not making a function to do that(increasing units properties) right?

If you really want this to work the you have to do(I think this is the easiest way to do this):

1. Go here and download newgen if you don't have it -> newgen
2. Go here and download Unit Properties -> unit properties
3. then use custom script: call UnitModifyDamage(GetAttacker(), 1)
 

xAnaMorphine

Active Member
Reaction score
43
nothing to do, i attached a map witch solves the problem imo
 

Attachments

  • TD_AttackGrow.w3x
    13.7 KB · Views: 210

FannyShaver

Well-Known Member
Reaction score
31
Erm. Right. I've got it working, but:

I was hoping it's gonna get that damage fit into base damage, not as a bonus, as I have another bonus running, and this (+1) is not affected by another bonus :/
 

Sgqvur

FullOfUltimateTruthsAndEt ernalPrinciples, i.e shi
Reaction score
62
Hope this is what you wanted -> see the attached map

You could check DotU's official site www.playdotu.com also.
 

Attachments

  • PDG inspired by DotU.w3x
    19.7 KB · Views: 235

FannyShaver

Well-Known Member
Reaction score
31
Did you actually tried that map before you pasted? I had to add another player to see that no damage is added to this tower.
 

Grymlax

Probably not around
Reaction score
138
Adding an inventory slot is the way to go if you don't want it to be green bonus damage. here is a test map I made for you that is mui.


these are the triggers in the map.

Trigger:
  • bonus dmg
    • Events
      • Unit - A unit Is attacked
    • Conditions
      • (Unit-type of (Attacking unit)) Equal to damage gain
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • ((Attacking unit) is in avoidAbuse) Equal to True
        • Then - Actions
          • Unit Group - Remove (Attacking unit) from avoidAbuse
        • Else - Actions
          • Unit - Add Inventory (Hero) to (Attacking unit)
          • Hero - Create +1 damage tome and give it to (Attacking unit)
          • Unit - Remove Inventory (Hero) from (Attacking unit)


Damage gain is the name of the tower and +1 damage tome is just a tome which I gave a modified version of the ability "item permanent damage gain"

Trigger:
  • avoid abuse
    • Events
      • Unit - A unit Is issued an order with no target
      • Unit - A unit Is issued an order targeting an object
    • Conditions
      • (Unit-type of (Triggering unit)) Equal to damage gain
    • Actions
      • Unit Group - Add (Triggering unit) to avoidAbuse


If you didn't have this trigger you could spam stop or order the tower to attack another unit which would restart an attack resulting in more damage for the tower.

well thats about it here is the map:
 

Attachments

  • towerdmg.w3x
    17.8 KB · Views: 219
General chit-chat
Help Users
  • No one is chatting at the moment.
  • The Helper The Helper:
    The bots will show up as users online in the forum software but they do not show up in my stats tracking. I am sure there are bots in the stats but the way alot of the bots treat the site do not show up on the stats
  • Varine Varine:
    I want to build a filtration system for my 3d printer, and that shit is so much more complicated than I thought it would be
  • Varine Varine:
    Apparently ABS emits styrene particulates which can be like .2 micrometers, which idk if the VOC detectors I have can even catch that
  • Varine Varine:
    Anyway I need to get some of those sensors and two air pressure sensors installed before an after the filters, which I need to figure out how to calculate the necessary pressure for and I have yet to find anything that tells me how to actually do that, just the cfm ratings
  • Varine Varine:
    And then I have to set up an arduino board to read those sensors, which I also don't know very much about but I have a whole bunch of crash course things for that
  • Varine Varine:
    These sensors are also a lot more than I thought they would be. Like 5 to 10 each, idk why but I assumed they would be like 2 dollars
  • Varine Varine:
    Another issue I'm learning is that a lot of the air quality sensors don't work at very high ambient temperatures. I'm planning on heating this enclosure to like 60C or so, and that's the upper limit of their functionality
  • Varine Varine:
    Although I don't know if I need to actually actively heat it or just let the plate and hotend bring the ambient temp to whatever it will, but even then I need to figure out an exfiltration for hot air. I think I kind of know what to do but it's still fucking confusing
  • The Helper The Helper:
    Maybe you could find some of that information from AC tech - like how they detect freon and such
  • Varine Varine:
    That's mostly what I've been looking at
  • Varine Varine:
    I don't think I'm dealing with quite the same pressures though, at the very least its a significantly smaller system. For the time being I'm just going to put together a quick scrubby box though and hope it works good enough to not make my house toxic
  • Varine Varine:
    I mean I don't use this enough to pose any significant danger I don't think, but I would still rather not be throwing styrene all over the air
  • The Helper The Helper:
    New dessert added to recipes Southern Pecan Praline Cake https://www.thehelper.net/threads/recipe-southern-pecan-praline-cake.193555/
  • The Helper The Helper:
    Another bot invasion 493 members online most of them bots that do not show up on stats
  • Varine Varine:
    I'm looking at a solid 378 guests, but 3 members. Of which two are me and VSNES. The third is unlisted, which makes me think its a ghost.
    +1
  • The Helper The Helper:
    Some members choose invisibility mode
    +1
  • The Helper The Helper:
    I bitch about Xenforo sometimes but it really is full featured you just have to really know what you are doing to get the most out of it.
  • The Helper The Helper:
    It is just not easy to fix styles and customize but it definitely can be done
  • The Helper The Helper:
    I do know this - xenforo dropped the ball by not keeping the vbulletin reputation comments as a feature. The loss of the Reputation comments data when we switched to Xenforo really was the death knell for the site when it came to all the users that left. I know I missed it so much and I got way less interested in the site when that feature was gone and I run the site.
  • Blackveiled Blackveiled:
    People love rep, lol
    +1
  • The Helper The Helper:
    The recipe today is Sloppy Joe Casserole - one of my faves LOL https://www.thehelper.net/threads/sloppy-joe-casserole-with-manwich.193585/
  • The Helper The Helper:
    Decided to put up a healthier type recipe to mix it up - Honey Garlic Shrimp Stir-Fry https://www.thehelper.net/threads/recipe-honey-garlic-shrimp-stir-fry.193595/
  • The Helper The Helper:
    Here is another comfort food favorite - Million Dollar Casserole - https://www.thehelper.net/threads/recipe-million-dollar-casserole.193614/

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top