1. A slave to two rhythms, the 22nd Terraining Contest is here.
    Dismiss Notice
  2. The heavens smile on the old faithful. The 16th Techtree Contest has begun.
    Dismiss Notice
  3. The die is cast - the 6th Melee Mapping Contest results have been announced. Onward to the Hive Cup!
    Dismiss Notice
  4. The glory of the 20th Icon Contest is yours for the taking!
    Dismiss Notice
  5. Shoot to thrill, play to kill. Sate your hunger with the 33rd Modeling Contest!
    Dismiss Notice
  6. Do you hear boss music? It's the 17th Mini Mapping Contest!
    Dismiss Notice
  7. 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.

Advanced Item Range Increment System

Discussion in 'Requests' started by TheWarchief, Jan 2, 2011.

  1. TheWarchief

    TheWarchief

    Joined:
    Aug 19, 2009
    Messages:
    64
    Resources:
    0
    Resources:
    0
    Okay i got a problem here because i want this but i dont know if its even possible:

    I want to make it so that when a hero picks up a certain item (a gun, a throwing axe, everything ranged) the hero suddenly becomes ranged and gets a missile type that fits the item.

    Example: Melee hero picks up a gun. He now have 800 range and has the rifleman missile type and a attack bonus. When the hero then drops the item he is again melee.

    I have tried my best to try and make this work. I thought a changed orb could do it if i did it so it attacked ground ranged instead of air. It didn't work. Then i tried through triggers to enable/disable the Long Rifles upgrade and giving it to the hero but that didn't work either.

    Is this impossible or can it be done in JASS or something? Please help!
     
  2. Goolygot

    Goolygot

    Joined:
    Sep 1, 2008
    Messages:
    477
    Resources:
    0
    Resources:
    0
    Well you could make two units and swap them when he picks up a gun and drops it. And with trigger you can just change the level, exp and stats from the old unit to the new unit.
     
  3. TheWarchief

    TheWarchief

    Joined:
    Aug 19, 2009
    Messages:
    64
    Resources:
    0
    Resources:
    0
    Well i have seen maps with such replacing where you equip the weapon and then its a new hero with same stats and such but i dont want it like that as the hero is supposed to be able to equip multiple items at a time.
     
  4. TheWarchief

    TheWarchief

    Joined:
    Aug 19, 2009
    Messages:
    64
    Resources:
    0
    Resources:
    0
  5. Chizume

    Chizume

    Joined:
    May 26, 2009
    Messages:
    593
    Resources:
    1
    Maps:
    1
    Resources:
    1
    The dilemma is that the only thing that can increase units' range is an upgrade and upgrades cannot be degraded once upgraded.
     
  6. TheWarchief

    TheWarchief

    Joined:
    Aug 19, 2009
    Messages:
    64
    Resources:
    0
    Resources:
    0
    well it seems like this is impossible.
     
  7. greasontim

    greasontim

    Joined:
    Oct 27, 2008
    Messages:
    1,176
    Resources:
    0
    Resources:
    0
    Just tried something and it works to some degree.
    Hero needs to be effected by a Range Decrease Upgrade and a Range Increase Upgrade.
    Increase by 1
    Decrease by -1
    1000 levels for both.
    • Increase Range
      • Events
        • Unit - A unit Acquires an item
      • Conditions
        • Or - Any (Conditions) are true
          • Conditions
            • (Insert all your increase range items in here)
      • Actions
        • Player - Set the current research level of Test+ to (Integer((Current life of (Item being manipulated)))) for (Owner of (Triggering unit))


    • Decrease Range
      • Events
        • Unit - A unit Loses an item
        • Unit - A unit Pawns an item (to shop)
      • Conditions
      • Actions
        • Player - Set the current research level of Test- to (Integer((Current life of (Item being manipulated)))) for (Owner of (Triggering unit))
        • Player - Set the current research level of Test+ to 0 for (Owner of (Triggering unit))
        • Player - Set the current research level of Test- to 0 for (Owner of (Triggering unit))

    Sadly once you sell or lose the first item your range wont increase unless the Range + Upgrade increases.
     
    Last edited: Jan 5, 2011
  8. AlienAtSystem

    AlienAtSystem

    Joined:
    Dec 26, 2009
    Messages:
    604
    Resources:
    38
    Models:
    7
    Icons:
    28
    Packs:
    1
    Skins:
    1
    Spells:
    1
    Resources:
    38
    1000 is definetly not enough. If you take for example the standard hero range - 600 - then the first time the item is aquired, the upgrade is set to 600, the next time it would have to be set to 1200 - 200 over the limit, meaning that the hero will get only a range of 400 with the second equip and then 0 for all following.

    I have tested a bit with Orb abilities, that allow the activation of attacks, but sadly warcraft always prefers the melee attack over the ranged. A last, but probably useless solution would be to use the uproot ability which can also change the attack indices, but then the heroes would have to stand still for using a ranged weapon.
     
  9. defskull

    defskull

    Joined:
    Mar 27, 2008
    Messages:
    7,978
    Resources:
    17
    Spells:
    17
    Resources:
    17
    Upgrades/Research can be downgrade... ???
     
  10. Chizume

    Chizume

    Joined:
    May 26, 2009
    Messages:
    593
    Resources:
    1
    Maps:
    1
    Resources:
    1
    If no, then everything is normal.

    If yes, then Blizzard updated WE with a patch I have not noticed.
     
  11. defskull

    defskull

    Joined:
    Mar 27, 2008
    Messages:
    7,978
    Resources:
    17
    Spells:
    17
    Resources:
    17
  12. Chizume

    Chizume

    Joined:
    May 26, 2009
    Messages:
    593
    Resources:
    1
    Maps:
    1
    Resources:
    1
    Since it's only one unit, it could be a replacement unit?
     
  13. defskull

    defskull

    Joined:
    Mar 27, 2008
    Messages:
    7,978
    Resources:
    17
    Spells:
    17
    Resources:
    17
    It must have a well-coordinated trigger
    That saves items, damages, stats, and such
    You can't just use the Trigger action replacement just like that, well, it's a LOOONG work to do ;D
    But for Level, I don't think you need to save it in a variable because, a replacement of unit will still take its previous EXP along with it
    Example Human turns to Dragon
    Human has 1800 EXP while Dragon has 0
    If you use Replace unit action, that Dragon will get 1800 EXP, automatically
    I think I've done this method, not sure about items, whether you have to save it or not
     
  14. GIANT_CRAB

    GIANT_CRAB

    Joined:
    Apr 4, 2010
    Messages:
    542
    Resources:
    2
    Spells:
    2
    Resources:
    2
    • Unit - Replace lol1 with lol2

    Items, exp, skills(yes, it will, unless... the units' abilities is different), stats, armor, damage, blah blah.
     
  15. AlienAtSystem

    AlienAtSystem

    Joined:
    Dec 26, 2009
    Messages:
    604
    Resources:
    38
    Models:
    7
    Icons:
    28
    Packs:
    1
    Skins:
    1
    Spells:
    1
    Resources:
    38
    Replacement unit, just like demon hunter. Is probably the only working solution, but has the big disadvantage that you have to create a new hero type for all possible ranges.
     
  16. Goolygot

    Goolygot

    Joined:
    Sep 1, 2008
    Messages:
    477
    Resources:
    0
    Resources:
    0
    But then my idea was right and not a bad idea.
     
  17. defskull

    defskull

    Joined:
    Mar 27, 2008
    Messages:
    7,978
    Resources:
    17
    Spells:
    17
    Resources:
    17
    Demon Hunter -> Demon Form
    This is not a replacement method, it's more to Metamorphosis, more like change in state through ABILITY

    Replacing a unit is done in Trigger Editor, not Object Editor
    Therefore, it's different from one another
     
  18. GIANT_CRAB

    GIANT_CRAB

    Joined:
    Apr 4, 2010
    Messages:
    542
    Resources:
    2
    Spells:
    2
    Resources:
    2
    You should try using crow form and avatar while u are in metamorphosis. (spam it constantly for 5 times)
    See wut will happen.