| 05-18-2006, 02:15 PM | #1 |
I am not sure where to put this, if it belongs in triggers or general questions. Ok I have looked at a lot of stuff and read several tutorials. I have put my thoughts into order and hope there is someone with some difinitive answers on how to solve this issue. Issue: I have determined that this issue is a pathing issue. Basically I want to make it so a building can only be build within a certain limited area that has to be designated by the player. Possible Soltuions: What I am trying to do is very much like Undead and Blight - where a Player designates an area by building a minor building/irrigation ditch. Then the player must build the main building/farmhouse next to the minorbuilding/ditch. 1. A solution to this is to create a blight effect with a very small radius. Problem: I do not want the blight effect to create the blight tiling. Question: Is it possible to make blight effect tileset the exact same tileset as the rest of the game board? Is it possible to make the blight effect tileset non-existent. i.e. the blight effect just increases the radius of the building pathing and does not alter the tileset of the map? 2. A solution to this is to create a trigger: when unit is ordered to build a major building/farm, the trigger checks the distance from the minor building/irrigation and prevents or allows the building to commence. Problem: Adding lots of Triggers tends to cause issues. I like to avoid them. Question: What is the best way to develop this trigger -- I want to prevent the player from ever building the building if it is not in the right spot. Therefore, is there a way where I can say: Event - unit is issued an order. Order is = to building/construction? if so can someone give me an example of this. I am a real dunder head. 3. A solution to this is to create a custom pathing building. i.e. I mark the entire map as being unbuildable. The player then creates new pathing in an area by creating the minor building/irrigation ditch. Problem: I have no idea what I am talking about or how to alter building Pathing on this level. |
| 05-18-2006, 04:09 PM | #2 |
Il help you get your trigger sorted when i come back, im going out now. When i get back il show u the basics of what you need. It only requires the 1 trigger and should work pretty good, i would do it now but i really dont have much time, sorry. |
| 05-18-2006, 04:17 PM | #3 |
#2 is by far your best option. It's easy, and fast, and will do exactly what you want. Just make a trigger that whenever someone starts building a farm, set a temp unit group to units within x of the farm matching the irrigation unit type. Then check if the unit group is empty; if so, refund the money and remove the farm. |
| 05-18-2006, 08:00 PM | #4 |
ok. But it isn't possible to mess with blight? See the problem is with that trigger I cannot make it visible that it is impossible to build the farm. I kinda wanted the visual cue as well (i.e. the farm is red when it can't be built over the land). If it isn't possible to do that I will do the trigger, I was just hopin someone knew for sure. Also, do I really have to allow it to reach the stage of refunding money, can't I set the trigger so that when unit is issued the order to build, the order is cancelled if the farmhouse isn't near the irrigation ditch? Money isn't actually spent until the farmhouse is being built. |
| 05-19-2006, 02:20 AM | #5 | |||||
GUYS I Just discovered a trigger- action: Quote:
Would something like this work? If this will work, then would this also work: ----------------- omg I am looking at these commands I think I can do What I want to do with pathing, this would make it easier. Here let me point out some of the things: Quote:
In otherwords, I can turn the buildability on the entire map to be off and then this unit would make the buildability to be on. Or I can use this: Quote:
Basically if I do this I will be creating my own blight effect, correct? Can you help me specifically to do this? I know I am on the right track, does anyone else know what I am thinking? In otherwords: 1. If I use Quote:
I would only have to make 1 single trigger!!!!! If unit is built, it extends the building pathing around by a specific range! 2. If I use Quote:
NOW the only problem I have is putting these thoughts in order, and making it so the irrigation ditches MUST be built right next to each other. I do not know how to do that at all |
| 05-26-2006, 06:31 PM | #6 |
Anyone help? Ok umm I may be able to do this with triggers.. but is there anyone who knows JASS scripting who can make a script that basically says this: (specific building) turns red and cannot be built if it isn't next to (specific building)? |
