• 🏆 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!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

LoL and HoN "Pets"

Status
Not open for further replies.
Level 4
Joined
Sep 2, 2008
Messages
40
I have recently watched some videos of LoL (League of Legends) and HoN (Heroes of Newerth) In which some of the heroes/champions have spells that create a pet that follows the caster, the caster cannot control the pet directly but the pet follows the caster around like a guardian. I just wanted to know if such a thing could be accomplished and if so, how?
 
Level 22
Joined
Nov 14, 2008
Messages
3,256
Yes it is possible although it will require a trigger that orders that unit to move around the hero (or to the hero when the hero moves). Also you can add it chaos and a new unit which has locust so it wont be targetable. If it should be targetable, then you probably wont need this.
 
Level 22
Joined
Nov 14, 2008
Messages
3,256
Alright let's get this straight. First you create "your unit", it has locust and you set it into a variable. Every few seconds you order it to move to the hero. You can always enum around the hero to check if the move should be attack move or just move.
 
Level 15
Joined
Oct 18, 2008
Messages
1,588
Try this (i hope you kow what to do with it :D)
  • Pet Movement
    • Events
      • Time - Every 4.00 seconds of game time
    • Conditions
    • Actions
      • For each (Integer A) from 1 to 12, do (Actions)
        • Loop - Actions
          • Set HeroPos[(Integer A)] = (Position of Hero[(Integer A)])
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Attack Equal to True
            • Then - Actions
              • Unit - Order Pet[(Integer A)] to Attack-Move To HeroPos[(Integer A)]
            • Else - Actions
              • Unit - Order Pet[(Integer A)] to Move To HeroPos[(Integer A)]
            • Custom script: call RemoveLocation(udg_HeroPos[GetForLoopIndexA()])
It supports 1 pet/hero. About the pet-use locust ability or an allied computer's unit :) Or you can use this:
  • Pet Unselect
    • Events
      • Player - Player 1 (Red) Selects a unit
      • Player - Player 2 (Blue) Selects a unit
      • ... until Player 12
    • Conditions
    • Actions
      • Set Selection = Units currently selected by (Triggering player)
      • Unit Group - Pick every unit in (Selection) and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Picked unit) Equal to Pet[(Player number of (Triggering player))]
            • Then - Actions
              • Selection - Remove (Picked unit) from selection for (Triggering player)
            • Else - Actions
      • Custom script: call destroyGroup(udg_Selection)
Oh, and Pet=Unit Array | Hero=Unit Array | HeroPos=PointArray | Selection=Unit Group
 
Last edited:
Level 22
Joined
Nov 14, 2008
Messages
3,256
Ah now I know what is the problem, they have locust!

Alright do like this, create another unit that has locust from the start and remove locust on the first. Add a modified ability "chaos" where the new unit type is the second unit, set this unit into the variable that should work. If it don't I really need to start working on a map again :D

Else you can go with the one above. Just remember to set the unit group so it wont leak as the one above ;)
 
Level 15
Joined
Oct 18, 2008
Messages
1,588
Ah now I know what is the problem, they have locust!

Alright do like this, create another unit that has locust from the start and remove locust on the first. Add a modified ability "chaos" where the new unit type is the second unit, set this unit into the variable that should work. If it don't I really need to start working on a map again :D

Else you can go with the one above. Just remember to set the unit group so it wont leak as the one above ;)

Oh yeah thanks, forgot about it :D Going to repair it in seconds :D
 
Level 4
Joined
Sep 2, 2008
Messages
40
Originally Posted by baassee
Ah now I know what is the problem, they have locust!

Alright do like this, create another unit that has locust from the start and remove locust on the first. Add a modified ability "chaos" where the new unit type is the second unit, set this unit into the variable that should work. If it don't I really need to start working on a map again :D

Else you can go with the one above. Just remember to set the unit group so it wont leak as the one above ;)

The first unit will just become the second unit and still have locust after spawned.

EDIT: I am going to try something with changing the spawned unit to another team that is friendly, so that it is a guardian but still can be attacked.
 
Level 12
Joined
Nov 20, 2007
Messages
660
Ah now I know what is the problem, they have locust!

Alright do like this, create another unit that has locust from the start and remove locust on the first. Add a modified ability "chaos" where the new unit type is the second unit, set this unit into the variable that should work. If it don't I really need to start working on a map again :D

Else you can go with the one above. Just remember to set the unit group so it wont leak as the one above ;)

what "chaos" ability does ? :ogre_haosis:
 
Status
Not open for further replies.
Top