How can you 'trap' a target unit inside spawned units ?

marvey323

Member
Reaction score
1
I tried setting the collision size really high for a unit that I spawn around a target unit making him unable to move out of the spawned units (I spawned 6 of these units around him) but he can simply just walk right out of the entrapment.
 

Exide

I am amazingly focused right now!
Reaction score
448
You can either use pathing blockers (blocks other units as well.)
Or teleport the unit back into the region - if he leaves it.
You can also set it's movespeed to 0, to prevent it from moving at all.

Why would you want to trap a unit like that anyway?
 

Emu.Man00

New Member
Reaction score
41
You can either use pathing blockers (blocks other units as well.)
Or teleport the unit back into the region - if he leaves it.
You can also set it's movespeed to 0, to prevent it from moving at all.

Why would you want to trap a unit like that anyway?

I think he's trying to make a spell like prophet's in dota. i.e. you get trapped inside a bunch of units/destructables for x seconds, like a makeshift disable
 

Exide

I am amazingly focused right now!
Reaction score
448
I think he's trying to make a spell like prophet's in dota. i.e. you get trapped inside a bunch of units/destructables for x seconds, like a makeshift disable

Oh, I see.
In that case this trigger should work:

Trigger:
  • Sprout
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Sprout
    • Actions
      • Set CenterPoint = (Position of (Target unit of ability being cast))
      • For each (Integer A) from 1 to 6, do (Actions)
        • Loop - Actions
          • Set TreePoint = (CenterPoint offset by 128.00 towards Degrees degrees)
          • Destructible - Create a SpawnTree at TreePoint facing 270.00 with scale 0.70 and variation 0
          • Custom script: call RemoveLocation(udg_TreePoint)
          • Set Degrees = (Degrees + 60.00)
      • Custom script: call RemoveLocation(udg_CenterPoint)
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top