1. Are you planning to upload your awesome spell or system to Hive? Please review the rules here.
    Dismiss Notice
  2. Updated Resource Submission Rules: All model & skin resource submissions must now include an in-game screenshot. This is to help speed up the moderation process and to show how the model and/or texture looks like from the in-game camera.
    Dismiss Notice
  3. DID YOU KNOW - That you can unlock new rank icons by posting on the forums or winning contests? Click here to customize your rank or read our User Rank Policy to see a list of ranks that you can unlock. Have you won a contest and still havn't received your rank award? Then please contact the administration.
    Dismiss Notice
  4. The Lich King demands your service! We've reached the 19th edition of the Icon Contest. Come along and make some chilling servants for the one true king.
    Dismiss Notice
  5. The 4th SFX Contest has started. Be sure to participate and have a fun factor in it.
    Dismiss Notice
  6. The poll for the 21st Terraining Contest is LIVE. Be sure to check out the entries and vote for one.
    Dismiss Notice
  7. The results are out! Check them out.
    Dismiss Notice
  8. Don’t forget to sign up for the Hive Cup. There’s a 555 EUR prize pool. Sign up now!
    Dismiss Notice
  9. The Hive Workshop Cup contest results have been announced! See the maps that'll be featured in the Hive Workshop Cup tournament!
    Dismiss Notice
  10. Check out the Staff job openings thread.
    Dismiss Notice
Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.

Blind Version 1.1.0

Submitted by BunnyAng, Daffa the Mage
This bundle is marked as approved. It works and satisfies the submission rules.
Introduction
This spell was requested by BunnyAng at Kawaii Spell Workshop.
I was the one who handle the request.
Permission for upload can be found Here

