I have it so that multiple marines (the builders in the map) can construct a building simultaneously, however only if they are all owned by the player that owns the building. I am not sure how to have multiple players construct a building owned by another player. Is there a data editor setting that anyone knows of?
I used "Set Alliance Aspect (Spend Resources)" which allows me to start a building with another player's units, but I am still unable to finish constructing player A's buildings with player B's units.
you should really learn how to do this stuff with the data editor.....
if a unit builds a building that building will be owned by the owner of unit that built it.. if your changing the ownership with triggers mid build it may not complete.
I understand and agree with your advocation for preferring the data editor over triggers.
However, the only trigger that I have attempted with this problem was the one above, Spend Player Resources.
Since I was unable to locate any solution to solving it in the data editor, I tried the trigger in the logic that if they can spend a player's resources and use the other player's workers to construct a building, then hopefully it would allow their workers to assist in construction as well.
It did not solve the issue, but I posted about it here anyway to update my search.
As far as the data editor goes, I looked for a target search flag or anything similar on all of the construction related abilities / effects / behaviors that I could find, in the hopes that I could check Ally in addition to the presumed Player flag. Unfortunately I have been unable to locate anything. That doesn't mean it isn't there though, which is why I am here. I am completely open to a data editor based solution, and would, as stated, prefer one.
BNet SirNewbzAlot.290 (NA)
Join date 23 Jul 2010
Posts 215
Last login 21 Oct 2010 Reply Quote 35 minutes later (on Thu, 14 Oct 2010 22:50:19)
@Selfcreation: Go
in the data editor if you open up your structure for producing units there is a field titled interact that allows you to share the building. Look up biffu's item tutorial and watch that, it will show you how to make shared buildings.
I dont think you should do it with triggers!! triggers for this will just lag up ur game and cause way to much work for an eassy thing to do.
I have to say that I had a lot of hopes for this technique, however it did not appear to help. (based on the Interact ability as detailed by Bifuu here)
This is murdering my progress on the map, it is a blocking issue.
I feel like there should be a very simple data editor solution to just let players help build another player's buildings, but now I suspect I may have to use some sort of complex trigger based approach, such as creating invisible dummy workers for the owner of the building that work while the other player units perform a dummy build animation.
did u try changing the Interactive field for your builder? or just the building?
it soudns easy lol but i guess it int:
did you try activating the INTERACTIVE field for botht he buildign and builder , and there should also be an abillity or behaviour you can add that alows you to use MULTY builders to build a single building ( like int he campain )
I could not find anything name "interact" or "interactive" as a field in the ability or unit data objects, only the Interact behavior type that was mentioned. If you can show me where to find what you are referring to, that would be good.
I have successfully allowed multiple builders using the campaign ability, like you mentioned, but only if the builders belong to the owner of the building.
How about this.... instead of units actually helping build something.... why not just have the unit apply a behavior to the building that speeds up the construction progress... which i know you can do
Im pretty damn sure that you can not help construct something that doesnt belong to you... why your trying to make it do that is beyond me....
create a custom ability that can target freindly structures. make this ability a channeled ability .... while the ability is channeled it applys a buff to the targeted structure that increases the construction progress..... when the channeled ability is broken it stops applying the buff .... you would also add a requirement to the casting and the channeling the require the building to be under construction and not completed.
theres a behavior buff that makes it so units speed up.. it generally effects everything about the unit .. but as long as its removed after the building is costructed youll be fine. you can add a requirement to the behavior buff itself that it requires its host unit to be in the construction progress.
thats pretty much what you want it to do anyways...
then you make a trigger that says.... when scv is ordered to move to allied building that isnt finished being constructed order scv to use custom ability on unfinished builded
That's actually a very good idea, I will try that out.
I am trying to do it because that is how Natural Selection the game works. Each player on the marine team controls a single marine, and the marine "commander" can place unconstructed buildings, which individual marines can all help construct. It's a vital mechanic of the game.
I've not yet had the opportunity to attempt it, however I have thought of an obstacle.
The marine team has a "commander" that places buildings around the map, and then the other players (marines) actually build them. So the owner of the building (commander) will not be present to build it, thus the progress bar will not be moving until a marine starts building it. Since the there is no progress to scale up, time scale would not help.
However come to think of it I could probably just grant ownership of any uncompleted building to the first marine that tries to build it, and other marines can use the buff method on it, then give ownership back to the commander once it is complete.
Yesterday while toying around I discovered that if a worker is in the build process and the owner of the building changes via a trigger, the worker will continue building.
Apparently a worker build ability only checks for ownership to start, but doesn't care about ownership once it has started.
I attempted to exploit this and made a trigger (paraphrasing):
Events
(Any unit) is issued order (move)
Conditions
(Target of order) is (structure) owned by (ally of triggering player)
(Target of order) is (under construction)
Actions
Change owner of (target of order) to (owner of triggering unit)
Basically if they right click on the building, it gives them ownership.
Pros:
This means a different player can "join in" on the construction since they will "own" the building when their worker starts, and the original builder's unit is still working on it even though it has changed ownership.
Cons:
Basically the player has to click twice, once to "gain ownership" and once to "build".
Troubleshooting
Would like to have it such that only a single click is required. Possible solutions?
Assuming a single click, if player A clicks from a far distance, they gain the structure. If player B then also clicks a worker on it, then B will gain ownership, so when Player A's unit arrives it will be unable to build since A no longer owns the structure. Possible solutions?
Obviously the ultimate solution would be to simply have build abilities ignore ownership, so if anyone can figure that out that would be best
I know I'm being persistent about this issue but I'd like to find a good solution so that
A) The community can always know how to solve it if anyone else ever needs to know and
B) I can finish a fun map for people to play on battle net!
@scmapcritic: Go
Wouldn't your solution work if you simply checked range first, and if the unit is in range, it will change ownership and then order the worker to build the structure through an "issue order" command, and then after a short delay (0.2~ sec) automatically swap back to neutral ownership? It won't even be visible if you don't change the color with the ownership, and to prevent it from bugging you can turn off the trigger for the 0.2 sec, so that in the rare case that the actions do collide the second player will only have to click a second time (or even do it automatically after the 0.2 sec if you're feeling really fancy)
Working on my Natural Selection map.
I have it so that multiple marines (the builders in the map) can construct a building simultaneously, however only if they are all owned by the player that owns the building. I am not sure how to have multiple players construct a building owned by another player. Is there a data editor setting that anyone knows of?
@scmapcritic: Go
I used "Set Alliance Aspect (Spend Resources)" which allows me to start a building with another player's units, but I am still unable to finish constructing player A's buildings with player B's units.
@scmapcritic: Go
Still hoping someone out there can offer some insight.
you should really learn how to do this stuff with the data editor.....
if a unit builds a building that building will be owned by the owner of unit that built it.. if your changing the ownership with triggers mid build it may not complete.
@SouLCarveRR: Go
I understand and agree with your advocation for preferring the data editor over triggers.
However, the only trigger that I have attempted with this problem was the one above, Spend Player Resources.
Since I was unable to locate any solution to solving it in the data editor, I tried the trigger in the logic that if they can spend a player's resources and use the other player's workers to construct a building, then hopefully it would allow their workers to assist in construction as well.
It did not solve the issue, but I posted about it here anyway to update my search.
As far as the data editor goes, I looked for a target search flag or anything similar on all of the construction related abilities / effects / behaviors that I could find, in the hopes that I could check Ally in addition to the presumed Player flag. Unfortunately I have been unable to locate anything. That doesn't mean it isn't there though, which is why I am here. I am completely open to a data editor based solution, and would, as stated, prefer one.
From a post i did a phew weeks ago.
happy04
Regular Shmoe
BNet SirNewbzAlot.290 (NA) Join date 23 Jul 2010 Posts 215 Last login 21 Oct 2010 Reply Quote 35 minutes later (on Thu, 14 Oct 2010 22:50:19)
@Selfcreation: Go in the data editor if you open up your structure for producing units there is a field titled interact that allows you to share the building. Look up biffu's item tutorial and watch that, it will show you how to make shared buildings.
I dont think you should do it with triggers!! triggers for this will just lag up ur game and cause way to much work for an eassy thing to do.
@Selfcreation: Go
I have to say that I had a lot of hopes for this technique, however it did not appear to help. (based on the Interact ability as detailed by Bifuu here)
Thanks though, worth a shot.
This is murdering my progress on the map, it is a blocking issue.
I feel like there should be a very simple data editor solution to just let players help build another player's buildings, but now I suspect I may have to use some sort of complex trigger based approach, such as creating invisible dummy workers for the owner of the building that work while the other player units perform a dummy build animation.
did u try changing the Interactive field for your builder? or just the building?
it soudns easy lol but i guess it int:
did you try activating the INTERACTIVE field for botht he buildign and builder , and there should also be an abillity or behaviour you can add that alows you to use MULTY builders to build a single building ( like int he campain )
@Selfcreation: Go
I could not find anything name "interact" or "interactive" as a field in the ability or unit data objects, only the Interact behavior type that was mentioned. If you can show me where to find what you are referring to, that would be good.
I have successfully allowed multiple builders using the campaign ability, like you mentioned, but only if the builders belong to the owner of the building.
How about this.... instead of units actually helping build something.... why not just have the unit apply a behavior to the building that speeds up the construction progress... which i know you can do
Im pretty damn sure that you can not help construct something that doesnt belong to you... why your trying to make it do that is beyond me....
create a custom ability that can target freindly structures. make this ability a channeled ability .... while the ability is channeled it applys a buff to the targeted structure that increases the construction progress..... when the channeled ability is broken it stops applying the buff .... you would also add a requirement to the casting and the channeling the require the building to be under construction and not completed.
theres a behavior buff that makes it so units speed up.. it generally effects everything about the unit .. but as long as its removed after the building is costructed youll be fine. you can add a requirement to the behavior buff itself that it requires its host unit to be in the construction progress.
thats pretty much what you want it to do anyways...
then you make a trigger that says.... when scv is ordered to move to allied building that isnt finished being constructed order scv to use custom ability on unfinished builded
@SouLCarveRR: Go
That's actually a very good idea, I will try that out.
I am trying to do it because that is how Natural Selection the game works. Each player on the marine team controls a single marine, and the marine "commander" can place unconstructed buildings, which individual marines can all help construct. It's a vital mechanic of the game.
would it not be easyer to just make ur building NUTRAL? i guess that doesnt work?
@scmapcritic: Go
How did my idea pan out for you.
@SouLCarveRR: Go
I've not yet had the opportunity to attempt it, however I have thought of an obstacle.
The marine team has a "commander" that places buildings around the map, and then the other players (marines) actually build them. So the owner of the building (commander) will not be present to build it, thus the progress bar will not be moving until a marine starts building it. Since the there is no progress to scale up, time scale would not help.
However come to think of it I could probably just grant ownership of any uncompleted building to the first marine that tries to build it, and other marines can use the buff method on it, then give ownership back to the commander once it is complete.
Yesterday while toying around I discovered that if a worker is in the build process and the owner of the building changes via a trigger, the worker will continue building.
Apparently a worker build ability only checks for ownership to start, but doesn't care about ownership once it has started.
I attempted to exploit this and made a trigger (paraphrasing):
Events
Conditions
Actions
Basically if they right click on the building, it gives them ownership.
Pros:
Cons:
Troubleshooting
Obviously the ultimate solution would be to simply have build abilities ignore ownership, so if anyone can figure that out that would be best I know I'm being persistent about this issue but I'd like to find a good solution so that A) The community can always know how to solve it if anyone else ever needs to know and B) I can finish a fun map for people to play on battle net!
Thanks!
@scmapcritic: Go Wouldn't your solution work if you simply checked range first, and if the unit is in range, it will change ownership and then order the worker to build the structure through an "issue order" command, and then after a short delay (0.2~ sec) automatically swap back to neutral ownership? It won't even be visible if you don't change the color with the ownership, and to prevent it from bugging you can turn off the trigger for the 0.2 sec, so that in the rare case that the actions do collide the second player will only have to click a second time (or even do it automatically after the 0.2 sec if you're feeling really fancy)
@mark8264: Go
Yeah but if they aren't in range it should still run up and build.