Hi GiL!

What could be the reason that my enemies sometimes double hit with the Basic Attack? My feeling was that it could be something with the size of the damage dealers?

Best regards!

/Thrilled
  • I'd say it has something to do with your setup :)

    If your damage dealer has One Time Damage enabled, it can only damage one time per being activated.

    Other things to check:
    - is the battle event added twice to the ability
    - is the target status change added twice
    - etc.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Well...

    Yes the damage dealer does have "One Time Damage" enabled and "One Target" enabled.

    What does the base attack/counter attack under the damage dealer do?

    It uses a battle event called standardAttack and it's only added once on the ability.

    image

    No status effects added through the ability.

    The damage calculation is done by Target Changes on the ability which uses a formula that is working as it should.

    Any more ideas what it could be?
  • edited September 2015
    Well - you say you're using damage dealers?
    There's a Calculate step in your event, i.e. that's where the abiltiy's target status changes are calculated (i.e. it'll do damage here). If you additionally use damage dealers (since there's no step for activating damage dealers, I assume it's done through auto activation using tags), the damage dealer will do a 2nd damage when it hit a damage zone of an enemy.

    In short: either use a Calculate step or damage dealers for doing damage :)
    Post edited by gamingislove on
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • edited September 2015
    Hehe I figured you would say that... that's why I posted the image along... I wasn't completely sure myself.

    Ok I will remove the calculate step :)

    ** Edit **

    When I look at the battle event above.... how will the sounds and particles be played if I remove the calculate step? I mean how is the hit and miss being detected and thus the correct sounds and particles applied?
    Post edited by thrilled on
  • There are settings for that in the ability's damage dealer settings (when using auto activation) and in the Activate Damage Dealer step.

    Optionally, you can also use battle events to animate the damage dealer's damage (when hitting an enemy), where you'd use a Calculate step to do the damage and spawn prefabs how you need.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • edited October 2015
    Not sure that I get understand you here GiL...

    Ie if I under my ability change the event to NOT include the calculate step (just using the play animation and delay), then the goblin will swing all the time but no damage calculations will be done at all.

    Then I tried to add the Calculate Step in an own event which I saved and then used that event under the animate settings in the Damage Dealer Setting. Then the goblin still swings but again no calculate is being done :(

    So I now decided to try to disable the animate step under Animation Settings and only keep the Damage Dealer Settings. Well now it will calculate but instead not play the animation *grrr*. So it seem to me that as soon I have Animate under the Animation Settings activated then it will take priority over the damage dealer settings animate.

    Could you guide me more what I should do here?

    Something feels a bit weird to be honest since in my mind I thought it would be the damage dealer entering the damage zone that trigger the calculation, but why do I get a calculation when I don't get the animation running as mentioned above?

    I am beginning to think that the damage dealer isn't working as intended (maybe misconfiguration, although I have used you tutorial in the beginning). I have an autocombat settings enabled on the combatants set to start at 2 units distance, this one is very much needed for me though ;)

    Any insight here is most gratefully accepted!

    * Edit* How would I do to just use a battle event for the whole thing? Instead of using Auto Activate and to get the damage calc to work as I expect.
    Post edited by thrilled on
  • Adding more details of the current setup:

    Damage dealer on goblin is set to "Trigger Enter", it's set to Real Time Battles only, One Target and One Time Damage is enabled. Tag is Weapon. The collider for the weapon is correct located around the weapon itself.

    The Basic Attack is using the tag weapon in Damage Dealer Settings. It's also using the event that I posted as a picture above ( set under Animation Settings-->Animate). The event itself has autoactive damage dealer enabled.

    The damage zone is added to the root object of my player character.

    With this and just by removing the calculate step from the event above then I only get the animation and no calculations at all.



  • Did a quick test and works just fine here - the ability is animated and the damage dealer does additional stuff (and calculates the damage) using battle events.

    If you disable the animation of the ability, the ability will just be calculated - there's no damage dealer used, since that'd require the battle events to activate it.

    Make sure the battle event animating the ability activate the damage dealer - either through the auto activation or an Activate Damage Dealer step. The auto activation only works if the damage dealer is on the user's game object (e.g. through a weapon of an equipment viewer). Also, check if the tags on the damage dealer and the ability match.

    If you're using the Animate settings in the ability's damage dealer settings, make sure you're using the correct event and the used battle system type is enabled.
    You can test if the damage dealer does damage without animating by disabling the Animate option in the damage dealer settings. If that's not working as well, your damage dealer is probably not activated or deactivated before hitting anything.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Hi GiL!

    Thanks for the replies...

    Well I did follow your tutorial when I set up the damage dealers.

    The battle event used is the exact one as you can see on the screenshot above in the thread. It is using Auto Activate Damage Dealers on the settings. Should I remove the calculate steps and other nodes connected to that?

    Regarding the Damge Dealer on the object I will add screenshot..

    image

    The tag on the ability is weapon and the tag on the damage dealer is weapon

    If I remove the calculate step and the nodes connected to it so I only have the play animation and wait node left (with the autoactivate damage dealer enabled). Then I only use this battle event as animate on the ability and no animate at all on Damage Dealer settings. If I then run the project then the goblin will make the animation but no calculation will happen. I am am running the full battle event without removing the calculate step then everything is working just fine except that the goblin sometimes double hit (which I obviously want to get rid off).

  • Ok I got some steps further....

    For some reason if I disabled the AutoActivate Damage Dealer on settings on my Animate BattleEvent and instead added a Activate Damage Dealer node at the end then it's working.

    See screenshot of this event below:

    image

    Since I then do not have any particles effects when being hit then I added the following to the Animate under Damage Dealer Settings:

    image

    This results in having the goblin to now only hit ONCE (goodie) and it will emit particles and play sound when it hits (good).....

    Now the bad... it ALSO plays a hit sound and emit particles on misses.

    So basically two questions here:

    How can I get it to actually stop playing hit sound and emit particles on misses? I thought I had that specified in my battleevent.

    Why doesn't it work for me when I have AutoActivate Damage Dealers enabled on settings, but it's working when I manually add the Activate Damage Dealer node on the event? Can it be because the damage dealer is on a childnode?

    Best regards!

    /Thrilled
  • Since you activate the damage dealer at the end and don't deactivate it, I'd guess that your event's duration is too short for the damage dealer to hit the target while it's activated - thus the auto activation (which automatically activates at the start and deactivates at the end of the event) isn't damaging the target.
    You should add a bigger wait time that matches the attack animation (or when using legacy animations, use the Wait option in the animation step).

    For the sound and effect - make sure you don't have sound/prefab set up in the damage dealer settings of the ability or the activation step.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Hi as I mentioned, I have deactivated the auto activate damage dealer on the event since I have an activate damage dealer node at the end.

    Also the animation wait time that's there is already matched with the animation so that the animation reaches the "the perfect hit point" before the event proceeds.

    No sound prefabs on either the damage dealer settings of the ability or the Activate Damage Dealer step.

    I have done some changes... I added the activate damage dealer right after settings and then ended the whole event with a deactivate damage dealers. That works just fine too..

    I also think there is something weird going on with the calculate node... since if I remove the connection from the next on the calculate node then I ofc do not get any hit sound and particles effects, but also when missing then the annoying hit sound and particles effects are also gone. However it's not playing the sound that I have instructed to happen when the calculate gives a miss. So for some reason it seems that it takes the path of "next" on both misses and hits.
  • Ok, seems like Calculate in battle events used for damage dealers don't get the calculation results to decide the next step, will fix that in the next update :)
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Thanks - that makes sense ;)
Sign In or Register to comment.