got some problem :S

n1mr0d

Member
Reaction score
1
ok so i'm working right now about 2 spells , those 2 spells have abilities to construct some towers , but with out "BUILD" icon(i mean like in the real games , there is the icon where u click and will appear the buildings which you want to build , i don't want this !.), and i wanna do that the 1 tower can be summoned only 10 times ,and the other only 5 time , if this reach 10 or 5, the 1st tower created will be destroyed(in both spells , so there it will be max 15 tower, 10 one type , and 5 second type, if one type's count reach 10 then the 1st tower will be destroyed, and this will be same with the second type of tower), some help ? is there any command for this ? what will be his event name ? (i want in gui :D!) Please help me :). I will be very happy.
 

Amn

Member
Reaction score
18
there's a function named FirstOfGroup you can try, i never used it

trigger would look something like this, it's just an example
you have to build it on your map

JASS:

trigger
    Events
        unit finishes construction
    Conditions
    Actions
        Add constructed unit to TowersGroup
        if CountUnits in TowersGroup greater than 10 then
        Kill FirstOfGroup( TowersGroup )
        Remove FirstOfGroup from ( TowersGroup )
        endif
 

n1mr0d

Member
Reaction score
1
thx , but this is working on spells like Build Stronghold (from Voodoo building (from orcs)).?


EDIT: I got a bug :S. can you check it :S? my bug is that it doesn't destroy the 1st tower , it only destroy the second , after u spawn 14 tower in total.View attachment bug.w3x

Use warpten and greedisgood 100000.
 

Iky

New Member
Reaction score
2
i got, take , dont forget the credits XD

w3x[1].gif
View attachment bugFixedByIky.w3x
 

n1mr0d

Member
Reaction score
1
thank you
EDIT : XD , even your's its bugged :p, if u build like 20 towers, the 19th tower will not be destroyed, and u can spawn creating towers XD.]
EDIT 2 : Is there any chance turn off for a building the collision? so the unit's can move trought the building ? (and the building remain clickable)
 

Iky

New Member
Reaction score
2
aff, all am i do is bugged? ¬¬ i guess yes,
i'll see and reply
EDIT
i finish, now, bug free XD (i hope ¬¬)
EDIT²
a dont know how to add lucoust to a unit by trigger :/
 

Attachments

  • bugFixed
    17.2 KB · Views: 120
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