Ok, I have a problem concerning orders that I really need help with.
[Overview of the trigger]
-What I am trying to create, is a system which will allow peasants to mine various resources, not just gold and wood.
What I've done is created a system based on items, rather than the ui, for example, the stone resource is counted by the integer variable "stone"
and whenever a peasant strikes a quarry, a grey "+8" appears above his head, and the variable gains an additional 8, all buildings which use stone gain an additional +8 charges to their stone item. this all works fine, and is not causing problems, however...
[The problem]
-What I really want, in order to make the system more lifelike, not too mention, a lot like blizzards, however, The units will just stay in one place, hacking away at the stone, with numbers above their heads. what I really need is for the peasants to go back and forth between the closest town hall and the quarry. I have the idea wrapped up, with the peasants getting the item and its charges and giving it to the building, though here is where the real problem arises, the game crashes when ordered by a trigger to attack the quarry (I don't use harvest in this case, they attack the stone and get the item)
[What I need]
I desperately need two problems fixed here, the first being a way to order the peasant to attack the quarry when the player right clicks on it when selected, the second being a way for the peasant to repeat his harvesting routine when he completes it.
I can't give you the exact trigger at the moment, as I am away from the computer I work on the project with, though I think I know the source of the problem;
there is an action which reads something like this:
order(ordered unit) to attack (target of order)
the crash seems to originate from here, though I cant get the quarry to become the target in any other way I know of, even by ordering the peasant to attack units in the area of the quarry, it still crashes.
any kind of help would be greatly appreciated, I'm new here so I'm sorry if this is in the wrong section of the forum, if it is, let me know.
Thank you
[Overview of the trigger]
-What I am trying to create, is a system which will allow peasants to mine various resources, not just gold and wood.
What I've done is created a system based on items, rather than the ui, for example, the stone resource is counted by the integer variable "stone"
and whenever a peasant strikes a quarry, a grey "+8" appears above his head, and the variable gains an additional 8, all buildings which use stone gain an additional +8 charges to their stone item. this all works fine, and is not causing problems, however...
[The problem]
-What I really want, in order to make the system more lifelike, not too mention, a lot like blizzards, however, The units will just stay in one place, hacking away at the stone, with numbers above their heads. what I really need is for the peasants to go back and forth between the closest town hall and the quarry. I have the idea wrapped up, with the peasants getting the item and its charges and giving it to the building, though here is where the real problem arises, the game crashes when ordered by a trigger to attack the quarry (I don't use harvest in this case, they attack the stone and get the item)
[What I need]
I desperately need two problems fixed here, the first being a way to order the peasant to attack the quarry when the player right clicks on it when selected, the second being a way for the peasant to repeat his harvesting routine when he completes it.
I can't give you the exact trigger at the moment, as I am away from the computer I work on the project with, though I think I know the source of the problem;
there is an action which reads something like this:
order(ordered unit) to attack (target of order)
the crash seems to originate from here, though I cant get the quarry to become the target in any other way I know of, even by ordering the peasant to attack units in the area of the quarry, it still crashes.
any kind of help would be greatly appreciated, I'm new here so I'm sorry if this is in the wrong section of the forum, if it is, let me know.
Thank you