this code is just not working, its give me a event type error
my problem is that , triggering units most be selected and selected units most be owned by triggering player, can anyone help me or have better suggestion ?
because I don t want the tower to be destroy, you see in my tower defence you dont have a builder you start the game with 28 building who can morph in tower, so if i put the sell function like you said, then the main building will be destroy and the player wont be able to build another, do you see the problem ?
I need a good old -sell chat command, with unit replacement, but how do i do that
to be more precise:
if any player say -sell and have a tower selected who is own by him, then replace selected unit by unite x and Add mineral = to selected unite cost for triggering player
I have also think of a morph back ability but that will be way to long to add all those actor event I already made around 100 morph actor , I don't want to be force to make more
You did not like the option to destroy the tower right?
Why don't you remove it from the game then?
I don't think thats the same thing and should work for your target.
Sell Tower X:
Event: Player types message = "Sell Tower X"
Requirement: If Text Message = "Sell Tower X"
Action: Give Triggering Player (1337 Minerals)
Action: Run Trigger = [Replace Tower X Trigger]
Replace Tower X Trigger:
Event: A Player Selects A Unit
Requirement: If Unittype Of Selected Unit = Tower X
Action: Remove Tower X from game
Action: Create Tower Y At Position Of Last Removed Unit
I know this is not the exact trigger, but if I understand you correct this should be the right direction.
I just don't understand why you want to use a chat based method. That is so clumsy and counterintuitive. Just use a dummy ability that when cast gives the appropriate amount of gold and replaces the tower with the base one. You mention not wanting to deal with the unwieldy data editor, so just trigger all the actions. The guy above me has basically done that for you.
thx for the help it appreciated. if I read you correctly h34dl4g I will have to do 27 script (one for each tower ) and 27 more of each tower replacement , isn't that a bit to much ? your idea sound good, but without the correct script entry name am afraid I wont be able to make it work, you see this: "If Unit type Of Selected Unit=" simply do not exist in the editor as a condition, I searched everywhere. but it seams that you can not ask the trigger to verify what units is selected. anyway thx for putting me in the good direction
for karawasa, well there a bug in my map that I cant quite figure out ,if I add any more ability to any of my existing or newly created tower it disable ability "X" of tower "A" if I add another one it disable ability "X" of tower "B" and so on, and the ability "X" is the upgrade(Morph) ability. so if I add the salvage ability for example to each of my 9 lvl 1 tower they all lose there +1 lvl upgrade morph ability, if I continue and add it to lvl 2 and lvl 3 tower then the base tower selector witch is the tower you start with lose all is 9 tower ability. maybe there a flag somewhere that am unaware of and forgot to check idk...
btw karawasa , when will you release eletd for sc2 ?
this code is just not working, its give me a event type error
my problem is that , triggering units most be selected and selected units most be owned by triggering player, can anyone help me or have better suggestion ?
That event does not define a "triggering unit"
Why don't you just use salvage which removes the towers, then grants the sell amount.
I use this trigger for my TD.
Set the "Bounty Minerals" for each tower, so you know your sell amount.
@RealFrozenShadow: Go
because I don t want the tower to be destroy, you see in my tower defence you dont have a builder you start the game with 28 building who can morph in tower, so if i put the sell function like you said, then the main building will be destroy and the player wont be able to build another, do you see the problem ?
I need a good old -sell chat command, with unit replacement, but how do i do that
to be more precise: if any player say -sell and have a tower selected who is own by him, then replace selected unit by unite x and Add mineral = to selected unite cost for triggering player
I have also think of a morph back ability but that will be way to long to add all those actor event I already made around 100 morph actor , I don't want to be force to make more
so please "trigger" help me :)
if you need more more information just ask :)
the map is live and call: StarForge - awakening
BUMP
its nice to see that no one helping.... thx sc2mapster
There hasn`t been too much activity recently. Its this `season` after all. Things just seem a bit quite.
Give it time, and Im sure someone will help.
You did not like the option to destroy the tower right?
Why don't you remove it from the game then?
I don't think thats the same thing and should work for your target.
Sell Tower X:
Event: Player types message = "Sell Tower X"
Requirement: If Text Message = "Sell Tower X"
Action: Give Triggering Player (1337 Minerals)
Action: Run Trigger = [Replace Tower X Trigger]
Replace Tower X Trigger:
Event: A Player Selects A Unit
Requirement: If Unittype Of Selected Unit = Tower X
Action: Remove Tower X from game
Action: Create Tower Y At Position Of Last Removed Unit
I know this is not the exact trigger, but if I understand you correct this should be the right direction.
I just don't understand why you want to use a chat based method. That is so clumsy and counterintuitive. Just use a dummy ability that when cast gives the appropriate amount of gold and replaces the tower with the base one. You mention not wanting to deal with the unwieldy data editor, so just trigger all the actions. The guy above me has basically done that for you.
thx for the help it appreciated. if I read you correctly h34dl4g I will have to do 27 script (one for each tower ) and 27 more of each tower replacement , isn't that a bit to much ? your idea sound good, but without the correct script entry name am afraid I wont be able to make it work, you see this: "If Unit type Of Selected Unit=" simply do not exist in the editor as a condition, I searched everywhere. but it seams that you can not ask the trigger to verify what units is selected. anyway thx for putting me in the good direction
for karawasa, well there a bug in my map that I cant quite figure out ,if I add any more ability to any of my existing or newly created tower it disable ability "X" of tower "A" if I add another one it disable ability "X" of tower "B" and so on, and the ability "X" is the upgrade(Morph) ability. so if I add the salvage ability for example to each of my 9 lvl 1 tower they all lose there +1 lvl upgrade morph ability, if I continue and add it to lvl 2 and lvl 3 tower then the base tower selector witch is the tower you start with lose all is 9 tower ability. maybe there a flag somewhere that am unaware of and forgot to check idk...
btw karawasa , when will you release eletd for sc2 ?