I was reading FuzzYD's tutorial on user types, in it he uses custom script. It occurred to me that i should learn custom script. So i went through the site and I couldn't find any tutorials on it :( Could someone make one and then link it to the main galaxy tutorial page . (yes i looked other places besides there) and then post a reply on this post.
Check the cost of the new unit. Also check the cost of the ability to use you probably have one of them set to -150
Btw switch is easier to work with
General - switch (actions) depending on ((Unit Type of (triggering unit))
-cases
--if Tal'darim - plasma tower
---then Player - Modify player (Owner of (Triggering unit)) Minerals: Add (((Minerals cost of (Unit type of (Triggering unit))) / 5) + ((Minerals cost of Tal'darim - Photon Cannon) / 5))
Also just for you to note in the future of you tower upgrades there is a limit to how many abilities they can have linked to them (if they morph they get the abilities of the unit they morph into linked to them all the way down the morph line).
The best way to get around that is to create a dummy morph ability and have a trigger replace the unit when it happens
I feel like a noob for aking this(which i am), but how do i post my map here.
Edit: TY Zelda
This is a ranndom spawn trigger set, i'm using it in a map i'm making. It allows you to spawn the unit at any region within a list and also customize their team colors while keeping their original owners(or whatever you would like to change for the unit).
Edit:
Added an old map of mine to which I inputted my random generation kit and also has a bunch of triggers that are really interesting such as
1. chat system where chat appears at players unit instead of in chat area
2. a massive amount of triggers for a computer(not an AI, but a simulated computer) that does stuff.
3. some other stuff I can't remember off the top of my head.
Why not just give each unit the salvage ability. Just scale it for each one
ex:
salvage for tower 1
cost - .2 min
salvage for tower 2
cost -.4 min
Yes it takes longer but data doesn't have a limit while triggers do (256 or something like that)
but if you still want to do it with triggers
create a switch with a different return for each tower
Ex
switch
if tower 1
Player - Modify player (Owner of (Triggering unit)) Minerals: Add ((Minerals cost of (Unit type of (Triggering unit))) / 5)
if tower 2
Player - Modify player (Owner of (Triggering unit)) Minerals: Add ((Minerals cost of (Unit type of (Triggering unit))) / 5)
Player - Modify player (Owner of (Triggering unit)) Minerals: Add ((Minerals cost of tower 1)) / 5)
0
Thanks
0
I was reading FuzzYD's tutorial on user types, in it he uses custom script. It occurred to me that i should learn custom script. So i went through the site and I couldn't find any tutorials on it :( Could someone make one and then link it to the main galaxy tutorial page . (yes i looked other places besides there) and then post a reply on this post.
0
Check the cost of the new unit. Also check the cost of the ability to use you probably have one of them set to -150
Btw switch is easier to work with
General - switch (actions) depending on ((Unit Type of (triggering unit))
-cases
--if Tal'darim - plasma tower
---then Player - Modify player (Owner of (Triggering unit)) Minerals: Add (((Minerals cost of (Unit type of (Triggering unit))) / 5) + ((Minerals cost of Tal'darim - Photon Cannon) / 5))
Also just for you to note in the future of you tower upgrades there is a limit to how many abilities they can have linked to them (if they morph they get the abilities of the unit they morph into linked to them all the way down the morph line).
The best way to get around that is to create a dummy morph ability and have a trigger replace the unit when it happens
0
I feel like a noob for aking this(which i am), but how do i post my map here.
Edit: TY Zelda
This is a ranndom spawn trigger set, i'm using it in a map i'm making. It allows you to spawn the unit at any region within a list and also customize their team colors while keeping their original owners(or whatever you would like to change for the unit).
Edit:
Added an old map of mine to which I inputted my random generation kit and also has a bunch of triggers that are really interesting such as
1. chat system where chat appears at players unit instead of in chat area
2. a massive amount of triggers for a computer(not an AI, but a simulated computer) that does stuff.
3. some other stuff I can't remember off the top of my head.
0
Why not just give each unit the salvage ability. Just scale it for each one
ex:
salvage for tower 1
cost - .2 min
salvage for tower 2
cost -.4 min
Yes it takes longer but data doesn't have a limit while triggers do (256 or something like that)
but if you still want to do it with triggers
create a switch with a different return for each tower
Ex
switch
if tower 1
Player - Modify player (Owner of (Triggering unit)) Minerals: Add ((Minerals cost of (Unit type of (Triggering unit))) / 5)
if tower 2
Player - Modify player (Owner of (Triggering unit)) Minerals: Add ((Minerals cost of (Unit type of (Triggering unit))) / 5)
Player - Modify player (Owner of (Triggering unit)) Minerals: Add ((Minerals cost of tower 1)) / 5)