Trigger
Triggers
  • Blind Config
    • Events
      • Map initialization
    • Conditions
    • Actions
      • -------- Important Stuff! Setup them correctly! --------
      • Set BL_BlindAbility = Blind
      • Set BL_BlindAbilityVisionReducer = Blind Vision
      • Set BL_BlindAbilityDisableAttack = Blind Disable
      • Set BL_BlindDebuffAbility = Blind Debuff
      • Set BL_BlindDebuff = Blind
      • Set BL_DummyType = Dummy
      • -------- Customizable Effects --------
      • -------- Blinded unit can't attack (disables Confuse) --------
      • Set BL_BlindDisablesAttack = True
      • -------- Blinded unit takes more X damage from Y attack type --------
      • Set BL_BlindIncreaseMagicalDamage = True
      • Set BL_BlindIncreasePhysicalDamage = True
      • Set BL_BlindIncreaseTriggerDamage = True
      • -------- Blinded unit may attack allies or enemies (completely random) --------
      • Set BL_BlindConfuseTargetAttack = False
      • -------- Confusion Range (ConfuseTargetAttack must be true) --------
      • Set BL_ConfusionRange = 600.00
      • -------- New Damage Rate --------
      • Set BL_MagicalRate = 1.25
      • Set BL_PhysicalRate = 1.75
      • Set BL_TriggeredRate = 1.25
      • Set BL_ShowNewDamageRateText = True
      • -------- Duration of Blind --------
      • Set BL_BlindDuration[1] = 1.00
      • Set BL_BlindDuration[2] = 2.00
      • Set BL_BlindDuration[3] = 3.00
      • Set BL_BlindDuration[4] = 4.00
      • -------- END CONFIG --------
      • Custom script: set udg_BL_BlindLoopSpeed = 0.03125
      • Trigger - Add to Blind Loop <gen> the event (Time - Every BL_BlindLoopSpeed seconds of game time)
      • -------- Securities (Avoid unwated behaviors) --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • BL_BlindIncreasePhysicalDamage Equal to False
          • BL_BlindIncreaseMagicalDamage Equal to False
          • BL_BlindIncreaseTriggerDamage Equal to False
        • Then - Actions
          • Set BL_ShowNewDamageRateText = False
          • Trigger - Turn off Blind Damage Text <gen>
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • BL_BlindDisablesAttack Equal to True
        • Then - Actions
          • Set BL_BlindConfuseTargetAttack = False
        • Else - Actions

  • Blind Cast
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to BL_BlindAbility
    • Actions
      • Set BL_CastingUnit = (Triggering unit)
      • Set BL_TargetUnit = (Target unit of ability being cast)
      • Set TargetValue = (Custom value of BL_TargetUnit)
      • Set HeroLevel = (Level of BL_BlindAbility for BL_CastingUnit)
      • Set BL_BlindedUnitDuration[TargetValue] = BL_BlindDuration[HeroLevel]
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (BL_TargetUnit has buff BL_BlindDebuff) Equal to True
        • Then - Actions
          • Skip remaining actions
        • Else - Actions
      • Unit - Add BL_BlindAbilityVisionReducer to BL_TargetUnit
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • BL_BlindDisablesAttack Equal to True
        • Then - Actions
          • Unit - Add BL_BlindAbilityDisableAttack to BL_TargetUnit
        • Else - Actions
      • Set BL_TempPoint = (Position of BL_CastingUnit)
      • Unit - Create 1 BL_DummyType for (Owner of BL_CastingUnit) at BL_TempPoint facing Default building facing degrees
      • Custom script: call RemoveLocation(udg_BL_TempPoint)
      • Set BL_BlindDummy = (Last created unit)
      • Unit - Add BL_BlindDebuffAbility to BL_BlindDummy
      • Unit - Order BL_BlindDummy to Undead Banshee - Curse BL_TargetUnit
      • Unit - Add a 1.00 second Generic expiration timer to BL_BlindDummy
      • Unit Group - Add BL_TargetUnit to BL_BlindGroup
      • Set BL_Counter = (BL_Counter + 1)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • BL_Counter Equal to 1
        • Then - Actions
          • Trigger - Turn on Blind Loop <gen>
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • BL_BlindConfuseTargetAttack Equal to True
        • Then - Actions
          • Set BL_TempPoint = (Position of BL_TargetUnit)
          • Set BL_RandomTargetGroup = (Units within BL_ConfusionRange of BL_TempPoint)
          • Set BL_RandomTarget = (Random unit from BL_RandomTargetGroup)
          • Unit - Order BL_TargetUnit to Attack BL_RandomTarget
          • Custom script: call RemoveLocation(udg_BL_TempPoint)
          • Custom script: call DestroyGroup(udg_BL_RandomTargetGroup)
        • Else - Actions

  • Blind Loop
    • Events
    • Conditions
    • Actions
      • Unit Group - Pick every unit in BL_BlindGroup and do (Actions)
        • Loop - Actions
          • Set BL_TargetUnit = (Picked unit)
          • Set TargetValue = (Custom value of BL_TargetUnit)
          • Set BL_BlindedUnitDuration[TargetValue] = (BL_BlindedUnitDuration[TargetValue] - BL_BlindLoopSpeed)
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • BL_BlindedUnitDuration[TargetValue] Less than or equal to 0.00
            • Then - Actions
              • Set BL_TargetUnit = (Picked unit)
              • Unit Group - Remove BL_TargetUnit from BL_BlindGroup
              • Set BL_Counter = (BL_Counter - 1)
              • Unit - Remove BL_BlindAbilityVisionReducer from BL_TargetUnit
              • Unit - Remove BL_BlindDebuff buff from BL_TargetUnit
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • BL_BlindDisablesAttack Equal to True
                • Then - Actions
                  • Unit - Remove BL_BlindAbilityDisableAttack from BL_TargetUnit
                • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • BL_BlindConfuseTargetAttack Equal to True
                • Then - Actions
                  • Unit - Order BL_TargetUnit to Stop
                • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • BL_Counter Equal to 0
                • Then - Actions
                  • Trigger - Turn off Blind Loop <gen>
                • Else - Actions
            • Else - Actions

  • Blind Damage Text
    • Events
      • Game - damageEventTrigger becomes Equal to 1.00
    • Conditions
      • ((Triggering unit) has buff BL_BlindDebuff) Equal to True
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • damageType Equal to PHYSICAL
          • BL_BlindIncreasePhysicalDamage Equal to True
        • Then - Actions
          • Set amount = (amount x BL_PhysicalRate)
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • damageType Equal to SPELL
              • BL_BlindIncreaseMagicalDamage Equal to True
            • Then - Actions
              • Set amount = (amount x BL_MagicalRate)
            • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • damageType Equal to CODE
                  • BL_BlindIncreaseTriggerDamage Equal to True
                • Then - Actions
                  • Set amount = (amount x BL_TriggeredRate)
                • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • BL_ShowNewDamageRateText Equal to True
        • Then - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • damageType Equal to PHYSICAL
            • Then - Actions
              • Floating Text - Create floating text that reads (String((Integer(amount)))) above target with Z offset 0.00, using font size 10.00, color (100.00%, 0.00%, 0.00%), and 0.00% transparency
            • Else - Actions
              • Floating Text - Create floating text that reads (String((Integer(amount)))) above target with Z offset 0.00, using font size 10.00, color (0.00%, 0.00%, 100.00%), and 0.00% transparency
          • Set BL_LastFloatingText = (Last created floating text)
          • Floating Text - Set the velocity of BL_LastFloatingText to 64.00 towards 90.00 degrees
          • Floating Text - Change BL_LastFloatingText: Disable permanence
          • Floating Text - Change the fading age of BL_LastFloatingText to 4.00 seconds
          • Floating Text - Change the lifespan of BL_LastFloatingText to 6.00 seconds
        • Else - Actions


