• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Remove Unit-Type

Status
Not open for further replies.
Level 3
Joined
Apr 6, 2007
Messages
45
OK...I know u all had enought of me...but I really need help with my map.

QUESTION: How to make trigger like this.

Event: Unit Dies
Condition: Dying unit equal to TempleOfTides
Action: (THIS PART I DUNNO BUT IT MUST LOOK SOMETHING LIKE THIS) Pick 1 unit of type Necropolis and remove it from triggering player.

This is idea i got so i cant cheat system so he thinks that my TempleOfTides is TownHall coz i have hidden Necropolis (coz i already tried classification and gameplay constants.....nothing worked).

Trigger idea is when TempleOfTides dies, Necropolis is removed from game too.

PLEASE HELP........BEG BEG
 
Level 3
Joined
Apr 6, 2007
Messages
45
The thing is.....i can't figure out how to set up to remove unit of type....from whole map....I can just select unit from world map.
 
Level 3
Joined
Apr 6, 2007
Messages
45
Guys Understand that I am using other original townhall only as dummy...so I want when my Custom TownHall dies.....so does dummy dies. HELP ME WITH THIS
 

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,258
Thank you for breaking the rules, atleast 3 times. You have double posted twice even though there is an edit button and you have started 2 topics about the same thing. Kid, please learn to read rules and behave properly before joining to this site.

Your only getting away with it due to this section is un moderated. Things may change soon though. . .
 
Level 10
Joined
Jan 21, 2007
Messages
576
This sight is helpful, sure you dont care. Dr supergood you know in your heart of hearts NOONE reads the rules when coming to a sight, most people have common sense though. BUT if you are warned about something and you do it agian its your fault dont get mad about it.
 
Level 3
Joined
Apr 6, 2007
Messages
45
Here is the thing.......I wasn't warned :D


AND


Code:
Remove Necropolis
    Events
        Unit - A unit dies
    Conditions
        ((Unit-type of (Dying unit)) Equal to Temple of Tides
    Actions
        *Actions*

Under unit-type comparison.

Erm...what is point of this (Every fool can make that part).
 
Level 7
Joined
Apr 5, 2006
Messages
128
Actually, to pick only the necropolis of the owner you'd need to do this:

Code:
Remove Necropolis
    Events
        Unit - A unit dies
    Conditions
        ((Unit-type of (Dying unit)) Equal to Temple of Tides
    Actions
        Set Leak_Group = (Units of type Necropolis)
        Unit Group - Pick every units in Leak_Group and do (Actions)
            Loop - Actions
                If ((Owner of (Dying unit)) Equal to (Owner of (Picked unit))) then do (Unit - Kill (Picked unit)) else do (Do nothing)
        Custom script:    call DestroyGroup(udg_Leak_Group)

EDIT:
Erm...what is point of this (Every fool can make that part).

First of all, you didn't even make it in your original post.

Second, if you don't want help you won't get help.

Anyways, here's your complete trigger now.
 
Level 3
Joined
Apr 6, 2007
Messages
45
Again that thingy....I want only 1 UnitType Necropolis to be deleted from owner...not all of his Necropolises.


And sry......I was pissed yesterday :p
 
Level 15
Joined
Feb 9, 2006
Messages
1,598
I don't have the editor infront of me, but the action would look like something like this:

Actions
Pick random unit from unitgroup all units of type of (Necropolis for owner of triggering player) And do following actions
Remove picked unit
 
Level 3
Joined
Apr 6, 2007
Messages
45
Well 1 very nice guy gaved me this:

Remove Necropolis
Events
Unit - A unit dies
Conditions
((Unit-type of (Dying unit)) Equal to Temple of Tides
Actions
Set Leak_Group = (Random 1 units from (Units of type Necropolis))
Unit Group - Pick every units in Leak_Group and do (Actions)
Loop - Actions
If ((Owner of (Dying unit)) Equal to (Owner of (Picked unit))) then do (Unit - Kill (Picked unit)) else do (Do nothing)
Custom script: call DestroyGroup(udg_Leak_Group)

Will try it now, I hope it will work.
 
Status
Not open for further replies.
Top