• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

[Trigger] Item in slot 1 changes attack range?

Status
Not open for further replies.
Level 5
Joined
Dec 11, 2010
Messages
101
Alright, simple enough right? Its simple and easy to do for other people, but not me. What i need is when (for example) Pistol is in slot 1, it changes the (Unit Survivor) range to 400, but i don't know a lot much. IF you can, try not to use variables. Also there are 4 different survivors so its 4 players.

I'll give credits for anyone who helps.
Thanks
 
Level 10
Joined
Aug 14, 2009
Messages
309
I'm afraid this can be complicated to do for you.

In order to change an unit's range back and forth you should use a morphing spell (like metamorphosis) so you can change between a low range hero and a high range hero.

In order to make this work on item change and not being castable by the player you should hide the ability in a disabled spellbook. Then trigger the ability when a unit picks up the pistol.

Good luck :)
 
Level 4
Joined
Aug 5, 2011
Messages
99
cant u just use the night elf range upgrade? whenever a unit acquires an item u set the research lvl for the upgrade to the right lvl for that player...
 
Level 5
Joined
Dec 11, 2010
Messages
101
Player - Set the current research level of M1911 to 0 for Player 1 (Red)
is this the trigger? if so i have no clue what to do with it :3
but so far this is what i got

M1911R
Events
Unit - A unit Acquires an item

Condition
(Item-type of (Item carried by (Hero manipulating item) in slot 1)) Equal to M1911

Player - Set the current research level of M1911 to 0 for Player 1 (Red)
 
Level 4
Joined
Aug 5, 2011
Messages
99
if he aquires the item u should set the research lvl to 1 (or w/e lvl u need), if he loses the item again set research lvl to 0 so its back to the old state. Also make sure the upgrade works on your survivor. i think this is what you want...

  • trigger
    • Events
      • Unit - A unit Acquires an item
      • Unit - A unit Loses an item
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Item-type of (Item carried by (Triggering unit) in slot 1)) Equal to your pistol
        • Then - Actions
          • Player - Set the current research level of your upgrade to 1 for (Owner of (Triggering unit))
        • Else - Actions
          • Player - Set the current research level of your upgrade to 0 for (Owner of (Triggering unit))
 
Level 5
Joined
Dec 11, 2010
Messages
101
mckill2009 where it says attached files test range, is that the explanation why it doesnt work or is it the way to make it work? (im on a difforent laptop so ill dl later)

I dowloaded. i see the problem. Ill try and do the Transformations again.

Ps. - "You must register first before using" this was in the how to use. what it mean? (and why do u make it special coding, it makes it hard to do?)
 
Last edited:
Level 5
Joined
Dec 11, 2010
Messages
101
What??? this trigger doesnt work?

Unit - A unit Acquires an item

(Item-type of (Item carried by (Hero manipulating item) of type Mystery Box)) Equal to Mystery Box

Item - Remove (Item carried by (Hero manipulating item) of type Mystery Box)
Item - Create (Random level 8 Charged item-type) at (Center of Myster Box <gen>)

What happens is it creates the same items in the same order EVERY time i buy the Mystery Box item? what am i doing wrong? it should be random..
 
Status
Not open for further replies.
Top