Changelogs
Version 1.1.0 :
Fixed everything mentioned in Post #17
Older Versions

Version 1.0.0 :
First Upload


Credits
BunnyAng : Requester - Giving Permission
Malhorne : Kawaii Spell Workshop Owner
Bribe : Unit Indexer GUI
looking_for_help : DamageEvent Jass

Keywords:
Blind, Paladin, Charm, Confusion, Confuse, Confusia, Hypnosis, Unable, Inability, Attack, Limited, Archmage
Contents

Blind (Map)

Reviews
Moderator
07:45, 13th Jun 2014 BPower: Changes mentioned are made. Approved. 12:43, 21st May 2014 PurgeandFire: Review: http://www.hiveworkshop.com/forums/2529843-post17.html
  1. 07:45, 13th Jun 2014
    BPower:
    Changes mentioned are made. Approved.

    12:43, 21st May 2014
    PurgeandFire: Review:
    http://www.hiveworkshop.com/forums/2529843-post17.html
     
  2. Daffa the Mage

    Daffa the Mage

    Map Moderator

    Joined:
    Jan 30, 2013
    Messages:
    7,685
    Resources:
    27
    Packs:
    1
    Maps:
    8
    Spells:
    16
    Tutorials:
    2
    Resources:
    27
    Wow, quite a low size for a spell.
    Never thought of that.
     
  3. BunnyAng

    BunnyAng

    Joined:
    Jun 9, 2012
    Messages:
    824
    Resources:
    1
    Spells:
    1
    Resources:
    1
    Ahh you uploaded it at last. Good job on the spell.
     
  4. ukn0wnD3str0y3r

    ukn0wnD3str0y3r

    Joined:
    Feb 15, 2013
    Messages:
    367
    Resources:
    3
    Maps:
    1
    Spells:
    2
    Resources:
    3
    Where is my requested spells?
     
  5. Quilnez

    Quilnez

    Joined:
    Oct 12, 2011
    Messages:
    3,258
    Resources:
    37
    Icons:
    2
    Tools:
    1
    Maps:
    7
    Spells:
    21
    Tutorials:
    2
    JASS:
    4
    Resources:
    37
    after reading the configuration, I think I like the concept, code looks perfect, I can't find anything's wrong. Except this:
    • Unit - Order BlindDummy to Undead Banshee - Curse TargetUnit
    I'm not sure but I think the order need to be stored in variable. Just wait for other's opinion.

    Good job ! I haven't checked the object editor data, but seeing from the code, I vote for quick approval
     
  6. Wrda

    Wrda

    Joined:
    Nov 18, 2012
    Messages:
    1,123
    Resources:
    3
    Maps:
    1
    Spells:
    2
    Resources:
    3
    I don't think its needed a variable for that :b also, it's nearly 2 bytes of a crappy variable.
    But I think it should be only a dummy for the debuff, do it at the init trigger :p.
    Also, the spell can get messy if cast constantly (in terms of whether being able to attack or not).
    4/5 good work :thumbs_up:
     
  7. ILH

    ILH

    Joined:
    May 8, 2012
    Messages:
    608
    Resources:
    16
    Models:
    14
    Icons:
    1
    Tutorials:
    1
    Resources:
    16
    Lol.

    Hey, good job daffa!:thumbs_up:
     
  8. Daffa the Mage

    Daffa the Mage

    Map Moderator

    Joined:
    Jan 30, 2013
    Messages:
    7,685
    Resources:
    27
    Packs:
    1
    Maps:
    8
    Spells:
    16
    Tutorials:
    2
    Resources:
    27
    Thanks a lot! :)

    Which one? I'll take a look at the workshop, I' hope you're aware I was busy with exams.

    Thanks, I must admit it's not the best actually.
    That one shouldn't need to be in a variable, there's no way users can modify the curse orderId.

    Yep, it's a crap.
    Yeah, perhaps I manipulate it a little so only one dummy used.
    For the constant spam, I'm sure it shouldn't be much of an issue.

    Thanks!
     
  9. Quilnez

    Quilnez

    Joined:
    Oct 12, 2011
    Messages:
    3,258
    Resources:
    37
    Icons:
    2
    Tools:
    1
    Maps:
    7
    Spells:
    21
    Tutorials:
    2
    JASS:
    4
    Resources:
    37
    wait, I think the order DOES need to be stored into variable and added to configuration part, in case user has another "Channel" ability with same order id, it will bugged if user can't configure.. please fix it. ;) still haven't check the file though

    also every aspect of floating text should be configurable (fading age, lifespan, size, etc.)
     
  10. Daffa the Mage

    Daffa the Mage

    Map Moderator

    Joined:
    Jan 30, 2013
    Messages:
    7,685
    Resources:
    27
    Packs:
    1
    Maps:
    8
    Spells:
    16
    Tutorials:
    2
    Resources:
    27
    The dummy is by default using it.
    The only purpose for the dummy is for the buff.

    I'll fix the floating text ASAP.
     
  11. Wrda

    Wrda

    Joined:
    Nov 18, 2012
    Messages:
    1,123
    Resources:
    3
    Maps:
    1
    Spells:
    2
    Resources:
    3
    The "ability" you are talking about is the dummy's one, it's based on curse, so what you just said doesn't make sense.
     
  12. Quilnez

    Quilnez

    Joined:
    Oct 12, 2011
    Messages:
    3,258
    Resources:
    37
    Icons:
    2
    Tools:
    1
    Maps:
    7
    Spells:
    21
    Tutorials:
    2
    JASS:
    4
    Resources:
    37
    I know you noticed that part so why you deleted it from your quote? I said it because I had reason: I haven't opened the file. your post 10x makes no sense sir.
     
    Last edited: May 13, 2014
  13. Wrda

    Wrda

    Joined:
    Nov 18, 2012
    Messages:
    1,123
    Resources:
    3
    Maps:
    1
    Spells:
    2
    Resources:
    3
    That is irrelevant, you don't need to check the file to see if it's based on curse or not, and it is a dummy ability, why should it be channel-based?
    Anyway, I'm not going to argue about this stupid thing.
     
  14. IcemanBo

    IcemanBo

    Joined:
    Sep 6, 2013
    Messages:
    6,166
    Resources:
    22
    Maps:
    3
    Spells:
    11
    Template:
    1
    Tutorials:
    4
    JASS:
    3
    Resources:
    22
    Why it only can be used on heroes? It didn't work for me when I tried it on a normal unit.

    In your trigger "Blind Loop": You store "Picked unit" twice into a variable if the first condition is true.

    First you do:
    • Set BlindConfuseTargetAttack = False

    And then you check a boolean and would also set it to false, that doesnt make sense:
    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      • 'IF'-Bedingungen
        • BlindDisablesAttack == True
      • Then - Actions
        • Set BlindConfuseTargetAttack = False
      • Else - Actions

    And anyway don't set it before, if you later check a boolean to possibly set it to an other value. You could take usage of the "Else" here.

    Same you do with "ShowNewDamageRateText":
    • Set ShowNewDamageRateText = True
    • ...
    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      • 'IF'-Bedingungen
        • BlindIncreasePhysicalDamage == False
        • BlindIncreaseMagicalDamage == False
        • BlindIncreaseTriggeredDamage == False
      • Then - Actions
        • Trigger - Turn off Blind Damage Text <gen>
        • Set ShowNewDamageRateText = False
      • Else - Actions


    Personally I prefer indexing instead of UnitGroups, but I think it's ok here.
    Anyway I think using a counter for instances is better to check instead of using the function "Number of Units in Group" so often. (to turn trigger on/off)
    Using the count function is less efficient.

    Furthermore I think throwing a flashbang or something similar would improve the realistic near a lot, instead of casting an instant spell without any projectile graphics.

    Else it worked fine. Code is not very complex, but once all works properly it might be useful. :csmile: (no rating yet)
     
  15. Daffa the Mage

    Daffa the Mage

    Map Moderator

    Joined:
    Jan 30, 2013
    Messages:
    7,685
    Resources:
    27
    Packs:
    1
    Maps:
    8
    Spells:
    16
    Tutorials:
    2
    Resources:
    27
    I'll split your post for easy answer.

    It was the intention :p
    Maybe I'll make it available for units too :)

    Thanks for informing, I'll make a check and fix it.

    It was a security measure, since if Blind disables attack, there's no need for target to get confused. (He/she already can't attack :p)

    It's also for security measures, I don't want unwanted operations here :D

    I guess you're right, it can help a lot. I haven't remember the inefficiency (haven't been triggering for a while, so forget some of it).

    I'll check the Model Section, perhaps some useful model can be found there (else I'll try to make one)

    Thanks :)
    I'm not a fan of super hard coding spells, I won't make long codes unless necessary.
     
  16. IcemanBo

    IcemanBo

    Joined:
    Sep 6, 2013
    Messages:
    6,166
    Resources:
    22
    Maps:
    3
    Spells:
    11
    Template:
    1
    Tutorials:
    4
    JASS:
    3
    Resources:
    22
    Just a short statement to the booleans "BlindConfuseTargetAttack" and "ShowNewDamageRateText":

    The parser anyway gets to the If/Then/Else part, so it's kind of redundant to set the boolean before. You could only set it in the 'Then' and 'Else' part. :)
     
  17. PurgeandFire

    PurgeandFire

    Code Moderator

    Joined:
    Nov 11, 2006
    Messages:
    7,426
    Resources:
    18
    Icons:
    1
    Spells:
    4
    Tutorials:
    9
    JASS:
    4
    Resources:
    18
    First things first: I like the idea, and it seems to perform quite well in game.

    Review:
    • Your ability should untick "Disable Other Abilities" in the object editor.
    • Set the button position to something other than (2, 0). (if you try casting blind on your own hero, the button will jump to the attack's button position)
    • Your variables should be prefixed. e.g. CastingUnit -> B_CastingUnit, or better yet, BL_CastingUnit (it is usually more common to have two letters as a prefix). This will prevent collisions.
    • Keep track of the units in the group with a variable instead of using "Number of units in <Group>" (that function will iterate through the entire group to count the units). Whenever you add a unit to the BlindGroup, just increment it. Whenever you remove one, decrement it:
      • Unit Group - Add BL_TargetUnit to BL_Group
      • Set BL_GroupCount = BL_GroupCount + 1

      • Unit Group - Remove BL_TargetUnit from BL_Group
      • Set BL_GroupCount = BL_GroupCount - 1
    • In the "Blind Cast" trigger, you should check if the unit already has the Blind debuff. That way, you can just update the Blind duration value and then skip remaining actions.
      • Set BlindedUnitDuration[TargetValue] = BlindDuration[HeroLevel]
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • BL_TargetUnit has buff BlindDebuff
        • Then - Actions
          • Skip Remaining Actions
        • Else - Actions

      That way, you don't go through a whole bunch of extra steps. I think. You might have to try it out and see if it works. It works in my head, but I can't be sure.

    Otherwise, it is a nice spell. I like how compact it is, and it makes great use of the damage modification offered by lfh's damage library, as well as the default wc3 abilities. Nice job! Make those changes, and it should be approvable.
     
  18. Daffa the Mage

    Daffa the Mage

    Map Moderator

    Joined:
    Jan 30, 2013
    Messages:
    7,685
    Resources:
    27
    Packs:
    1
    Maps:
    8
    Spells:
    16
    Tutorials:
    2
    Resources:
    27
    Thanks, these will be applied within this week (hopefully).
     
  19. GywGod133

    GywGod133

    Joined:
    Jul 16, 2012
    Messages:
    633
    Resources:
    3
    Maps:
    1
    Spells:
    1
    Tutorials:
    1
    Resources:
    3
    :D you use 0.03125 sec
    hihi